Welcome, Guest. Please Login
IMPORTANT MESSAGE! This forum has now been replaced by a new forum at http://forum.eastgate.com and no further posting or member registration is allowed. The forum is still accessible via read-only access for reference purposes. If you wish to discuss content here, please use the new forum. N.B. - posting in the new forum requires a fresh registration in the new forum (sorry - member data can't be ported).
Pages: 1
Send Topic Print
aTbRef - sitemap & similarTo tweaks (Read 2527 times)
Mark Anderson
YaBB Administrator

User - not staff!

Posts: 5689
Southsea, UK
aTbRef - sitemap & similarTo tweaks
Jan 25th, 2013, 12:51pm
I've just uploaded an updated ZIP file of the current aTbRef with two interesting new things.

Demo: a sitemap.xml. [url-http://en.wikipedia.org/wiki/Sitemaps]Whats a sitemap[/url]? If you don't know what one of these is, likely your website doesn't need one. Anyway, this came up in conversation yesterday and a wondered if it would be easy. Turns out it is: a single note and 2 new templates! See note "ATbRef sitmap.xml" in the TBX document. Be aware the export is turned off at present as it will make TB chug a bit running out the whole file - plus the XML resulting file is >8 MB.  still, if you're interested in the 'how', take a look at the TBX and the templates and borrow the concept for your own projects.

Faster Export. When a added in ^similarTo^ to most pages' templates export went from seconds to minutes. This is frustrating if I just want to do a quick full export to check a template change. So, and in a way another demo, I've made the made the code for the similar links into an inlcude in the main templates and in the include (note: /BOILERPLATE/similarto-panel) I've put the original code inside an ^if()^ which checks a Boolean that is a key attribute for the include note. Now, simply ticking-un-ticking the Boolean toggles in/out inclusion of the resource-intensive ^similarTo^ code:

Back to top

Mark Anderson
TB user and Wiki Gardener
aTbRef v6
(TB consulting - email me)
WWW shoantel   IP Logged
Pages: 1
Send Topic Print