We use cookies to improve your experience. No personal information is gathered and we don't serve ads. Cookies Policy.

ExpressionEngine Logo ExpressionEngine
Features Pricing Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University
Log In or Sign Up
Log In Sign Up
ExpressionEngine Logo
Features Pro new Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University Blog
  • Home
  • Forums

New Module: Structure - Uses entries to create a page hierarchy for static and listing pages

Development and Programming

Jason Morehead's avatar
Jason Morehead
454 posts
16 years ago
Jason Morehead's avatar Jason Morehead

Sorry to hog the thread, but I have one more feature request.

I’ve noticed that the {exp:structure:nav_sub} tag’s output doesn’t nest lists properly. For example, here’s how the tag currently outputs the lists:

<ul id="nav_sub">
    <li class="sub_level_0"><a href="/about/overview/">Worship & Music</a></li>
    <li class="sub_level_0 parent_here"><a href="/about/staff/">Men</a></li>
    <ul>
        <li class="sub_level_1 here"><a href="/about/staff/managers/">Managers</a></li>
        <li class="sub_level_1"><a href="/about/staff/sales/">Sales</a></li>
    </ul>
    <li class="sub_level_0"><a href="/about/catalog/">Catalog</a></li>
</ul>

Note that the “sub_level_1” list is actually outside the <li> that contains its parent. This output certainly works, but it makes the CSS styling a lot more difficult (and it’s less correct semantically). Could the output be adjusted to look like this?

<ul id="nav_sub">
    <li class="sub_level_0"><a href="/about/overview/">Worship & Music</a></li>
    <li class="sub_level_0 parent_here"><a href="/about/staff/">Men</a>
    <ul>
        <li class="sub_level_1 here"><a href="/about/staff/managers/">Managers</a></li>
        <li class="sub_level_1"><a href="/about/staff/sales/">Sales</a></li>
    </ul>
    </li>
    <li class="sub_level_0"><a href="/about/catalog/">Catalog</a></li>
</ul>

Now, the “sub_level_1” list is correctly nested within its parent’s <li>. It’s more correct semantically, and makes styling with CSS easier as well.

What do you think?

       
rockthenroll's avatar
rockthenroll
485 posts
16 years ago
rockthenroll's avatar rockthenroll

That is DEFINITELY broke. Thanks for finding that. I’ll get a fix into our system and post when it’s fixed.

       
Jason Morehead's avatar
Jason Morehead
454 posts
16 years ago
Jason Morehead's avatar Jason Morehead

Thanks for the quick response.

       
rockthenroll's avatar
rockthenroll
485 posts
16 years ago
rockthenroll's avatar rockthenroll

New version uploaded to fix the li bug. http://www.ngenworks.com/software/ee/structure/

Thanks again @opuszine!

       
Nico Smit's avatar
Nico Smit
48 posts
16 years ago
Nico Smit's avatar Nico Smit

Hi Travis,

Great module!

When I try to access my homepage, I’m getting the error message that the tag {exp:structure:breadcrumb}, can’t be found. In other pages/levels (with URLs) the tag does work. Any clue?

Question/Request: Is is possible to completely remove the main add/edit buttons in the header and only use the Structure tab for customers?

       
rockthenroll's avatar
rockthenroll
485 posts
16 years ago
rockthenroll's avatar rockthenroll

@NicoSmit Not sure what’s up here because the breadcrumb tag shouldn’t cause any errors on your homepage. It doesn’t return anything when there. Can you PM me a login to look at your install? Or post the code?

We’re finishing up an extension now that allows tabs for groups or individuals, ordering and hiding the default ones. We’ll release it soon, gotta make time to write the docs.

       
bluesonora's avatar
bluesonora
90 posts
16 years ago
bluesonora's avatar bluesonora

i just installed this after thinking i was going about an essentially ‘static’ site a**-backwards. i’ll probably have more to say but so far, this is very cool. kudos.

eta: probably a setting issue of my site, but when i use the sub_nav it is relative to the web root, not the index.php. e.g. nuun.cl/about/what_is_nuun as opposed to nuun.cl/index.php/about/what_is_nuun

       
rockthenroll's avatar
rockthenroll
485 posts
16 years ago
rockthenroll's avatar rockthenroll

@littlered Glad you like it! I think the subnav tag has a hard coded root. We always remove the index.php. Maybe we’ll change it next version…

       
Jason Morehead's avatar
Jason Morehead
454 posts
16 years ago
Jason Morehead's avatar Jason Morehead

I’ve noticed that when I move pages around, the site structure seems to be updated but the word “Error” (in red) always appears next to the page I’ve moved. Why is that?

It doesn’t happen on the other that I’m using “Structure” with. There, I just get a red asterisk that disappears almost immediately.

       
rockthenroll's avatar
rockthenroll
485 posts
16 years ago
rockthenroll's avatar rockthenroll

Were those entries created before installing Structure? The problem is most likely that they don’t have Structure data associated with them. It creates an alias/url for EVERY entry, so one’s created before probably don’t have the correct data associated with them yet. If that’s the case go in and resave that entry and it should work.

       
Robert Aitken's avatar
Robert Aitken
13 posts
16 years ago
Robert Aitken's avatar Robert Aitken

Nice module!

I had a bit of trouble initially because I was using hidden templates. As soon as I removed the period at the start of my template name it started working. It would be nice if hidden templates were supported as this seems like a situation where you’d want to use them.

       
rockthenroll's avatar
rockthenroll
485 posts
16 years ago
rockthenroll's avatar rockthenroll

@Robert Aitken: That’s on the list, but there are some template hurdles we’re not going to spend time on right now. Stay tuned and it may make it to a future release. Thanks!

       
Jason Morehead's avatar
Jason Morehead
454 posts
16 years ago
Jason Morehead's avatar Jason Morehead
Were those entries created before installing Structure? The problem is most likely that they don’t have Structure data associated with them. It creates an alias/url for EVERY entry, so one’s created before probably don’t have the correct data associated with them yet. If that’s the case go in and resave that entry and it should work.

I tried re-saving, to no avail: I still get the “Error” text.

The only odd thing I notice is that, when selecting what tabs appear on the “Publish” form, I still have an option to display the “Pages” tab, even though I uninstalled the “Pages” module (I had installed it when I was first configuring EE for this site, which was before I discovered “Structure”).

       
rockthenroll's avatar
rockthenroll
485 posts
16 years ago
rockthenroll's avatar rockthenroll

I think that tab is just built into the system as an option under the Weblog Management prefs regardless of whether Pages is installed or not.

This may have to do with some kind of errors since you had Pages data installed, but I would need more details to be able to help debug anything. You should also be fine as long as Pages is uninstalled, so I’m thinking there’s something else at work here.

Can you PM me a login? If that doesn’t yield anything obvious can you try with a clean install as a demo? That way we can narrow down if it’s a bug or the environment…

       
Tyssen's avatar
Tyssen
756 posts
16 years ago
Tyssen's avatar Tyssen

How would you get {exp:structure:nav_sub} to only display the entries related to the page you’re currently on? For instance, if you’re on a second level page, it doesn’t show other pages at the same level, but only shows the children of that page.

       
First 2 3 4 5 6 Last

Reply

Sign In To Reply

ExpressionEngine Home Features Pro Contact Version Support
Learn Docs University Forums
Resources Support Add-Ons Partners Blog
Privacy Terms Trademark Use License

Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.