srorecords Posted October 8, 2013 Posted October 8, 2013 Hi folks, Trying to get our countries that we ship to together, but they only list 4 at a time, despite it stating it "Displaying 1 to 50 (of 227 countries)" - still only lists 4 on each page... Not a browser rendering issue, viewing source also indicates only 4 are being displayed... Can anyone tell me what might be going on? Thank you! Jeff
MrPhil Posted October 8, 2013 Posted October 8, 2013 Hmm. 5 pages would be right for 227 entries. If you go to page 2, is it the next after Bahamas (Bahrain?), number 5, or is it number 51 on the country list? Do other pages show only 4 entries?
srorecords Posted October 8, 2013 Author Posted October 8, 2013 Yes, each page only lists 4. It says it's listing 50 on each page, but only delivering 4.
MrPhil Posted October 8, 2013 Posted October 8, 2013 So it is showing the first 20 countries over 5 pages. I will try to take a look at it tonight when I get home, unless this cold completely knocks me out before then :( .
srorecords Posted October 8, 2013 Author Posted October 8, 2013 Feel better! I just figured it out; the search results in Search Results and Category Listing was set to "4", is that default? That was odd, to say the leastFeel better! I just figured it out; the search results in Search Results and Category Listing was set to "4", is that default? That was odd, to say the least... Thanks for looking! Once more question, off the beaten path of the subject here: we just enabled the "Our Social in Footer" in \Modules\Boxes\Our Social in Footer - Where do we put our specific info, our facebook namce, etc..."
MrPhil Posted October 8, 2013 Posted October 8, 2013 Thanks. I'll still try to take a look at it, because it sounds like conflicting parameters -- one is saying "4 at a time" and the other is saying "50 at a time", and the latter is being used to figure the number of pages (ceil(227/50) => 5 pages, ceil(227/4) => 57 pages), while the former is used to calculate the starting point and items per page. If anyone else is looking for something to do in the next 7 hours or so, feel free to dive in and spare me the effort.
MrPhil Posted October 9, 2013 Posted October 9, 2013 I can't see anything in the standard code that would exhibit this behavior, which suggests that your code has been improperly edited. You might at least compare catalog/admin/includes/classes/split_page_results.php against a clean copy, and see if there are any differences. The code uses MAX_DISPLAY_SEARCH_RESULTS (title: "Search Results"/"Amount of products to list"), which defaults to 20 per page (it's in the database). Even if you changed it to 4, the code still should have given you 57 pages of 4 countries each (page 1: 1-4, page 2: 5-8, etc.). The pages you show are suggesting that it's partly using 50 per page, which is why I would suggest looking at split_page_results.php first. You haven't changed the code in catalog/admin/countries.php, have you? split-pages is counting on making some exact matches in the SQL query string passed to it (e.g., " from", not " FROM").
Recommended Posts
Archived
This topic is now archived and is closed to further replies.