tomsskline
Forum Replies Created
-
in common_functions.php locate this line:
foreach ($Listings as $Listings) {
and then right above that line add this line:
$i = 0;
then below the line:
foreach ($Listings as $Listings) {
add this line:
$i++ ;
then find this line:
$PageContent .= '<div style="clear: both;"></div>';
and right below that line add this line:
if($i >= 40) break;
Now that does not add pagination, but it does allow you to limit the number of listings that display. If you wanted to display 30 listings, change 40 to 30. If you want to display 20 listings change 40 to 20 etc.
I will get the pagination figured out. But it will take a little while longer. The break statement is a temp fix. FWIW, this plugin is a hacked down version of the firestorm e-commerce plugin; which does include pagination. It appears they are using the Real Estate plugin to troll for paying customers.
Hey coolizard … I can feel you on the pagination and the other work you did. I spent many, many hours on this one. I managed to fix many errors in the plugin and extended it quite a bit. Added some more tables, restructered much of it and changed the listings display also. I added another status, another listings page for a different category, dozens of more options, enhanced admin pages, etc. Even though I did not come up with a workable pagination solution, I ended up using a break to limit the number of listings displayed. This is not a complete fix, but it is a possible workaround. One bonus is that the Google Map will show markers for all the listings, plus, with the search widget (which I modified somewhat) it still allows users to search for additional listings or click on a marker to see any of the listings. What I did was I limited the listings to 40 and changed the way they were ordered to last_updated. This way, if I want to change which listings are displayed, I simply update the listings so I get the ones I want displayed to show up on the list or more specifically, at the top of the list. Also, I have two feature sliders and a rotator I incorporated on different pages. (This is a custom theme I built for this site) With a break statement you could limit the listings displayed to 10, 20, 30, 40, 50 etc. Since I added another thumb size of 30×30 for the listings page, and limited the content displayed and edited the css, I can fit 40 listings on a page and it fits fine. FWIW, I believe the pagination along with many other parts of the plugin are intentionally missing. For the average person, if you cannot get the plugin to work, there is a chance you will pay the developer to provide the code that was intentionally left out. Out of the box, it will not work for a live site. However, with some extensive reworking, and a bunch of mental sweat equity you can have a plugin that will work … although it is not the plugin that we downloaded.