![]() |
Show more than one 'random product' on /reviews/index.php? How do I show more than one 'random product' on /reviews/index.php? I can't see a field to add a vlue for this in the config so is it only one? I've had a look at the feature.tmpl template that generates the code for that block but can't make sense of what portions of the code I need to copy / amend to have more than just one product showing up - but I can't make sense of it. |
In your sidebar templates change the number in black Code: Content visible to verified customers only. |
Thanks for the speedy reply Chuck. In v3.31 those lines in the relevant templates are shown below - they show three numbers in each line but your code only shows two numbers. SHould there be two or three? sidebar_leftopen.tmpl display_gallery("random", "", "", 1, 1, 1); sidebar_rightclose.tmpl display_gallery("random", "", "", 1, 1, 2); |
change the second number |
I'm not seeing any change at all... still only one product thumbnail is being shown in the 'random products' block. Out of curiosity / better understanding - is there any reason why '6' is used and not another number? |
Are you sure your changing the right template in the right directory? If your sidebar is on the left its sidebar_leftopen and if your using vb3 its the one in the vb3enhanced directory under templates. 6 was what I was suggesting you change it to. I also just checked and I was completely right in my original post. the display_gallery line in sidebar_leftopen is this Code: Content visible to verified customers only. |
1 Attachment(s) I am using vB3 intergration and it's the templates in the vb3enhanced directory that I've been looking at. display_gallery("random", "", "", 1, 1); is from the regular sidebar_leftopen template display_gallery("random", "", "", 1, 1, 1); is from the vB3 sidebar_leftopen template - note the extra digit To make sure we're talking about the same block I've attached a screenshot |
Change the second ONE of the 3 ONES to the number you want |
Unfortunately I'm not seeing any change at all... still only one product thumbnail is being shown in the 'random products' block. |
I dont know to explain to you any more plainly that I already have Code: Content visible to verified customers only. |
I've done exactly what you told me - I'm editing /templates/vb3enhanced/sidebar_leftopen.tmpl - have you tried it? does it work for you? |
It works fine for me thanks. |
Could it have anything to do with any settings in the adminCP? I only have the the 'Recent Reviews' and 'Random Products' showing whereas you have a couple of extra blocks showing. |
No you just need to make sure your editing the correct thing. I mean so what your saying now is you do not have a sidebar running. Your running the undercats.tmpl so there is your issue. Change the line in that template ;) |
I never said I was running / not running a sidebar - I didn't realise that made a difference. changing that line in the undercats.tmpl does the trick. Thanks for your help on this... even though it took us a while to get there. Cheers! :) :) |
Next time you ask such a question try including a picture or site link and things wont take so long :) |
Is there a way to exclude / only have (thumbs of products showing) from certain categories show in this block? Here's the code that generates the thumbnails: Code: Content visible to verified customers only. |
You need to modify directly the queries in the display_gallery function in pp-inc.php |
I had a look at the code and from what I could make out that's the code that creates the random products photo block... I'm after the random products PAL. It it is that code that I should be editing I'd appreciate a pointer on what I should be editing - there wasn't anything obvious that I could find. |
That function creates all the photo blocks. Good luck with your code hacking |
| All times are GMT -5. The time now is 09:35 PM. |
Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0