<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<?xml-stylesheet type="text/xsl" href="./modx.prosilver.en.xsl" ?>
<!--
	NOTICE: Please open this file in your web browser. If presented with a security warning, you may safely tell it to allow the blocked content.
-->
<!--For security purposes, please check: http://www.phpbb.com/mods/ for the latest version of this MOD. Although MODs are checked before being allowed in the MODs Database there is no guarantee that there are no security problems within the MOD. No support will be given for MODs not found within the MODs Database which can be found at http://www.phpbb.com/mods/-->
<mod xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://www.phpbb.com/mods/xml/modx-1.2.2.xsd">
<header>
	<meta name="generator" content="MODX file generated with PP MODX Creator by tumba25" />
	<license>http://opensource.org/licenses/gpl-license.php GNU General Public License v2</license>
	<title lang="en">Add Homepage link in header</title>
	<title lang="el">Add Homepage link in header</title>
	<description lang="en">Creates an ACP field in board settings section, where you can add your homepage's URL and it will be displayed on the header of your forum (Right before "Board Index").
There are also switches to easily enable/disable the mod, open your homepage in a new window, set the title etc..</description>
	<description lang="el">Δημιουργεί ένα νέο πεδίο στον Π.Ε.Δ. όπου μπορείτε να εισάγετε το URL της αρχικής σας σελίδας στην κορυφή της κοινότητάς σας (ακριβώς πριν το "Αρχική Κοινότητας").
Υπάρχει δυνατότητα ενεργοποίησης/απενεργοποίησης, ορισμού του τίτλου, ελέγχου αν θα ανοίγει ή όχι σε νέο παράθυρο κλπ..</description>
	<author-notes lang="en">I saw a lot of people asking about this, so I decided to make a howto and pack it as a mod:)
Since version 1.0.6 it is much more than a simple howto, though...:)</author-notes>
	<author-notes lang="el">Μιας και πολλοί έψαχναν τρόπο για να βάλουν τον σύνδεσμο της αρχικής τους σελίδας στην σελίδα της κοινότητάς τους αποφάσισα να φτιάξω έναν οδηγό και να τον πακετάρω σαν MOD.
Από την έκδοση 1.0.6 και μετά, βέβαια, είναι πολύ περισσότερα από ένας απλός οδηγός...:)</author-notes>
	<author-group>
		<author>
			<realname>Chris</realname>
			<username>ChriZathens</username>
			<homepage>http://www.seatnet.gr</homepage>
		</author>
	</author-group>
	<mod-version>1.0.8</mod-version>
	<installation>
		<level>easy</level>
		<time>420</time>
		<target-version>3.0.5</target-version>
	</installation>
	<history>
		<entry>
			<date>2009-05-18</date>
			<rev-version>1.0.0</rev-version>
			<changelog lang="el">
				<change>Αρχική έκδοση</change>
			</changelog>
			<changelog lang="en">
				<change>Initial release.</change>
			</changelog>
		</entry>
		<entry>
			<date>2009-05-18</date>
			<rev-version>1.0.1</rev-version>
			<changelog lang="el">
				<change>Αλλάχτηκε το  access από  h σε y - για την πρόταση αυτή ευχαριστώ πολύ  camm15h.</change>
			</changelog>
			<changelog lang="en">
				<change>Changed the access key from h to y - thanks to a recommendation by camm15h.</change>
			</changelog>
		</entry>
		<entry>
			<date>2009-06-08</date>
			<rev-version>1.0.2</rev-version>
			<changelog lang="el">
				<change>Αλλαγές στο πακέτο - υποβλήθηκε στην MODDB για έγκριση :)</change>
			</changelog>
			<changelog lang="en">
				<change>Changes in the package - submitted in the MODDB for validation :)</change>
			</changelog>
		</entry>
		<entry>
			<date>2009-07-02</date>
			<rev-version>1.0.3</rev-version>
			<changelog lang="el">
				<change>Προστέθηκε ένα /li tag το οποίο έλειπε και το MOD αποτύγχανε στον έλεγχο για συμβατότητα XHTML 1.0 Strict. (Χαζομάρα μου...)</change>
			</changelog>
			<changelog lang="en">
				<change>Added a missing /li tag which was causing mod to fail XHTML 1.0 Strict validation.(my bad...)</change>
			</changelog>
		</entry>
		<entry>
			<date>2009-07-03</date>
			<rev-version>1.0.4</rev-version>
			<changelog lang="el">
				<change>Προστέθηκε δυνατότητα ελέγχου του υπερσυνδέσμου μέσα από τον Π.Ε.Δ.</change>
				<change>Επανασχεδιαμός όλου σχεδόν του MOD</change>
			</changelog>
			<changelog lang="en">
				<change>Redesign of the whole mod:</change>
				<change>Added ACP control for the link</change>
			</changelog>
		</entry>
		<entry>
			<date>2009-07-04</date>
			<rev-version>1.0.5</rev-version>
			<changelog lang="el">
				<change>Προστέθηκε δυνατότητα για ενεργοποίηση/απενεργοποίηση του MOD</change>
			</changelog>
			<changelog lang="en">
				<change>Added the ability to turn the mod on/off</change>
			</changelog>
		</entry>
		<entry>
			<date>2009-07-05</date>
			<rev-version>1.0.6</rev-version>
			<changelog lang="el">
				<change>Τώρα, αν το MOD είναι μεν ενεργό, αλλά δεν βάλετε τίποτα στην διεύθυνση, δεν θα εμφανίζεται ούτε ο υπερσύνδεσμος :)</change>
			</changelog>
			<changelog lang="en">
				<change>Now, if the mod is enabled but  you enter nothing in your homepage address, the link will not show, either :)</change>
			</changelog>
		</entry>
		<entry>
			<date>2009-07-11</date>
			<rev-version>1.0.7</rev-version>
			<changelog lang="el">
				<change>Προστέθηκε η δυνατότητα ώστε, προαιρετικά, να ανοίγει η αρχική σας σελίδα σε νέο παράθυρο</change>
				<change>Προστέθηκε η δυνατότητα ώστε, προαιρετικά, να εισάγετε τον τίτλο της αρχικής σας σελίδας</change>
			</changelog>
			<changelog lang="en">
				<change>Added the ability to optionaly open your homepage in a new window</change>
				<change>Added the ability to optionaly set your homepage's title</change>
			</changelog>
		</entry>
		<entry>
			<date>2009-07-15</date>
			<rev-version>1.0.8</rev-version>
			<changelog lang="el">
				<change>Κάποιες αλλαγές για να μπορέσει να εγκριθεί</change>
			</changelog>
			<changelog lang="en">
				<change>Made some changes to make validation possible</change>
			</changelog>
		</entry>
	</history>
	<link-group>
		<link type="template" href="contrib/subsilver2.xml" lang="en">subsilver2 instructions</link>
		<link type="contrib" href="contrib/upgrade_1.0.2_to_1.0.8.xml" lang="en">upgrade from version 1.0.2</link>
		<link type="language" href="contrib/el.xml" lang="el">Greek (Hellenic) language changes</link>
		<link type="template" href="contrib/subsilver2_1.0.2_to_1.0.8.xml" lang="en">subsilver2 upgrade from 1.0.2 instructions</link>
	</link-group>
</header>
<action-group>
	<sql><![CDATA[INSERT INTO phpbb_config (config_name, config_value) VALUES ('show_homepage', '0');
INSERT INTO phpbb_config (config_name, config_value) VALUES ('show_homepage_in_new', '0');
INSERT INTO phpbb_config (config_name, config_value) VALUES ('homepage_url', 'http://www.your_own_site.com');
INSERT INTO phpbb_config (config_name, config_value) VALUES ('homepage_title', 'Your homepage title');]]></sql>
	<open src="includes/functions.php">
		<edit>
			<find><![CDATA[		'SITE_LOGO_IMG'			=> $user->img('site_logo'),]]></find>
			<action type="after-add"><![CDATA[		'S_SHOW_HOMEPAGE'		=> ($config['show_homepage']) ? true : false ,
		'S_SHOW_HOMEPAGE_IN_NEW' => ($config['show_homepage_in_new']) ? true : false ,
		'U_HOMEPAGE'			=> $config['homepage_url'],
		'U_HOMEPAGE_TITLE'		=> $config['homepage_title'],]]></action>
		</edit>
	</open>
	<open src="includes/acp/acp_board.php">
		<edit>
			<find><![CDATA[						'site_desc'				=> array('lang' => 'SITE_DESC',				'validate' => 'string',	'type' => 'text:40:255', 'explain' => false),]]></find>
			<action type="after-add"><![CDATA[						'show_homepage'			=> array('lang' => 'SHOW_HOMEPAGE',			'validate' => 'bool',	'type' => 'radio:yes_no', 'explain' => true),
						'show_homepage_in_new'	=> array('lang' => 'SHOW_HOMEPAGE_IN_NEW',	'validate' => 'bool',	'type' => 'radio:yes_no', 'explain' => true),
						'homepage_url'			=> array('lang' => 'HOMEPAGE_URL',			'validate' => 'string',	'type' => 'text:40:255', 'explain' => true),
						'homepage_title'		=> array('lang' => 'HOMEPAGE_TITLE',		'validate' => 'string',	'type' => 'text:40:255', 'explain' => true),]]></action>
		</edit>
	</open>
	<open src="language/en/common.php">
		<edit>
			<find><![CDATA[	'HOME'							=> 'Home',]]></find>
			<action type="after-add"><![CDATA[	'HOMEPAGE'						=> 'Homepage',]]></action>
		</edit>
	</open>
	<open src="language/en/acp/board.php">
		<edit>
			<find><![CDATA[	'DISABLE_BOARD'					=> 'Disable board',]]></find>
			<action type="after-add"><![CDATA[	'HOMEPAGE_URL'					=> 'Homepage url',
	'HOMEPAGE_URL_EXPLAIN'			=> 'Enter here your homepage’s URL. You can either use something like "../site", if your homepage is at the same domain, or use the absolute path for other domains.. ',
	'HOMEPAGE_TITLE'				=> 'Homepage title',
	'HOMEPAGE_TITLE_EXPLAIN'		=> 'This title will show when you have your mouse over your homepage link. If you don´t want to show a title, just leave this field blank.',]]></action>
		</edit>
		<edit>
			<find><![CDATA[	'OVERRIDE_STYLE_EXPLAIN'		=> 'Replaces user’s style with the default.',]]></find>
			<action type="after-add"><![CDATA[	'SHOW_HOMEPAGE'					=> 'Show your homepage URL on the header',
	'SHOW_HOMEPAGE_EXPLAIN'			=> 'If you select "No" your homepage URL will not be shown on the header',
	'SHOW_HOMEPAGE_IN_NEW'			=> 'Homepage in new window',
	'SHOW_HOMEPAGE_IN_NEW_EXPLAIN'	=> 'If you select "Yes" the link to your homepage will open in a new window',
]]></action>
		</edit>
	</open>
	<open src="styles/prosilver/template/overall_header.html">
		<edit>
			<find><![CDATA[				<li class="icon-home"><a href="{U_INDEX}" accesskey="h">{L_INDEX}]]></find>
			<inline-edit>
				<inline-find><![CDATA[<li class="icon-home">]]></inline-find>
				<inline-action type="before-add"><![CDATA[<!-- IF S_SHOW_HOMEPAGE and U_HOMEPAGE --><li class="icon-home"><a href="{U_HOMEPAGE}" <!-- IF U_HOMEPAGE_TITLE -->title="{U_HOMEPAGE_TITLE}"<!-- ENDIF --><!-- IF S_SHOW_HOMEPAGE_IN_NEW -->onclick="window.open(this.href); return false;"<!-- ENDIF --> accesskey="y">{L_HOMEPAGE}</a></li><!-- ENDIF -->]]></inline-action>
			</inline-edit>
		</edit>
	</open>
	<diy-instructions lang="en">Go to your ACP, clear your cache and refresh your templates
The new field in your ACP, where you can insert your homepage address is located in "Board Configuration" --> Board settings</diy-instructions>
	<diy-instructions lang="el">Πηγαίνετε στον Π.Ε.Δ., καθαρίστε την λανθάνουσα μνήμη και κάντε ανανέωση των προτύπων σας.
Το νέο πεδίο, όπου μπορείτε να εισάγετε την διεύθυνση της αρχικής σας σελίδας, βρίσκεται στον Π.Ε.Δ.--> "Παραμετροποίηση Δ. Συζήτησης" --> Ρυθμίσεις Δ. Συζήτησης</diy-instructions>
</action-group>
</mod>
