Page 1 of 3 123 LastLast
Results 1 to 10 of 22
  1. #1
    Join Date
    Jan 2007
    Posts
    143
    Plugin Contributions
    0

    Default WARNING: An Error occurred, please refresh the page and try again (tried the fix)

    Hi,
    I accessed options_values_manager.php with no problem searched back and forwards between pages, deleted one option fine and when I went to rename another option I got a WARNING: An Error occurred, please refresh the page and try again.

    Now that error is all I get on attributes controller, option names manager, option values manager.

    I have tried the fix on http://www.zen-cart.com/showthread.p...25#post1154025 with no lucky.

    I was deleting options in the attributes controller only a few weeks ago with no problems, nothing added or changed since then.

    Website www.anythingframed.co.uk

    Current version 1.5.1

    Fresh install was 1.3.6 FTP and was upgraded to 1.3.7, 1.3.8, 1.3.9h, 1.5.0 and 1.5.1

    Sadly the upgrade (last year) from 1.3.9h to 1.5.0 was done by someone on odesk (big mistake, big nightmare).

    Used to have the old newsletter subscribe addon.

    Have installed, tabbed products pro, Testimonials Manager, Recaptcha Settings, Sitemap XML.

    It was never requested but added and turned off Ceon URI Mapping (SEO)

    Error log
    PHP Fatal error: 1064:You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'int)PRODUCTS_OPTIONS_VALUES_TEXT_ID, 1, 'TEXT')' at line 1 :: INSERT INTO products_options_values (products_options_values_id, language_id, products_options_values_name) VALUES ((int)PRODUCTS_OPTIONS_VALUES_TEXT_ID, 1, 'TEXT') in /home/sites/anythingframed.co.uk/public_html/includes/classes/db/mysql/query_factory.php on line 120

  2. #2
    Join Date
    Jan 2004
    Posts
    66,373
    Blog Entries
    7
    Plugin Contributions
    274

    Default Re: WARNING: An Error occurred, please refresh the page and try again (tried the fix)

    If you're *still* getting that error then you didn't apply the fix you said you did.
    http://www.zen-cart.com/showthread.p...25#post1154025
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  3. #3
    Join Date
    Jan 2007
    Posts
    143
    Plugin Contributions
    0

    Default Re: WARNING: An Error occurred, please refresh the page and try again (tried the fix)

    Thank you for your reply.

    I have downloaded the 3 files in question and compared them to the 3 files from the fix folder and they are identical.

    Back to scratching my head, can't understand how it works one minute but the next minute errors.

    been using zencart since 2007 so i'm no newbie and have searched and read a lot of other posts before posting this.

  4. #4
    Join Date
    Jan 2004
    Posts
    66,373
    Blog Entries
    7
    Plugin Contributions
    274

    Default Re: WARNING: An Error occurred, please refresh the page and try again (tried the fix)

    Quote Originally Posted by Woody619 View Post
    Error log
    PHP Fatal error: 1064:You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'int)PRODUCTS_OPTIONS_VALUES_TEXT_ID, 1, 'TEXT')' at line 1 :: INSERT INTO products_options_values (products_options_values_id, language_id, products_options_values_name) VALUES ((int)PRODUCTS_OPTIONS_VALUES_TEXT_ID, 1, 'TEXT') in /home/sites/anythingframed.co.uk/public_html/includes/classes/db/mysql/query_factory.php on line 120
    While I understand that you say you changed it, if the errors you're STILL getting are indeed still the same as what you posted above, then you've not applied the fix, else the error message would be different.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  5. #5
    Join Date
    Jan 2007
    Posts
    143
    Plugin Contributions
    0

    Default Re: WARNING: An Error occurred, please refresh the page and try again (tried the fix)

    again thank you so much for your reply.

    the error log now
    [08-Aug-2013 17:37:01] PHP Fatal error: 1062: Duplicate entry '0-1' for key 'PRIMARY' :: INSERT INTO products_options_values (products_options_values_id, language_id, products_options_values_name) VALUES (0, 1, 'TEXT') in /home/sites/anythingframed.co.uk/public_html/includes/classes/db/mysql/query_factory.php on line 120

  6. #6
    Join Date
    Jan 2004
    Posts
    66,373
    Blog Entries
    7
    Plugin Contributions
    274

    Default Re: WARNING: An Error occurred, please refresh the page and try again (tried the fix)

    The quick fix for that is (if I recall correctly) discussed in the thread that's linked in the post you quoted. Ajeh outlines the process. I'll summarize it here: find that products_option_values table in phpMyAdmin, and delete the records whose values are 0, 1, 'TEXT' already. After that the PHP code should work okay again.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  7. #7
    Join Date
    Jan 2007
    Posts
    143
    Plugin Contributions
    0

    Default Re: WARNING: An Error occurred, please refresh the page and try again (tried the fix)

    Excellent thank you very much, working now.

    Just had to delete a 0 value in products_option_values table in phpMyAdmin.

  8. #8
    Join Date
    Jun 2009
    Posts
    86
    Plugin Contributions
    0

    Default Re: WARNING: An Error occurred, please refresh the page and try again (tried the fix)

    After applying this fix, I am having a strange issue when trying to apply an option value.

    Scenario:
    When selecting option names from the admin menu, upon loading the page, zen cart follows the code replaced by this fix, and displays what would be the next product name id in the first column of the table along the insert line, in my case, i have 20 option names, the number displays 21.
    NOTE: This does not write to the table! I refreshed it several times going between this page and any other in the admin side.

    When selecting option values from the admin menu, upon loading, zen cart follows the code replace by the fix for that code, and displays what should be the next option value, however, in the product value id, it displays 319, I only have 110? for some reason, it jumps 200+ id numbers.
    NOTE: This DOES write to the database! It keeps the number in the database unlike the product options names. Navigating away and back, writes another entry.

    So when you click insert, of course it fails with a duplicate record of 319 or what ever the last number it incremented to.
    I just cant figure out where it is getting the 200+ jump in ids from?
    Any help appreciated.
    Jeff

  9. #9
    Join Date
    Jun 2009
    Posts
    86
    Plugin Contributions
    0

    Default Re: WARNING: An Error occurred, please refresh the page and try again (tried the fix)

    So rimming out this section, line 28 in options_value_manager.php is seeming to work, it no longer inserts the lines in the database when switching to and from the pages.
    for ($i=0, $n=sizeof($languages); $i<$n; $i ++) {
    if ((int)$languages[$i]['id'] > 0 && !in_array((int)$languages[$i]['id'], $ary)) {
    // $db->Execute("INSERT INTO products_options_values (products_options_values_id, language_id, products_options_values_name) VALUES ((int)PRODUCTS_OPTIONS_VALUES_TEXT_ID, " . (int)$languages[$i]['id'] . ", 'TEXT')");
    //$db->Execute("INSERT INTO " . TABLE_PRODUCTS_OPTIONS_VALUES . " (products_options_values_id, language_id, products_options_values_name) VALUES (" . (int)PRODUCTS_OPTIONS_VALUES_TEXT_ID . ", " . (int)$languages[$i]['id'] . ", 'TEXT')");
    }
    }
    I know this is not the proper fix but it works for now, any help would be appreciated.
    Jeff

  10. #10
    Join Date
    Apr 2008
    Location
    Lindenwood, Illinois
    Posts
    27
    Plugin Contributions
    2

    Default Re: WARNING: An Error occurred, please refresh the page and try again (tried the fix)

    zen 1.5.1 linux refresh install ftp

    adding attribute values cause error on product page. products show in category listing but getting error on product detail page. removing all attributes corrects problem.

 

 
Page 1 of 3 123 LastLast

Similar Threads

  1. v154 WARNING: An Error occurred, please refresh the page and try again.
    By TruePCs in forum General Questions
    Replies: 2
    Last Post: 21 Jun 2016, 12:35 AM
  2. WARNING: An Error occurred, please refresh the page and try again.
    By kkjoseph in forum Customization from the Admin
    Replies: 10
    Last Post: 17 May 2013, 06:58 PM
  3. v151 Warning: An Error occurred, please refresh the page and try again...
    By Sellerz in forum Installing on a Windows Server
    Replies: 2
    Last Post: 4 Nov 2012, 03:12 AM
  4. v150 WARNING: An Error occurred, please refresh the page and try again.
    By jo54iv in forum General Questions
    Replies: 2
    Last Post: 30 Apr 2012, 05:34 AM
  5. v150 WARNING: An Error occurred, please refresh the page and try again
    By ccn1 in forum Discounts/Coupons, Gift Certificates, Newsletters, Ads
    Replies: 1
    Last Post: 9 Apr 2012, 06:48 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