Page 159 of 351 FirstFirst ... 59109149157158159160161169209259 ... LastLast
Results 1,581 to 1,590 of 3501
  1. #1581
    Join Date
    May 2006
    Location
    Montana
    Posts
    291
    Plugin Contributions
    20

    Default Re: EasyPopulate 4.0 Support Thread

    EP4 FATAL ERROR: No default language set. Table: languages Code: en is set

    Above is the new error after making the change

    Quote Originally Posted by mc12345678 View Post
    In the file YOUR_ADMIN/easypopulate_4.php at line 177 that reads:

    Code:
    exit("EP4 FATAL ERROR: No default language set."); // this should never happen
    Change to read:

    Code:
    exit("EP4 FATAL ERROR: No default language set. Table: ".TABLE_LANGUAGES." Code: ".DEFAULT_LANGUAGE." is set" ); // this should never happen
    And please repost the resulting error message.

  2. #1582
    Join Date
    Jul 2012
    Posts
    16,521
    Plugin Contributions
    17

    Default Re: EasyPopulate 4.0 Support Thread

    Quote Originally Posted by stellarweb View Post
    EP4 FATAL ERROR: No default language set. Table: languages Code: en is set

    Above is the new error after making the change
    Try this if you wouldn't mind after line 171, add the following:
    Code:
    $epdlanguage_query->store_result();
    Ie:between these two lines:

    Code:
    $epdlanguage_query = ep_4_query("SELECT languages_id, name FROM ".TABLE_LANGUAGES." WHERE code = '".DEFAULT_LANGUAGE."'");
    if (($ep_uses_mysqli ? mysqli_num_rows($epdlanguage_query) : mysql_num_rows($epdlanguage_query))) {
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  3. #1583
    Join Date
    May 2006
    Location
    Montana
    Posts
    291
    Plugin Contributions
    20

    Default Re: EasyPopulate 4.0 Support Thread

    Done

    Now get blank white page. Error log generated as follows

    [21-Aug-2014 12:06:11 America/Denver] PHP Warning: mysqli_query() expects parameter 1 to be mysqli, resource given in /home3/beadins1/public_html/bI1544+/includes/functions/extra_functions/easypopulate_4_functions.php on line 990
    [21-Aug-2014 12:06:11 America/Denver] PHP Warning: mysqli_errno() expects parameter 1 to be mysqli, resource given in /home3/beadins1/public_html/bI1544+/includes/functions/extra_functions/easypopulate_4_functions.php on line 991
    [21-Aug-2014 12:06:11 America/Denver] PHP Warning: mysqli_fetch_array() expects parameter 1 to be mysqli_result, null given in /home3/beadins1/public_html/bI1544+/includes/functions/extra_functions/easypopulate_4_functions.php on line 895
    [21-Aug-2014 12:06:11 America/Denver] PHP Warning: mysqli_query() expects parameter 1 to be mysqli, resource given in /home3/beadins1/public_html/bI1544+/includes/functions/extra_functions/easypopulate_4_functions.php on line 990
    [21-Aug-2014 12:06:11 America/Denver] PHP Warning: mysqli_errno() expects parameter 1 to be mysqli, resource given in /home3/beadins1/public_html/bI1544+/includes/functions/extra_functions/easypopulate_4_functions.php on line 991
    [21-Aug-2014 12:06:11 America/Denver] PHP Warning: mysqli_fetch_array() expects parameter 1 to be mysqli_result, null given in /home3/beadins1/public_html/bI1544+/includes/functions/extra_functions/easypopulate_4_functions.php on line 895
    [21-Aug-2014 12:06:11 America/Denver] PHP Warning: mysqli_query() expects parameter 1 to be mysqli, resource given in /home3/beadins1/public_html/bI1544+/includes/functions/extra_functions/easypopulate_4_functions.php on line 990
    [21-Aug-2014 12:06:11 America/Denver] PHP Warning: mysqli_errno() expects parameter 1 to be mysqli, resource given in /home3/beadins1/public_html/bI1544+/includes/functions/extra_functions/easypopulate_4_functions.php on line 991
    [21-Aug-2014 12:06:11 America/Denver] PHP Warning: mysqli_fetch_array() expects parameter 1 to be mysqli_result, null given in /home3/beadins1/public_html/bI1544+/includes/functions/extra_functions/easypopulate_4_functions.php on line 895
    [21-Aug-2014 12:06:11 America/Denver] PHP Warning: mysqli_query() expects parameter 1 to be mysqli, resource given in /home3/beadins1/public_html/bI1544+/includes/functions/extra_functions/easypopulate_4_functions.php on line 990
    [21-Aug-2014 12:06:11 America/Denver] PHP Warning: mysqli_errno() expects parameter 1 to be mysqli, resource given in /home3/beadins1/public_html/bI1544+/includes/functions/extra_functions/easypopulate_4_functions.php on line 991
    [21-Aug-2014 12:06:11 America/Denver] PHP Warning: mysqli_fetch_array() expects parameter 1 to be mysqli_result, null given in /home3/beadins1/public_html/bI1544+/includes/functions/extra_functions/easypopulate_4_functions.php on line 895
    [21-Aug-2014 12:06:11 America/Denver] PHP Warning: mysqli_query() expects parameter 1 to be mysqli, resource given in /home3/beadins1/public_html/bI1544+/includes/functions/extra_functions/easypopulate_4_functions.php on line 990
    [21-Aug-2014 12:06:11 America/Denver] PHP Warning: mysqli_errno() expects parameter 1 to be mysqli, resource given in /home3/beadins1/public_html/bI1544+/includes/functions/extra_functions/easypopulate_4_functions.php on line 991
    [21-Aug-2014 12:06:11 America/Denver] PHP Warning: mysqli_fetch_array() expects parameter 1 to be mysqli_result, null given in /home3/beadins1/public_html/bI1544+/includes/functions/extra_functions/easypopulate_4_functions.php on line 895
    [21-Aug-2014 12:06:11 America/Denver] PHP Warning: mysqli_query() expects parameter 1 to be mysqli, resource given in /home3/beadins1/public_html/bI1544+/includes/functions/extra_functions/easypopulate_4_functions.php on line 990
    [21-Aug-2014 12:06:11 America/Denver] PHP Warning: mysqli_errno() expects parameter 1 to be mysqli, resource given in /home3/beadins1/public_html/bI1544+/includes/functions/extra_functions/easypopulate_4_functions.php on line 991
    [21-Aug-2014 12:06:11 America/Denver] PHP Warning: mysqli_fetch_array() expects parameter 1 to be mysqli_result, null given in /home3/beadins1/public_html/bI1544+/includes/functions/extra_functions/easypopulate_4_functions.php on line 895
    [21-Aug-2014 12:06:11 America/Denver] PHP Warning: mysqli_query() expects parameter 1 to be mysqli, resource given in /home3/beadins1/public_html/bI1544+/includes/functions/extra_functions/easypopulate_4_functions.php on line 990
    [21-Aug-2014 12:06:11 America/Denver] PHP Warning: mysqli_errno() expects parameter 1 to be mysqli, resource given in /home3/beadins1/public_html/bI1544+/includes/functions/extra_functions/easypopulate_4_functions.php on line 991
    [21-Aug-2014 12:06:11 America/Denver] PHP Warning: mysqli_fetch_array() expects parameter 1 to be mysqli_result, null given in /home3/beadins1/public_html/bI1544+/includes/functions/extra_functions/easypopulate_4_functions.php on line 895
    [21-Aug-2014 12:06:11 America/Denver] PHP Warning: mysqli_character_set_name() expects parameter 1 to be mysqli, resource given in /home3/beadins1/public_html/bI1544+/easypopulate_4.php on line 138
    [21-Aug-2014 12:06:11 America/Denver] PHP Warning: mysqli_query() expects parameter 1 to be mysqli, resource given in /home3/beadins1/public_html/bI1544+/includes/functions/extra_functions/easypopulate_4_functions.php on line 990
    [21-Aug-2014 12:06:11 America/Denver] PHP Warning: mysqli_errno() expects parameter 1 to be mysqli, resource given in /home3/beadins1/public_html/bI1544+/includes/functions/extra_functions/easypopulate_4_functions.php on line 991
    [21-Aug-2014 12:06:11 America/Denver] PHP Fatal error: Call to a member function store_result() on a non-object in /home3/beadins1/public_html/bI1544+/easypopulate_4.php on line 172


    Quote Originally Posted by mc12345678 View Post
    Try this if you wouldn't mind after line 171, add the following:
    Code:
    $epdlanguage_query->store_result();
    Ie:between these two lines:

    Code:
    $epdlanguage_query = ep_4_query("SELECT languages_id, name FROM ".TABLE_LANGUAGES." WHERE code = '".DEFAULT_LANGUAGE."'");
    if (($ep_uses_mysqli ? mysqli_num_rows($epdlanguage_query) : mysql_num_rows($epdlanguage_query))) {

  4. #1584
    Join Date
    Jul 2012
    Posts
    16,521
    Plugin Contributions
    17

    Default Re: EasyPopulate 4.0 Support Thread

    Ami correct that the three lines read:

    Code:
    $epdlanguage_query = ep_4_query("SELECT languages_id, name FROM ".TABLE_LANGUAGES." WHERE code = '".DEFAULT_LANGUAGE."'");
    $epdlanguage_query->store_result();
    if (($ep_uses_mysqli ? mysqli_num_rows($epdlanguage_query) : mysql_num_rows($epdlanguage_query))) {
    In that sequence?

    Here's what I have found regarding the way this has gone. Prior to the use of mysqli_, it seems that although possible, not as frequent that the returned data would be unbuffered and therefore when a function such as num_rows was called, the value returned would either be 0 (unbuffered) or the number of rows that actually exist(ed). It appears that the two reported occurrences of this have been more of the result of the return of zero rows even though the data could be enumerated. I have two alternative tests I'm working on for you to try which may need to happen in the functions file or in the main base file. The above error list is similar to what I observed when updating EP4 to work under ZC 1.5.3. Though I want to be sure that the above code is in the correct sequence before continuing down that alternative path. Also, wanted to verify that the test(s) that were requested in the original notification of this problem were also run with equivalent results. (Ie, verification that performing the sql query in myphpadmin had a successful result.)

    Some of the next "solution" is to identify in how many places the additional "correction" would be needed. I thought that the num_rows function was only used the one time and all other actions were based on straight forward pull and check type routines, not necessarily a "hey how many" type call.
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  5. #1585
    Join Date
    May 2006
    Location
    Montana
    Posts
    291
    Plugin Contributions
    20

    Default Re: EasyPopulate 4.0 Support Thread

    Lines 171 to 180

    $epdlanguage_query = ep_4_query("SELECT languages_id, name FROM ".TABLE_LANGUAGES." WHERE code = '".DEFAULT_LANGUAGE."'");
    $epdlanguage_query->store_result();
    if (($ep_uses_mysqli ? mysqli_num_rows($epdlanguage_query) : mysql_num_rows($epdlanguage_query))) {
    $epdlanguage = ($ep_uses_mysqli ? mysqli_fetch_array($epdlanguage_query) : mysql_fetch_array($epdlanguage_query));
    $epdlanguage_id = $epdlanguage['languages_id'];
    $epdlanguage_name = $epdlanguage['name'];
    } else {
    //exit("EP4 FATAL ERROR: No default language set."); // this should never happen
    exit("EP4 FATAL ERROR: No default language set. Table: ".TABLE_LANGUAGES." Code: ".DEFAULT_LANGUAGE." is set" ); // this should never happen
    }

    Quote Originally Posted by mc12345678 View Post
    Ami correct that the three lines read:

    Code:
    $epdlanguage_query = ep_4_query("SELECT languages_id, name FROM ".TABLE_LANGUAGES." WHERE code = '".DEFAULT_LANGUAGE."'");
    $epdlanguage_query->store_result();
    if (($ep_uses_mysqli ? mysqli_num_rows($epdlanguage_query) : mysql_num_rows($epdlanguage_query))) {
    In that sequence?

    Here's what I have found regarding the way this has gone. Prior to the use of mysqli_, it seems that although possible, not as frequent that the returned data would be unbuffered and therefore when a function such as num_rows was called, the value returned would either be 0 (unbuffered) or the number of rows that actually exist(ed). It appears that the two reported occurrences of this have been more of the result of the return of zero rows even though the data could be enumerated. I have two alternative tests I'm working on for you to try which may need to happen in the functions file or in the main base file. The above error list is similar to what I observed when updating EP4 to work under ZC 1.5.3. Though I want to be sure that the above code is in the correct sequence before continuing down that alternative path. Also, wanted to verify that the test(s) that were requested in the original notification of this problem were also run with equivalent results. (Ie, verification that performing the sql query in myphpadmin had a successful result.)

    Some of the next "solution" is to identify in how many places the additional "correction" would be needed. I thought that the num_rows function was only used the one time and all other actions were based on straight forward pull and check type routines, not necessarily a "hey how many" type call.

  6. #1586
    Join Date
    Jul 2012
    Posts
    16,521
    Plugin Contributions
    17

    Default Re: EasyPopulate 4.0 Support Thread

    Quote Originally Posted by stellarweb View Post
    Lines 171 to 180

    $epdlanguage_query = ep_4_query("SELECT languages_id, name FROM ".TABLE_LANGUAGES." WHERE code = '".DEFAULT_LANGUAGE."'");
    $epdlanguage_query->store_result();
    if (($ep_uses_mysqli ? mysqli_num_rows($epdlanguage_query) : mysql_num_rows($epdlanguage_query))) {
    $epdlanguage = ($ep_uses_mysqli ? mysqli_fetch_array($epdlanguage_query) : mysql_fetch_array($epdlanguage_query));
    $epdlanguage_id = $epdlanguage['languages_id'];
    $epdlanguage_name = $epdlanguage['name'];
    } else {
    //exit("EP4 FATAL ERROR: No default language set."); // this should never happen
    exit("EP4 FATAL ERROR: No default language set. Table: ".TABLE_LANGUAGES." Code: ".DEFAULT_LANGUAGE." is set" ); // this should never happen
    }
    Two different thoughts for solution...
    Okay, try removing the new line 172 from admin/easypopulate_4.php
    And add in admin/includes/functions/extra_functions/easypopulate_4_functions.php at line x:

    Code:
    $result = ($ep_uses_mysqli ? mysqli_query($db->link, $query, MYSQLI_STORE_RESULT) : mysql_query($query));
    The other thing I can think of trying is to still remove 172 in the above file, then replace the if statement that follows with:the below and comment out the line that follows that.

    Code:
    if (($epdlanguage = ($ep_uses_mysqli ? mysqli_fetch_array($epdlanguage_query) : mysql_fetch_array($epdlanguage_query)))) {
    //$epdlanguage = ($ep_uses_mysqli ? mysqli_fetch_array($epdlanguage_query) : mysql_fetch_array($epdlanguage_query));
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  7. #1587
    Join Date
    Jul 2012
    Posts
    16,521
    Plugin Contributions
    17

    Default Re: EasyPopulate 4.0 Support Thread

    A third option if the first aabove is a no go is to place a line at 991 og the functions file, similar to what was added in line 172 in the main file with the appropriate variable substitution.

    This would be something instead of 1 or 2. So suggesting to implement only one of these three at a time for now.

    My reasoning behind all this is the following.

    The query function is supposed to default to the store option suggested in the first option; however, it is possible that this version of php on the host could have something incorrectly configured/compiled and does not default to that constant. Next is that the constant could be incorrectly assigned and not accounted for in the query function. If so, the first option above won't resolve the issue. The second option above is suggested in the event that the query is coming back with a result, but the num_rows function isn't returning a value until either the result has been completely stepped through, or a result has been tested, so the second modification should identify if the query returned with something because if it did then the language should be assigned in the if statement. If the query comes back with more than one result, well we rent worried about that and justuse the first returned result. The third revision identified in this post is to further account for the reason(s) why the first option was unsuccessful and to force the action of storing the result, but doing so while the result is still in memory, where the previous attempt at line 172 may have been performed when the data was already lost.

    Unfortunately, the environment(s) in which this has been tested have not produced the troubled results seen by the two of you.
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  8. #1588
    Join Date
    Jul 2012
    Posts
    16,521
    Plugin Contributions
    17

    Default Re: EasyPopulate 4.0 Support Thread

    The next thing I can see to do is to look through the ZC code for the db class and see how queries under mysqli_ style calls are handled. It may be that some query preparation needs to be performed although it appears that none of the data into EP4 really is subject to malicious action. Hmm, maybe the query in line 171 where the single quotes are used need to be escaped for the query to work? Or the single quotes removed from around the returned variable(s). Although I had already suggested hard coding the query (not using variables) to see if that would be successful, not directly to you, but as an attempted solution.)

    Not being able to reproduce the issue makes it difficult to suggest solutions. Between the time of it working and now when it doesn't, nothing was added to the cart code? No template changes? Anything that could cause something to load as a part of kicking off the code that could interfere or modify the expected response(s) of the system?
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

  9. #1589
    Join Date
    May 2006
    Location
    Montana
    Posts
    291
    Plugin Contributions
    20

    Default Re: EasyPopulate 4.0 Support Thread

    I tried the second solution - still the same problem.

    Please know I am not a coder, nor do I play one on TV so I do not know what you mean by the "line x" in the following statement:

    "And add in admin/includes/functions/extra_functions/easypopulate_4_functions.php at line x:"

    Quote Originally Posted by mc12345678 View Post
    Two different thoughts for solution...
    Okay, try removing the new line 172 from admin/easypopulate_4.php
    And add in admin/includes/functions/extra_functions/easypopulate_4_functions.php at line x:

    Code:
    $result = ($ep_uses_mysqli ? mysqli_query($db->link, $query, MYSQLI_STORE_RESULT) : mysql_query($query));
    The other thing I can think of trying is to still remove 172 in the above file, then replace the if statement that follows with:the below and comment out the line that follows that.

    Code:
    if (($epdlanguage = ($ep_uses_mysqli ? mysqli_fetch_array($epdlanguage_query) : mysql_fetch_array($epdlanguage_query)))) {
    //$epdlanguage = ($ep_uses_mysqli ? mysqli_fetch_array($epdlanguage_query) : mysql_fetch_array($epdlanguage_query));

  10. #1590
    Join Date
    Jul 2012
    Posts
    16,521
    Plugin Contributions
    17

    Default Re: EasyPopulate 4.0 Support Thread

    Quote Originally Posted by stellarweb View Post
    I tried the second solution - still the same problem.

    Please know I am not a coder, nor do I play one on TV so I do not know what you mean by the "line x" in the following statement:

    "And add in admin/includes/functions/extra_functions/easypopulate_4_functions.php at line x:"
    Oops, sorry that line was supposed to be changed to modify line 990 to read like the code that was suggested in the line above.

    You're doing well. With regards to making the change using option 2 above, was the result still that no language was defined?
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...

 

 

Similar Threads

  1. Hebrew Support - latest release [Support Thread]
    By eranariel in forum Addon Language Packs
    Replies: 19
    Last Post: 23 Jan 2023, 08:04 AM
  2. BackUp ZC [Support Thread]
    By skipwater in forum All Other Contributions/Addons
    Replies: 285
    Last Post: 23 Dec 2020, 10:40 AM
  3. Wordpress On ZC [Support Thread]
    By hira in forum All Other Contributions/Addons
    Replies: 1858
    Last Post: 17 Jan 2014, 01:24 AM
  4. ZJ Black 2 support thread
    By Liamv in forum Addon Templates
    Replies: 1
    Last Post: 15 Feb 2010, 02:53 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR