WebsiteBaker Community Forum

WebsiteBaker Support (2.8.x) => Droplets & Snippets => Topic started by: fab2000 on June 18, 2017, 08:16:43 PM

Title: Droplet Children not functions on WB ver. 2.10.0
Post by: fab2000 on June 18, 2017, 08:16:43 PM
As for subjet
someone can help me?
TIA
Title: Re: Droplet Children not functions on WB ver. 2.10.0
Post by: Gast on June 19, 2017, 12:19:38 AM
pls post the droplet code here
Title: Re: Droplet Children not functions on WB ver. 2.10.0
Post by: fab2000 on June 19, 2017, 02:04:35 PM
Hello
this is the droplet code

ob_start();
show_menu2(0, SM2_CURR+1, SM2_ALL, SM2_ALL|SM2_CURRTREE);
$content = ob_get_contents();
ob_end_clean();
return $content.' ';
Title: Re: Droplet Children not functions on WB ver. 2.10.0
Post by: Gast on June 19, 2017, 03:09:23 PM
this code works for me without problems, try it in different variants like droplet, direct output etc
it shows only childs from the current page/ from this current tree and only, if this childs are visible (visible-status not set to hidden! or none). if a child of this current page has visibility = hidden or none, it will not showing visible childs of this (hidden) child

example tree (Droplet call inside of a code- or wysiwyg-section on Page 1 && Page 2)
EN
--- Page 1
------ Subpage 1 (visibility = visible)
---------Sub-Subpage 1 (visibility = visible)
--- Page 2 (visibility = hidden)
------ Subpage 2 (visibility = visible)
---------Sub-Subpage 2 (visibility = visible)

result: Droplet show a submenu only if you visit Page 1 && Subpage 1, but not on Sub-Subpage1, Page 2, Sub-Subpage 2

important: if you add the droplet call inside of the content, for example in wysiwyg or code section, the start-level for this submenu is the current page and the menu will only show'n, if you stay on this page, and not, if you go to another page (without this droplet call) - if you need a automatically submenu, everytime, if childpages avaiable, add the droplet call in your index.php of the template

important: if you add a new droplet in AdminTools-> Droplet, it has the status = inactive automatically (see red icon in the list), maybe, thats the problem

Title: Re: Droplet Children not functions on WB ver. 2.10.0
Post by: fab2000 on June 19, 2017, 06:20:41 PM
thanks
I verify all that you said droplet is green, ok
the problem appear after update from 2.8.3 to 2.10.0
on the page where I put droplet in frontend I see [[children]] but not the list of subpage.
May be the template is old one, I used it in 2014 for this site!!!

Sorry but I'm not a professional webmaster; site I made, very few, are only for friends ... and I like WebsiteBaker for his user friendlyness
Title: Re: Droplet Children not functions on WB ver. 2.10.0
Post by: Gast on June 19, 2017, 06:29:35 PM
if you see the "real" droplet call (like [[children]]) in the frontend output, the output-filter droplets is not active or you have a php-error on this page

#1: pls check at first under AdminTools -> OutputFilter -> check activated filters, save it and reload this page again.

#2: if you dont have a list like exact this screenshot here (doesnt matter, what checkbox is activated), go to addons -> modules -> advanced -> manuell upgrade -> select output filter -< click execute, then follow the tips in #1

(https://i.gyazo.com/9983a5fe2b318340cb6cfd879f0e7558.png)
Title: Re: Droplet Children not functions on WB ver. 2.10.0
Post by: fab2000 on June 19, 2017, 06:32:59 PM
thanks!!!
#2 solve my problem!