Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Re: [archived] glx_hl_current highlight current article
sorry i think i know what the problem is on my last post, i wasn’t injection an “active” style into my CSS
so i got the plugin working on a different site, but what’s happening is it’s working on one nav menu, and then on another one it isn’t. the code is almost identical. anyone ever had this problem?
Not working:
<div id='navbar'>
<div class='navi'>
<ul>
<li<txp:glx_hl_current_section section="News" />><a href="<txp:section name="News" url="1" />">News</a></li>
<li<txp:glx_hl_current_section section="Video" />><li><a href="<txp:section name="Video" url="1" />">Video</a></li>
<li<txp:glx_hl_current_section section="info" />><a href="<txp:section name="info" url="1" />">Info</a></li>
</ul>
</div>
</div>
working:
<div id="infonav">
<ul class='info'>
<li<txp:glx_hl_current_section section="info" />><a href="<txp:section name="info" url="1" />">About</a></h2></li>
<li<txp:glx_hl_current_section section="ski" />><a href="<txp:section name="ski" url="1" />">Snowboard/Ski</a></li>
<li<txp:glx_hl_current_section section="dates" />><a href="<txp:section name="dates" url="1" />">Dates/Prices</a></li>
<li<txp:glx_hl_current_section section="parents" />><a href="<txp:section name="parents" url="1" />">Parents</a></li>
</ul>
</div>
Offline
#32 2009-02-13 23:14:20
- els
- Moderator

- From: The Netherlands
- Registered: 2004-06-06
- Posts: 7,458
Re: [archived] glx_hl_current highlight current article
Just a guess: the ‘not working’ code has section names with capitals.
Offline
Re: [archived] glx_hl_current highlight current article
Els wrote:
Just a guess: the ‘not working’ code has section names with capitals.
i just removed the capitals, and now it actually works on the “News” and “Info” section but not Video for some reason. which leads me to believe it was probably working on Info before I even posted this.
<li<txp:glx_hl_current_section section="news" />><a href="<txp:section name="news" url="1" />">News</a></li>
<li<txp:glx_hl_current_section section="video" />><li><a href="<txp:section name="video" url="1" />">Video</a></li>
<li<txp:glx_hl_current_section section="info" />><a href="<txp:section name="info" url="1" />">Info</a></li>
Last edited by mrtunes (2009-02-13 23:27:47)
Offline
#34 2009-02-13 23:45:52
- els
- Moderator

- From: The Netherlands
- Registered: 2004-06-06
- Posts: 7,458
Re: [archived] glx_hl_current highlight current article
What is the url="1" doing in your code? It’s not an existing attribute ;)
Edit: I am sleeping ;) This: <a href="<txp:section name="news" url="1" />">News</a> wouldn’t work anyway as far as I can see… Besides, you don’t need the plugin:
<li<txp:if_section name="news"> class="current"</txp:if_section>><txp:section name="news" title="1" link="1" /></li>
or
<li<txp:if_section name="news"> class="current"</txp:if_section>><a href="<txp:site_url /><txp:section name="news" />/">News</a></li>
Last edited by els (2009-02-14 00:01:34)
Offline
Re: [archived] glx_hl_current highlight current article
interesting, i didn’t even need the plugin all along lol!
well i tried your first snippet using <txp:if_section>, and the exact same problem is happening where the video won’t go “current”. so it wasn’t the plugin’s fault. still unresolved. this one is slowly becoming a pain hah
Last edited by mrtunes (2009-02-14 19:21:30)
Offline
#36 2009-02-14 19:23:02
- els
- Moderator

- From: The Netherlands
- Registered: 2004-06-06
- Posts: 7,458
Re: [archived] glx_hl_current highlight current article
Did you change the ‘video’ section name to lowercase as well in the tag as in the sections tab?
Offline
Re: [archived] glx_hl_current highlight current article
Els wrote:
Did you change the ‘video’ section name to lowercase as well in the tag as in the sections tab?
yeah. i’m thinking this is the source of the problem. maybe the video section has to get deleted and recreated to fix the database or something?
EDIT: that didnt work :(
Last edited by mrtunes (2009-02-14 19:28:40)
Offline
#38 2009-02-14 19:33:33
- els
- Moderator

- From: The Netherlands
- Registered: 2004-06-06
- Posts: 7,458
Re: [archived] glx_hl_current highlight current article
Hmm… have a look at the tag trace of that page, if it doesn’t tell you anything can you post it here?
Offline
Re: [archived] glx_hl_current highlight current article
ok looking at the source helped identify the simple culprit
<li<txp:glx_hl_current_section section=“video” />>*<li>*<a href=”<txp:section name=“video” url=“1” />”>Video</a></li>
an extra li snuck in there :)
i have another question about this but since i’m not using the plugin any more it might have to get its own thread if i can’t find the answer in a search.
Offline
#40 2009-02-14 20:45:28
- els
- Moderator

- From: The Netherlands
- Registered: 2004-06-06
- Posts: 7,458
Re: [archived] glx_hl_current highlight current article
mrtunes wrote:
an extra li snuck in there :)
Oops! Completely missed that. Forgot to mention: in case of troubles, first step: validate :)
Offline
#41 2009-02-23 16:17:08
- dressedinvalue
- Member

- From: Louisville, KY
- Registered: 2008-12-31
- Posts: 21
Re: [archived] glx_hl_current highlight current article
Can someone post the plugin text here? The download link is broken.
Offline
Re: [archived] glx_hl_current highlight current article
dressedinvalue wrote:
Can someone post the plugin text here? The download link is broken.
sorry i keep forgetting where to find it. when someone locates it, please put it on a Google Homepage server so it won’t expire. or i’ll do it if you just tell me where to find this.
Offline
Re: [archived] glx_hl_current highlight current article
glx_hl_current @ Markup Artist/Johan Nilsson
Last edited by maverick (2009-02-23 17:38:01)
Offline
Re: [archived] glx_hl_current highlight current article
I thought to be a clever guy … :(
<txp:recent_articles break="li<txp:glx_hl_current_section />" label="" labeltag="h5" limit="99" section="home" sort="position asc" wraptag="ol" />
getting this >

So, I need some help!
Offline
#45 2009-02-23 20:46:57
- els
- Moderator

- From: The Netherlands
- Registered: 2004-06-06
- Posts: 7,458
Re: [archived] glx_hl_current highlight current article
I’m not sure if you can put anything besides the li in the break attribute at all, but if it should work, you should at least change the double quotes to single ones (tags in tags…):
<txp:recent_articles break='li<txp:glx_hl_current_section />' label="" labeltag="h5" limit="99" section="home" sort="position asc" wraptag="ol" />
If it doesn’t work you can always use article_custom and a proper form ;)
Offline