Trex 0.98

flDisqusComments attribute

A new attribute that's a carryover from the worldoutline software, it lets you selectively turn off comments without modifying the template.

If flDisqusComments is defined and is not equal to "true" then the <%comments%> macro is the empty string.

Here's a screen shot of the attributes of a headline with the new attribute set false.

rssLink macro

We now have a proper link to the feed embedded in every page on our sites.

The new macro is called rssLink (). If there is a feed element in the head of the OPML, we generate the link. If the element isn't there, we return the empty string.

<%rssLink ()%>

It's meant to be included in the head section of the template. It's supported in the default templates.

googleAnalytics macro

A new macro generates the code to connect with Google Analytics.

The macro takes one optional parameter, the account identifier.

<script><%googleAnalytics ("UA-XXXXXXXX-1")%></script>

It can also be called without a parameter, then we get the ID from the #googleAnalyticsID directive.

#googleAnalyticsID "UA-XXXXXXXX-1"

If both the parameter and the #googleAnalyticsID directive are not present, the macro returns the empty string.

For the domain name, we use the Host header on the HTTP request.

Disqus change

The default groupname was scripting2. It has changed to smallpict.

It's important to make this change as early as possible in the deployment of Trex. We should have made it even earlier.

The upshot is that any existing discussions you have will now be empty. If you haven't had any discussions yet, there's nothing to worry about. However if you have some, and want to keep them, there is an easy fix.

Add this directive where ever you need to use the old group.

#disqusGroupName "scripting2"

I needed to do this for I just put it inside the June 2013 branch. With July 1 on Monday, the site will automatically switch over to the new group.

Of course you can easily create your own disqus group to allow the comments of your users to all be grouped together. Highly recommended!

Posted: Sat, 29 Jun 2013 21:37:31 GMT