WebsiteBaker Community Forum
WebsiteBaker Support (2.13.x) => General Help & Support => Topic started by: crnogorac081 on February 05, 2024, 08:13:48 PM
-
one more bug to fix that I just noticed:
in Pages, when you create new page from Form ,and select as Parent some page (which is in different MenuId), if will assign MenuId = 1 in DB to new page instead MenuId from Parent page that is selected.
-
My test was as follows:
A form page under a wysiwyg page
and it works for me.
see
https://82.umojasingers.de/pages/home/form-unter-wysiwyg.php
-
Can you check in database too ?
If there are multiple menus and parent page Is Menu id =2 ( not 1 by default) and you add subpage using form on the bottom of the /admin/pages/index.php (Add Page form below the menu tree) in the menu there is sub page displayed as child of parent page , but in database it will have menuId = 1 instead 2 , which Is menu id from parent page
-
page_id parent root_parent level link page_trail position menu language page_code visibility target page_title
30 1 1 1 /home/form-unter-wysiwyg 1,30 2 1 DE 0 public _top Form unter wysiwyg
-
Maybe I wasnt clear
Check images
(https://i.ibb.co/fHtVcQn/sc1.png) (https://ibb.co/fHtVcQn)
(https://i.ibb.co/2qnHdQ8/sc2.png) (https://ibb.co/2qnHdQ8)
-
Okay, then I'm out. I really don't understand the problem.
Should I create a subpage with a form from a page, regardless of which module was used?
or
Should I create a subpage from your form page?
Maybe there is a user who understands it better and can check it.
-
In Frontend Template, there should be multiple menus, and multiple menus enabled
example:
$menu[1] = 'Mainmenu';
$menu[2] = 'Topbarmenu';
$menu[3] = 'Sidebarmenu';
1. Below page tree, use Add Page, and create new page called example Page123 (select any module, set parent = none)
2. Open settings for this page, set menu = 'Topbarmenu' (menu id = 2). Now for this Page123, in database Menu id = 2, which coresponds to 'Topbarmenu'
3. Now back to Page tree page, and create new page called Subpage (select any module, set parent = Page123 ).
The problem is when this Subpage is added, in database fileld menu id for subpage is set to 1 by default, and should be inherited from parent page - menu id = 2
I hope it is now clear.
-
one more bug to fix that I just noticed:
in Pages, when you create new page from Form ,and select as Parent some page (which is in different MenuId), if will assign MenuId = 1 in DB to new page instead MenuId from Parent page that is selected.
Can confirm. Seems the menu id from the first menu in list is standard if a new page was created.
-
I have created test code that dumps pages From DB, then checks of there Are multiple menu_id's and create array like menu_id => array _tree(); menu_id => array _tree().. , where array tree Is parent-,> child multiLevel array
In my output it looks like this (separated lists)
https://ibb.co/py9cnTx
And this Is default view (currntly)
https://ibb.co/fHtVcQn
It Is not possible with phplib and i AM doing migration for complete backand to twig. But I need to create and load class to Handle Pages and Media ( the Rest of the code Can be reusable)
-
I rebuilt this with WebsiteBaker 2.8.3 with php 5.6. The behavior is already wrong.
I will post a ticket here
https://project.WebsiteBaker.org/projects/wb-2-13/issues (https://project.WebsiteBaker.org/projects/wb-2-13/issues)
Done
https://project.WebsiteBaker.org/issues/147
-
Yes it's easy fix , if parent is set, use menu_id From parent.
Probably YUI couldnt Handle multiple lists or multiLevel lists. So i am moving to Sortable.js (vanila js)