<?php
$c=&$this->config;
$c['manager_theme'] = "MODxRE";
$c['settings_version'] = "1.0.12";
$c['show_meta'] = "0";
$c['server_offset_time'] = "0";
$c['server_protocol'] = "http";
$c['manager_language'] = "english";
$c['modx_charset'] = "UTF-8";
$c['site_name'] = "Tinfra Engineering Limited ";
$c['site_start'] = "1";
$c['error_page'] = "7";
$c['unauthorized_page'] = "4";
$c['site_status'] = "1";
$c['site_unavailable_message'] = "The site is currently unavailable";
$c['track_visitors'] = "0";
$c['top_howmany'] = "10";
$c['auto_template_logic'] = "parent";
$c['default_template'] = "3";
$c['old_template'] = "3";
$c['publish_default'] = "0";
$c['cache_default'] = "1";
$c['search_default'] = "1";
$c['friendly_urls'] = "0";
$c['friendly_url_prefix'] = "";
$c['friendly_url_suffix'] = ".html";
$c['friendly_alias_urls'] = "1";
$c['use_alias_path'] = "1";
$c['use_udperms'] = "1";
$c['udperms_allowroot'] = "0";
$c['failed_login_attempts'] = "3";
$c['blocked_minutes'] = "60";
$c['use_captcha'] = "0";
$c['captcha_words'] = "MODX,Access,Better,BitCode,Cache,Desc,Design,Excell,Enjoy,URLs,TechView,Gerald,Griff,Humphrey,Holiday,Intel,Integration,Joystick,Join(),Tattoo,Genetic,Light,Likeness,Marit,Maaike,Niche,Netherlands,Ordinance,Oscillo,Parser,Phusion,Query,Question,Regalia,Righteous,Snippet,Sentinel,Template,Thespian,Unity,Enterprise,Verily,Veri,Website,WideWeb,Yap,Yellow,Zebra,Zygote";
$c['emailsender'] = "babumuraya@gmail.com";
$c['email_method'] = "mail";
$c['smtp_auth'] = "0";
$c['smtp_host'] = "";
$c['smtp_port'] = "25";
$c['smtp_username'] = "";
$c['emailsubject'] = "Your login details";
$c['number_of_logs'] = "100";
$c['number_of_messages'] = "30";
$c['number_of_results'] = "20";
$c['use_editor'] = "1";
$c['use_browser'] = "1";
$c['rb_base_dir'] = "C:/xampp/htdocs/tinfra/assets/";
$c['rb_base_url'] = "assets/";
$c['which_editor'] = "TinyMCE";
$c['fe_editor_lang'] = "english";
$c['fck_editor_toolbar'] = "standard";
$c['fck_editor_autolang'] = "0";
$c['editor_css_path'] = "";
$c['editor_css_selectors'] = "";
$c['strip_image_paths'] = "1";
$c['upload_images'] = "bmp,ico,gif,jpeg,jpg,png,psd,tif,tiff";
$c['upload_media'] = "au,avi,mp3,mp4,mpeg,mpg,wav,wmv";
$c['upload_flash'] = "fla,flv,swf";
$c['upload_files'] = "aac,au,avi,css,cache,doc,docx,gz,gzip,htaccess,htm,html,js,mp3,mp4,mpeg,mpg,ods,odp,odt,pdf,ppt,pptx,rar,tar,tgz,txt,wav,wmv,xls,xlsx,xml,z,zip";
$c['upload_maxsize'] = "1048576";
$c['new_file_permissions'] = "0644";
$c['new_folder_permissions'] = "0755";
$c['filemanager_path'] = "C:/xampp/htdocs/tinfra/";
$c['theme_refresher'] = "";
$c['manager_layout'] = "4";
$c['custom_contenttype'] = "application/rss+xml,application/pdf,application/vnd.ms-word,application/vnd.ms-excel,text/html,text/css,text/xml,text/javascript,text/plain,application/json";
$c['auto_menuindex'] = "1";
$c['session.cookie.lifetime'] = "604800";
$c['mail_check_timeperiod'] = "60";
$c['manager_direction'] = "ltr";
$c['tinymce_editor_theme'] = "editor";
$c['tinymce_custom_plugins'] = "style,advimage,advlink,searchreplace,print,contextmenu,paste,fullscreen,nonbreaking,xhtmlxtras,visualchars,media";
$c['tinymce_custom_buttons1'] = "undo,redo,selectall,separator,pastetext,pasteword,separator,search,replace,separator,nonbreaking,hr,charmap,separator,image,link,unlink,anchor,media,separator,cleanup,removeformat,separator,fullscreen,print,code,help";
$c['tinymce_custom_buttons2'] = "bold,italic,underline,strikethrough,sub,sup,separator,bullist,numlist,outdent,indent,separator,justifyleft,justifycenter,justifyright,justifyfull,separator,styleselect,formatselect,separator,styleprops";
$c['tree_show_protected'] = "0";
$c['rss_url_news'] = "http://feeds.feedburner.com/modx-announce";
$c['rss_url_security'] = "http://feeds.feedburner.com/modxsecurity";
$c['validate_referer'] = "1";
$c['datepicker_offset'] = "-10";
$c['xhtml_urls'] = "1";
$c['allow_duplicate_alias'] = "0";
$c['automatic_alias'] = "1";
$c['datetime_format'] = "dd-mm-YYYY";
$c['warning_visibility'] = "1";
$c['remember_last_tab'] = "0";
$c['enable_bindings'] = "1";
$c['seostrict'] = "0";
$c['cache_type'] = "1";
$c['maxImageWidth'] = "1600";
$c['maxImageHeight'] = "1200";
$c['thumbWidth'] = "150";
$c['thumbHeight'] = "150";
$c['thumbsDir'] = ".thumbs";
$c['jpegQuality'] = "90";
$c['denyZipDownload'] = "0";
$c['denyExtensionRename'] = "0";
$c['showHiddenFiles'] = "0";
$c['docid_incrmnt_method'] = "0";
$c['make_folders'] = "0";
$c['site_id'] = "52b6b2c57dc47";
$c['site_unavailable_page'] = "";
$c['reload_site_unavailable'] = "";
$c['siteunavailable_message_default'] = "The site is currently unavailable.";
$c['check_files_onlogin'] = "index.php\r\n.htaccess\r\nmanager/index.php\r\nmanager/includes/config.inc.php";
$c['error_reporting'] = "1";
$c['send_errormail'] = "3";
$c['pwd_hash_algo'] = "UNCRYPT";
$c['reload_captcha_words'] = "";
$c['captcha_words_default'] = "MODX,Access,Better,BitCode,Chunk,Cache,Desc,Design,Excell,Enjoy,URLs,TechView,Gerald,Griff,Humphrey,Holiday,Intel,Integration,Joystick,Join(),Oscope,Genetic,Light,Likeness,Marit,Maaike,Niche,Netherlands,Ordinance,Oscillo,Parser,Phusion,Query,Question,Regalia,Righteous,Snippet,Sentinel,Template,Thespian,Unity,Enterprise,Verily,Tattoo,Veri,Website,WideWeb,Yap,Yellow,Zebra,Zygote";
$c['reload_emailsubject'] = "";
$c['emailsubject_default'] = "Your login details";
$c['reload_signupemail_message'] = "";
$c['signupemail_message'] = "Hello [+uid+] \r\n\r\nHere are your login details for [+sname+] Content Manager:\r\n\r\nUsername: [+uid+]\r\nPassword: [+pwd+]\r\n\r\nOnce you log into the Content Manager ([+surl+]), you can change your password.\r\n\r\nRegards,\r\nSite Administrator";
$c['system_email_signup_default'] = "Hello [+uid+] \r\n\r\nHere are your login details for [+sname+] Content Manager:\r\n\r\nUsername: [+uid+]\r\nPassword: [+pwd+]\r\n\r\nOnce you log into the Content Manager ([+surl+]), you can change your password.\r\n\r\nRegards,\r\nSite Administrator";
$c['reload_websignupemail_message'] = "";
$c['websignupemail_message'] = "Hello [+uid+]\r\n\r\nHere are your login details for [+sname+]:\r\n\r\nUsername: [+uid+]\r\nPassword: [+pwd+]\r\n\r\nOnce you log into [+sname+] ([+surl+]), you can change your password.\r\n\r\nRegards,\r\nSite Administrator";
$c['system_email_websignup_default'] = "Hello [+uid+]\r\n\r\nHere are your login details for [+sname+]:\r\n\r\nUsername: [+uid+]\r\nPassword: [+pwd+]\r\n\r\nOnce you log into [+sname+] ([+surl+]), you can change your password.\r\n\r\nRegards,\r\nSite Administrator";
$c['reload_system_email_webreminder_message'] = "";
$c['webpwdreminder_message'] = "Hello [+uid+]\r\n\r\nTo activate your new password click the following link:\r\n\r\n[+surl+]\r\n\r\nIf successful you can use the following password to login:\r\n\r\nPassword:[+pwd+]\r\n\r\nIf you did not request this email then please ignore it.\r\n\r\nRegards,\r\nSite Administrator";
$c['system_email_webreminder_default'] = "Hello [+uid+]\r\n\r\nTo activate your new password click the following link:\r\n\r\n[+surl+]\r\n\r\nIf successful you can use the following password to login:\r\n\r\nPassword:[+pwd+]\r\n\r\nIf you did not request this email then please ignore it.\r\n\r\nRegards,\r\nSite Administrator";
$c['tree_page_click'] = "3";
$c['resource_tree_node_name'] = "pagetitle";
$c['rb_webuser'] = "0";
$c['clean_uploaded_filename'] = "0";
$c['mce_editor_skin'] = "default";
$c['mce_template_docs'] = "";
$c['mce_template_chunks'] = "";
$c['mce_entermode'] = "p";
$c['mce_element_format'] = "xhtml";
$c['mce_schema'] = "html4";
$c['tinymce_custom_buttons3'] = "";
$c['tinymce_custom_buttons4'] = "";
$c['tinymce_css_selectors'] = "left=justifyleft;right=justifyright";
$c['sys_files_checksum'] = "a:3:{s:32:\"C:/xampp/htdocs/tinfra/index.php\";s:32:\"cd008df3faa7d7ecbce5b05480fa8c34\";s:40:\"C:/xampp/htdocs/tinfra/manager/index.php\";s:32:\"ef228d1a7e707d376ab4e2ec314c7f6c\";s:54:\"C:/xampp/htdocs/tinfra/manager/includes/config.inc.php\";s:32:\"6ef1d5985048e606c683dfc4ece75287\";}";
$this->aliasListing = array();
$a = &$this->aliasListing;
$d = &$this->documentListing;
$m = &$this->documentMap;
$d['index'] = 1;
$a[1] = array('id' => 1, 'alias' => 'index', 'path' => '', 'parent' => 0, 'isfolder' => 0);
$m[] = array('0' => '1');
$d['blog'] = 2;
$a[2] = array('id' => 2, 'alias' => 'blog', 'path' => '', 'parent' => 0, 'isfolder' => 1);
$m[] = array('0' => '2');
$d['our-services'] = 15;
$a[15] = array('id' => 15, 'alias' => 'our-services', 'path' => '', 'parent' => 0, 'isfolder' => 1);
$m[] = array('0' => '15');
$d['33'] = 33;
$a[33] = array('id' => 33, 'alias' => '33', 'path' => '', 'parent' => 0, 'isfolder' => 0);
$m[] = array('0' => '33');
$d['about-us'] = 32;
$a[32] = array('id' => 32, 'alias' => 'about-us', 'path' => '', 'parent' => 0, 'isfolder' => 0);
$m[] = array('0' => '32');
$d['contact-us'] = 6;
$a[6] = array('id' => 6, 'alias' => 'contact-us', 'path' => '', 'parent' => 0, 'isfolder' => 0);
$m[] = array('0' => '6');
$d['thank-you'] = 46;
$a[46] = array('id' => 46, 'alias' => 'thank-you', 'path' => '', 'parent' => 0, 'isfolder' => 0);
$m[] = array('0' => '46');
$d['request-an-account'] = 5;
$a[5] = array('id' => 5, 'alias' => 'request-an-account', 'path' => '', 'parent' => 0, 'isfolder' => 0);
$m[] = array('0' => '5');
$d['blog-login'] = 37;
$a[37] = array('id' => 37, 'alias' => 'blog-login', 'path' => '', 'parent' => 0, 'isfolder' => 0);
$m[] = array('0' => '37');
$d['login'] = 4;
$a[4] = array('id' => 4, 'alias' => 'login', 'path' => '', 'parent' => 0, 'isfolder' => 0);
$m[] = array('0' => '4');
$d['search-results'] = 8;
$a[8] = array('id' => 8, 'alias' => 'search-results', 'path' => '', 'parent' => 0, 'isfolder' => 0);
$m[] = array('0' => '8');
$d['feed.rss'] = 11;
$a[11] = array('id' => 11, 'alias' => 'feed.rss', 'path' => '', 'parent' => 0, 'isfolder' => 0);
$m[] = array('0' => '11');
$d['doc-not-found'] = 7;
$a[7] = array('id' => 7, 'alias' => 'doc-not-found', 'path' => '', 'parent' => 0, 'isfolder' => 0);
$m[] = array('0' => '7');
$d['tools-and-equipment'] = 50;
$a[50] = array('id' => 50, 'alias' => 'tools-and-equipment', 'path' => '', 'parent' => 0, 'isfolder' => 0);
$m[] = array('0' => '50');
$d['our-projects'] = 51;
$a[51] = array('id' => 51, 'alias' => 'our-projects', 'path' => '', 'parent' => 0, 'isfolder' => 0);
$m[] = array('0' => '51');
$d['gallery'] = 52;
$a[52] = array('id' => 52, 'alias' => 'gallery', 'path' => '', 'parent' => 0, 'isfolder' => 0);
$m[] = array('0' => '52');
$d['article-1126081344'] = 9;
$a[9] = array('id' => 9, 'alias' => 'article-1126081344', 'path' => '', 'parent' => 2, 'isfolder' => 0);
$m[] = array('2' => '9');
$d['article-1128398162'] = 18;
$a[18] = array('id' => 18, 'alias' => 'article-1128398162', 'path' => '', 'parent' => 2, 'isfolder' => 0);
$m[] = array('2' => '18');
$d['turnkey-consulting-services'] = 16;
$a[16] = array('id' => 16, 'alias' => 'turnkey-consulting-services', 'path' => '', 'parent' => 15, 'isfolder' => 0);
$m[] = array('15' => '16');
$d['building-construction'] = 22;
$a[22] = array('id' => 22, 'alias' => 'building-construction', 'path' => '', 'parent' => 15, 'isfolder' => 0);
$m[] = array('15' => '22');
$d['maintenance-of-existing-structures'] = 14;
$a[14] = array('id' => 14, 'alias' => 'maintenance-of-existing-structures', 'path' => '', 'parent' => 15, 'isfolder' => 0);
$m[] = array('15' => '14');
$d['49'] = 49;
$a[49] = array('id' => 49, 'alias' => '49', 'path' => '', 'parent' => 15, 'isfolder' => 0);
$m[] = array('15' => '49');
$d['48'] = 48;
$a[48] = array('id' => 48, 'alias' => '48', 'path' => '', 'parent' => 15, 'isfolder' => 0);
$m[] = array('15' => '48');
$d['47'] = 47;
$a[47] = array('id' => 47, 'alias' => '47', 'path' => '', 'parent' => 15, 'isfolder' => 0);
$m[] = array('15' => '47');
$d['modification-and-renovations-to-existing-structures'] = 24;
$a[24] = array('id' => 24, 'alias' => 'modification-and-renovations-to-existing-structures', 'path' => '', 'parent' => 15, 'isfolder' => 0);
$m[] = array('15' => '24');
$c = &$this->contentTypes;
$c[11] = 'text/xml';
$c = &$this->chunkCache;
$c['mm_rules'] = '// more example rules are in assets/plugins/managermanager/example_mm_rules.inc.php

// example of how PHP is allowed - check that a TV named documentTags exists before creating rule
if($modx->db->getValue("SELECT COUNT(id) FROM " . $modx->getFullTableName(\'site_tmplvars\') . " WHERE name=\'documentTags\'")) {
    mm_widget_tags(\'documentTags\',\' \'); // Give blog tag editing capabilities to the \'documentTags (3)\' TV
}
mm_widget_showimagetvs(); // Always give a preview of Image TVs
';
$c['WebLoginSideBar'] = '<!-- #declare:separator <hr> -->
<!-- login form section-->
<form method="post" name="loginfrm" action="[+action+]">
    <input type="hidden" value="[+rememberme+]" name="rememberme" />
    <fieldset>
        <h3>Your Login Details</h3>
        <label for="username">User: <input type="text" name="username" id="username" tabindex="1" onkeypress="return webLoginEnter(document.loginfrm.password);" value="[+username+]" /></label>
    	<label for="password">Password: <input type="password" name="password" id="password" tabindex="2" onkeypress="return webLoginEnter(document.loginfrm.cmdweblogin);" value="" /></label>
    	<input type="checkbox" id="checkbox_1" name="checkbox_1" tabindex="3" size="1" value="" [+checkbox+] onclick="webLoginCheckRemember()" /><label for="checkbox_1" class="checkbox">Remember me</label>
    	<input type="submit" value="[+logintext+]" name="cmdweblogin" class="button" />
	<a href="#" onclick="webLoginShowForm(2);return false;" id="forgotpsswd">Forget Your Password?</a>
	</fieldset>
</form>
<hr>
<!-- log out hyperlink section -->
<h4>You\'re already logged in</h4>
Do you wish to <a href="[+action+]" class="button">[+logouttext+]</a>?
<hr>
<!-- Password reminder form section -->
<form name="loginreminder" method="post" action="[+action+]">
    <fieldset>
        <h3>It happens to everyone...</h3>
        <input type="hidden" name="txtpwdrem" value="0" />
        <label for="txtwebemail">Enter the email address of your account to reset your password: <input type="text" name="txtwebemail" id="txtwebemail" size="24" /></label>
        <label>To return to the login form, press the cancel button.</label>
    	<input type="submit" value="Submit" name="cmdweblogin" class="button" /> <input type="reset" value="Cancel" name="cmdcancel" onclick="webLoginShowForm(1);" class="button" style="clear:none;display:inline" />
    </fieldset>
</form>

';
$c['FormSignup'] = '<!-- #declare:separator <hr> --> 
<!-- login form section-->
<form id="websignupfrm" method="post" name="websignupfrm" action="[+action+]">
    <fieldset>
        <h3>User Details</h3>
        <p>Items marked by * are required</p>
		<label for="su_username">User name:* <input type="text" name="username" id="su_username" class="inputBox" size="20" maxlength="30" value="[+username+]" /></label>
        <label for="fullname">Full name: <input type="text" name="fullname" id="fullname" class="inputBox" size="20" maxlength="100" value="[+fullname+]" /></label>
		<label for="email">Email address:* <input type="text" name="email" id="email" class="inputBox" size="20" value="[+email+]" /></label>
	</fieldset>
	
	<fieldset>
	    <h3>Password</h3>
	    <label for="su_password">Password:* <input type="password" name="password" id="su_password" class="inputBox" size="20" /></label>
	    <label for="confirmpassword">Confirm password:* <input type="password" name="confirmpassword" id="confirmpassword" class="inputBox" size="20" /></label>
	</fieldset>
	
	<fieldset>
		<h3>Optional Account Profile Info</h3>
		<label for="country">Country:</label>
		<select size="1" name="country" id="country">
			<option value="" selected="selected">&nbsp;</option>
			<option value="1">Afghanistan</option>
			<option value="2">Albania</option>
			<option value="3">Algeria</option>
			<option value="4">American Samoa</option>
			<option value="5">Andorra</option>
			<option value="6">Angola</option>
			<option value="7">Anguilla</option>
			<option value="8">Antarctica</option>
			<option value="9">Antigua and Barbuda</option>
			<option value="10">Argentina</option>
			<option value="11">Armenia</option>
			<option value="12">Aruba</option>
			<option value="13">Australia</option>
			<option value="14">Austria</option>
			<option value="15">Azerbaijan</option>
			<option value="16">Bahamas</option>
			<option value="17">Bahrain</option>
			<option value="18">Bangladesh</option>
			<option value="19">Barbados</option>
			<option value="20">Belarus</option>
			<option value="21">Belgium</option>
			<option value="22">Belize</option>
			<option value="23">Benin</option>
			<option value="24">Bermuda</option>
			<option value="25">Bhutan</option>
			<option value="26">Bolivia</option>
			<option value="27">Bosnia and Herzegowina</option>
			<option value="28">Botswana</option>
			<option value="29">Bouvet Island</option>
			<option value="30">Brazil</option>
			<option value="31">British Indian Ocean Territory</option>
			<option value="32">Brunei Darussalam</option>
			<option value="33">Bulgaria</option>
			<option value="34">Burkina Faso</option>
			<option value="35">Burundi</option>
			<option value="36">Cambodia</option>
			<option value="37">Cameroon</option>
			<option value="38">Canada</option>
			<option value="39">Cape Verde</option>
			<option value="40">Cayman Islands</option>
			<option value="41">Central African Republic</option>
			<option value="42">Chad</option>
			<option value="43">Chile</option>
			<option value="44">China</option>
			<option value="45">Christmas Island</option>
			<option value="46">Cocos (Keeling) Islands</option>
			<option value="47">Colombia</option>
			<option value="48">Comoros</option>
			<option value="49">Congo</option>
			<option value="50">Cook Islands</option>
			<option value="51">Costa Rica</option>
			<option value="52">Cote D&#39;Ivoire</option>
			<option value="53">Croatia</option>
			<option value="54">Cuba</option>
			<option value="55">Cyprus</option>
			<option value="56">Czech Republic</option>
			<option value="57">Denmark</option>
			<option value="58">Djibouti</option>
			<option value="59">Dominica</option>
			<option value="60">Dominican Republic</option>
			<option value="61">East Timor</option>
			<option value="62">Ecuador</option>
			<option value="63">Egypt</option>
			<option value="64">El Salvador</option>
			<option value="65">Equatorial Guinea</option>
			<option value="66">Eritrea</option>
			<option value="67">Estonia</option>
			<option value="68">Ethiopia</option>
			<option value="69">Falkland Islands (Malvinas)</option>
			<option value="70">Faroe Islands</option>
			<option value="71">Fiji</option>
			<option value="72">Finland</option>
			<option value="73">France</option>
			<option value="74">France, Metropolitan</option>
			<option value="75">French Guiana</option>
			<option value="76">French Polynesia</option>
			<option value="77">French Southern Territories</option>
			<option value="78">Gabon</option>
			<option value="79">Gambia</option>
			<option value="80">Georgia</option>
			<option value="81">Germany</option>
			<option value="82">Ghana</option>
			<option value="83">Gibraltar</option>
			<option value="84">Greece</option>
			<option value="85">Greenland</option>
			<option value="86">Grenada</option>
			<option value="87">Guadeloupe</option>
			<option value="88">Guam</option>
			<option value="89">Guatemala</option>
			<option value="90">Guinea</option>
			<option value="91">Guinea-bissau</option>
			<option value="92">Guyana</option>
			<option value="93">Haiti</option>
			<option value="94">Heard and Mc Donald Islands</option>
			<option value="95">Honduras</option>
			<option value="96">Hong Kong</option>
			<option value="97">Hungary</option>
			<option value="98">Iceland</option>
			<option value="99">India</option>
			<option value="100">Indonesia</option>
			<option value="101">Iran (Islamic Republic of)</option>
			<option value="102">Iraq</option>
			<option value="103">Ireland</option>
			<option value="104">Israel</option>
			<option value="105">Italy</option>
			<option value="106">Jamaica</option>
			<option value="107">Japan</option>
			<option value="108">Jordan</option>
			<option value="109">Kazakhstan</option>
			<option value="110">Kenya</option>
			<option value="111">Kiribati</option>
			<option value="112">Korea, Democratic People&#39;s Republic of</option>
			<option value="113">Korea, Republic of</option>
			<option value="114">Kuwait</option>
			<option value="115">Kyrgyzstan</option>
			<option value="116">Lao People&#39;s Democratic Republic</option>
			<option value="117">Latvia</option>
			<option value="118">Lebanon</option>
			<option value="119">Lesotho</option>
			<option value="120">Liberia</option>
			<option value="121">Libyan Arab Jamahiriya</option>
			<option value="122">Liechtenstein</option>
			<option value="123">Lithuania</option>
			<option value="124">Luxembourg</option>
			<option value="125">Macau</option>
			<option value="126">Macedonia, The Former Yugoslav Republic of</option>
			<option value="127">Madagascar</option>
			<option value="128">Malawi</option>
			<option value="129">Malaysia</option>
			<option value="130">Maldives</option>
			<option value="131">Mali</option>
			<option value="132">Malta</option>
			<option value="133">Marshall Islands</option>
			<option value="134">Martinique</option>
			<option value="135">Mauritania</option>
			<option value="136">Mauritius</option>
			<option value="137">Mayotte</option>
			<option value="138">Mexico</option>
			<option value="139">Micronesia, Federated States of</option>
			<option value="140">Moldova, Republic of</option>
			<option value="141">Monaco</option>
			<option value="142">Mongolia</option>
			<option value="143">Montserrat</option>
			<option value="144">Morocco</option>
			<option value="145">Mozambique</option>
			<option value="146">Myanmar</option>
			<option value="147">Namibia</option>
			<option value="148">Nauru</option>
			<option value="149">Nepal</option>
			<option value="150">Netherlands</option>
			<option value="151">Netherlands Antilles</option>
			<option value="152">New Caledonia</option>
			<option value="153">New Zealand</option>
			<option value="154">Nicaragua</option>
			<option value="155">Niger</option>
			<option value="156">Nigeria</option>
			<option value="157">Niue</option>
			<option value="158">Norfolk Island</option>
			<option value="159">Northern Mariana Islands</option>
			<option value="160">Norway</option>
			<option value="161">Oman</option>
			<option value="162">Pakistan</option>
			<option value="163">Palau</option>
			<option value="164">Panama</option>
			<option value="165">Papua New Guinea</option>
			<option value="166">Paraguay</option>
			<option value="167">Peru</option>
			<option value="168">Philippines</option>
			<option value="169">Pitcairn</option>
			<option value="170">Poland</option>
			<option value="171">Portugal</option>
			<option value="172">Puerto Rico</option>
			<option value="173">Qatar</option>
			<option value="174">Reunion</option>
			<option value="175">Romania</option>
			<option value="176">Russian Federation</option>
			<option value="177">Rwanda</option>
			<option value="178">Saint Kitts and Nevis</option>
			<option value="179">Saint Lucia</option>
			<option value="180">Saint Vincent and the Grenadines</option>
			<option value="181">Samoa</option>
			<option value="182">San Marino</option>
			<option value="183">Sao Tome and Principe</option>
			<option value="184">Saudi Arabia</option>
			<option value="185">Senegal</option>
			<option value="186">Seychelles</option>
			<option value="187">Sierra Leone</option>
			<option value="188">Singapore</option>
			<option value="189">Slovakia (Slovak Republic)</option>
			<option value="190">Slovenia</option>
			<option value="191">Solomon Islands</option>
			<option value="192">Somalia</option>
			<option value="193">South Africa</option>
			<option value="194">South Georgia and the South Sandwich Islands</option>
			<option value="195">Spain</option>
			<option value="196">Sri Lanka</option>
			<option value="197">St. Helena</option>
			<option value="198">St. Pierre and Miquelon</option>
			<option value="199">Sudan</option>
			<option value="200">Suriname</option>
			<option value="201">Svalbard and Jan Mayen Islands</option>
			<option value="202">Swaziland</option>
			<option value="203">Sweden</option>
			<option value="204">Switzerland</option>
			<option value="205">Syrian Arab Republic</option>
			<option value="206">Taiwan</option>
			<option value="207">Tajikistan</option>
			<option value="208">Tanzania, United Republic of</option>
			<option value="209">Thailand</option>
			<option value="210">Togo</option>
			<option value="211">Tokelau</option>
			<option value="212">Tonga</option>
			<option value="213">Trinidad and Tobago</option>
			<option value="214">Tunisia</option>
			<option value="215">Turkey</option>
			<option value="216">Turkmenistan</option>
			<option value="217">Turks and Caicos Islands</option>
			<option value="218">Tuvalu</option>
			<option value="219">Uganda</option>
			<option value="220">Ukraine</option>
			<option value="221">United Arab Emirates</option>
			<option value="222">United Kingdom</option>
			<option value="223">United States</option>
			<option value="224">United States Minor Outlying Islands</option>
			<option value="225">Uruguay</option>
			<option value="226">Uzbekistan</option>
			<option value="227">Vanuatu</option>
			<option value="228">Vatican City State (Holy See)</option>
			<option value="229">Venezuela</option>
			<option value="230">Viet Nam</option>
			<option value="231">Virgin Islands (British)</option>
			<option value="232">Virgin Islands (U.S.)</option>
			<option value="233">Wallis and Futuna Islands</option>
			<option value="234">Western Sahara</option>
			<option value="235">Yemen</option>
			<option value="236">Yugoslavia</option>
			<option value="237">Zaire</option>
			<option value="238">Zambia</option>
			<option value="239">Zimbabwe</option>
			</select>
        </fieldset>
        
        <fieldset>
            <h3>Bot-Patrol</h3>
            <p>Enter the word/number combination shown in the image below.</p>
            <p><a href="[+action+]"><img align="top" src="[(site_manager_url)]includes/veriword.php" width="148" height="60" alt="If you have trouble reading the code, click on the code itself to generate a new random code." style="border: 1px solid #039" /></a></p>
        <label>Form code:* 
            <input type="text" name="formcode" class="inputBox" size="20" /></label>
            </fieldset>
        
        <fieldset>
            <input type="submit" value="Submit" name="cmdwebsignup" />
	</fieldset>
</form>

<script language="javascript" type="text/javascript"> 
	var id = "[+country+]";
	var f = document.websignupfrm;
	var i = parseInt(id);	
	if (!isNaN(i)) f.country.options[i].selected = true;
</script>
<hr>
<!-- notification section -->
<p class="message">Signup completed successfully!<br />
Your account was created. A copy of your signup information was sent to your email address.</p>
';
$c['nl_sidebar'] = '<strong><a href="[~[+id+]~]" title="[+title+]">[+title+]</a></strong><br />
[+longtitle+]<br /><br />';
$c['ditto_blog'] = '<div class="ditto_summaryPost">
  <h3><a href="[~[+id+]~]" title="[+title+]">[+title+]</a></h3>
  <div class="ditto_info" >By <strong>[+author+]</strong> on [+date+]. <a  href="[~[+id+]~]#commentsAnchor">Comments
  ([!Jot?&docid=`[+id+]`&action=`count-comments`!])</a></div><div class="ditto_tags">Tags: [+tagLinks+]</div>
  [+summary+]
  <p class="ditto_link">[+link+]</p>
</div>';
$c['footer'] = '<div id="contentFooter">
        <p>© Tinfra Engineering Limited <script>var tD = new Date();var datestr =  tD.getFullYear();document.write(datestr);</script>. All rights reserved </p>
        <div id="find"> 
              <!--<p>Site by <a href="http://imagequestgraphicske.com/" target="blank">Enha</a></p>--> 
            </div>
      </div>';
$c['sidebar'] = '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
</head>

<body>
<div id="sidebar"> 
					<h3>SubMenu</h3> 
					<ol id="">
						
<li class="active"><a href="#2" title="About Us">About Us</a></li>
<li><a href="#3" title="our Vision">Vision</a></li>
<li><a href="#4" title="Objectives">Objectives</a></li>

</ol>
				
					<div>
						
					</div>
                    <p><span style="color: #808000;"><strong>NEWLETTER</strong></span></p>
                                <p>
								
                              
[!TXNewsletters? &action=add!] 
                              <br />
                            </p>
				<div><a href="[~52~]"><img src="images/gallery_.png" /></a></div>
				</div>
</body>
</html>
';
$c['meta'] = '<p><a href="http://validator.w3.org/check/referer" title="This page validates as XHTML 1.0 Transitional">Valid <abbr title="eXtensible HyperText Markup Language">XHTML</abbr></a></p>                	<p><a href="http://jigsaw.w3.org/css-validator/check/referer" title="This page uses valid Cascading Stylesheets" rel="external">Valid <abbr title="W3C Cascading Stylesheets">css</abbr></a></p>				    <p><a href="http://modx.com/" title="Powered by MODX, Do more with less.">MOD<strong>x</strong></a></p>';
$c['mh.InnerRowTpl'] = '<li[+wf.classes+]><a href="[+wf.link+]" title="[+wf.title+]">[+wf.linktext+]</a>[+wf.wrapper+]</li>';
$c['mh.InnerTpl'] = '<ul style="display:none">
  [+wf.wrapper+]
</ul>';
$c['mh.OuterTpl'] = '  <ul id="myajaxmenu">
    [+wf.wrapper+]
  </ul>';
$c['mh.RowTpl'] = '<li class="category [+wf.classnames+]"><a href="[+wf.link+]" title="[+wf.title+]">[+wf.linktext+]</a>[+wf.wrapper+]</li>';
$c['Comments'] = '<div id="commentsAnchor">
[!Jot? &customfields=`name,email` &subscribe=`1` &pagination=`4` &badwords=`dotNet` &canmoderate=`Site Admins` !]
</div>';
$c['ContactForm'] = '<p class="error">[+validationmessage+]</p>

<form method="post" action="[~[*id*]~]" id="EmailForm" name="EmailForm">

	<fieldset>
		<h3> Contact Form</h3>

		<input name="formid" type="hidden" value="ContactForm" />

		<label for="cfName">Name: &nbsp; &nbsp; &nbsp;&nbsp; 
 &nbsp;    &nbsp;    
 <input name="name" type="text" class="text" id="cfName" size="34" eform="Your Name::1:" /> </label>

		<label for="cfEmail"><br>
		  <br />
		  Email :&nbsp; &nbsp; &nbsp;&nbsp; 
 &nbsp;    &nbsp;  
		  <input name="email" type="text" class="text" id="cfEmail" size="34" eform="Email Address:email:1" /> 
	  </label>

    <label for="cfRegarding"><br>
      <br />
      Regarding: &nbsp; &nbsp; &nbsp;&nbsp;  &nbsp;&nbsp; 
 &nbsp;</label>
	  <select name="subject" id="cfRegarding" eform="Form Subject::1">
			<option value="General Inquiries">General Inquiries</option>
			<option value="Press">Press or Interview Request</option>
			<option value="Partnering">Partnering Opportunities</option>
    </select>

		<br>
		<br>
	  <br />
		<label for="cfMessage">Message: 
		 &nbsp; &nbsp; <br><br>

		 &nbsp;&nbsp;  &nbsp; &nbsp; &nbsp;&nbsp; 

 <textarea name="message" id="cfMessage" rows="4" cols="15" eform="Message:textarea:1"></textarea>
	 
	    <br>
	    <br>


	 
    </label>

		<div style="width:150px;margin-top: 5px;margin-bottom: 5px;"><a href="[+jot.link.current:esc+]"><a href="[+jot.link.current:esc+]"><img src="[(base_url)]manager/includes/veriword.php?rand=[+jot.seed+]" width="148" height="60" alt="If you have trouble reading the code, click on the code itself to generate a new random code." style="border: 1px solid #003399" /></a>
		</div>
	
	  <label for="vericode[+jot.id+]">Help prevent spam - enter security code above:<br>
      <br /><input type="text" name="vericode" style="width:150px;" size="20" id="vericode[+jot.id+]" /></label>&nbsp;
      <br>
      <br />


	  <label>&nbsp;</label><input type="submit" name="contact" id="cfContact" class="button" value="Send This Message" />

	</fieldset>

</form>

';
$c['ContactFormReport'] = '<p>This is a response sent by <b>[+name+]</b> using the feedback form on the website. The details of the message follow below:</p>


<p>Name: [+name+]</p>
<p>Email: [+email+]</p>
<p>Regarding: [+subject+]</p>
<p>comments:<br />[+message+]</p>

<p>You can use this link to reply: <a href="mailto:[+email+]?subject=RE: [+subject+]">[+email+]</a></p>
';
$c['reflect_month_tpl'] = '<a href="[+url+]" title="[+month+] [+year+]" class="reflect_month_link">[+month+] [+year+]</a>';
$c['ContactStyles'] = '<style type="text/css">
div.errors{ color:#F00; }
#EmailForm .invalidValue{ background: #FFDFDF; border:1px solid #F00; }
#EmailForm .requiredValue{ background: #FFFFDF; border:1px solid #F00; }
</style>';
$c['header'] = '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
	<head>
	<meta http-equiv="content-type" content="text/html; charset=UTF-8">
	<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE8">

		  <title>[(site_name)] | [*pagetitle*]</title>
	<link rel="stylesheet" type="text/css" media="screen" href="css/styles.css">
	<link href="css/nivo-slider.css" rel="stylesheet" type="text/css">

	<!--[if lt IE 8]>
		<script src="http://ie7-js.googlecode.com/svn/version/2.1(beta3)/IE8.js"></script>
	<![endif]-->
	<!-- jQuery -->
	<script type="text/javascript" src="css/jquery-1_002.js"></script>
	<!-- Cufon Scripts -->
	<script type="text/javascript" src="css/cufon-yui.js"></script>
	<style type="text/css">
cufon {
	text-indent:0!important;
}
@media screen, projection {
cufon {
	display:inline!important;
	display:inline-block!important;
	position:relative!important;
	vertical-align:middle!important;
	font-size:1px!important;
	line-height:1px!important;
}
cufon cufontext {
	display:-moz-inline-box!important;
	display:inline-block!important;
	width:0!important;
	height:0!important;
	overflow:hidden!important;
	text-indent:-10000in!important;
}
cufon canvas {
	position:relative!important;
}
}
@media print {
cufon {
	padding:0!important;
}
cufon canvas {
	display:none!important;
}
}
</style>
	<script type="text/javascript" src="css/Helvetica_LT_Std_300.js"></script>
	<script type="text/javascript" src="css/jquery-1.js"></script>
	<script type="text/javascript" src="css/superfish.js"></script>
	<script type="text/javascript" src="css/supersubs.js"></script>
	<script type="text/javascript" src="css/jquery.js"></script>
	<script type="text/javascript" src="css/jquery_002.js"></script>
	<script type="text/javascript">
	
	jQuery(window).load(function() {
		jQuery(\'#slider\').nivoSlider({
			effect:\'fold\', //Specify sets like: \'sliceDownRight,sliceDownLeft,fold,fade\'
			slices:15,
			animSpeed:600, //Slide transition speed
			pauseTime:6000,
			directionNav:true, //Next &amp; Prev
			startSlide:0, //Set starting Slide (0 index)
			customChange: function(){
			Cufon.replace(\'#slideshow h1, #slideshow .slider-desc\', {fontFamily: \'Yanone Kaffeesatz Regular\'});
			}
		});
		 Cufon.refresh();
		 
		//Menu
		jQuery("ul.sf-menu").supersubs({ 
		minWidth		: 12,		// requires em unit.
		maxWidth		: 27,		// requires em unit.
		extraWidth		: 1	// extra width can ensure lines don\'t sometimes turn over due to slight browser differences in how they round-off values
							   // due to slight rounding differences and font-family 
		}).superfish();  // call supersubs first, then superfish, so that subs are 
						 // not display:none when measuring. Call before initialising 
						 // containing tabs for same reason. 
	});
	</script>
	<script type="text/javascript" src="css/jquery_003.js"></script>

	<!-- JavaScript Test Zone -->
	<script type="text/javascript">
	$(document).ready(function() {
		
		$(\'blockquote\').quovolver();
		
	});
	</script>

	<!--Demo Switcher-->
	<link id="skinscss" href="css/light-.htm" rel="stylesheet" type="text/css">
	<!-- DD_belatedPNG fix -->
	<!--[if IE 6]>
		<script src="js/DD_belatedPNG_0.0.8a-min.js"></script>
		<script>
  			DD_belatedPNG.fix(\'h1 a\');
			DD_belatedPNG.fix(\'#contentWrapper\');
			DD_belatedPNG.fix(\'li\');
		</script>
	<![endif]-->
	</head>';
$c['column'] = '<div id="infoColumn">
    <h1><a href="#" title="Tinfra Engineering Limited">Tinfra Engineering Limited</a></h1>
    <!-- BEGIN: languages --><!-- END: languages -->
    <div id="contacts">
          <div>
        <h6><br />
              Our Contacts:<br />
              <br />
            </h6>
        <ul>
              <li><strong>Tinfra Engineering Limited</strong></li>
              <li>Airport North Road, Nairobi)</li>
              <li>P.o. Box                                :  27699- 00100</li>
              <li>Telephone                             :  020 2336 297 <br />
              Fax: 020 233 1952</li>
              <li>Email                                    : info@tinfra.co.ke</li>
            </ul>
        <h3>Our Location</h3>
      <img src="images/lyrsm237011989hlensrcapiv2x19735sy16501z15sGa.png" alt="" width="184" height="184" /> </div>
        </div>
  </div>';
$c['nav'] = '<ul id="mainNav">
        <li class="first active"><a href="[~1~]" title="Home">Home</a></li>
        <li><a href="[~32~]" title="About Us">About Us</a></li>
        <li><a href="[~33~]" title="Why Tinfra ">Our team</a></li>
        <li><a href="[~15~]" title="Tinfra  Services">Our servicess</a></li>
        <li><a href="[~50~]" title="Tools and equipment">Equipment</a></li>
	<li class="last"><a href="[~52~]" title="Gallery">Gallery </a></li>
        <li class="last"><a href="[~51~]" title="Projects">Projects </a></li>
        <li class="last"><a href="[~6~]" title="Contacts">contacts</a></li>
      </ul>';
$c['slide'] = '<div id="slideshow">
        <div style="position: relative; background: url(images/slider5.gif;) no-repeat scroll 0% 0% transparent;" id="slider" class="nivoSlider"> 
        <img style="display: none;" src="images/slider1.jpg" alt="" title="#htmlcaption0">
        <img style="display: none;" src="images/slider2.jpg" alt="" title="#htmlcaption1">
        <img style="display: none;" src="images/slider3.jpg" alt="" title="#htmlcaption2">
        <img style="display: none;" src="images/slider4.jpg" alt="" title="#htmlcaption3">
    
              <div style="display: none;" class="nivo-directionNav"><a class="nivo-prevNav">Prev</a><a class="nivo-nextNav">Next</a></div>
              <div class="nivo-controlNav"><a class="nivo-control" rel="0">1</a><a class="nivo-control active" rel="1">2</a><a class="nivo-control" rel="2">3</a><a class="nivo-control" rel="3">4</a><a class="nivo-control" rel="4">5</a></div>
              <div style="left: 0px; width: 63px; height: 100%; opacity: 1; background: url(images/slider4.jpg;) no-repeat scroll 0px 0% transparent; top: 0px;" class="nivo-slice"></div>
              <div style="left: 63px; width: 63px; height: 100%; opacity: 1; background: url(images/slider4.jpg;) no-repeat scroll -63px 0% transparent; top: 0px;" class="nivo-slice"></div>
              <div style="left: 126px; width: 63px; height: 100%; opacity: 1; background: url(images/slider4.jpg;) no-repeat scroll -126px 0% transparent; top: 0px;" class="nivo-slice"></div>
              <div style="left: 189px; width: 63px; height: 100%; opacity: 1; background: url(images/slider4.jpg;) no-repeat scroll -189px 0% transparent; top: 0px;" class="nivo-slice"></div>
              <div style="left: 252px; width: 63px; height: 100%; opacity: 1; background: url(images/slider4.jpg;) no-repeat scroll -252px 0% transparent; top: 0px;" class="nivo-slice"></div>
              <div style="left: 315px; width: 63px; height: 100%; opacity: 1; background: url(images/slider4.jpg;) no-repeat scroll -315px 0% transparent; top: 0px;" class="nivo-slice"></div>
              <div style="left: 378px; width: 63px; height: 100%; opacity: 1; background: url(images/slider4.jpg;) no-repeat scroll -378px 0% transparent; top: 0px;" class="nivo-slice"></div>
              <div style="left: 441px; width: 63px; height: 100%; opacity: 1; background: url(images/slider4.jpg;) no-repeat scroll -441px 0% transparent; top: 0px;" class="nivo-slice"></div>
              <div style="left: 504px; width: 63px; height: 100%; opacity: 1; background: url(images/slider4.jpg;) no-repeat scroll -504px 0% transparent; top: 0px;" class="nivo-slice"></div>
              <div style="left: 567px; width: 63px; height: 100%; opacity: 1; background: url(images/slider4.jpg;) no-repeat scroll -567px 0% transparent; top: 0px;" class="nivo-slice"></div>
              <div style="left: 630px; width: 63px; height: 100%; opacity: 1; background: url(images/slider4.jpg;) no-repeat scroll -630px 0% transparent; top: 0px;" class="nivo-slice"></div>
              <div style="left: 693px; width: 63px; height: 100%; opacity: 1; background: url(images/slider4.jpg;) no-repeat scroll -693px 0% transparent; top: 0px;" class="nivo-slice"></div>
              <div style="left: 756px; width: 63px; height: 100%; opacity: 1; background: url(images/slider4.jpg;) no-repeat scroll -756px 0% transparent; top: 0px;" class="nivo-slice"></div>
              <div style="left: 819px; width: 63px; height: 100%; opacity: 1; background: url(images/slider4.jpg;) no-repeat scroll -819px 0% transparent; top: 0px;" class="nivo-slice"></div>
              <div style="left: 882px; width: 58px; height: 100%; opacity: 1; background: url(images/slider4.jpg;) no-repeat scroll -882px 0% transparent; top: 0px;" class="nivo-slice"></div>
            </div>
      </div>';
$c['sidebar2'] = '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
</head>



<body>

<div id="sidebar"> 
					<h3>SubMenu</h3> 
					<ol id="">
						

<li>
    <a href="[~16~]">Turnkey consulting services</a></li>
  <li>  <a href="[~22~]">Building construction</a></li>
  <li><a href="[~14~]">  Maintenance of existing structures</a></li>
 <li><a href="[~24~]">   Modification and renovations to existing structures</a></li>
 <li>   <a href="[~47~]">Roads works, Civil  & Structural works</a></li>
  <li><a href="[~48~]">  Electrical & Telecoms installation works</a></li>
  <li>  <a href="[~49~]">Supply of equipments and materials</a></li>
</li>

</ol>
				
					<div>
						
					</div>
					<p><span style="color: #808000;"><strong>NEWLETTER</strong></span></p>
<p>


[!TXNewsletters? &action=add!] 

</p>

<br>


<div><a href="[~52~]"><img src="images/gallery_.png" /></a></div>


</div>
</body>
</html>
';
$s = &$this->snippetCache;
$s['AjaxSearch'] = 'return require MODX_BASE_PATH.\'assets/snippets/ajaxSearch/snippet.ajaxSearch.php\';';
$s['Breadcrumbs'] = 'return require MODX_BASE_PATH.\'assets/snippets/breadcrumbs/snippet.breadcrumbs.php\';';
$s['Ditto'] = 'return require MODX_BASE_PATH.\'assets/snippets/ditto/snippet.ditto.php\';';
$s['eForm'] = 'return require MODX_BASE_PATH.\'assets/snippets/eform/snippet.eform.php\';';
$s['FirstChildRedirect'] = 'return require MODX_BASE_PATH.\'assets/snippets/firstchildredirect/snippet.firstchildredirect.php\';';
$s['if'] = 'return require MODX_BASE_PATH.\'assets/snippets/if/snippet.if.php\';';
$s['Jot'] = '/*####
#
# Author: Armand "bS" Pondman (apondman@zerobarrier.nl)
#
# Latest Version: http://modxcms.com/Jot-998.html
# Jot Demo Site: http://projects.zerobarrier.nl/modx/
# Documentation: http://wiki.modxcms.com/index.php/Jot (wiki)
#
####*/

$jotPath = $modx->config[\'base_path\'] . \'assets/snippets/jot/\';
include_once($jotPath.\'jot.class.inc.php\');

$Jot = new CJot;
$Jot->VersionCheck("1.1.4");
$Jot->Set("path",$jotPath);
$Jot->Set("action", $action);
$Jot->Set("postdelay", $postdelay);
$Jot->Set("docid", $docid);
$Jot->Set("tagid", $tagid);
$Jot->Set("subscribe", $subscribe);
$Jot->Set("moderated", $moderated);
$Jot->Set("captcha", $captcha);
$Jot->Set("badwords", $badwords);
$Jot->Set("bw", $bw);
$Jot->Set("sortby", $sortby);
$Jot->Set("numdir", $numdir);
$Jot->Set("customfields", $customfields);
$Jot->Set("guestname", $guestname);
$Jot->Set("canpost", $canpost);
$Jot->Set("canview", $canview);
$Jot->Set("canedit", $canedit);
$Jot->Set("canmoderate", $canmoderate);
$Jot->Set("trusted", $trusted);
$Jot->Set("pagination", $pagination);
$Jot->Set("placeholders", $placeholders);
$Jot->Set("subjectSubscribe", $subjectSubscribe);
$Jot->Set("subjectModerate", $subjectModerate);
$Jot->Set("subjectAuthor", $subjectAuthor);
$Jot->Set("notify", $notify);
$Jot->Set("notifyAuthor", $notifyAuthor);
$Jot->Set("validate", $validate);
$Jot->Set("title", $title);
$Jot->Set("authorid", $authorid);
$Jot->Set("css", $css);
$Jot->Set("cssFile", $cssFile);
$Jot->Set("cssRowAlt", $cssRowAlt);
$Jot->Set("cssRowMe", $cssRowMe);
$Jot->Set("cssRowAuthor", $cssRowAuthor);
$Jot->Set("tplForm", $tplForm);
$Jot->Set("tplComments", $tplComments);
$Jot->Set("tplModerate", $tplModerate);
$Jot->Set("tplNav", $tplNav);
$Jot->Set("tplNotify", $tplNotify);
$Jot->Set("tplNotifyModerator", $tplNotifyModerator);
$Jot->Set("tplNotifyAuthor", $tplNotifyAuthor);
$Jot->Set("tplSubscribe", $tplSubscribe);
$Jot->Set("debug", $debug);
$Jot->Set("output", $output);
return $Jot->Run();';
$s['ListIndexer'] = 'return require MODX_BASE_PATH.\'assets/snippets/listindexer/snippet.listindexer.php\';';
$s['MemberCheck'] = 'return require MODX_BASE_PATH.\'assets/snippets/membercheck/snippet.membercheck.php\';';
$s['Personalize'] = 'return require MODX_BASE_PATH.\'assets/snippets/personalize/snippet.personalize.php\';';
$s['phpthumb'] = 'return require MODX_BASE_PATH.\'assets/snippets/phpthumb/snippet.phpthumb.php\';
';
$s['Reflect'] = '/*
 * Author: 
 *      Mark Kaplan for MODx CMF
 * 
 * Note: 
 *      If Reflect is not retrieving its own documents, make sure that the
 *          Ditto call feeding it has all of the fields in it that you plan on
 *       calling in your Reflect template. Furthermore, Reflect will ONLY
 *          show what is currently in the Ditto result set.
 *       Thus, if pagination is on it will ONLY show that page\'s items.
*/
 

// ---------------------------------------------------
//  Includes
// ---------------------------------------------------

$reflect_base = isset($reflect_base) ? $modx->config[\'base_path\'].$reflect_base : $modx->config[\'base_path\']."assets/snippets/reflect/";
/*
    Param: ditto_base
    
    Purpose:
    Location of Ditto files

    Options:
    Any valid folder location containing the Ditto source code with a trailing slash

    Default:
    [(base_path)]assets/snippets/ditto/
*/

$config = (isset($config)) ? $config : "default";
/*
    Param: config

    Purpose:
    Load a custom configuration

    Options:
    "default" - default blank config file
    CONFIG_NAME - Other configs installed in the configs folder or in any folder within the MODx base path via @FILE

    Default:
    "default"
    
    Related:
    - <extenders>
*/

require($reflect_base."configs/default.config.php");
require($reflect_base."default.templates.php");
if ($config != "default") {
    require((substr($config, 0, 5) != "@FILE") ? $reflect_base."configs/$config.config.php" : $modx->config[\'base_path\'].trim(substr($config, 5)));
}

// ---------------------------------------------------
//  Parameters
// ---------------------------------------------------

$id = isset($id) ? $id."_" : false;
/*
    Param: id

    Purpose:
    Unique ID for this Ditto instance for connection with other scripts (like Reflect) and unique URL parameters

    Options:
    Any valid folder location containing the Ditto source code with a trailing slash

    Default:
    "" - blank
*/
$getDocuments = isset($getDocuments) ? $getDocuments : 0;
/*
    Param: getDocuments

    Purpose:
    Force Reflect to get documents

    Options:
    0 - off
    1 - on
    
    Default:
    0 - off
*/
$showItems = isset($showItems) ? $showItems : 1;
/*
    Param: showItems

    Purpose:
    Show individual items in the archive

    Options:
    0 - off
    1 - on
    
    Default:
    1 - on
*/
$groupByYears = isset($groupByYears)? $groupByYears : 1;
/*
    Param: groupByYears

    Purpose:
    Group the archive by years

    Options:
    0 - off
    1 - on
    
    Default:
    1 - on
*/
$targetID = isset($targetID) ? $targetID : $modx->documentObject[\'id\'];
/*
    Param: targetID

    Purpose:
    ID for archive links to point to

    Options:
    Any MODx document with a Ditto call setup with extenders=`dateFilter`
    
    Default:
    Current MODx Document
*/
$dateSource = isset($dateSource) ? $dateSource : "createdon";
/*
    Param: dateSource

    Purpose:
    Date source to display for archive items

    Options:
    # - Any UNIX timestamp from MODx fields or TVs such as createdon, pub_date, or editedon
    
    Default:
    "createdon"
    
    Related:
    - <dateFormat>
*/
$dateFormat = isset($dateFormat) ? $dateFormat : "%d-%b-%y %H:%M";  
/*
    Param: dateFormat

    Purpose:
    Format the [+date+] placeholder in human readable form

    Options:
    Any PHP valid strftime option

    Default:
    "%d-%b-%y %H:%M"
    
    Related:
    - <dateSource>
*/
$yearSortDir = isset($yearSortDir) ? $yearSortDir : "DESC";
/*
    Param: yearSortDir

    Purpose:
    Direction to sort documents

    Options:
    ASC - ascending
    DESC - descending

    Default:
    "DESC"
    
    Related:
    - <monthSortDir>
*/
$monthSortDir = isset($monthSortDir) ? $monthSortDir : "ASC";
/*
    Param: monthSortDir

    Purpose:
    Direction to sort the months

    Options:
    ASC - ascending
    DESC - descending

    Default:
    "ASC"
    
    Related:
    - <yearSortDir>
*/
$start = isset($start)? intval($start) : 0;
/*
    Param: start

    Purpose:
    Number of documents to skip in the results
    
    Options:
    Any number

    Default:
    0
*/  
$phx = (isset($phx))? $phx : 1;
/*
    Param: phx

    Purpose:
    Use PHx formatting

    Options:
    0 - off
    1 - on
    
    Default:
    1 - on
*/

// ---------------------------------------------------
//  Initialize Ditto
// ---------------------------------------------------
$placeholder = ($id != false && $getDocuments == 0) ? true : false;
if ($placeholder === false) {
    $rID = "reflect_".rand(1,1000);
    $itemTemplate = isset($tplItem) ? $tplItem: "@CODE:".$defaultTemplates[\'item\'];
    $dParams = array(
        "id" => "$rID",
        "save" => "3",  
        "summarize" => "all",
        "tpl" => $itemTemplate,
    );
    
    $source = $dittoSnippetName;
    $params = $dittoSnippetParameters;
        // TODO: Remove after 3.0
        
    if (isset($params)) {
        $givenParams = explode("|",$params);
        foreach ($givenParams as $parameter) {
            $p = explode(":",$parameter);
            $dParams[$p[0]] = $p[1];
        }
    }
    /*
        Param: params

        Purpose:
        Pass parameters to the Ditto instance used to retreive the documents

        Options:
        Any valid ditto parameters in the format name:value 
        with multiple parameters separated by a pipe (|)
        
        Note:
        This parameter is only needed for config, start, and phx as you can
        now simply use the parameter as if Reflect was Ditto

        Default:
        [NULL]
    */
    
    $reflectParameters = array(\'reflect_base\',\'config\',\'id\',\'getDocuments\',\'showItems\',\'groupByYears\',\'targetID\',\'yearSortDir\',\'monthSortDir\',\'start\',\'phx\',\'tplContainer\',\'tplYear\',\'tplMonth\',\'tplMonthInner\',\'tplItem\',\'save\');
    $params =& $modx->event->params;
    if(is_array($params)) {
        foreach ($params as $param=>$value) {
            if (!in_array($param,$reflectParameters) && substr($param,-3) != \'tpl\') {
                $dParams[$param] = $value;
            }
        }
    }

    $source = isset($source) ? $source : "Ditto";
    /*
        Param: source

        Purpose:
        Name of the Ditto snippet to use

        Options:
        Any valid snippet name

        Default:
        "Ditto"
    */
    $snippetOutput = $modx->runSnippet($source,$dParams);
    $ditto = $modx->getPlaceholder($rID."_ditto_object");
    $resource = $modx->getPlaceholder($rID."_ditto_resource");
} else {
    $ditto = $modx->getPlaceholder($id."ditto_object");
    $resource = $modx->getPlaceholder($id."ditto_resource");
}
if (!is_object($ditto) || !isset($ditto) || !isset($resource)) {
    return !empty($snippetOutput) ? $snippetOutput : "The Ditto object is invalid. Please check it.";
}

// ---------------------------------------------------
//  Templates
// ---------------------------------------------------

$templates[\'tpl\'] = isset($tplContainer) ? $ditto->template->fetch($tplContainer): $defaultTemplates[\'tpl\'];
/*
    Param: tplContainer

    Purpose:
    Container template for the archive

    Options:
    - Any valid chunk name
    - Code via @CODE:
    - File via @FILE:

    Default:
    See default.tempates.php
*/
$templates[\'year\'] = isset($tplYear) ? $ditto->template->fetch($tplYear): $defaultTemplates[\'year\'];
/*
    Param: tplYear

    Purpose:
    Template for the year item

    Options:
    - Any valid chunk name
    - Code via @CODE:
    - File via @FILE:

    Default:
    See default.tempates.php
*/
$templates[\'year_inner\'] = isset($tplYearInner) ? $ditto->template->fetch($tplYearInner): $defaultTemplates[\'year_inner\'];
/*
    Param: tplYearInner

    Purpose:
    Template for the year item (the ul to hold the year template)

    Options:
    - Any valid chunk name
    - Code via @CODE:
    - File via @FILE:

    Default:
    See default.tempates.php
*/
$templates[\'month\'] = isset($tplMonth) ? $ditto->template->fetch($tplMonth): $defaultTemplates[\'month\'];
/*
    Param: tplMonth

    Purpose:
    Template for the month item

    Options:
    - Any valid chunk name
    - Code via @CODE:
    - File via @FILE:

    Default:
    See default.tempates.php
*/
$templates[\'month_inner\'] = isset($tplMonthInner) ? $ditto->template->fetch($tplMonthInner): $defaultTemplates[\'month_inner\'];
/*
    Param: tplMonthInner

    Purpose:
    Template for the month item  (the ul to hold the month template)

    Options:
    - Any valid chunk name
    - Code via @CODE:
    - File via @FILE:

    Default:
    See default.tempates.php
*/
$templates[\'item\'] = isset($tplItem) ? $ditto->template->fetch($tplItem): $defaultTemplates[\'item\'];
/*
    Param: tplItem

    Purpose:
    Template for the individual item

    Options:
    - Any valid chunk name
    - Code via @CODE:
    - File via @FILE:

    Default:
    See default.tempates.php
*/

$ditto->addField("date","display","custom");
    // force add the date field if receiving data from a Ditto instance

// ---------------------------------------------------
//  Reflect
// ---------------------------------------------------

if (function_exists("reflect") === FALSE) {
function reflect($templatesDocumentID, $showItems, $groupByYears, $resource, $templatesDateSource, $dateFormat, $ditto, $templates,$id,$start,$yearSortDir,$monthSortDir) {
    global $modx;
    $cal = array();
    $output = \'\';
    $ph = array(\'year\'=>\'\',\'month\'=>\'\',\'item\'=>\'\',\'out\'=>\'\');
    $build = array();
    $stop = count($resource);

    // loop and fetch all the results
    for ($i = $start; $i < $stop; $i++) {
        $date = getdate($resource[$i][$templatesDateSource]);
        $year = $date["year"];
        $month = $date["mon"];
        $cal[$year][$month][] = $resource[$i];
    }
    if ($yearSortDir == "DESC") {
        krsort($cal);
    } else {
        ksort($cal);
    }
    foreach ($cal as $year=>$months) {
        if ($monthSortDir == "ASC") {
            ksort($months);
        } else {
            krsort($months);
        }
        $build[$year] = $months;
    }
    
    foreach ($build as $year=>$months) {
        $r_year = \'\';
        $r_month = \'\';
        $r_month_2 = \'\';
        $year_count = 0;
        $items = array();
        
        foreach ($months as $mon=>$month) {
            $month_text = strftime("%B", mktime(10, 10, 10, $mon, 10, $year));
            $month_url = $ditto->buildURL("month=".$mon."&year=".$year."&day=false&start=0",$templatesDocumentID,$id);
            $month_count = count($month);
            $year_count += $month_count;
            $r_month = $ditto->template->replace(array("year"=>$year,"month"=>$month_text,"url"=>$month_url,"count"=>$month_count),$templates[\'month\']);
            if ($showItems) {
                foreach ($month as $item) {
                    $items[$year][$mon][\'items\'][] = $ditto->render($item, $templates[\'item\'], false, $templatesDateSource, $dateFormat, array(),$phx);
                }
                $r_month_2 = $ditto->template->replace(array(\'wrapper\' => implode(\'\',$items[$year][$mon][\'items\'])),$templates[\'month_inner\']);
                $items[$year][$mon] = $ditto->template->replace(array(\'wrapper\' => $r_month_2),$r_month);
            } else {
                $items[$year][$mon] = $r_month;
            }
        }
        if ($groupByYears) {
            $year_url = $ditto->buildURL("year=".$year."&month=false&day=false&start=0",$templatesDocumentID,$id);
            $r_year =  $ditto->template->replace(array("year"=>$year,"url"=>$year_url,"count"=>$year_count),$templates[\'year\']);
            $var = $ditto->template->replace(array(\'wrapper\'=>implode(\'\',$items[$year])),$templates[\'year_inner\']);
            $output .= $ditto->template->replace(array(\'wrapper\'=>$var),$r_year);
        } else {
            $output .= implode(\'\',$items[$year]);
        }
    }

    $output = $ditto->template->replace(array(\'wrapper\'=>$output),$templates[\'tpl\']);
    $modx->setPlaceholder($id.\'reset\',$ditto->buildURL(\'year=false&month=false&day=false\',$templatesDocumentID,$id));

return $output;
    
}
}

return reflect($targetID, $showItems, $groupByYears, $resource, $dateSource, $dateFormat, $ditto, $templates,$id,$start,$yearSortDir,$monthSortDir);';
$s['UltimateParent'] = 'return require MODX_BASE_PATH.\'assets/snippets/ultimateparent/snippet.ultimateparent.php\';';
$s['Wayfinder'] = 'return require MODX_BASE_PATH.\'assets/snippets/wayfinder/snippet.wayfinder.php\';';
$s['WebChangePwd'] = '# Created By Raymond Irving April, 2005
#::::::::::::::::::::::::::::::::::::::::
# Params:	
#
#	&tpl			- (Optional)
#		Chunk name or document id to use as a template
#				  
#	Note: Templats design:
#			section 1: change pwd template
#			section 2: notification template 
#
# Examples:
#
#	[[WebChangePwd? &tpl=`ChangePwd`]] 

# Set Snippet Paths 
$snipPath  = (($modx->insideManager())? "../":"");
$snipPath .= "assets/snippets/";

# check if inside manager
if ($m = $modx->insideManager()) {
	return \'\'; # don\'t go any further when inside manager
}


# Snippet customize settings
$tpl		= isset($tpl)? $tpl:"";

# System settings
$isPostBack		= count($_POST) && isset($_POST[\'cmdwebchngpwd\']);

# Start processing
include_once $snipPath."weblogin/weblogin.common.inc.php";
include_once $snipPath."weblogin/webchangepwd.inc.php";

# Return
return $output;



';
$s['WebLogin'] = '# Created By Raymond Irving 2004
#::::::::::::::::::::::::::::::::::::::::
# Params:	
#
#	&loginhomeid 	- (Optional)
#		redirects the user to first authorized page in the list.
#		If no id was specified then the login home page id or 
#		the current document id will be used
#
#	&logouthomeid 	- (Optional)
#		document id to load when user logs out	
#
#	&pwdreqid 	- (Optional)
#		document id to load after the user has submited
#		a request for a new password
#
#	&pwdactid 	- (Optional)
#		document id to load when the after the user has activated
#		their new password
#
#	&logintext		- (Optional) 
#		Text to be displayed inside login button (for built-in form)
#
#	&logouttext 	- (Optional)
#		Text to be displayed inside logout link (for built-in form)
#	
#	&tpl			- (Optional)
#		Chunk name or document id to as a template
#				  
#	Note: Templats design:
#			section 1: login template
#			section 2: logout template 
#			section 3: password reminder template 
#
#			See weblogin.tpl for more information
#
# Examples:
#
#	[[WebLogin? &loginhomeid=`8` &logouthomeid=`1`]] 
#
#	[[WebLogin? &loginhomeid=`8,18,7,5` &tpl=`Login`]] 

# Set Snippet Paths 
$snipPath = $modx->config[\'base_path\'] . "assets/snippets/";

# check if inside manager
if ($m = $modx->insideManager()) {
	return \'\'; # don\'t go any further when inside manager
}

# deprecated params - only for backward compatibility
if(isset($loginid)) $loginhomeid=$loginid;
if(isset($logoutid)) $logouthomeid = $logoutid;
if(isset($template)) $tpl = $template;

# Snippet customize settings
$liHomeId	= isset($loginhomeid)? explode(",",$loginhomeid):array($modx->config[\'login_home\'],$modx->documentIdentifier);
$loHomeId	= isset($logouthomeid)? $logouthomeid:$modx->documentIdentifier;
$pwdReqId	= isset($pwdreqid)? $pwdreqid:0;
$pwdActId	= isset($pwdactid)? $pwdactid:0;
$loginText	= isset($logintext)? $logintext:\'Login\';
$logoutText	= isset($logouttext)? $logouttext:\'Logout\';
$tpl		= isset($tpl)? $tpl:"";

# System settings
$webLoginMode = isset($_REQUEST[\'webloginmode\'])? $_REQUEST[\'webloginmode\']: \'\';
$isLogOut		= $webLoginMode==\'lo\' ? 1:0;
$isPWDActivate	= $webLoginMode==\'actp\' ? 1:0;
$isPostBack		= count($_POST) && (isset($_POST[\'cmdweblogin\']) || isset($_POST[\'cmdweblogin_x\']));
$txtPwdRem 		= isset($_REQUEST[\'txtpwdrem\'])? $_REQUEST[\'txtpwdrem\']: 0;
$isPWDReminder	= $isPostBack && $txtPwdRem==\'1\' ? 1:0;

$site_id = isset($site_id)? $site_id: \'\';
$cookieKey = substr(md5($site_id."Web-User"),0,15);

# Start processing
include_once $snipPath."weblogin/weblogin.common.inc.php";
include_once ($modx->config[\'site_manager_path\'] . "includes/crypt.class.inc.php");

if ($isPWDActivate || $isPWDReminder || $isLogOut || $isPostBack) {
	# include the logger class
	include_once $modx->config[\'site_manager_path\'] . "includes/log.class.inc.php";
	include_once $snipPath."weblogin/weblogin.processor.inc.php";
}

include_once $snipPath."weblogin/weblogin.inc.php";

# Return
return $output;
';
$s['WebLoginProps'] = '&loginhomeid=Login Home Id;string; &logouthomeid=Logout Home Id;string; &logintext=Login Button Text;string; &logouttext=Logout Button Text;string; &tpl=Template;string; ';
$s['WebSignup'] = '# Created By Raymond Irving April, 2005
#::::::::::::::::::::::::::::::::::::::::
# Usage:     
#    Allows a web user to signup for a new web account from the website
#    This snippet provides a basic set of form fields for the signup form
#    You can customize this snippet to create your own signup form
#
# Params:    
#
#    &tpl        - (Optional) Chunk name or document id to use as a template
#    &groups     - Web users groups to be assigned to users
#    &useCaptcha - (Optional) Determine to use (1) or not to use (0) captcha
#                  on signup form - if not defined, will default to system
#                  setting. GD is required for this feature. If GD is not 
#                  available, useCaptcha will automatically be set to false;
#                  
#    Note: Templats design:
#        section 1: signup template
#        section 2: notification template 
#
# Examples:
#
#    [[WebSignup? &tpl=`SignupForm` &groups=`NewsReaders,WebUsers`]] 

# Set Snippet Paths 
$snipPath = $modx->config[\'base_path\'] . "assets/snippets/";

# check if inside manager
if ($m = $modx->insideManager()) {
    return \'\'; # don\'t go any further when inside manager
}


# Snippet customize settings
$tpl = isset($tpl)? $tpl:"";
$useCaptcha = isset($useCaptcha)? $useCaptcha : $modx->config[\'use_captcha\'] ;
// Override captcha if no GD
if ($useCaptcha && !gd_info()) $useCaptcha = 0;

# setup web groups
$groups = isset($groups) ? explode(\',\',$groups):array();
for($i=0;$i<count($groups);$i++) $groups[$i] = trim($groups[$i]);

# System settings
$isPostBack        = count($_POST) && isset($_POST[\'cmdwebsignup\']);

$output = \'\';

# Start processing
include_once $snipPath."weblogin/weblogin.common.inc.php";
include_once $snipPath."weblogin/websignup.inc.php";

# Return
return $output;';
$s['WebSignupProps'] = '&tpl=Template;string; ';
$s['TXNewsletters'] = '/*--------------------------------------------------------------------------------------------------------

 Snippet Name:        TXNewsletters

 Short Description:   <strong>0.9</strong> - TXNewsletters subscribe / unsubscribe form snippet

 Version:  0.9

 Authors:  Franck TRUILLOT
           Manuel STEPHAN

 Usage:

   Display subscribe form : [!TXNewsletters? &action=add!]

   Display unsubscribe form on another page if necessary : [!TXNewsletters!]
   
   Add a &lang=... parameter to display forms with a specific language with value : english, francais, francais-utf8, ... 

--------------------------------------------------------------------------------------------------------*/

//Options :
$modx->TXNewsletters[\'lang\'] = isset($modx->config[\'manager_language\']) ? $modx->config[\'manager_language\'] : \'english\';  
$modx->TXNewsletters[\'lang\'] = isset($lang) ? $lang : $modx->TXNewsletters[\'lang\'];

$modx->TXNewsletters[\'emailFrom\']=$emailFrom;
$modx->TXNewsletters[\'newslettersBaseId\']=$newslettersBaseId;
$modx->TXNewsletters[\'nbPerPage\']=$nbPerPage;
$modx->TXNewsletters[\'idPageSubscribe\']=$idPageSubscribe;
$modx->TXNewsletters[\'idPageUnsubscribe\']=$idPageUnsubscribe;

//includes
$modx->TXNewsletters[\'tb_prefix\'] = $modx->db->config[\'table_prefix\'];
$modx_root_dir =$modx->config[\'base_path\'];
$modx_base_url = $modx->config[\'base_url\'];
$modx->TXNewsletters[\'path\'] = $modx->config[\'base_path\'] . "assets/modules/txnewsletters/";
$modx->TXNewsletters[\'path_url\'] = $modx->config[\'base_url\'] . "assets/modules/txnewsletters/";
include_once($modx->TXNewsletters[\'path\'].\'txnewsletters.version.inc.php\');
if(file_exists($modx->TXNewsletters[\'path\'].\'lang/lang.\'.$modx->TXNewsletters[\'lang\'].\'.inc.php\')){
	include_once($modx->TXNewsletters[\'path\'].\'lang/lang.\'.$modx->TXNewsletters[\'lang\'].\'.inc.php\');
}
else {
	include_once($modx->TXNewsletters[\'path\'].\'lang/lang.english.inc.php\');
}
include_once($modx->TXNewsletters[\'path\'].\'txnewsletters.inc.php\');
include_once($modx->TXNewsletters[\'path\'].\'csv.class.inc.php\');
if(file_exists($modx->TXNewsletters[\'path\'].\'conf/conf.\'.$modx->TXNewsletters[\'lang\'].\'.xml\')){
	$fichier = $modx->TXNewsletters[\'path\'].\'conf/conf.\'.$modx->TXNewsletters[\'lang\'].\'.xml\';
}
else {
	$fichier = $modx->TXNewsletters[\'path\'].\'conf/conf.english.xml\';
}
$fichier_import = $modx->TXNewsletters[\'path\'].\'txnewsletters.datas.csv\';

$modx->TXNewsletters[\'fields\'] = getFields($fichier);
         

//////////////////////////////////////////////////////////////

if(!isset($action)){$action=\'\';}
$action = isset($_POST[\'formmenuaction\']) ? delCode($_POST[\'formmenuaction\']) : $action;
$action = isset($_GET[\'action\']) ? delCode($_GET[\'action\']) : $action;
switch ($action) {

/* Affichage formulaire d\'inscription */
case \'add\' :

  $Err = NULL;
  echo formHTML(\'add_send\',$Err);

break;

/* Affichage formulaire d\'inscription après envoi / inscription Ok */
case \'add_send\' :

  $Err = checkForm();
  $nbErr = count($Err);
  $testEmail = testEmail();
  if ($nbErr>0 || $testEmail==true) {
    if($testEmail){ echo $modx->TXNewsletters[\'txtlang\'][\'email_err\'].\'<br /><br />\'."\\n"; }
    echo formHTML(\'add_send\',$Err);
  }
  else {
    $xmlPost = checkPost();
    $sql = genSQLinsert($xmlPost);
    $results = $modx->db->query($sql);
    if($results) { echo $modx->TXNewsletters[\'txtlang\'][\'subscribe_ok\'].\'<br />\'."\\n"; }
    else{
      echo $modx->TXNewsletters[\'txtlang\'][\'subscribe_err1\'].\'<br />\'."\\n";
      echo $modx->TXNewsletters[\'txtlang\'][\'subscribe_err2\'].\'<br />\'."\\n";
    }
  }

break;

/* Affichage formulaire de changement d\'inscription / annulation inscription */
case \'del\' :

  if (isset($_GET[\'email\']) && strlen($_GET[\'email\'])>6 && isset($_GET[\'control\'])){
    $email = delCode($_GET[\'email\']);
    $MD5 = delCode($_GET[\'control\']);
    if(checkControl($email,$MD5) && testEmail($email)){
      echo \'<div>\'.$modx->TXNewsletters[\'txtlang\'][\'subscribe_mod_msg\'].\'</div>\'."<br />\\n";
      $sql = genSQLedit($email);
      $results = $modx->db->query($sql);
      $values = mysql_fetch_assoc($results);
      echo formHTMLeditMod($email,\'del_edit\',$values);
    }
  }

break;

/* Affichage désinscription */
case \'del_send\' :

  if (isset($_POST[\'lastEmail\']) && strlen($_POST[\'lastEmail\'])<6){
    echo \'>> \'.$modx->TXNewsletters[\'txtlang\'][\'subscribe_mod_notok1\'].\'<br /><br />\';
    echo $modx->TXNewsletters[\'txtlang\'][\'subscribe_mod_notok2\'].\'<br />\';
    echo \'<a href="/"> \'.$modx->TXNewsletters[\'txtlang\'][\'msg_back_to_home\'].\' </a> \';
  }
  elseif(isset($_POST[\'lastEmail\'])) {
    $sql = genSQLdel(delCode($_POST[\'lastEmail\']));
    $results = $modx->db->query($sql);
  if ($results){
    echo \'>> \'.$modx->TXNewsletters[\'txtlang\'][\'subscribe_mod_ok1\'].\' " \'.$_POST[\'lastEmail\'].\' " \'.$modx->TXNewsletters[\'txtlang\'][\'subscribe_mod_ok2\']."<br /><br />\\n";
    echo \'<a href="/"> \'.$modx->TXNewsletters[\'txtlang\'][\'msg_back_to_home\'].\' </a> \';
  }
  else {
    echo \'>> \'.$modx->TXNewsletters[\'txtlang\'][\'subscribe_mod_notok1\'].\'<br /><br />\';
    echo $modx->TXNewsletters[\'txtlang\'][\'subscribe_mod_notok2\'].\'<br />\';
    echo \'<a href="/"> \'.$modx->TXNewsletters[\'txtlang\'][\'msg_back_to_home\'].\' </a> \';
  }
  }
  else {
    echo \'>> \'.$modx->TXNewsletters[\'txtlang\'][\'subscribe_mod_notok1\'].\'<br /><br />\';
    echo $modx->TXNewsletters[\'txtlang\'][\'subscribe_mod_notok2\'].\'<br />\';
    echo \'<a href="/"> \'.$modx->TXNewsletters[\'txtlang\'][\'msg_back_to_home\'].\' </a> \';
  }

break;

/* Affichage modification inscription */
case \'del_edit\' :

  $Err = checkForm();
  if ($Err[\'Subscribe\']) {
    if($testEmail){ echo $modx->TXNewsletters[\'txtlang\'][\'email_err\'].\'<br /><br />\'."\\n"; }
    echo formHTMLMod(\'del_edit\',$Err);
  }
  else {
    $xmlPost = checkPost($fields);
    $sql = genSQLupdateMod($xmlPost);
    @$results = $modx->db->query($sql);
    if($results) { echo \'>> \'.$modx->TXNewsletters[\'txtlang\'][\'subscribe_mod_edit_ok\'].\'<br /><br />\'."\\n"; }
    else { echo \'>> \'.$modx->TXNewsletters[\'txtlang\'][\'subscribe_mod_edit_notok1\'].\'<br />\'.$modx->TXNewsletters[\'txtlang\'][\'subscribe_mod_edit_notok2\'].\'<br />\'."\\n"; }
  }

break;

/* Par defaut */
default :

break;

}
//////////////////////////////////////////////////////////////
';
$s['easy2'] = '
$snippetFile = realpath(MODX_BASE_PATH . \'assets/modules/easy2/snippet.easy2gallery.php\');
if (!empty($snippetFile) && file_exists($snippetFile)) {
    return include $snippetFile;
} else {
    return \'\';
}
';
$p = &$this->pluginCache;
$p['CodeMirror'] = '$_CM_BASE = \'assets/plugins/codemirror/\';

$_CM_URL = $modx->config[\'site_url\'] . $_CM_BASE;

require(MODX_BASE_PATH. $_CM_BASE .\'codemirror.plugin.php\');

';
$p['CodeMirrorProps'] = '&theme=Theme;list;default,ambiance,blackboard,cobalt,eclipse,elegant,erlang-dark,lesser-dark,midnight,monokai,neat,night,rubyblue,solarized,twilight,vibrant-ink,xq-dark,xq-light; &indentUnit=Indent unit;int;4 &tabSize=The width of a tab character;int;4 &lineWrapping=lineWrapping;list;true,false;true &matchBrackets=matchBrackets;list;true,false;false &activeLine=activeLine;list;true,false;false &emmet=emmet;list;true,false;true &search=search;list;true,false;true ';
$p['FileSource'] = 'require MODX_BASE_PATH.\'assets/plugins/filesource/plugin.filesource.php\';';
$p['Forgot Manager Login'] = 'require MODX_BASE_PATH.\'assets/plugins/forgotmanagerlogin/plugin.forgotmanagerlogin.php\';';
$p['ManagerManager'] = '$js_default_url_local = $modx->config[\'site_url\']. \'/assets/js/jquery.min.js\';
$js_default_url_remote = \'http://ajax.googleapis.com/ajax/libs/jquery/1.8/jquery.min.js\';
$asset_path = $modx->config[\'base_path\'] . \'assets/plugins/managermanager/mm.inc.php\';
include($asset_path);
';
$p['ManagerManagerProps'] = '&config_chunk=Configuration Chunk;text;mm_rules; &remove_deprecated_tv_types_pref=Remove deprecated TV types;list;yes,no;yes &which_jquery=jQuery source;list;local (assets/js),remote (google code),manual url (specify below);local (assets/js) &js_src_type=jQuery URL override;text; ';
$p['TinyMCE Rich Text Editor'] = 'require MODX_BASE_PATH.\'assets/plugins/tinymce/plugin.tinymce.php\';
';
$p['TinyMCE Rich Text EditorProps'] = '&customparams=Custom Parameters;textarea;valid_elements : "*[*]", &mce_formats=Block Formats;text;p,h1,h2,h3,h4,h5,h6,div,blockquote,code,pre &entity_encoding=Entity Encoding;list;named,numeric,raw;named &entities=Entities;text; &mce_path_options=Path Options;list;Site config,Absolute path,Root relative,URL,No convert;Site config &mce_resizing=Advanced Resizing;list;true,false;true &disabledButtons=Disabled Buttons;text; &link_list=Link List;list;enabled,disabled;enabled &webtheme=Web Theme;list;simple,editor,creative,custom;simple &webPlugins=Web Plugins;text;style,advimage,advlink,searchreplace,contextmenu,paste,fullscreen,xhtmlxtras,media &webButtons1=Web Buttons 1;text;undo,redo,selectall,|,pastetext,pasteword,|,search,replace,|,hr,charmap,|,image,link,unlink,anchor,media,|,cleanup,removeformat,|,fullscreen,code,help &webButtons2=Web Buttons 2;text;bold,italic,underline,strikethrough,sub,sup,|,|,blockquote,bullist,numlist,outdent,indent,|,justifyleft,justifycenter,justifyright,justifyfull,|,styleselect,formatselect,|,styleprops &webButtons3=Web Buttons 3;text; &webButtons4=Web Buttons 4;text; &webAlign=Web Toolbar Alignment;list;ltr,rtl;ltr &width=Width;text;95% &height=Height;text;500 ';
$p['TransAlias'] = 'require MODX_BASE_PATH.\'assets/plugins/transalias/plugin.transalias.php\';';
$p['TransAliasProps'] = '&table_name=Trans table;list;common,russian,dutch,german,czech,utf8,utf8lowercase;utf8lowercase &char_restrict=Restrict alias to;list;lowercase alphanumeric,alphanumeric,legal characters;legal characters &remove_periods=Remove Periods;list;Yes,No;No &word_separator=Word Separator;list;dash,underscore,none;dash &override_tv=Override TV name;string; ';
$p['easy2'] = '
$pluginFile = realpath(MODX_BASE_PATH . \'assets/modules/easy2/plugin.easy2gallery.php\');
if (!empty($pluginFile) && file_exists($pluginFile)) {
    return include $pluginFile;
} else {
    return \'\';
}
';
$e = &$this->pluginEvent;
$e['OnBeforeManagerLogin'] = array('Forgot Manager Login');
$e['OnBeforePluginFormSave'] = array('FileSource');
$e['OnBeforeSnipFormSave'] = array('FileSource');
$e['OnChunkFormRender'] = array('CodeMirror');
$e['OnDocFormPrerender'] = array('ManagerManager');
$e['OnDocFormRender'] = array('CodeMirror','ManagerManager');
$e['OnInterfaceSettingsRender'] = array('TinyMCE Rich Text Editor');
$e['OnManagerAuthentication'] = array('Forgot Manager Login');
$e['OnManagerLoginFormRender'] = array('Forgot Manager Login');
$e['OnModFormRender'] = array('CodeMirror');
$e['OnPluginFormPrerender'] = array('FileSource');
$e['OnPluginFormRender'] = array('CodeMirror','FileSource');
$e['OnRichTextEditorInit'] = array('TinyMCE Rich Text Editor');
$e['OnRichTextEditorRegister'] = array('TinyMCE Rich Text Editor');
$e['OnSnipFormPrerender'] = array('FileSource');
$e['OnSnipFormRender'] = array('FileSource','CodeMirror');
$e['OnStripAlias'] = array('TransAlias');
$e['OnTempFormRender'] = array('CodeMirror');
$e['OnTVFormRender'] = array('ManagerManager');
$e['OnWebPageComplete'] = array('easy2');
$e['OnWebPageInit'] = array('easy2');

