Page 2 of 2 FirstFirst 12
Results 11 to 16 of 16
  1. #11
    Join Date
    Feb 2013
    Posts
    332
    Plugin Contributions
    0

    Default Re: Error in advanced search page.

    Quote Originally Posted by mc12345678 View Post
    Why an integer rather than a floating point number or a determination of if it is set or not to then determine a value against which to calculate? Won't forcing either the provided value or the calculated value to an integer cause a sort of "rounding" issue? 24.99 set to an integer would result in 24, 24.99/10 set to an integer would result in 2 instead of 2.50 or 2.499...
    I changed the coding to this:
    HTML Code:
    $rate = $currencies->get_value($_SESSION['currency']);
    if ($rate) {
      $pfrom = (int) $_GET['pfrom'] / $rate;
      $pto = (int) $_GET['pto'] / $rate;
    }
    now i can't add anything to my cart - so i'm changing it back now. is that the correct coding?

  2. #12
    Join Date
    Feb 2013
    Posts
    332
    Plugin Contributions
    0

    Default Re: Error in advanced search page.

    Quote Originally Posted by lidlchris View Post
    I changed the coding to this:
    HTML Code:
    $rate = $currencies->get_value($_SESSION['currency']);
    if ($rate) {
      $pfrom = (int) $_GET['pfrom'] / $rate;
      $pto = (int) $_GET['pto'] / $rate;
    }
    now i can't add anything to my cart - so i'm changing it back now. is that the correct coding?
    i changed the coding back to the original and still can't add anything to my cart.. not sure what's happening as this is probably why we haven't gotten an order in weeks. the error log in the /logs folder show no errors with the (int) coding nor without it.

  3. #13
    Join Date
    Jul 2012
    Posts
    13,112
    Plugin Contributions
    16

    Default Re: Error in advanced search page.

    Quote Originally Posted by lidlchris View Post
    would i use (float) instead of (int)
    As implemented in Zen Cart 1.5.f, yes, would use (float) at that location.
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...
    Upgraded to Zen Cart V1.5.3 from V1.5.1 from V1.5.0 from V1.3.9h

  4. #14
    Join Date
    Jul 2012
    Posts
    13,112
    Plugin Contributions
    16

    Default Re: Error in advanced search page.

    The site is suffering from a series of mixed content. There is an htaccess rewrite forcing every page to show up as https:; however, the store is not configured to use https consistently. This stems primarily from following direction where the problem was described as receiving a blank screen rather than stating something like when attempting to add a product that told that the cart is empty...

    Big difference.

    The logged error going away is because the associated problem did go away but by using (int) instead of (float) a more logic error was generated rather than a "file" error.
    ZC Installation/Maintenance Support <- Site
    Contribution for contributions welcome...
    Upgraded to Zen Cart V1.5.3 from V1.5.1 from V1.5.0 from V1.3.9h

  5. #15
    Join Date
    Feb 2013
    Posts
    332
    Plugin Contributions
    0

    Default Re: Error in advanced search page.

    Quote Originally Posted by mc12345678 View Post
    The site is suffering from a series of mixed content. There is an htaccess rewrite forcing every page to show up as https:; however, the store is not configured to use https consistently. This stems primarily from following direction where the problem was described as receiving a blank screen rather than stating something like when attempting to add a product that told that the cart is empty...

    Big difference.

    The logged error going away is because the associated problem did go away but by using (int) instead of (float) a more logic error was generated rather than a "file" error.
    now i'm really lost. i was told to add that htaccess by someone on here and YES the problem at the time was a blank screen. The 'can't add to cart' didn't start until after December 3rd. THe mixed content you talk about i'm assuming is the fact that there are a number of add-ons for this site??

    by 'logical' error, what do you mean? it won't show up on the error log file? How would i go about debugging the fact that i can't anything to cart if there are no errors??

  6. #16
    Join Date
    Jan 2004
    Posts
    65,014
    Blog Entries
    7
    Plugin Contributions
    222

    Default Re: Error in advanced search page.

    Here's how v1.5.6 changed that section of code (note, the line numbers still don't match yours, probably because other parts of your file have been changed):
    https://github.com/zencart/zencart/b....php#L371-L382
    .

    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.

 

 
Page 2 of 2 FirstFirst 12

Similar Threads

  1. Replies: 1
    Last Post: 5 Sep 2014, 01:05 PM
  2. Replies: 10
    Last Post: 4 Oct 2010, 11:08 PM
  3. Replies: 5
    Last Post: 20 Apr 2010, 12:54 PM
  4. Remove 'Search by Date Added' field from advanced search page?
    By gaffettape in forum General Questions
    Replies: 7
    Last Post: 24 Jan 2010, 03:34 PM
  5. How to align search criteria boxes on advanced search page?
    By shinyadornments in forum Basic Configuration
    Replies: 1
    Last Post: 29 Jan 2008, 06:36 AM

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