Hi, I would like to create a glossary like the following:
http://www.etfmarketpro.com/glossary.html
The original thread said it was created using EZfaq, but I would appreciate if someone could ellaborate on hoew to get the EZfaq to this stage?
Thanks
www.PawsForWildlife.co.uk
www.Borntobrick.co.uk
There are a couple of ways to do it with EZfaq (though I’ve never done it). You could rewrite the EZfaq code. It’s definitely doable but you’d have to be somewhat fluent in PHP to do it. It would just be a matter of stepping in where the array of items is completed, sort them, and step through inserting the anchor tags where appropriate. You’d also have to create the links at the top (or put them in the resource).
Another way would be to sort the items manually in the EZfaq content resource, add the links the top, and insert the anchors manually as Extra: (*not* EXTRA:) items.
In Evolution there are a couple of A to Z snippets that would do it for you automatically if each item were in a different resource. I’m currently working on a Revolution version of the same thing. It should be done in a day or two.
Thanks. I am a little lost. I came across an old thread that kinda explained ’Extra:Anchor name’. But I am unsure how to implement this. So far I have a container (published), and a child doc (unpublished with Q + A’s). I did get an Atoz listing from the download area but am unable to get them to work together? Any ideas?
www.PawsForWildlife.co.uk
www.Borntobrick.co.uk
The A to Z snippet will only work if every item is in its own resource.
The other method (using Extra:) is very straightforward. Any thing marked as Extra: (*not* EXTRA:) in EZfaq is simply inserted directly into the page content at that point with no processing (except for removing the "EXTRA:").
You just put standard HTML anchor tags there. The anchor tag at the beginning of the B section might look like this:
Extra:<p><a name="jump_to_B" id="jump_to_B"></a><strong>B</strong></p>;
The links at the top of the page would look like this in MODx Revolution:
<a href="[[~[[*id]]]]#jump_to_A'">A</a><a href="[[~[[*id]]]]#jump_to_B'">B</a><a href="[[~[[*id]]]]#jump_to_C'">C</a> // etc.
In Evolution, the tags would be
instead of
Forgive my ignorance, but the first code (EXTRA) goes in the content box, and then the glossary words beginning with ’B’ go underneath (my Q: and A: ’s)?
The links would go in my template?
Regards
www.PawsForWildlife.co.uk
www.Borntobrick.co.uk
Really confused on this one. Have tried all manner of ways to do it, but none work. The EZFaq is great, I just cant understand the anchor tag linking
www.PawsForWildlife.co.uk
www.Borntobrick.co.uk
I would probably put the A-Z header in the FAQ document, just above the [[!EZfaq]] tag, but I think it could also go in the unpublished doc (at the top, before any Q or A sections.
The A-Z Header would look something like this (for Revolution -- change the link tags if it’s Evo):
<a class="az-headeritem" href="[[~[[*id]]]]#jump_to_A">A</a> |
<a class="az-headeritem" href="[[~[[*id]]]]#jump_to_B">B</a> |
<a class="az-headeritem" href="[[~[[*id]]]]#jump_to_C">C</a> |
etc.
Extra: (not EXTRA:) must end with a colon.
The FAQ content doc would look something like this:
Extra:<p class="az-anchor"><a name="jump_to_A" id="jump_to_A"></a><strong>A</strong></p>
Q:
A:
Q:
A:
Extra:<p class="az-anchor"><a name="jump_to_B" id="jump_to_B"></a><strong>B</strong></p>
Q::
A:
Q:
A:
Extra:<p class="az-anchor"><a name="jump_to_C" id="jump_to_C"></a><strong>C</strong></p>
Q:
A:
Q:
A:
etc.
I have done as you have posted. Added the headeritem code with MCE turned off. Now I get a link on the page at the top (i.e, A|B|C) but it still does not ’jump’ to specified place it seems it will not recognise the word ’EXTRA:’?
Link -
http://www.pawsforwildlife.co.uk/index.php?q=glossary.html#jump_to_B
www.PawsForWildlife.co.uk
www.Borntobrick.co.uk
Quote from: distant_smile at Jan 26, 2011, 01:44 AM
I have done as you have posted. Added the headeritem code with MCE turned off. Now I get a link on the page at the top (i.e, A|B|C) but it still does not ’jump’ to specified place it seems it will not recognise the word ’EXTRA:’?
Link - http://www.pawsforwildlife.co.uk/index.php?q=glossary.html#jump_to_B
Sorry, I’m an idiot. I wrote that a long time ago and never use that feature. I forgot that it has to be:
instead of
Otherwise, EZfaq parses the A: as an answer.
Sorry, again for all the trouble.
Nice site, BTW.
Hi Bobray, thanks for the comments on the site, it’s down to people like yourself who have helped.
I hate to be a pain, but I have added the ’<a class="az-headeritem" href="[~[*id*]~]#jump_to_A">A</a> | ’ tags
to the top of my Published page, with Tiny MCE turned off.
I have added the ’Extra:<p class="az-anchor"><a name="jump_to_B" id="jump_to_B"></a><strong>B</strong></p>’ tags to my unpublished page, at the top of the words I want to jump to (i.e, jump to C at top of ’C’ section)
I get the links on the page (A|B, etc) but unfortunately they do not ’jump’ to my tags. I have never used anchor tags so I have done the above, is there anything I have missed? (The tags above were entered minus the comma’s)
Thanks for all your help, your site has been a great resource to me!
www.PawsForWildlife.co.uk
www.Borntobrick.co.uk