From a589b04566b4e4a6f787fd1bf81d1f32e1ea1dd9 Mon Sep 17 00:00:00 2001 From: Denis Walker <dez@sucs.org> Date: Mon, 26 Nov 2007 19:30:40 +0000 Subject: [PATCH] Moves some of the text in the templates into settings.php --- settingstemplate | 8 ++++++++ templates/foot.cy.tpl | 4 +--- templates/foot.tpl | 2 +- templates/head.tpl | 2 +- templates/search.cy.tpl | 6 +++--- templates/search.tpl | 8 ++++---- 6 files changed, 18 insertions(+), 12 deletions(-) diff --git a/settingstemplate b/settingstemplate index 430cdd4..8764ac8 100644 --- a/settingstemplate +++ b/settingstemplate @@ -1,4 +1,12 @@ <?php +// Name of the website +define('SUCS_SITENAME', 'SUCS'); + +// Disclaimer/Copyright notice +define('SUCS_FOOTERMSG', 'SUCSsite - created by members of <a href="http://sucs.org/">SUCS</a>'); +// ...in Welsh +define('SUCS_FOOTERMSG_cy', 'SUCSsite - creu gan ymaelodau <a href="http://sucs.org/">CGPA</a>'); + // root directory for website - *with* trailing / define('SUCS_BASEDIR', '$BASEDIR/'); diff --git a/templates/foot.cy.tpl b/templates/foot.cy.tpl index 5d1fd80..29c2f5d 100644 --- a/templates/foot.cy.tpl +++ b/templates/foot.cy.tpl @@ -13,9 +13,7 @@ <div class="cornerBottomLeft"> <div class="cornerBottomRight"> - <p> - Cynnalwyd y safle hwn a cynllunwyd gan CGPA. Mae personau perthnasol sy biau y barnau rhain nid y gymdeithas. - </p> + <p>{$smarty.const.SUCS_FOOTERMSG_cy}</p> </div> </div> </div> diff --git a/templates/foot.tpl b/templates/foot.tpl index 8057465..2f51fd3 100644 --- a/templates/foot.tpl +++ b/templates/foot.tpl @@ -17,7 +17,7 @@ <div id="footer"> <div class="cornerBottomLeft"> <div class="cornerBottomRight"> - <p>Site designed and maintained by SUCS. All opinions expressed are those of the relevant individual and not of the society.</p> + <p>{$smarty.const.SUCS_FOOTERMSG}</p> {if isset($totaltime)}<p>Script executed in {$totaltime} seconds</p>{/if} </div> </div> diff --git a/templates/head.tpl b/templates/head.tpl index 2f8ed49..2b0caf0 100644 --- a/templates/head.tpl +++ b/templates/head.tpl @@ -3,7 +3,7 @@ <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="{$language.code}"> <head> - <title>{$title} - SUCS</title> + <title>{$title} - {$smarty.const.SUCS_SITENAME}</title> <link rel="SHORTCUT ICON" href="/favicon.ico" /> <script type="text/javascript" src="/js/cb.js"></script> diff --git a/templates/search.cy.tpl b/templates/search.cy.tpl index d174d04..c300e2f 100644 --- a/templates/search.cy.tpl +++ b/templates/search.cy.tpl @@ -9,9 +9,9 @@ <input class="submit" type="submit" name="sa" value="Chwilio" /> </div> - <input type="hidden" name="cof" value="S:http://sucs.org;AH:left;LH:76;L:http://beta.sucs.org/images/sucslogo-halo.png;LW:170;AWFID:624aceb6f2753532;" /> - <input type="hidden" name="domains" value="sucs.org" /> - <input type="hidden" name="sitesearch" value="sucs.org" /> + <input type="hidden" name="cof" value="S:http://{$smarty.const.SUCS_BASEURL};AH:left;LH:76;L:http://{$smarty.const.SUCS_PREFERRED_HOSTNAME}{$smarty.const.SUCS_BASEURL}/images/sucslogo-halo.png;LW:170;AWFID:624aceb6f2753532;" /> + <input type="hidden" name="domains" value="{$smarty.const.SUCS_BASEURL}" /> + <input type="hidden" name="sitesearch" value="{$smarty.const.SUCS_BASEURL}" /> </div> </form> <div class="clear"> </div> diff --git a/templates/search.tpl b/templates/search.tpl index 308d379..2620140 100644 --- a/templates/search.tpl +++ b/templates/search.tpl @@ -1,5 +1,5 @@ <div class="cbb"> - <h3>Search SUCS</h3> + <h3>Search {$smarty.const.SUCS_SITENAME}</h3> <form method="get" action="http://www.google.co.uk/custom"> <div id="search"> <input type="text" class="text" name="q" maxlength="255" value="" /><br /> @@ -9,9 +9,9 @@ <input class="submit" type="submit" name="sa" value="Search" /> </div> - <input type="hidden" name="cof" value="S:http://sucs.org;AH:left;LH:76;L:http://beta.sucs.org/images/sucslogo-halo.png;LW:170;AWFID:624aceb6f2753532;" /> - <input type="hidden" name="domains" value="sucs.org" /> - <input type="hidden" name="sitesearch" value="sucs.org" /> + <input type="hidden" name="cof" value="S:http://{$smarty.const.SUCS_PREFERRED_HOSTNAME};AH:left;LH:76;L:http://{$smarty.const.SUCS_PREFERRED_HOSTNAME}{$smarty.const.SUCS_BASEURL}/images/sucslogo-halo.png;LW:170;AWFID:624aceb6f2753532;" /> + <input type="hidden" name="domains" value="{$smarty.const.SUCS_PREFERRED_HOSTNAME}" /> + <input type="hidden" name="sitesearch" value="{$smarty.const.SUCS_PREFERRED_HOSTNAME}" /> </div> </form> -- GitLab