Announcement

Collapse
No announcement yet.

freebie: popout section aware nav.

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    #16
    LOL he is Jo

    Comment


      #17
      Originally posted by Darren B View Post
      LOL he is Jo
      dont you mean jan?

      Comment


        #18
        ok i am trying to install this....

        I took the php code from post #1 and added to actinic_main.php

        i took the block code from post #12 and placed it in layout where i want the nav to show

        I'll do the css later.

        but on upload i get "Fatal error: Call to undefined function: makenav() in main on line 1" wherethe nav should be.

        site is visible at testing dot surf-wax dot co dot uk

        Comment


          #19
          does that show in your offline preview too, Jo?
          It sounds very similar to the error I was getting when I tried (was months ago now, can't recall exactly)
          Tracey

          Comment


            #20
            yes offline too - thats why i uploaded it - i thought maybe it had to beonline to work as i've got other php stuff that only show serverside?

            Comment


              #21
              *gets very mad with 'quick reply' button STILL not working*

              I never managed to work out why this wouldn't work for me. It seemed, at the time, as if I was the only person who had a problem with it. I couldn't even get it to work on a brand new, default site.

              Not looked at it lately though (although I was planning to soon-ish) but it is kinda reassuring to know it's not just me!
              Tracey

              Comment


                #22
                Jo have you restarted actinic or the pc, im guessing you probably have but the main php wont recognise changes until a restart, its loaded when actinic 1st boots

                D

                Comment


                  #23
                  Originally posted by gabrielcrowe View Post

                  Assuming use, thus:
                  HTML Code:
                  <div class="navcontainerment">
                  <actinic:block php="true" > MakeNav(0,1,0,0); </actinic:block>
                  </div>
                  Ok I'm clearly confused - what does the above mean?

                  and how does it work with

                  After some people had problems making this work due to error it generates, I hashed this together:

                  Code:

                  <actinic:block if="%3cactinic%3avariable%20name%3d%22PageType%22%20%2f%3e%20%3d%3d%20%27Brochure%27" > <actinic:block php="true" > MakeNav(0,2,0,0); </actinic:block></actinic:block>
                  <actinic:block if="%3cactinic%3avariable%20name%3d%22PageType%22%20%2f%3e%20%3d%3d%20%27Checkout%20Page%200%27" > </actinic:block>
                  <actinic:block if="%3cactinic%3avariable%20name%3d%22PageType%22%20%2f%3e%20%3d%3d%20%27Checkout%20Page%201%27" > </actinic:block>
                  <actinic:block if="%3cactinic%3avariable%20name%3d%22PageType%22%20%2f%3e%20%3d%3d%20%27Checkout%20Page%202%27" > </actinic:block>
                  <actinic:block if="%3cactinic%3avariable%20name%3d%22PageType%22%20%2f%3e%20%3d%3d%20%27Shopping%20Cart%27" > <actinic:block php="true" > MakeNav(0,1,0,0); </actinic:block></actinic:block>
                  <actinic:block if="%3cactinic%3avariable%20name%3d%22PageType%22%20%2f%3e%20%3d%3d%20%27Add%20To%20Cart%20Confirmation%27" > <actinic:block php="true" > MakeNav(0,1,0,0); </actinic:block></actinic:block>
                  <actinic:block if="%3cactinic%3avariable%20name%3d%22PageType%22%20%2f%3e%20%3d%3d%20%27Receipt%27" > </actinic:block>
                  <actinic:block if="%3cactinic%3avariable%20name%3d%22PageType%22%20%2f%3e%20%3d%3d%20%27Search%27" > <actinic:block php="true" > MakeNav(0,2,0,0); </actinic:block></actinic:block>
                  <actinic:block if="%3cactinic%3avariable%20name%3d%22PageType%22%20%2f%3e%20%3d%3d%20%27Search%20Results%27" > <actinic:block php="true" > MakeNav(0,1,0,0); </actinic:block></actinic:block>
                  <actinic:block if="%3cactinic%3avariable%20name%3d%22PageType%22%20%2f%3e%20%3d%3d%20%27Bounce%20Page%27" > <actinic:block php="true" > MakeNav(0,1,0,0); </actinic:block></actinic:block>
                  <actinic:block if="%3cactinic%3avariable%20name%3d%22PageType%22%20%2f%3e%20%3d%3d%20%27Site%20Map%27" > <actinic:block php="true" > MakeNav(0,1,0,0); </actinic:block></actinic:block>
                  <actinic:block if="%3cactinic%3avariable%20name%3d%22PageType%22%20%2f%3e%20%3d%3d%20%27Terms%20And%20Conditions%27" > <actinic:block php="true" > MakeNav(0,1,0,0); </actinic:block></actinic:block>
                  <actinic:block if="%3cactinic%3avariable%20name%3d%22PageType%22%20%2f%3e%20%3d%3d%20%27Section%27">
                  <actinic:block if="%3cactinic%3avariable%20name%3d%22SectionLevel%22%20%2f%3e%20%3e%200">
                  <actinic:block php="true" > MakeNav(0,2,0,<actinic:variable name="SectionID" />); </actinic:block>
                  </actinic:block>
                  <actinic:block if="%3cactinic%3avariable%20name%3d%22SectionLevel%22%20%2f%3e%20%3d%3d%200" >
                  <actinic:block php="true" > MakeNav(0,1,0,0); </actinic:block>
                  </actinic:block>
                  </actinic:block>

                  What is it?

                  its a set of blocks that allow the navigation to be inserted into the brochure pages, or the catalog, without generating any 'SectionID out of context' errors.

                  the blocks (if you take a peek at them) allow you to configure the way that the nav behaves, on pages such as the sitemap, and in searches.

                  overall a powerful addition. The original Block if idea came from a post by jan i think. thanks jan.
                  cos when i use the set of blocks i get the parse error in the php, but if i use the single block statement that gabe says "assuming...." its ok.

                  Guess i'm not assuming

                  Darren - I've rebooted etc

                  Comment


                    #24
                    Originally posted by pinbrook View Post
                    Ok I'm clearly confused - what does the above mean?
                    Looking at the original code in the comments it shows

                    Code:
                     * usage example:
                    MakeNav($sectid,$recursedepth,$prestyle,$thissect)
                    is that more confusing


                    Bikster
                    SellerDeck Designs and Responsive Themes

                    Comment


                      #25
                      <actinic:block php="true" > MakeNav(0,2,0,<actinic:variable name="SectionID" />); </actinic:block>
                      </actinic:block>
                      ok i thinks its this causing hte parse error

                      Comment


                        #26
                        Jo the mak nav bit is the levels to show the tree e.t.c 0,2,0 will work, i played around with these ages ago basically its how the section list is shown.

                        ok all the block statements are what gabe has had to put in as actinic V9 produced aload of script errors, i dont know fully what gabe did but this was the fix for all then, well i guess not all by your post though. But you need all the code not just the
                        Code:
                        <div class="navcontainerment">
                        <actinic:block php="true" > MakeNav(0,1,0,0); </actinic:block>
                        </div>
                        Not sure were Gabe is of late, missing in action i think, but i bet he will catch up with it all.

                        Comment


                          #27
                          Darren would you mind posting or pm ing me your layout with the code - just so i can see what goes where Ta!

                          i'm using 851HFUA just in case this makes a difference

                          Comment


                            #28
                            some points;

                            1: actinic is very awkward when it comes to items in the actinic_main.php

                            if there are any errors, or things out of place, then this is the first place to look. actinic maintains a list of php errors, in its program files folder. This thread might give you some insight. norman details another method to include the function, and i'v used that method too, to great success.

                            2: the numbers in the function are not very helpful.

                            yes, i was quick to code, and generally i thought only i'd use this php, so i wasnt very descriptive about the numbers.
                            Code:
                            MakeNav(0,1,0,0);
                            This number denotes the node at which the tree starts. '0' Means the root. If you know the SectionID of your downtree section, you can start the tree rendering from a subsection.

                            This number is the depth at which the tree will expand. 1, means show only sections immidiately below this section.

                            This number is a switch. '0' Means expand only sections in this context. '1' means expand all branches up to this depth.

                            This number is the current context. This is used to determine if a section should expand, or have special css applied to it, when rendered. Passing 'SectionID' into this, causes the menu to expand and contract when the Actinic page changes.

                            3: Actinic preview is dire. Turn if off and use your browser. Actinic cannot render this menu properly in its own preview.

                            4: the div and id around the blocks for css, are only so that i can lock onto the div using css styles, they arent important to the rendering of the menu. this div allows clever styling of the structure.

                            Comment


                              #29
                              Sorry guys but I cannot even locate actinic_main.php, as requested. Where is it concealed?

                              Is there an easier option somewhere, somehow?
                              Richard Hodgson
                              Fantasy
                              www.whatsyourfantasy.co.uk

                              Comment


                                #30
                                if there was an easier option, this thread would be pretty pointless, wouldn't you say?

                                You should find your php file in your main Actinic folder, in Program Files.
                                You could always have done a file search on your computer to locate it
                                Tracey

                                Comment

                                Working...
                                X