Ignore:
Timestamp:
2013-03-28T17:46:57+13:00 (11 years ago)
Author:
ak19
Message:

Shifting position of RSS link in GS2 to header area. Smaller icon. Changes to demo collection's extra.dm macro file, as the RSS link will appear on all pages in the header now the user specifies that it should appear. Moved the actual rsslink macro and javascript into nav_css which defines the header, rather than in base and style.dm where the rsslink macro and associated javacsript function were before'

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/trunk/greenstone2/macros/style.dm

    r27099 r27150  
    229229}
    230230
    231 # Javascript that's used for appending "&hostname=host:port" to the link to the RSS feed
    232 # The script is activated on loading the rss icon <img>, since onLoad doesn't work on <a>
    233 # The rsslink that embeds rssicon are two macros defined in base.dm
    234 # To use this script, define pagescriptextra macro to contain the domainscript macro
    235 # Can do so at collectionlevel in a collection's extra.dm (try to add it to package about)
    236 
    237 _rssscript_ {
    238   function addDomainToRSSAnchor (imgtag)
    239   \{
    240      parent = imgtag.parentNode;
    241      if (parent && parent.href)
    242      \{
    243         parent.href += "&hostname="+location.hostname;
    244     if(location.port) \{
    245            parent.href += ":"+location.port;   
    246         \}
    247      \}
    248   \}
    249 }
    250231
    251232# imagescript only used in nav_ns4.dm
Note: See TracChangeset for help on using the changeset viewer.