Author Topic: Make PrevPage2 & NextPage2 droplets work on hidden pages  (Read 2189 times)

Offline Kaliphornia

  • Posts: 40
  • Gender: Male
    • Gweb
Make PrevPage2 & NextPage2 droplets work on hidden pages
« on: June 05, 2013, 02:14:36 AM »
Hey all,

I have a little problem. I'm using the PrevPage2 and NextPage2 droplets to go back and forth between pages on one of my websites. It works fine unless I call the droplets from a hidden page:
http://www.smudgedesignco.com/pages/branding/aod-van-wrap.php

Then the Next arrow goes back to the homepage and the Prev arrow goes to the very last page of the site. It's because the page in the link above is hidden.

Anyone know how to alter the droplets so they treat hidden pages like they're not hidden? Any help would be greatly appreciated.

Thanks!

Offline Ruud

  • Posts: 3653
  • Gender: Male
  • Do not use PM for help! Please use the forum!
    • Dev4Me - Professional WebsiteBaker Development
Re: Make PrevPage2 & NextPage2 droplets work on hidden pages
« Reply #1 on: June 05, 2013, 10:42:38 AM »
These droplets are using show_menu2 for getting the next item.
Show_menu2 by default will not show hidden pages (that is why they are set hidden).

Try adding SM2_SHOWHIDDEN to the second SM2_ALL parameter in all show_menu2 calls.
Code: (untested) [Select]
show_menu2(0,SM2_ROOT,SM2_ALL,SM2_ALL|SM2_SHOWHIDDEN ,',[url]','','','','','');and
Code: (untested) [Select]
show_menu2(0,SM2_ROOT,SM2_ALL,SM2_ALL|SM2_SHOWHIDDEN,',[page_id]','','','','','');

 

postern-length