Woohoo!
Announcement
Collapse
No announcement yet.
freebie: popout section aware nav.
Collapse
X
-
Need a barcode label or card printer? Look no further than OnlyZebra.
Thinking about barcode scanning and whether it could improve your business' efficiency? We can offer a range of products from numerous manufacturers. OnlyAML, OnlyIntermec, OnlyLXE, OnlyOpticon & OnlyPsion or OnlyRugged, the one stop shop for all your needs.
-
Great to hear fourone!
It feels good to give something back for a changeNeed a barcode label or card printer? Look no further than OnlyZebra.
Thinking about barcode scanning and whether it could improve your business' efficiency? We can offer a range of products from numerous manufacturers. OnlyAML, OnlyIntermec, OnlyLXE, OnlyOpticon & OnlyPsion or OnlyRugged, the one stop shop for all your needs.
Comment
-
thanks for the addition of the extra menus, but there is a more interesting issue at hand.
Dont you think that removing the complexity of a store navigation from the cart is a good idea?
Why would you want them to go faffing about in the store, when you need them to go and pay for something? I understand the need to upsell, but there are things inside actinic that can do that for you.
take a look at amazon, play and dabs to see what i mean. they remove the left hand nav, when paying for goods, it confuses people and makes the checkout more freindly.
Comment
-
Dunno, I was just answering the question lolNeed a barcode label or card printer? Look no further than OnlyZebra.
Thinking about barcode scanning and whether it could improve your business' efficiency? We can offer a range of products from numerous manufacturers. OnlyAML, OnlyIntermec, OnlyLXE, OnlyOpticon & OnlyPsion or OnlyRugged, the one stop shop for all your needs.
Comment
-
Originally posted by malbro View PostJust found a problem in the code.
If you have any deleted sections in the site then the current code builds them into the menu system.
it needs an additional condition ( AND [Status]='N' ) in the function SectionList to check the value of Status.
So the code
Code:if($respect==true) { $query = "SELECT [sPageName], [Section text], [nSectionID] FROM [Catalog Section] WHERE [nParentSectionID]=".$sectid." AND [bHideOnWebSite]=0 AND [bIncludeToSiteMap]=1 ORDER BY [Catalogue Section Sequence] ASC"; } else { $query = "SELECT [sPageName], [Section text], [nSectionID] FROM [Catalog Section] WHERE [nParentSectionID]=".$sectid." AND [bHideOnWebSite]=0 ORDER BY [Catalogue Section Sequence] ASC"; }
Code:if($respect==true) { $query = "SELECT [sPageName], [Section text], [nSectionID] FROM [Catalog Section] WHERE [nParentSectionID]=".$sectid." AND [bHideOnWebSite]=0 AND [bIncludeToSiteMap]=1 AND [Status]='N' ORDER BY [Catalogue Section Sequence] ASC"; } else { $query = "SELECT [sPageName], [Section text], [nSectionID] FROM [Catalog Section] WHERE [nParentSectionID]=".$sectid." AND [bHideOnWebSite]=0 AND [Status]='N' ORDER BY [Catalogue Section Sequence] ASC"; }
I've reinstalled the whole menu from scratch, to make sure I was using up to date code/latest version but no luck.
I've restarted (Actinic) and compacted several times.
Any ideas what else could be making these deleted sections appear in the menu still?
(How long is a piece of string? I know...but someone else may have had the same problem and managed to resolve it)
Editted to add: It works ok with sections hidden..just that it still shows deleted (red X) onesTracey
Comment
-
Anyone who wants an alphabetic sort on the sections can use this code but change the last section of the line as below
Code:if($respect==true) { $query = "SELECT [sPageName], [Section text], [nSectionID] FROM [Catalog Section] WHERE [nParentSectionID]=".$sectid." AND [bHideOnWebSite]=0 AND [bIncludeToSiteMap]=1 AND [Status]='N' ORDER BY [Section text] ASC"; } else { $query = "SELECT [sPageName], [Section text], [nSectionID] FROM [Catalog Section] WHERE [nParentSectionID]=".$sectid." AND [bHideOnWebSite]=0 AND [Status]='N' ORDER BY [Section text] ASC"; }
Comment
-
Error in menu
I have I think done everythink right.
Point 16 in your noob giude needs to be more well noob friendly!
Anyway thye menu displays but apart from the first link in the list the rest either do not work or take you back to the home page.
Any ideas.
Thanks
John
PS using version 9 and closed down and restarted actinic etc.
Comment
-
Originally posted by John_C View PostI have I think done everythink right.
Point 16 in your noob giude needs to be more well noob friendly!
Anyway thye menu displays but apart from the first link in the list the rest either do not work or take you back to the home page.
Any ideas.
Thanks
John
PS using version 9 and closed down and restarted actinic etc.
Go to your design tab and look over to the right hand side. There should be a section of the window called either 'Design Tree' or 'Content Tree'. If not, go to the Window menu on the top toolbar and select 'Restore Split View Layout'.
So, over to the right hand side of the screen, there should be the Design Tree or Content Tree. If it's showing content tree, go to the bottom of that section and click the other tab. Either way you should now be on the Design Tree.
Right click on the very top entry (should be something relating to your outer layout) and click 'Insert Layout'. A new window should appear where you'll be able to select your newly created layout selector. Once you've found it, click Insert and it should show right at the top of the list (but below the very top entry).
Don't know if you've already got that far or if it helps at all!Need a barcode label or card printer? Look no further than OnlyZebra.
Thinking about barcode scanning and whether it could improve your business' efficiency? We can offer a range of products from numerous manufacturers. OnlyAML, OnlyIntermec, OnlyLXE, OnlyOpticon & OnlyPsion or OnlyRugged, the one stop shop for all your needs.
Comment
-
Originally posted by John_C View PostAnyway thye menu displays but apart from the first link in the list the rest either do not work or take you back to the home page.
If the menu appears with all the sections in it then it is likely the code is correctly inserted, the php code scans the actinic database and generates the menu listing on the web page. I presume that you have not modified the code supplied by gabe in anyway.
Comment
-
Error in menu solved?
I have solved it but it was not related to any of the scripts.
In the page settings in the sections content tree if there is not a name/address under the page name field that section does not have a link under the script when it displays on the webpage.
I do not know if there is a quick way to fill this feild in for all the sections but now that seems the issue.
Anyway good addon
Thanks
John
Comment
-
Originally posted by John_C View PostI have solved it but it was not related to any of the scripts.
In the page settings in the sections content tree if there is not a name/address under the page name field that section does not have a link under the script when it displays on the webpage.
I do not know if there is a quick way to fill this feild in for all the sections but now that seems the issue.
Anyway good addon
Thanks
John
Code:if (!function_exists('SectionList')) { function SectionList($connect,$sectid,$recursedepth,$rendermode,$thispatharr,$stylecounter,$respect) { $recursedepth=$recursedepth-1; $stylecounter=$stylecounter+1; if($respect==true) { $query = "SELECT [sPageName], [Section text], [nSectionID] FROM [Catalog Section] WHERE [nParentSectionID]=".$sectid." AND [bHideOnWebSite]=0 AND [bIncludeToSiteMap]=1 ORDER BY [Catalogue Section Sequence] ASC"; } else { $query = "SELECT [sPageName], [Section text], [nSectionID] FROM [Catalog Section] WHERE [nParentSectionID]=".$sectid." AND [bHideOnWebSite]=0 ORDER BY [Catalogue Section Sequence] ASC"; } $result = odbc_exec($connect, $query); $numrows = useful_odbc_num_rows($result); if ($numrows!=0) {echo "\n\n<ul class=\"ul".$stylecounter."\">\n";} while(odbc_fetch_row($result)){ $sPageName = odbc_result($result, 1); $Sectiontext = odbc_result($result, 2); $nSectionID = odbc_result($result, 3); // add this line here to stop generating code for non existent pages if ($sPageName!="") { $thisstyle=""; $expandthis=false; foreach ($thispatharr as $value) { if ($value==$nSectionID) { $thisstyle="_selected"; $expandthis=true; } } $linkitem="<a href=\"#link#\" class=\"link".$stylecounter.$thisstyle."\">"; echo "\t<li class=\"li".$stylecounter.$thisstyle."\">"; echo str_replace("#link#",$sPageName,$linkitem); echo trim($Sectiontext); echo "</a>"; //recurse if ($rendermode == 1) { $expandthis=true; } if ($recursedepth>=1 and $expandthis==true){ SectionList($connect,$nSectionID,$recursedepth,$rendermode,$thispatharr,$stylecounter,$respect); } echo "</li>\n"; // and this one to close the condition. } } if ($numrows!=0) { echo "</ul>\n\n"; } odbc_free_result($result); } }
Comment
-
Originally posted by John_C View PostI have a new issue in version 10, but it may be a problem with older versions.
If I do a new section it does not show up and if I delete a section it still shows in the nav menu.
Any ideas?
Have you just upgraded to V10 or was it always in V10? The php code reads the database from the current Actinic site however the code is specific to the relevant version of Actinic. For example if it worked on V9 and you install V10 alongside V9 and import th site into the V10 version of Actinic whilst the old version is still on the machine then the code will read the database from the V9 site not the V10 one.
If this is the case then go through the PHP code in the V10 version and change all references to Catalog9 to be Catalog10.
Comment
Comment