<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Texelate&#039;s Web Design Leeds Blog</title>
	<atom:link href="http://www.texelate.co.uk/blog/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.texelate.co.uk/blog</link>
	<description>Texelate&#039;s Web Design Leeds Blog</description>
	<lastBuildDate>Wed, 15 May 2013 12:53:27 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.5.1</generator>
		<item>
		<title>Generate a country drop down using PHP</title>
		<link>http://www.texelate.co.uk/blog/generate-a-country-drop-down-using-php/</link>
		<comments>http://www.texelate.co.uk/blog/generate-a-country-drop-down-using-php/#comments</comments>
		<pubDate>Wed, 15 May 2013 12:47:56 +0000</pubDate>
		<dc:creator>Tim Bennett</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[Tutorials and How-Tos]]></category>

		<guid isPermaLink="false">http://www.texelate.co.uk/blog/?p=1041</guid>
		<description><![CDATA[The most time consuming part of creating a country drop down is the data. Here you can find the data for all countries—including their codes (ISO 3166-1 alpha-2)—in a PHP array. That way you can output it however you like. The array is associative and has the two digit country code as the index and [...]]]></description>
				<content:encoded><![CDATA[<p>The most time consuming part of creating a country drop down is the data. Here you can find the data for all countries—including their codes (ISO 3166-1 alpha-2)—in a PHP array. That way you can output it however you like.</p>
<p>The array is associative and has the two digit country code as the index and the country name as the element value.</p>
<p>Country codes are useful as some eCommerce payment gateways require these rather than the full country name. Here&#8217;s the array:<span id="more-1041"></span></p>
<pre><code>$countries = array("AF" =&gt; "Afghanistan",
"AX" =&gt; "Åland Islands",
"AL" =&gt; "Albania",
"DZ" =&gt; "Algeria",
"AS" =&gt; "American Samoa",
"AD" =&gt; "Andorra",
"AO" =&gt; "Angola",
"AI" =&gt; "Anguilla",
"AQ" =&gt; "Antarctica",
"AG" =&gt; "Antigua and Barbuda",
"AR" =&gt; "Argentina",
"AM" =&gt; "Armenia",
"AW" =&gt; "Aruba",
"AU" =&gt; "Australia",
"AT" =&gt; "Austria",
"AZ" =&gt; "Azerbaijan",
"BS" =&gt; "Bahamas",
"BH" =&gt; "Bahrain",
"BD" =&gt; "Bangladesh",
"BB" =&gt; "Barbados",
"BY" =&gt; "Belarus",
"BE" =&gt; "Belgium",
"BZ" =&gt; "Belize",
"BJ" =&gt; "Benin",
"BM" =&gt; "Bermuda",
"BT" =&gt; "Bhutan",
"BO" =&gt; "Bolivia",
"BA" =&gt; "Bosnia and Herzegovina",
"BW" =&gt; "Botswana",
"BV" =&gt; "Bouvet Island",
"BR" =&gt; "Brazil",
"IO" =&gt; "British Indian Ocean Territory",
"BN" =&gt; "Brunei Darussalam",
"BG" =&gt; "Bulgaria",
"BF" =&gt; "Burkina Faso",
"BI" =&gt; "Burundi",
"KH" =&gt; "Cambodia",
"CM" =&gt; "Cameroon",
"CA" =&gt; "Canada",
"CV" =&gt; "Cape Verde",
"KY" =&gt; "Cayman Islands",
"CF" =&gt; "Central African Republic",
"TD" =&gt; "Chad",
"CL" =&gt; "Chile",
"CN" =&gt; "China",
"CX" =&gt; "Christmas Island",
"CC" =&gt; "Cocos (Keeling) Islands",
"CO" =&gt; "Colombia",
"KM" =&gt; "Comoros",
"CG" =&gt; "Congo",
"CD" =&gt; "Congo, The Democratic Republic of The",
"CK" =&gt; "Cook Islands",
"CR" =&gt; "Costa Rica",
"CI" =&gt; "Cote D'ivoire",
"HR" =&gt; "Croatia",
"CU" =&gt; "Cuba",
"CY" =&gt; "Cyprus",
"CZ" =&gt; "Czech Republic",
"DK" =&gt; "Denmark",
"DJ" =&gt; "Djibouti",
"DM" =&gt; "Dominica",
"DO" =&gt; "Dominican Republic",
"EC" =&gt; "Ecuador",
"EG" =&gt; "Egypt",
"SV" =&gt; "El Salvador",
"GQ" =&gt; "Equatorial Guinea",
"ER" =&gt; "Eritrea",
"EE" =&gt; "Estonia",
"ET" =&gt; "Ethiopia",
"FK" =&gt; "Falkland Islands (Malvinas)",
"FO" =&gt; "Faroe Islands",
"FJ" =&gt; "Fiji",
"FI" =&gt; "Finland",
"FR" =&gt; "France",
"GF" =&gt; "French Guiana",
"PF" =&gt; "French Polynesia",
"TF" =&gt; "French Southern Territories",
"GA" =&gt; "Gabon",
"GM" =&gt; "Gambia",
"GE" =&gt; "Georgia",
"DE" =&gt; "Germany",
"GH" =&gt; "Ghana",
"GI" =&gt; "Gibraltar",
"GR" =&gt; "Greece",
"GL" =&gt; "Greenland",
"GD" =&gt; "Grenada",
"GP" =&gt; "Guadeloupe",
"GU" =&gt; "Guam",
"GT" =&gt; "Guatemala",
"GG" =&gt; "Guernsey",
"GN" =&gt; "Guinea",
"GW" =&gt; "Guinea-bissau",
"GY" =&gt; "Guyana",
"HT" =&gt; "Haiti",
"HM" =&gt; "Heard Island and Mcdonald Islands",
"VA" =&gt; "Holy See (Vatican City State)",
"HN" =&gt; "Honduras",
"HK" =&gt; "Hong Kong",
"HU" =&gt; "Hungary",
"IS" =&gt; "Iceland",
"IN" =&gt; "India",
"ID" =&gt; "Indonesia",
"IR" =&gt; "Iran, Islamic Republic of",
"IQ" =&gt; "Iraq",
"IE" =&gt; "Ireland",
"IM" =&gt; "Isle of Man",
"IL" =&gt; "Israel",
"IT" =&gt; "Italy",
"JM" =&gt; "Jamaica",
"JP" =&gt; "Japan",
"JE" =&gt; "Jersey",
"JO" =&gt; "Jordan",
"KZ" =&gt; "Kazakhstan",
"KE" =&gt; "Kenya",
"KI" =&gt; "Kiribati",
"KP" =&gt; "Korea, Democratic People's Republic of",
"KR" =&gt; "Korea, Republic of",
"KW" =&gt; "Kuwait",
"KG" =&gt; "Kyrgyzstan",
"LA" =&gt; "Lao People's Democratic Republic",
"LV" =&gt; "Latvia",
"LB" =&gt; "Lebanon",
"LS" =&gt; "Lesotho",
"LR" =&gt; "Liberia",
"LY" =&gt; "Libyan Arab Jamahiriya",
"LI" =&gt; "Liechtenstein",
"LT" =&gt; "Lithuania",
"LU" =&gt; "Luxembourg",
"MO" =&gt; "Macao",
"MK" =&gt; "Macedonia, The Former Yugoslav Republic of",
"MG" =&gt; "Madagascar",
"MW" =&gt; "Malawi",
"MY" =&gt; "Malaysia",
"MV" =&gt; "Maldives",
"ML" =&gt; "Mali",
"MT" =&gt; "Malta",
"MH" =&gt; "Marshall Islands",
"MQ" =&gt; "Martinique",
"MR" =&gt; "Mauritania",
"MU" =&gt; "Mauritius",
"YT" =&gt; "Mayotte",
"MX" =&gt; "Mexico",
"FM" =&gt; "Micronesia, Federated States of",
"MD" =&gt; "Moldova, Republic of",
"MC" =&gt; "Monaco",
"MN" =&gt; "Mongolia",
"ME" =&gt; "Montenegro",
"MS" =&gt; "Montserrat",
"MA" =&gt; "Morocco",
"MZ" =&gt; "Mozambique",
"MM" =&gt; "Myanmar",
"NA" =&gt; "Namibia",
"NR" =&gt; "Nauru",
"NP" =&gt; "Nepal",
"NL" =&gt; "Netherlands",
"AN" =&gt; "Netherlands Antilles",
"NC" =&gt; "New Caledonia",
"NZ" =&gt; "New Zealand",
"NI" =&gt; "Nicaragua",
"NE" =&gt; "Niger",
"NG" =&gt; "Nigeria",
"NU" =&gt; "Niue",
"NF" =&gt; "Norfolk Island",
"MP" =&gt; "Northern Mariana Islands",
"NO" =&gt; "Norway",
"OM" =&gt; "Oman",
"PK" =&gt; "Pakistan",
"PW" =&gt; "Palau",
"PS" =&gt; "Palestinian Territory, Occupied",
"PA" =&gt; "Panama",
"PG" =&gt; "Papua New Guinea",
"PY" =&gt; "Paraguay",
"PE" =&gt; "Peru",
"PH" =&gt; "Philippines",
"PN" =&gt; "Pitcairn",
"PL" =&gt; "Poland",
"PT" =&gt; "Portugal",
"PR" =&gt; "Puerto Rico",
"QA" =&gt; "Qatar",
"RE" =&gt; "Reunion",
"RO" =&gt; "Romania",
"RU" =&gt; "Russian Federation",
"RW" =&gt; "Rwanda",
"SH" =&gt; "Saint Helena",
"KN" =&gt; "Saint Kitts and Nevis",
"LC" =&gt; "Saint Lucia",
"PM" =&gt; "Saint Pierre and Miquelon",
"VC" =&gt; "Saint Vincent and The Grenadines",
"WS" =&gt; "Samoa",
"SM" =&gt; "San Marino",
"ST" =&gt; "Sao Tome and Principe",
"SA" =&gt; "Saudi Arabia",
"SN" =&gt; "Senegal",
"RS" =&gt; "Serbia",
"SC" =&gt; "Seychelles",
"SL" =&gt; "Sierra Leone",
"SG" =&gt; "Singapore",
"SK" =&gt; "Slovakia",
"SI" =&gt; "Slovenia",
"SB" =&gt; "Solomon Islands",
"SO" =&gt; "Somalia",
"ZA" =&gt; "South Africa",
"GS" =&gt; "South Georgia and The South Sandwich Islands",
"ES" =&gt; "Spain",
"LK" =&gt; "Sri Lanka",
"SD" =&gt; "Sudan",
"SR" =&gt; "Suriname",
"SJ" =&gt; "Svalbard and Jan Mayen",
"SZ" =&gt; "Swaziland",
"SE" =&gt; "Sweden",
"CH" =&gt; "Switzerland",
"SY" =&gt; "Syrian Arab Republic",
"TW" =&gt; "Taiwan, Province of China",
"TJ" =&gt; "Tajikistan",
"TZ" =&gt; "Tanzania, United Republic of",
"TH" =&gt; "Thailand",
"TL" =&gt; "Timor-leste",
"TG" =&gt; "Togo",
"TK" =&gt; "Tokelau",
"TO" =&gt; "Tonga",
"TT" =&gt; "Trinidad and Tobago",
"TN" =&gt; "Tunisia",
"TR" =&gt; "Turkey",
"TM" =&gt; "Turkmenistan",
"TC" =&gt; "Turks and Caicos Islands",
"TV" =&gt; "Tuvalu",
"UG" =&gt; "Uganda",
"UA" =&gt; "Ukraine",
"AE" =&gt; "United Arab Emirates",
"GB" =&gt; "United Kingdom",
"US" =&gt; "United States",
"UM" =&gt; "United States Minor Outlying Islands",
"UY" =&gt; "Uruguay",
"UZ" =&gt; "Uzbekistan",
"VU" =&gt; "Vanuatu",
"VE" =&gt; "Venezuela",
"VN" =&gt; "Viet Nam",
"VG" =&gt; "Virgin Islands, British",
"VI" =&gt; "Virgin Islands, U.S.",
"WF" =&gt; "Wallis and Futuna",
"EH" =&gt; "Western Sahara",
"YE" =&gt; "Yemen",
"ZM" =&gt; "Zambia",
"ZW" =&gt; "Zimbabwe");</code></pre>
<p>The countries names are alphabetical but the country codes aren&#8217;t as some countries names are somewhat illogical. For example, <em>United Kingdom</em> is <em>GB</em>. If you wish to order them by country code simple use PHP&#8217;s <code>ksort</code>.</p>
<pre><code>ksort($countries);</code></pre>
<p>Here&#8217;s an example of how you could output your drop down:</p>
<pre><code>&lt;select name="countries"&gt;
&lt;?php

foreach($countries as $key =&gt; $value) {

?&gt;
&lt;option value="&lt;?= $key ?&gt;" title="&lt;?= htmlspecialchars($value) ?&gt;"&gt;&lt;?= htmlspecialchars($value) ?&gt;&lt;/option&gt;
&lt;?php

}

?&gt;
&lt;/select&gt;</code></pre>
<div class="notice">For more information on country codes visit <a rel="nofollow" href="http://en.wikipedia.org/wiki/ISO_3166-1_alpha-2" target="_blank">http://en.wikipedia.org/wiki/ISO_3166-1_alpha-2</a></div>
]]></content:encoded>
			<wfw:commentRss>http://www.texelate.co.uk/blog/generate-a-country-drop-down-using-php/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Get plain text intro from HTML using PHP</title>
		<link>http://www.texelate.co.uk/blog/get-plain-text-intro-from-html-using-php/</link>
		<comments>http://www.texelate.co.uk/blog/get-plain-text-intro-from-html-using-php/#comments</comments>
		<pubDate>Fri, 03 May 2013 10:38:25 +0000</pubDate>
		<dc:creator>Tim Bennett</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[Tutorials and How-Tos]]></category>

		<guid isPermaLink="false">http://www.texelate.co.uk/blog/?p=1035</guid>
		<description><![CDATA[So you have HTML stored in your database. How do you create a plain text introduction from it? Here&#8217;s how. This tutorial assumes you are using the UTF-8 charset function getplaintextintrofromhtml($html, $numchars) { // Remove the HTML tags $html = strip_tags($html); // Convert HTML entities to single characters $html = html_entity_decode($html, ENT_QUOTES, 'UTF-8'); // Make [...]]]></description>
				<content:encoded><![CDATA[<p>So you have HTML stored in your database. How do you create a plain text introduction from it? Here&#8217;s how.</p>
<div class="notice">This tutorial assumes you are using the UTF-8 charset</div>
<p><span id="more-1035"></span></p>
<pre><code>function getplaintextintrofromhtml($html, $numchars) {

    // Remove the HTML tags
    $html = strip_tags($html);

    // Convert HTML entities to single characters
    $html = html_entity_decode($html, ENT_QUOTES, 'UTF-8');

    // Make the string the desired number of characters
    $html = substr($html, 0, $numchars);

    // Add an elipsis
    $html .= "…";

    return $html;

}</code></pre>
<p>The reason <code>strip_tags</code> only won&#8217;t do is because otherwise things like <em>&amp;</em> will output as <em>&amp;amp;</em>. If you&#8217;re outputting to a web page you may think you don&#8217;t need to decode the entities but what if your string cut-off point is part way through an entity? This function converts HTML to pure plain text so you can do what you want with it. That does mean if you are outputting to HTML you will need to call <code>htmlspecialchars</code> or <code>htmlentities</code>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.texelate.co.uk/blog/get-plain-text-intro-from-html-using-php/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>JQuery: What&#8217;s the difference between height, innerHeight and outerHeight?</title>
		<link>http://www.texelate.co.uk/blog/jquery-whats-the-difference-between-height-innerheight-and-outerheight/</link>
		<comments>http://www.texelate.co.uk/blog/jquery-whats-the-difference-between-height-innerheight-and-outerheight/#comments</comments>
		<pubDate>Thu, 04 Apr 2013 06:45:33 +0000</pubDate>
		<dc:creator>Tim Bennett</dc:creator>
				<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[Tutorials and How-Tos]]></category>

		<guid isPermaLink="false">http://www.texelate.co.uk/blog/?p=1020</guid>
		<description><![CDATA[I was surprised to find there is no simple online comparison giving an overview of the difference between JQuery&#8217;s height, innerHeight and outerHeight. It&#8217;s really quite simple and is down to whether the calculation factors in padding, border and margin. Here&#8217;s the summary: &#160; padding border margin height innerHeight outerHeight outerHeight(true) &#160; Thanks to Mark James for [...]]]></description>
				<content:encoded><![CDATA[<p>I was surprised to find there is no simple online comparison giving an overview of the difference between JQuery&#8217;s height, innerHeight and outerHeight. It&#8217;s really quite simple and is down to whether the calculation factors in padding, border and margin.</p>
<p>Here&#8217;s the summary:</p>
<table cellspacing="0" class="datatable">
<tr>
<td>&nbsp;</td>
<td><strong style="font-weight: bold;">padding</strong></td>
<td><strong style="font-weight: bold;">border</strong></td>
<td><strong style="font-weight: bold;">margin</strong></td>
</tr>
<tr>
<td><code><a href="http://api.jquery.com/height/" target="_blank">height</a></code></td>
<td class="center"><img src="/img/blog/cross.gif" alt="" /></td>
<td class="center"><img src="/img/blog/cross.gif" alt="" /></td>
<td class="center"><img src="/img/blog/cross.gif" alt="" /></td>
</tr>
<tr>
<td><code><a href="http://api.jquery.com/innerHeight/" target="_blank">innerHeight</a></code></td>
<td class="center"><img src="/img/blog/tick.gif" alt="" /></td>
<td class="center"><img src="/img/blog/cross.gif" alt="" /></td>
<td class="center"><img src="/img/blog/cross.gif" alt="" /></td>
</tr>
<tr>
<td><code><a href="http://api.jquery.com/outerHeight/" target="_blank">outerHeight</a></code></td>
<td class="center"><img src="/img/blog/tick.gif" alt="" /></td>
<td class="center"><img src="/img/blog/tick.gif" alt="" /></td>
<td class="center"><img src="/img/blog/cross.gif" alt="" /></td>
</tr>
<tr>
<td><code><a href="http://api.jquery.com/outerHeight/" target="_blank">outerHeight(true)</a></code></td>
<td class="center"><img src="/img/blog/tick.gif" alt="" /></td>
<td class="center"><img src="/img/blog/tick.gif" alt="" /></td>
<td class="center"><img src="/img/blog/tick.gif" alt="" /></td>
</tr>
</table>
<p>&nbsp;</p>
<div class="small italic light">Thanks to Mark James for his excellent icons. http://www.famfamfam.com/lab/icons/silk/</div>
<p>&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.texelate.co.uk/blog/jquery-whats-the-difference-between-height-innerheight-and-outerheight/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Can you upload video to your website?</title>
		<link>http://www.texelate.co.uk/blog/can-you-upload-video-to-your-website/</link>
		<comments>http://www.texelate.co.uk/blog/can-you-upload-video-to-your-website/#comments</comments>
		<pubDate>Fri, 01 Mar 2013 14:08:55 +0000</pubDate>
		<dc:creator>Tim Bennett</dc:creator>
				<category><![CDATA[Blogging/Writing/Content]]></category>
		<category><![CDATA[Web Design]]></category>

		<guid isPermaLink="false">http://www.texelate.co.uk/blog/?p=976</guid>
		<description><![CDATA[This blog may appear overly technical and long-winded but I can assure you it isn&#8217;t. Read right through to the end and I promise you you’ll be wiser for it. Some years ago it seemed that YouTube was the only major player in the world of online video. Thanks to its success and popularity, other [...]]]></description>
				<content:encoded><![CDATA[<div class="notice">This blog may appear overly technical and long-winded but I can assure you it isn&#8217;t. Read right through to the end and I promise you you’ll be wiser for it.</div>
<p>Some years ago it seemed that YouTube was the only major player in the world of online video. Thanks to its success and popularity, other sites followed suit making the Internet awash with video content. Because of this, I’m often asked, “can you upload video to your website?”</p>
<p>To answer that question it is necessary to give an overview as to how video works online. Without wanting to get too technical here’s a very brief summary of how it works.<span id="more-976"></span></p>
<p>Video is essentially lots and lots of images and an audio track all in one file. Compared to a song on its own or a single image (especially so for the latter) a video is huge in file size. To make video a viable digital media medium it needs to be compressed first to reduce its size. Once compressed, it then needs to be decompressed by the user. The software that handles this is known as a “codec”—which is a portmanteau of <em>co</em>mpression and <em>dec</em>ompression.</p>
<p>In an ideal world there would only be a single codec; it would be perfectly efficient and be available on every computer, tablet and mobile in the world. As is often in the real world, the reality is far from perfect.</p>
<p>There are lots of codecs available. Each one handles the compression/decompression differently. They yield different files sizes and qualities, they are subject to different legal restrictions and are not necessarily available for all devices and computers.</p>
<p>This fragmented situation means that there is currently no standard way to deliver video through the web. Furthermore, an online video needs player controls (E.g. play, pause) for which there is also no standard implementation.</p>
<p>At any one time though, there are usually just a handful of formats that people use that cover the full gamut of website visitors. When adding video to your website it’s important to consider offering more than one format. Because of the huge technological difference between a desktop computer and a smartphone, for example, you will generally need to offer a different format for each one. To make things even more confusing the format you shot your video in may not even be suitable for the web in the first place.</p>
<p>At this point you&#8217;re probably ready to give up on the idea altogether. After all, if you knew what formats were suitable for the web, how to convert them and how to deliver the right format based on your visitor you wouldn&#8217;t be reading this article. Don&#8217;t give up though, the solution is here!</p>
<p>So, how do you learn to do all the above? The brilliantly simple answer is: you don&#8217;t.</p>
<p>All you need to do is create an account with an online provider such as YouTube or Vimeo. When you upload videos to such sites they do all the converting for you. They also factor in mobile devices. To add them to your site you simply get something called the “embed code”. This allows you to place the video onto your own website. Ask your web designer for more details on how this is done. It’s quick, easy and free though.</p>
<p>The only major con to the above method is you have little control over how the video looks and it contains third party branding. If you wish to style it yourself you have two options.</p>
<p><strong>Option one</strong> is to get your web designer to encode the video and add it directly to your website. However, you will have to pay for their time and you won&#8217;t be able to do it yourself.</p>
<p><strong>Option two</strong> is to install software onto your web server that works in the same way as YouTube, etc. That is, you upload video in the format you took it in and the software does the rest. While this makes for a very slick site, to do this you need your very own web server and would have to pay significant cost to have it installed, configured and integrated into your site.</p>
<p>To get a site with video call me on <strong>07843 483 078</strong> or <a href="/quote/">get a free quote online</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.texelate.co.uk/blog/can-you-upload-video-to-your-website/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Simple JQuery Sliding FAQs</title>
		<link>http://www.texelate.co.uk/blog/simple-jquery-sliding-faqs/</link>
		<comments>http://www.texelate.co.uk/blog/simple-jquery-sliding-faqs/#comments</comments>
		<pubDate>Wed, 27 Feb 2013 11:24:13 +0000</pubDate>
		<dc:creator>Tim Bennett</dc:creator>
				<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[Tutorials and How-Tos]]></category>

		<guid isPermaLink="false">http://www.texelate.co.uk/blog/?p=965</guid>
		<description><![CDATA[This is a really, really simple JQuery script to allow you to have sliding FAQs on your website. This is a great approach if you have loads of content on the page as the visitor only views one answer at a time. Here&#8217;s the demo And here&#8217;s the source code: &#60;!DOCTYPE html&#62; &#60;html lang="en"&#62; &#60;head&#62; [...]]]></description>
				<content:encoded><![CDATA[<p>This is a really, <em>really</em> simple JQuery script to allow you to have sliding FAQs on your website. This is a great approach if you have loads of content on the page as the visitor only views one answer at a time.</p>
<div class="success"><a href="/demos/simple-jquery-sliding-faqs.html">Here&#8217;s the demo</a></div>
<p>And here&#8217;s the source code:<span id="more-965"></span></p>
<pre><code>&lt;!DOCTYPE html&gt;
&lt;html lang="en"&gt;
&lt;head&gt;
&lt;meta charset="utf-8"&gt;
&lt;title&gt;Simple JQuery Sliding FAQs&lt;/title&gt;
&lt;script src="https://ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js"&gt;&lt;/script&gt;
&lt;script src="http://cdnjs.cloudflare.com/ajax/libs/jquery-easing/1.3/jquery.easing.min.js"&gt;&lt;/script&gt;
&lt;style media="all"&gt;

span {

    display: block;
    float: left;
    width: 35px;

}

div.faq, div.answer { width: 600px; }

/* This prevents JQuery's slidedown jerky bug */
h2 { margin: 0px; }

&lt;/style&gt;
&lt;script&gt;

$(function() {

    $('div.answer').hide();

    $('a.question').before('&lt;span class="faqplusminus"&gt;[+]&lt;/span&gt;');

    $('a.question').click(function() {

        $('div.answer').slideUp('slow', 'easeInOutExpo');

        $('span.faqplusminus').html('[+]');

        var slidedownelement = $(this).closest('div.faq').find('div.answer').eq(0);

        if(!slidedownelement.is(':visible')) {

            slidedownelement.slideDown('slow', 'easeInOutExpo');
            slidedownelement.parent().find('span.faqplusminus').html('[-]');

        }

    });

});

&lt;/script&gt;
&lt;/head&gt;
&lt;body&gt;
&lt;p&gt;Click on a question reveal the answer.&lt;/p&gt;
&lt;br /&gt;
&lt;div class="faq"&gt;
&lt;h2&gt;&lt;a class="question" href="javascript:void(0);"&gt;Does the name for question 1 go here?&lt;/a&gt;&lt;/h2&gt;
&lt;div class="answer"&gt;
&lt;p&gt;Yes. Latine tritani pri at, reformidans voluptatibus ei mei, ne equidem vituperata vel. Te dicta epicurei reprehendunt eum.
Ad eum sale salutandi, te mea ferri malorum neglegentur. Ad epicuri mentitum vim, an etiam noluisse duo. An per natum ferri
impetus.&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;br /&gt;
&lt;div class="faq"&gt;
&lt;h2&gt;&lt;a class="question" href="javascript:void(0);"&gt;Does the name for question 2 go here?&lt;/a&gt;&lt;/h2&gt;
&lt;div class="answer"&gt;
&lt;p&gt;Yes. Latine tritani pri at, reformidans voluptatibus ei mei, ne equidem vituperata vel. Te dicta epicurei reprehendunt eum.
Ad eum sale salutandi, te mea ferri malorum neglegentur. Ad epicuri mentitum vim, an etiam noluisse duo. An per natum ferri
impetus.&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;br /&gt;
&lt;div class="faq"&gt;
&lt;h2&gt;&lt;a class="question" href="javascript:void(0);"&gt;Does the name for question 3 go here?&lt;/a&gt;&lt;/h2&gt;
&lt;div class="answer"&gt;
&lt;p&gt;Yes. Latine tritani pri at, reformidans voluptatibus ei mei, ne equidem vituperata vel. Te dicta epicurei reprehendunt eum.
Ad eum sale salutandi, te mea ferri malorum neglegentur. Ad epicuri mentitum vim, an etiam noluisse duo. An per natum ferri
impetus.&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/body&gt;
&lt;/html&gt;</code></pre>
<p>So, how does it work?</p>
<p>First, we hide all the answers.</p>
<pre><code>$('div.answer').hide();</code></pre>
<p>Then we add a +/i icon. You can change this for an image icon if you like.</p>
<pre><code>$('a.question').before('&lt;span&gt;[+]&lt;/span&gt;');</code></pre>
<p>When a question link is clicked we first set all answers to slide up and change to [+].</p>
<pre><code>$('div.answer').slideUp('slow', 'easeInOutExpo');
$('span.faqplusminus').html('[+]');</code></pre>
<p>We immediately find the active answer element.</p>
<pre><code>var slidedownelement = $(this).closest('div.faq').find('div.answer').eq(0);</code></pre>
<p>Then we slide it down and change it to [-]. This cancels out the <code>slideup()</code> called earlier.</p>
<pre><code>if(!slidedownelement.is(':visible')) {

    slidedownelement.slideDown('slow', 'easeInOutExpo');
    slidedownelement.parent().find('span.faqplusminus').html('[-]');

}</code></pre>
<p>We call <code>!slidedownelement.is(':visible')</code> so that if the answer is already visible, nothing happens.</p>
<p>To create FAQs simply use this template for each one:</p>
<pre><code>&lt;div class="faq"&gt;
    &lt;h2&gt;&lt;a class="question" href="javascript:void(0);"&gt;Question&lt;/a&gt;&lt;/h2&gt;
    &lt;div class="answer"&gt;
        &lt;p&gt;Answer.&lt;/p&gt;
    &lt;/div&gt;
&lt;/div&gt;
</code></pre>
<div class="notice">You don&#8217;t have to use h2 tags but the anchors do need parent elements.</div>
<div class="success">This script degrades great with no JavaScript as the visitor can see it as a normal page of text.</div>
]]></content:encoded>
			<wfw:commentRss>http://www.texelate.co.uk/blog/simple-jquery-sliding-faqs/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>JQuery Vertical Align Function</title>
		<link>http://www.texelate.co.uk/blog/jquery-vertical-align-function/</link>
		<comments>http://www.texelate.co.uk/blog/jquery-vertical-align-function/#comments</comments>
		<pubDate>Mon, 18 Feb 2013 14:20:35 +0000</pubDate>
		<dc:creator>Tim Bennett</dc:creator>
				<category><![CDATA[JavaScript]]></category>

		<guid isPermaLink="false">http://www.texelate.co.uk/blog/?p=920</guid>
		<description><![CDATA[Getting content to align vertically can be a problem in HTML (without using tables). Here&#8217;s a nice method that uses JQuery; all you need to do is add a class name to your element and the script does the rest. This doesn&#8217;t rely on display: inline-block or display: table-cell so works great across all browsers. [...]]]></description>
				<content:encoded><![CDATA[<p>Getting content to align vertically can be a problem in HTML (without using tables). Here&#8217;s a nice method that uses JQuery; all you need to do is add a class name to your element and the script does the rest. This doesn&#8217;t rely on <code>display: inline-block</code> or <code>display: table-cell</code> so works great across all browsers.</p>
<div class="success"><a href="/demos/jquery-vertical-align.html">Click here to view the full code listing</a></div>
<p>For the impatient, here&#8217;s the complete code:<span id="more-920"></span></p>
<pre><code>&lt;!DOCTYPE html&gt;
&lt;html lang="en"&gt;
&lt;head&gt;
&lt;meta charset="utf-8"&gt;
&lt;title&gt;vAlign Test&lt;/title&gt;
&lt;script src="https://ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js"&gt;&lt;/script&gt;
&lt;style media="all"&gt;

body, html {

    height: 100%;
    margin: 0;

}

&lt;/style&gt;
&lt;script&gt;

$(function() {

    $('.valignmiddle').each(function() {

        $(this).parent().css('position', 'relative');
        $(this).css('position', 'absolute');
        $(this).css('top', '50%');
        $(this).css('left', '0px');
        $(this).css('width', '100%');

    });

    $(window).resize(function() {

        var thisheight = Math.round(parseInt($('.valignmiddle').outerHeight()) / 2);
        $('.valignmiddle').css('margin-top', '-' + thisheight + 'px');

        if(parseInt($('.valignmiddle').outerHeight()) > parseInt($('.valignmiddle').parent().outerHeight())) {
		
            $('.valignmiddle').parent().outerHeight($('.valignmiddle').outerHeight());
		
        }

    }).trigger('resize');

});

&lt;/script&gt;
&lt;/head&gt;
&lt;body&gt;
&lt;div style="width: 50%; height: 50%; border: 1px solid red;"&gt;
&lt;div class="valignmiddle" style="border: 1px solid green;"&gt;Hello&lt;/div&gt;
&lt;/div&gt;
&lt;/body&gt;
&lt;/html&gt;
</code></pre>
<p>How does it work?</p>
<p>First we set up some styles for both the parent element and the one we want to vertically align. We need an absolutely positioned element inside of a relatively positioned one and then the top value set to 50%.</p>
<pre><code>$('.valignmiddle').each(function() {

    $(this).parent().css('position', 'relative');
    $(this).css('position', 'absolute');
    $(this).css('top', '50%');
    $(this).css('left', '0px');
    $(this).css('width', '100%');

});</code></pre>
<p>The width is set to the same width as the parent element so you can centre text, etc.</p>
<p>This sort of vertically aligns the element but there is too much space at the top. This is because the start of the element begins half way down the parent element. So, what we need to do is add a negative margin that is half its own height.</p>
<pre><code>$(window).resize(function() {

    var thisheight = Math.round(parseInt($('.valignmiddle').outerHeight()) / 2);
    $('.valignmiddle').css('margin-top', '-' + thisheight + 'px');

}).trigger('resize');</code></pre>
<p>Notice how this code is called on when the browser resizes; this means if your parent element changes size (i.e. it is a % or em width), so does the child element as per table cell behaviour.</p>
<p>What if the child content has a greater height than its parent? To prevent it leaking out we simply check the heights and adjust accordingly if need be:</p>
<pre><code>if(parseInt($('.valignmiddle').outerHeight()) > parseInt($('.valignmiddle').parent().outerHeight())) {
		
    $('.valignmiddle').parent().outerHeight($('.valignmiddle').outerHeight());
		
}</code></pre>
<p>To use the code simply use the JQuery code in the script tags above and give your element the class name <code>.valignmiddle</code>.</p>
<div class="notice">The CSS is there for demonstration purposes only.</div>
<div class="notice">This code assumes you want to align according to the width and height of the parent element regardless of padding.</div>
]]></content:encoded>
			<wfw:commentRss>http://www.texelate.co.uk/blog/jquery-vertical-align-function/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Who is responsible for the text on your website?</title>
		<link>http://www.texelate.co.uk/blog/who-is-responsible-for-the-text-on-your-website/</link>
		<comments>http://www.texelate.co.uk/blog/who-is-responsible-for-the-text-on-your-website/#comments</comments>
		<pubDate>Wed, 30 Jan 2013 18:12:25 +0000</pubDate>
		<dc:creator>Tim Bennett</dc:creator>
				<category><![CDATA[Blogging/Writing/Content]]></category>

		<guid isPermaLink="false">http://www.texelate.co.uk/blog/?p=914</guid>
		<description><![CDATA[I heard the expression the other day that “a camel is a horse designed by committee”. It’s true that when too many people are involved (“too many cooks spoil the broth”—another adage!) and too many viewpoints are shared, a group project can have unexpected results. A website is no different. There are often at least [...]]]></description>
				<content:encoded><![CDATA[<p>I heard the expression the other day that “a camel is a horse designed by committee”. It’s true that when too many people are involved (“too many cooks spoil the broth”—another adage!) and too many viewpoints are shared, a group project can have unexpected results.</p>
<p>A website is no different. There are often at least two parties involved: the web person and the client. Usually though, and even on small projects, more people are involved.</p>
<p>As with other areas of a website, opinions can vary. When it comes to the matter of writing content for your website, who should have the final say? Here I outline some advice that can save horse.com becoming camel.co.uk.<span id="more-914"></span></p>
<p>First, consider who is involved and what their opinion and position might be.</p>
<h2>The designer</h2>
<p>The designer, quite rightly, wants the site to look good. This goes beyond logo, colour scheme and making things line up nicely. A good web designer knows where elements fit in on a page to make the experience pleasurable for the visitor. Perhaps less concerned with the unique selling points of the client’s brand new product—or the number of times a search keyword appears in the copywriter’s killer sales copy—the designer is more concerned with overall readability, typography and how the text sits on the page.</p>
<h2>The client</h2>
<p>While the client may not be a designer, writer or marketeer, he or she knows what they want. Whether it’s to make sure the entire product specification makes it to the website home page or to let the visitor know they’ve been trading for almost five decades, the client wants to be accurately represented online.</p>
<h2>The copywriter</h2>
<p>Happily living the the world of writing noticeable calls-to-action and tapping away about about benefits and <em>not</em> features, a copywriter wants to use words to sell what the client has to offer.</p>
<h2>The SEO company/consultant</h2>
<p>Finally, we come to the SEO expert. Keen to please both Google and the client, any good search engine company knows if the right words aren’t on the right pages then they have fallen at the first hurdle.</p>
<h2>So, who’s right?</h2>
<p>In actual fact no one is especially right or wrong as they all have valid viewpoints. Clearly though, there can be a conflict of priorities. For example, the client may want the technical product data on the site but the copywriter doesn’t feel that will appeal to the full gamut of visitors. The SEO guru wants a nice chunk of text on the home page to please the search engines but the designer feels this will turn his beloved design into an eyesore.</p>
<p>There’s no right or wrong way to approach this. It’s all about trying to get the best of each viewpoint and putting it together to make a workable solution. But what is a workable solution?</p>
<p>To avoid your horse becoming a camel, get a process in place and assign priority based on your findings. First of all, identify the main goals of the website. For example, a portfolio site for an interior design company might place more weight on design whereas an eCommerce site selling gadgets to scientists with PhDs may favour more technical information on the site.</p>
<p>In general though, a workable solution might function like this: the designer creates some (flexible) templates while the client writes an initial draft of the website text. Then the SEO company can perform their keyword research and pass it on to the copywriter with an amended text document—including notes regarding what keywords should appear where. Then finally, the copywriter can produce the finished piece.</p>
<p>While this is by no means a hard-and-fast rule it does demonstrate that by having a process in place your website’s text doesn’t deviate too far from the client’s original aim.</p>
<p>To get a website call me on <strong>07843 483 078</strong> or <a href="/quote/">get a free quote online</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.texelate.co.uk/blog/who-is-responsible-for-the-text-on-your-website/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Things to consider when creating a HTML newsletter</title>
		<link>http://www.texelate.co.uk/blog/things-to-consider-when-creating-a-html-newsletter/</link>
		<comments>http://www.texelate.co.uk/blog/things-to-consider-when-creating-a-html-newsletter/#comments</comments>
		<pubDate>Thu, 22 Nov 2012 10:30:00 +0000</pubDate>
		<dc:creator>Tim Bennett</dc:creator>
				<category><![CDATA[Emails]]></category>
		<category><![CDATA[Internet Marketing]]></category>

		<guid isPermaLink="false">http://www.texelate.co.uk/blog/?p=906</guid>
		<description><![CDATA[For various reasons HTML newsletters are much more limited than normal web pages. To prevent these limitations from getting in the way of your messages here are some things to consider when creating a HTML newsletter. Width To display in most email programs your newsletter should not exceed 600 pixels in width. You can afford [...]]]></description>
				<content:encoded><![CDATA[<p>For various reasons HTML newsletters are much more limited than normal web pages. To prevent these limitations from getting in the way of your messages here are some <strong>things to consider when creating a HTML newsletter</strong>.</p>
<h2>Width</h2>
<p>To display in most email programs your newsletter should not exceed 600 pixels in width. You can afford to go a little wider if you want but 600 pixels is optimal.</p>
<h2>Images</h2>
<p>A lot of people block images by default so your newsletter should be legible without images.<span id="more-906"></span></p>
<h2>Media and Other Elements</h2>
<p>You can&#8217;t embed Flash movies, video and other media into newsletters. Some email programs support animated GIFs but some don&#8217;t so make sure it looks fine if the GIF only shows the first frame of the animation. Other elements such as forms and JavaScript won&#8217;t work either.</p>
<h2>Email Client Limitations</h2>
<p>There are lots of email clients, or programs, out there—and each have their own limitations. The main consideration is Microsoft Outlook. In recent versions, Microsoft unilaterally decided to change the rendering engine of their HTML emails from Internet Explorer to Word, which is much more limited. One of the main roadblocks is the Word rendering engine does not properly support background images. Any good web designer/developer will be aware of what Outlook can and can&#8217;t do.</p>
<h2>Ability to Unsubscribe</h2>
<p>It is a legal requirement that you give people the ability to unsubscribe.</p>
<h2>Online Version</h2>
<p>As a final contingency, just in case even after all of the above they still can&#8217;t see your newsletter properly, provide a link to an online version where your newsletter isn&#8217;t bound by these limitations.</p>
<p>For help designing your newsletter call me on <strong>07843 483 078</strong> or <a href="/quote/">get a free quote online</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.texelate.co.uk/blog/things-to-consider-when-creating-a-html-newsletter/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The dangers of cheap web hosting</title>
		<link>http://www.texelate.co.uk/blog/the-dangers-of-cheap-web-hosting/</link>
		<comments>http://www.texelate.co.uk/blog/the-dangers-of-cheap-web-hosting/#comments</comments>
		<pubDate>Tue, 21 Aug 2012 08:34:56 +0000</pubDate>
		<dc:creator>Tim Bennett</dc:creator>
				<category><![CDATA[Hosting]]></category>

		<guid isPermaLink="false">http://www.texelate.co.uk/blog/?p=895</guid>
		<description><![CDATA[Few things have such a great potential to ruin your online business than your web hosting. Most website owners have at some point had to go through the stress of their website going down. As to how easy or difficult it is to reinstate your website depends largely on your hosting company. There are literally [...]]]></description>
				<content:encoded><![CDATA[<p>Few things have such a great potential to ruin your online business than your web hosting. Most website owners have at some point had to go through the stress of their website going down. As to how easy or difficult it is to reinstate your website depends largely on your hosting company. There are literally thousand of web companies out there and they vary greatly in price. Some prefer to go with cheaper companies to save a few pounds a year but in this blog post I argue the case for pushing the boat out a little as spending a bit extra can save you a lot of headaches.</p>
<p>So, what are <strong>the dangers of cheap web hosting?<span id="more-895"></span></strong></p>
<h2>More frequent downtime</h2>
<p>Cheap hosting packages mean there are less people to monitor the resources and this means your server and therefore your website is more likely to go down.</p>
<h2>Oversold servers</h2>
<p>Unless you have a dedicated server (a package where you lease the entire server meaning no one else is using it) your site will rung along site a number of other websites. Cheaper hosting companies have less stringent policies on how many sites they run on a server at any one time. The result is they run slowly as they try to do a lot of things at once.</p>
<h2>Slow, unreliable support</h2>
<p>Websites run twenty-four hours a day, seven days a week. So nine-to-five support is no good to you. Cheaper hosting companies often limit the time their help desk is open to save money. Furthermore, some do not offer telephone support to reduce their running costs.</p>
<h2>Overseas servers and support</h2>
<p>It’s more costly to run a server in the UK than it is in many other countries. Some companies save money by housing their servers and their support team overseas. This causes two problem: the support team may not speak the same languages as you and having a site on an overseas server may interfere with your search engine rankings.</p>
<p>Of course, this post is not saying that all cheap hosting companies are bad and all expensive ones are perfect—or that there is always a correlation between what you spend and the quality of service. The important point is that if a company seems unusually cheap, you should exercise caution. A quick search online will no doubt reveal reviews that show how good or bad they are.</p>
<p>If you need a website with a reliable hosting package call me on <strong>07843 483 078</strong> or <a href="/quote/">get a free quote online</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.texelate.co.uk/blog/the-dangers-of-cheap-web-hosting/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>What’s the difference between a Windows and a Linux website?</title>
		<link>http://www.texelate.co.uk/blog/whats-the-difference-between-a-windows-and-a-linux-website/</link>
		<comments>http://www.texelate.co.uk/blog/whats-the-difference-between-a-windows-and-a-linux-website/#comments</comments>
		<pubDate>Wed, 11 Jul 2012 12:49:36 +0000</pubDate>
		<dc:creator>Tim Bennett</dc:creator>
				<category><![CDATA[Web Development]]></category>

		<guid isPermaLink="false">http://www.texelate.co.uk/blog/?p=892</guid>
		<description><![CDATA[When potential clients approach me asking me to take over their new website, there might be a number of reasons why I say no—but one of the main reasons I’ll turn a job down early on in the discussion is because the site runs on a Windows server. This might seem like a small point [...]]]></description>
				<content:encoded><![CDATA[<p>When potential clients approach me asking me to take over their new website, there might be a number of reasons why I say no—but one of the main reasons I’ll turn a job down early on in the discussion is because the site runs on a Windows server. This might seem like a small point to the client but to me, and any other developer, it’s a big issue. Here I outline <strong>the difference between a Windows and a Linux website</strong>.<span id="more-892"></span></p>
<h2>How are they different?</h2>
<p>Windows and Linux are two different “platforms” for websites (there are more than just these two but these are the most popular). That is they form the foundation of the web server. Built on top of these are other technologies that are you used run your site such programming languages, database servers and email software. Although some software is available for both platforms, generally speaking, the Windows and Linux platforms use different software to accomplish the same purpose. Because learning these technologies is such a long process, developers tend to go down one route and stick to it. Some are capable in both but will generally favour one over the other. Expecting a developer to be able to work with your Windows site when they are predominantly of a Linux background is like expecting someone to be able to speak fluent Portuguese just because they can speak Spanish.</p>
<h2>Which is better?</h2>
<p>Neither is better than the other per se. However, due to the abundance of free software for it, Linux is generally the preferred choice for freelancers like myself. In terms of overall popularity, Linux has a clear edge on Windows although both have a very strong following.</p>
<h2>How to find the right developer</h2>
<p>As a rule-of-thumb, I do not take on Windows projects. The except to this is if they are “static” sites (pages of text and image with no database). However, when an enquiry comes in I do my best to find someone to refer the lead on to. If you have submitted a quote to a freelancer or web design company and they state this as a reason, ask them if they know anyone else that can help you. A good freelancer will be well-connected.</p>
<p>If you&#8217;d like a website give me a call on <strong>07843 483 078</strong> or <a href="/quote/">get a free quote online</a>.</p>
<p>&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.texelate.co.uk/blog/whats-the-difference-between-a-windows-and-a-linux-website/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
