Skip to content

Instantly share code, notes, and snippets.

@rwetzlmayr
Created December 27, 2011 07:16
Show Gist options
  • Save rwetzlmayr/1522950 to your computer and use it in GitHub Desktop.
Save rwetzlmayr/1522950 to your computer and use it in GitHub Desktop.
meta element 'description' for Textpattern sites w/ one page equaling one section
<txp:if_section name="default"><txp:variable name="s" value="home" /><txp:else /><txp:variable name="s" value='<txp:section />' /></txp:if_section>
<txp:article_custom section='<txp:variable name="s" />' limit="1">
<meta name="description" content="<txp:title />: <txp:rss_auto_excerpt words="30" striptags="1" showlinkwithexcerpt="0" stripbreakstabs="1" excerptwraptag="" ending="&#8230;" />" />
</txp:article_custom>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment