Create $extraHeaders for pages with blog entries.
This commit is contained in:
		
							parent
							
								
									46d61d79b9
								
							
						
					
					
						commit
						86c17427d5
					
				
					 1 changed files with 17 additions and 5 deletions
				
			
		|  | @ -12,13 +12,12 @@ site=$SERVER_NAME | ||||||
| sitedir=sites/$site | sitedir=sites/$site | ||||||
| headers=inc/headers.tpl | headers=inc/headers.tpl | ||||||
| body=index | body=index | ||||||
| siteTitle='' |  | ||||||
| siteSubTitle='' |  | ||||||
| title='' |  | ||||||
| template=_default | template=_default | ||||||
| sidebar=sidebar | sidebar=sidebar | ||||||
| basedir=/gsoc/www | basedir=/gsoc/www | ||||||
| baseuri=http://$site | baseuri=http://$site | ||||||
|  | for(i in siteTitle siteSubTitle title extraHeaders) | ||||||
|  |     $i = '' | ||||||
| 
 | 
 | ||||||
| # Title | # Title | ||||||
| fn gentitle { | fn gentitle { | ||||||
|  | @ -117,11 +116,24 @@ for ( i in '' $args ) { | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| template=$sitedir/$template.tpl | template=$sitedir/$template.tpl | ||||||
| body=$sitedir/$body |  | ||||||
| if (! ~ $#sidebar 0) | if (! ~ $#sidebar 0) | ||||||
|     sidebar=tpl/_inc/$sidebar.tpl |     sidebar=tpl/_inc/$sidebar.tpl | ||||||
| if (test -d $body) | 
 | ||||||
|  | body=$sitedir/$body | ||||||
|  | rssuri=$uri | ||||||
|  | if (test -d $body) { | ||||||
|     body=$body/index |     body=$body/index | ||||||
|  |     rssuri=$rssuri/ | ||||||
|  | } | ||||||
|  | rssuri=`{cleanname `{basename -d $uri}^/index.rss} | ||||||
|  | rssuri=$baseuri$rssuri | ||||||
|  | 
 | ||||||
|  | if(! ~ $#blogDirs 0) | ||||||
|  |     extraHeaders=$"extraHeaders ^ \ | ||||||
|  |     	'<link rel="alternate" type="application/rss+xml" title="RSS" href="'$rssuri'"> | ||||||
|  | ' | ||||||
|  | 
 | ||||||
|  | echo hesd: $extraHeaders | ||||||
| 
 | 
 | ||||||
| # RSS | # RSS | ||||||
| fn statpost { | fn statpost { | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Kris Maglione
						Kris Maglione