I’m still delving into Wayfinder and finding it to be a great utility. Some amazing stuff that it does!
One feature that I’m finding especially useful is the &rowIdPrefix parameter. I’m finding that very nice for assigning a different image to each button in a menu (trying to use restraint and good taste, of course!).
However, one aspect of it that seems to me a bit idiosyncratic (and contrary to ModX’s mission of simplifying maintenance) is the sequence of unique numbers it assigns to id’s. It appears from my reading that the sequence is determined by the [+wf.id+] and this is, of course, based on the document id’s used to generate the menu. If these id’s are not in a 1, 2, 3 ... order (and I’m guessing they rarely are) then you get HTML id’s assigned like:
<ul class="menu">
<li id="
nav6" > <a href="/index.php?id=6" title="Contact" >Contact</a> </li>
<li id="
nav47" > <a href="/index.php?id=47" title="About" >About</a> </li>
<li id="
nav32" > <a href="/index.php?id=32" title="Design" >Design</a> </li>
<li id="
nav33" > <a href="/index.php?id=33" title="Help" >Help</a> </li>
<li id="
nav15" > <a href="/index.php?id=15" title="MODx Features" >Features</a> </li>
<li id="
nav2" > <a href="/index.php?id=2" title="Blog" >Blog</a> </li>
<li id="
nav1" > <a href="
http://192.168.1.21/" title="Home" >Home</a> </li>
</ul>
where, as you can see, the order is 1, 2, 15, 33, 32, 47, 6 (I’m using descending order). Without changing the document id’s (something I also haven’t found a way of doing yet) I see no way to change this.
This isn’t particularly a big deal when doing one CSS that only I will ever modify, but if one is making a large site for other people to maintain, it would be impossible to (for example) assign style values for id’s 1 through 12 knowing that, however many documents someone adds later, there will be a style already defined to handle it. If the identifiers were assigned sequentially then this would be easy to do, and would make later maintenance much simpler.
Anyone know if there’s a way to do what I’m looking for, or have an explanation as to why what I’m wanting wouldn’t be a better way?
Many thanks,
- Dave