<?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>Mark Wilkinson</title>
	<atom:link href="http://equalmark.net/feed/" rel="self" type="application/rss+xml" />
	<link>http://equalmark.net</link>
	<description>WordPress Consultant and Web Developer</description>
	<lastBuildDate>Tue, 31 Aug 2010 13:43:04 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Watching Movies via Home WiFi on iPod</title>
		<link>http://equalmark.net/tutorials/ipodwifimovies/</link>
		<comments>http://equalmark.net/tutorials/ipodwifimovies/#comments</comments>
		<pubDate>Mon, 30 Aug 2010 12:05:12 +0000</pubDate>
		<dc:creator>Mark Wilkinson</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[iPad]]></category>
		<category><![CDATA[iPod]]></category>
		<category><![CDATA[Mac]]></category>
		<category><![CDATA[Movies]]></category>
		<category><![CDATA[Streaming]]></category>
		<category><![CDATA[Video]]></category>
		<category><![CDATA[WiFi]]></category>

		<guid isPermaLink="false">http://equalmark.net/?p=642</guid>
		<description><![CDATA[iPod and iPads all have the ability to watch movies and videos on them. However my iPod (iPhone) and iPad have a limited amount of storage space on them.  Therefore I can&#8217;t save all my videos onto the devices themselves.  But hang on I already have all my videos on my Mac which is on [...]]]></description>
			<content:encoded><![CDATA[<p class="intro">iPod and iPads all have the ability to watch movies and videos on them. However my iPod (iPhone) and iPad have a limited amount of storage space on them.  Therefore I can&#8217;t save all my videos onto the devices themselves.  But hang on I already have all my videos on my Mac which is on the same WiFi network as my handheld devices. So how can I watch movies and videos on the iPod and iPhone, streaming them over WiFi from my Mac?  Well here is how I have done it.</p>
<p>The great thing about Macs is that they have so much functionality built into them already, without have to purchase various different pieces of software to carry out this and that.  One such thing that sprung to mind when I cam across this problem was that your Mac is a web server.</p>
<p><span id="more-642"></span></p>
<p>If you take a look in the System Preferences and then the Sharing link ( &gt; System Preferences &gt; Sharing) you will see a whole list of sharing options.  One of these is labelled &#8220;<em>Web Sharing</em>&#8220;.  Turn this option on by clicking on the tick box next to it. In the information panel to the right, your Mac will now give you your personal website address which will be in the form of computername.lan/~honefoldername.  This folder is mapped to your sites folder which is contained in your home folder.</p>
<p><a rel="prettyPhoto" href="http://equalmark.net/wp-content/uploads/2010/08/mac-sharing-options.jpg"><img title="mac-sharing-options" src="http://equalmark.net/wp-content/uploads/2010/08/mac-sharing-options-500x409.jpg" alt="" width="500" height="409" /></a></p>
<p>The next thing to do is to copy any videos that you want to make available via WiFi to your iPod/iPad into this sites folder.  Then on your iPad or iPod open the Safari browser and enter the address given in the Web Sharing panel of System preferences and you you will be presented with a list of the video that you have copied into the site folder.  Click on them to play and you are good to go.</p>
<p>You will need to make sure that the videos are playable on an iPod or iPad using supported video and audio codecs, but I guess as they are videos you would store on those devices anyway they should be fine.</p>
]]></content:encoded>
			<wfw:commentRss>http://equalmark.net/tutorials/ipodwifimovies/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Integrating HTML5 Video with WordPress</title>
		<link>http://equalmark.net/wordpress/wordpresshtml5video/</link>
		<comments>http://equalmark.net/wordpress/wordpresshtml5video/#comments</comments>
		<pubDate>Thu, 26 Aug 2010 20:38:32 +0000</pubDate>
		<dc:creator>Mark Wilkinson</dc:creator>
				<category><![CDATA[WordPress]]></category>
		<category><![CDATA[HTML5]]></category>
		<category><![CDATA[JW Player Plugin]]></category>
		<category><![CDATA[Video]]></category>

		<guid isPermaLink="false">http://equalmark.net/?p=627</guid>
		<description><![CDATA[I have recently been working on a client site which needed the integration of HTML5 video.  The client deals heavily in social media and therefore required video to work in iPhones and iPads.  HTML5 video seemed like the best option.  Therefore my challenge was to integrate HTML5 video as well as including the more traditional [...]]]></description>
			<content:encoded><![CDATA[<p class="intro">I have recently been working on a client site which needed the integration of HTML5 video.  The client deals heavily in social media and therefore required video to work in iPhones and iPads.  HTML5 video seemed like the best option.  Therefore my challenge was to integrate HTML5 video as well as including the more traditional flash video for legacy browsers.  Here is my approach.</p>
<p>The first thing to note was the new HTML5 tags to integrate the HTML video.  There is now simply a <code>&lt;video&gt;</code> tag that can be used to incorporate video into your webpage.  The issue is what video codecs to use in order to display your video.  As usual different browser behave different and support different video and codec types, so the first thing is to get your video into the correct format.</p>
<p><span id="more-627"></span></p>
<p><img title="Integrating HTML Video with WordPress" src="http://equalmark.net/wp-content/uploads/2010/08/html5-wordpress.jpg" alt="" width="500" height="200" /></p>
<p>I quickly found that for each video that would be displayed on the website, we would need to encode the video in three different formats.  The first of these is the familiar H.264 video codec.  This is usually wrapped in an MPEG4 file and is recognised by Chrome, Safari, IE9, iPhone (iPad) and Android.  The second is the less well known Theora codec which is wrapped in a .OGV file.  This is compatible with Chrome, Opera and Firefox.  As you will notice it is only Chrome that supports both types and therefore to make sure that all users can see your videos you will need to include both types.</p>
<p>But what about users that are not using an up to date browser?  These users will need to relay of the older (although still widely used) flash (.flv) format.  Therefore you need to encode you final video in the .flv format or you could use a video sharing service such as YouTube.</p>
<p>In order to enable all three of these videos, so that all browsers and configurations are covered, the following code is used:</p>
<pre class="brush: xml;">
&lt;video width=&quot;480&quot; height=&quot;272&quot; controls&gt;
    &lt;!-- used for HTML5 enabled browsers --&gt;
    &lt;source src=&quot;video.mp4&quot; type='video/mp4; codecs=&quot;avc1.42E01E, mp4a.40.2&quot;'&gt;
    &lt;source src=&quot;video.ogv&quot; type='video/ogg; codecs=&quot;theora, vorbis&quot;'&gt;
    &lt;!-- fallback for none HTML5 users --&gt;
    &lt;p id='preview'&gt;In order to view this content you need to enable javascript in your browser.&lt;/p&gt;
    &lt;script type='text/javascript' src='swfobject.js'&gt;&lt;/script&gt;
    &lt;script type='text/javascript'&gt;
        var s1 = new SWFObject('player.swf','player','480','272','9');
        s1.addParam('allowfullscreen','true');
         s1.addParam('allowscriptaccess','always');
         s1.addParam('flashvars','file=video.flv');
         s1.write('preview');
    &lt;/script&gt;
&lt;/video&gt;
</pre>
<p>You can see that the first part of the code above is the HTML5 video.  We have embedded everything inside the new HTML5 video tag.  What this means is that first of all the browser will use the .mp4 version of the video, however browsers that can&#8217;t play that will then display the .ogv version of the video.  Any browser that doesn&#8217;t use HTML5 will not understand the video tags used and therefore will simply use the code inside the <code>&lt;script&gt;</code> tags which uses the <a href="http://www.longtailvideo.com/players/jw-flv-player/" target="_blank">JW Flash Player</a>.</p>
<p>This works really well but what I wanted to do was to give the user the ability from with a post or page to add the video URLs (for all three codecs) as well as the height of the video.  To do this I have utilised WordPress custom fields in order to store the information for the video URLs.  Therefore the code above has been turned into something like the code below in order to pull the video URLs and the height of the video from the current post or pages custom fields.</p>
<pre class="brush: php;">
&lt;video width=&quot;480&quot; height=&quot;&lt;?php echo get_post_meta($post-&gt;ID, &quot;th_videoheight&quot;, true); ?&gt;&quot; controls&gt;
    &lt;!-- used for HTML5 enabled browsers --&gt;
    &lt;?php if ( get_post_meta($post-&gt;ID, &quot;th_mp4videourl&quot;, true) ) { // checks if an mp4 version of the video has been added ?&gt;
         &lt;source src=&quot;&lt;?php echo get_post_meta($post-&gt;ID, &quot;th_mp4videourl&quot;, true); ?&gt;&quot; type='video/mp4; codecs=&quot;avc1.42E01E, mp4a.40.2&quot;'&gt;
    &lt;?php } ?&gt;
    &lt;?php if ( get_post_meta($post-&gt;ID, &quot;th_ogvvideourl&quot;, true) ) { // checks if an ogv version of the video has been added ?&gt;
         &lt;source src=&quot;&lt;?php echo get_post_meta($post-&gt;ID, &quot;th_ogvvideourl&quot;, true); ?&gt;&quot; type='video/ogg; codecs=&quot;theora, vorbis&quot;'&gt;
    &lt;?php } ?&gt;
    &lt;!-- fallback for none HTML5 users --&gt;
    &lt;p id='preview'&gt;In order to view this content you need to enable javascript in your browser.&lt;/p&gt;
    &lt;script type='text/javascript' src='&lt;?php bloginfo('template_url'); ?&gt;/videoplayer/swfobject.js'&gt;&lt;/script&gt;
    &lt;script type='text/javascript'&gt;
        var s1 = new SWFObject('&lt;?php bloginfo('template_url'); ?&gt;/videoplayer/player.swf','player','480','&lt;?php echo get_post_meta($post-&gt;ID, &quot;th_videoheight&quot;, true); ?&gt;','9');
        s1.addParam('allowfullscreen','true');
        s1.addParam('allowscriptaccess','always');
        s1.addParam('flashvars','file=&lt;?php echo get_post_meta($post-&gt;ID, &quot;th_flvvideourl&quot;, true); ?&gt;');
        s1.write('preview');
    &lt;/script&gt;
&lt;/video&gt;
</pre>
<p>In the code above you will notice that all the code starting with th_ is the custom field names that have been used.</p>
<p>The next thing that I did was to looks for a piece of software that I could use to encode my videos in the correct formats.  I came across a piece of software for Mac called <a href="http://thelittleappfactory.com/evom/" target="_blank">Evom</a> which enables you to choose to encode for HTML5 and therefore it produces video in the 2 HTML formats (.mp4 and .ogv).  I then used the Adobe Flash Video Encoder bundled with Adobe CS3 suite to make the flash version.</p>
<p>This code therefore enables HTML5 video with a WordPress install as well as using a more traditional flash player to cope with legacy browsers.  I hope you find this post useful and as usual please comment with any questions/feedback.</p>
]]></content:encoded>
			<wfw:commentRss>http://equalmark.net/wordpress/wordpresshtml5video/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>The Wallee iPad Mount</title>
		<link>http://equalmark.net/general/walleeipadmount/</link>
		<comments>http://equalmark.net/general/walleeipadmount/#comments</comments>
		<pubDate>Tue, 24 Aug 2010 14:03:24 +0000</pubDate>
		<dc:creator>Mark Wilkinson</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Apple]]></category>
		<category><![CDATA[iPad]]></category>
		<category><![CDATA[Wall Mount]]></category>
		<category><![CDATA[Wallee]]></category>

		<guid isPermaLink="false">http://equalmark.net/?p=621</guid>
		<description><![CDATA[I have been look for a while for a good wall mounting system for the iPad so that I could almost use this as a 3rd monitor in my office, probably to watch video on whilst working etc.  I  came across The Wallee through a Tweet on twitter and though that it was perfect. It [...]]]></description>
			<content:encoded><![CDATA[<p class="intro">I have been look for a while for a good wall mounting system for the iPad so that I could almost use this as a 3rd monitor in my office, probably to watch video on whilst working etc.  I  came across <a href="http://www.thewallee.com/" target="_blank">The Wallee</a> through a Tweet on twitter and though that it was perfect. It was delivered yesterday and I mounted it just now.</p>
<p>The kit consists of a plastic case for your iPad which can stay on the iPad all the time and act as a suitable case and a wall mounting disc which is the patented wall mounting part.  The idea is that you fasten the wall mounting disc to the wall and then this slots into the back of the case on the iPad.</p>
<p><span id="more-621"></span></p>
<p><a rel="prettyPhoto[walle]" href="http://farm5.static.flickr.com/4078/4923551738_d0867224bf_b.jpg"><img class="alignnone" title="Tools needed to install the Wallee iPad Mount" src="http://farm5.static.flickr.com/4078/4923551738_d0867224bf.jpg" alt="Tools needed to install the Wallee iPad Mount" width="500" height="281" /></a></p>
<p><a rel="prettyPhoto[wallee]" href="http://farm5.static.flickr.com/4134/4922963995_472030cccc_b.jpg"><img class="alignnone" title="Wall Mounted iPad with The Wallee" src="http://farm5.static.flickr.com/4134/4922963995_472030cccc.jpg" alt="Wall Mounted iPad with The Wallee" width="500" height="281" /></a></p>
<p>I have to say that initial impressions are extremely good and I am probably looking at purchasing a second or even third wall mounting disk from the Wallee store so that I can mount my iPad in several locations.  It was very easy to install and requires just some simple DIY tools.  Well done to The Wallee for a great product.</p>
]]></content:encoded>
			<wfw:commentRss>http://equalmark.net/general/walleeipadmount/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Moving a WordPress Site to a New Server</title>
		<link>http://equalmark.net/wordpress/movingwordpress/</link>
		<comments>http://equalmark.net/wordpress/movingwordpress/#comments</comments>
		<pubDate>Sat, 21 Aug 2010 16:23:35 +0000</pubDate>
		<dc:creator>Mark Wilkinson</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[cPanel]]></category>
		<category><![CDATA[Hosting]]></category>
		<category><![CDATA[Migration]]></category>
		<category><![CDATA[Server]]></category>

		<guid isPermaLink="false">http://equalmark.net/?p=597</guid>
		<description><![CDATA[There are lots of different web hosts out there and sometimes it can pay to move your site from one host to another in order to get both the best price and the best service. If you have a WordPress site and you are worried about moving the site to a new server then don&#8217;t, [...]]]></description>
			<content:encoded><![CDATA[<p class="intro">There are lots of different web hosts out there and sometimes it can pay to move your site from one host to another in order to get both the best price and the best service. If you have a WordPress site and you are worried about moving the site to a new server then don&#8217;t, the process is straight forward and here is how to do it.</p>
<p>Lets think a little about how your website points to the current server. Usually the domain registrar is the service which controls the DNS for your domain name. This means it controls where your website is stored i.e. which server it is on. Something there could be some different name servers set by the registrar but you will need to change these anyway.</p>
<p><span id="more-597"></span></p>
<p>The first stage is to copy all of the data from your WordPress site. Your consists of 2 elements that need to be copied.  The first are the files. This is the WordPress files that make your website run in WordPress including  your theme, plugins and all your uploads. Therefore what I always do is run a backup of all the files on the server. If you are using a cPanel host this is very easy.  Click on the <em>backups</em> icon on the cPanel home screen and then click the button which says <em>home folder</em>.  This will download all the files to your computer that are on your website.  Once download unpack the compressed folder and you are interested in the <em>public_html/</em> folder as that is where all your website files are stored.</p>
<p>What I now do is compress all these files into a ZIP file as it makes the site easier to upload to your new host.  Select all the files in the public_html folder and then compress them into 1 ZIP file.  Then login to the cPanel on the new host and upload this ZIP file to the <em>public_html/</em> folder. Use the cPanel File Manager tools in order to extract the files to the same folder they were uploaded too.</p>
<p>Now for your database which is the second thing that makes your WordPress website work.  In the cPanel of your old host, click on the <em>phpMyAdmin</em> icon.  Once loaded select the database that is being used for your site from the list on the left. Now click the <em>export</em> button.  Make sure all the tables are selected as well as the <em>Save As</em> check box at the bottom and click go.  A .sql file will now be downloaded to your computer.</p>
<p>Next step is to create a new database with your new host and import the tables that you have just exported.  In the cPanel of your new hosts in the databases section, click on the <em>MySQL Databases</em> icon and then create a new database and user.  Add the user to the database and grant all privileges.  Now go in <em>phpMyAdmin</em> in the new host and select the database you have just created on the left.  Click on the import tab along the top.  Choose the .sql file that was downloaded from the old host and then upload this.  Once done you should get a message saying that a certain amount of queries were executed, thats fine.</p>
<p><a rel="prettyPhoto" href="http://equalmark.net/wp-content/uploads/2010/08/mysql-export.jpg"><img title="mysql-export" src="http://equalmark.net/wp-content/uploads/2010/08/mysql-export-500x410.jpg" alt="" width="500" height="410" /></a></p>
<p>There are now just a couple of steps left to take.  The first is that you will need to edit your <em>wp-config.php</em> file in order to reflect the new database and user details.  Use the cPanel file manager to load that file and make the changes for your new database name and user as well as the password that you set when you created the new database and user.  Don&#8217;t forget to save the file.</p>
<p>Last but not least you will need to point the domain at the new host. This can either be done my changing the name servers to the new name servers given by your host or adding A records with your domain registrar to point to the new IP address of your server.  Once you have done this is could take 48 hours for the DNS to propagate around the Internet and therefore I would leave both your old and new sites live, and don&#8217;t make any changes to them during this time.  After a couple of days you can remove your old server and everything should be fine.</p>
]]></content:encoded>
			<wfw:commentRss>http://equalmark.net/wordpress/movingwordpress/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>URL Shortening with Your Own Domain</title>
		<link>http://equalmark.net/tutorials/urlshortening/</link>
		<comments>http://equalmark.net/tutorials/urlshortening/#comments</comments>
		<pubDate>Thu, 19 Aug 2010 08:42:24 +0000</pubDate>
		<dc:creator>Mark Wilkinson</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[Domain]]></category>
		<category><![CDATA[Shortening]]></category>
		<category><![CDATA[URL]]></category>

		<guid isPermaLink="false">http://equalmark.net/?p=584</guid>
		<description><![CDATA[URL shortening services are plentiful at the moment. With micro blogging services such as Twitter restricting posting to 140 characters we need to shorten URLs can can waste those valuable characters.  I have always wanted to keep URL shortening to a domain of my choice rather than using bit.ly or tinurl etc, mainly because I [...]]]></description>
			<content:encoded><![CDATA[<p class="intro">URL shortening services are plentiful at the moment. With micro blogging services such as Twitter restricting posting to 140 characters we need to shorten URLs can can waste those valuable characters.  I have always wanted to keep URL shortening to a domain of my choice rather than using bit.ly or tinurl etc, mainly because I am curious.  Here is how I have done it.</p>
<p>A quick search on the Internet and you will find several offerings of different solutions of how to shorten URLs using your very own domain for example Google offer a <a href="http://www.google.com/enterprise/marketplace/viewListing?productListingId=5143210+6352879591152674960" target="_blank">url shortening service</a> for their domain app customers.  However some of these seemed quite complicated and I just wanted something really simple. As I was not bothered about statistics or anything I just wanted something where I could enter the domain I wanted to shorten, press go and then it would provide me with a shortened URL using the domain I wanted.</p>
<p><span id="more-584"></span></p>
<p>My first tasks was to find a domain that I could use or this shortening.  The first requirement of such as domain was that it was short (of course!).  I also wanted it to represent <a href="http://equalwebcreative.com" target="_blank">Equal Web Creative</a> and therefore I tried all sorts of three letter dot two letter domains. To my surprise the only one that I could get that was reasonably priced was <a href="http://eqw.be" target="_blank">http://eqw.be</a>. I purchased this and then added it to my hosting package.</p>
<p>The solution that I settled on was a shortening script by Shaun Inman called <a href="http://www.shauninman.com/archive/2009/08/17/less_n" target="_blank">Lessn</a>. This seemed to tick all the boxes as it was simply and worked with PHP and MySQL, tools that I am fairly familiar with.  I download the script followed the very simply instructions in the readme/txt file provided and hey presto, my very own URL shortening service using a domain of my choice.</p>
]]></content:encoded>
			<wfw:commentRss>http://equalmark.net/tutorials/urlshortening/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Bypassing WordPress Attachment Posts</title>
		<link>http://equalmark.net/wordpress/removewpattachmentposts/</link>
		<comments>http://equalmark.net/wordpress/removewpattachmentposts/#comments</comments>
		<pubDate>Wed, 18 Aug 2010 12:49:25 +0000</pubDate>
		<dc:creator>Mark Wilkinson</dc:creator>
				<category><![CDATA[WordPress]]></category>
		<category><![CDATA[Attachments]]></category>
		<category><![CDATA[Redirection]]></category>
		<category><![CDATA[Uploads]]></category>

		<guid isPermaLink="false">http://equalmark.net/?p=580</guid>
		<description><![CDATA[This problem has been bugging me for a while now and finally I have managed to find a fix that seems to work well.  The problem being that clients, when linking to something they have uploaded to a page or post never click the &#8216;File URL&#8217; for the link, instead leaving it on &#8216;Post URL&#8217; [...]]]></description>
			<content:encoded><![CDATA[<p class="intro">This problem has been bugging me for a while now and finally I have managed to find a fix that seems to work well.  The problem being that clients, when linking to something they have uploaded to a page or post never click the &#8216;File URL&#8217; for the link, instead leaving it on &#8216;Post URL&#8217; which causes problems.  Here is how I fixed it.</p>
<p>When clients forget to click the File URL button it means that when they click on a link, instead of being show the file that they think they are linking to they are shown the post that WordPress creates for that attachment.  If the attachment is an image this not a major issue as you can include a custom image.php file in your theme folder and make that page looks nice. However if the link is to a PDF for example the user is simply presented with another post with the same link in that they just clicked on.  Worse still is that if the author has not added a title tag to the attachment they will see an ugly link.</p>
<p><span id="more-580"></span></p>
<p>First I wanted to see if there was a way to make WordPress default to the File URL rather than always placing the Post URL in the attachments link option. I drew a blank on this search but then came across a handy WordPress function called wp_redirect().  What this does is redirects the user to an absolute URL.  Therefore I combined this with wp_get_attachment_url() and hey presto, everytime a link is clicked to a file that has been uploaded in WordPress, whether an image or not the user gets sent straight to the files location and not the attachment post.  The code I placed in my attachment.php page is below:</p>
<pre class="brush: php;">
&lt;?php wp_redirect(wp_get_attachment_url()); ?&gt;
</pre>
]]></content:encoded>
			<wfw:commentRss>http://equalmark.net/wordpress/removewpattachmentposts/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Protecting WordPress Content</title>
		<link>http://equalmark.net/wordpress/protectingcontent/</link>
		<comments>http://equalmark.net/wordpress/protectingcontent/#comments</comments>
		<pubDate>Mon, 16 Aug 2010 09:19:43 +0000</pubDate>
		<dc:creator>Mark Wilkinson</dc:creator>
				<category><![CDATA[WordPress]]></category>
		<category><![CDATA[Logged In]]></category>
		<category><![CDATA[Protection]]></category>

		<guid isPermaLink="false">http://equalmark.net/?p=569</guid>
		<description><![CDATA[Since WordPress has its own built in user roles it is possible to protect WordPress content for users that are logged in, rather than general visitors.  This can be very handy if you want to show certain things only to those people who are logged in.  In this post I will show you how to [...]]]></description>
			<content:encoded><![CDATA[<p class="intro">Since WordPress has its own built in user roles it is possible to protect WordPress content for users that are logged in, rather than general visitors.  This can be very handy if you want to show certain things only to those people who are logged in.  In this post I will show you how to implement this as well as showing you an example.</p>
<p>Thanks to WordPress&#8217; comprehensive <a href="http://codex.wordpress.org/Template_Tags" target="_blank">template tags</a> the function to test whether or not a user is logged in or not is already present. By combining this function with a php if statement we can check whether the user is logged in and then display something accordingly.</p>
<p><span id="more-569"></span>The code below is the code to use in order to use the <code>is_user_logged_in();</code> function:</p>
<pre class="brush: php;">
&lt;?php if(is_user_logged_in() ) { ?&gt;
  &lt;!-- place here whatever you want to show to logged in users only --&gt;
&lt;?php } else { ?&gt;
  &lt;!-- place here the content that you want available to everyone --&gt;
&lt;?php } ?&gt;
</pre>
<p>So how might you take advantage of this feature?  There are lots of ways when this can be of use in a WordPress theme.  I have used it several times and below is an example.</p>
<p>In this example the site has been used in order to protect content for teachers on a site that students are using.  WordPress pages are used as lesson outlines and part of this there is a teacher section where notes can be added about the lesson which teachers do not want students to be able to see.  Therefore this lesson information is only displayed to logged in users only.</p>
<p><a title="In this example you can see that the dotted area is only shown to logged in users.  This means that only teachers can view this information." rel="prettyPhoto" href="http://equalmark.net/wp-content/uploads/2010/08/ribbweb-loggedin.jpg"><img class="alignnone size-large wp-image-571" title="Examples of Protecting Content with WordPress" src="http://equalmark.net/wp-content/uploads/2010/08/ribbweb-loggedin-500x278.jpg" alt="" width="500" height="278" /></a></p>
<p>There are a number things you can use this for.  You could even use it reverse as it were by cleaning up your site for logged in users that don&#8217;t want to see information for posts and pages that you would show for normal users.  It will be interesting to how others are using this handy little function.</p>
]]></content:encoded>
			<wfw:commentRss>http://equalmark.net/wordpress/protectingcontent/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Using WordPress for Client Development Logs</title>
		<link>http://equalmark.net/wordpress/wordpressclientlogs/</link>
		<comments>http://equalmark.net/wordpress/wordpressclientlogs/#comments</comments>
		<pubDate>Sat, 14 Aug 2010 10:15:50 +0000</pubDate>
		<dc:creator>Mark Wilkinson</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[Clients]]></category>
		<category><![CDATA[Development Logs]]></category>
		<category><![CDATA[Multisite]]></category>
		<category><![CDATA[Projects]]></category>

		<guid isPermaLink="false">http://equalmark.net/?p=548</guid>
		<description><![CDATA[Over at Equal Web Creative I have recently introduced the use of client development logs so that clients can keep a track of the progress on their sites and so that you can communicate more effectively with clients during a project.  In order to implement this I have used WordPress as a multisite installation as [...]]]></description>
			<content:encoded><![CDATA[<p class="intro">Over at Equal Web Creative I have recently introduced the use of client development logs so that clients can keep a track of the progress on their sites and so that you can communicate more effectively with clients during a project.  In order to implement this I have used WordPress as a multisite installation as well as a few themes and plugins.  Here I intend to explain how I have produced this.</p>
<p>To start with your will need to install a copy of WordPress onto your server and then activate the multisite capabilities of WordPress.  To do this I followed the excellent tutorial below:</p>
<p><span id="more-548"></span></p>
<p><embed src="http://v.wordpress.com/EvUbutnB" type="application/x-shockwave-flash" width="500" height="312" allowscriptaccess="always" allowfullscreen="true" wmode="transparent"></embed></p>
<p>Once you have your installation completed you now have the ability to create multiple sites on one WordPress install.  The idea here is that each of your clients will have a 1 site for their client or project log.  You then create users for each of the people within the organisation that will be working on the site so that they can contribute to the discussion and keep track of the progress that is being made.</p>
<p>The next thing is that you will need a theme for the client sites.  I had a brief look around for a theme that was in the style of discussion rather than pure blogging or a website and quickly remembered about Automattic&#8217;s <a href="http://p2theme.com/" target="_blank">P2 theme</a>.  This is a discussion real time blogged theme that is more conducive to a project logs functionality.  The one major alteration to the code that I wanted to make in this theme was to make it so that pages and posts did not appear unless the user was logged in.  To do this I made use of the WordPress <code>is_user_logged_in()</code> function.  The following was added to the site in order to display the content if the user is logged in and to show a login form if the user is not logged in:</p>
<pre class="brush: php;">
&lt;?php if(is_user_logged_in() ) { ?&gt;
  // continue with theme code
&lt;?php } else { &gt;
  &lt;?php
    // get the login form file
    get_template_part( 'loginform' );
  ?&gt;
&lt;?php } ?&gt;
</pre>
<p>The next thing I wanted to do was to make the users login from a standard page that was linked to on the Equal Web Creative site, labelled client login.  Therefore a created a very simple theme on the main network site that consisted on an index.php page in the same design and style as the main Equal Web Creative site that contained a login page.  On submit this redirected the users to the main sites dashboard.  Here is how this was done:</p>
<pre class="brush: php;">
&lt;form name=&quot;loginform&quot; id=&quot;loginform&quot; action=&quot;&lt;?php echo site_url('wp-login.php', 'login_post') ?&gt;&quot; method=&quot;post&quot;&gt;
  &lt;p&gt;
    &lt;label&gt;&lt;?php _e('Username') ?&gt;
    &lt;input type=&quot;text&quot; name=&quot;log&quot; id=&quot;user_login&quot; class=&quot;input&quot; value=&quot;&lt;?php echo $user_login; ?&gt;&quot; size=&quot;15&quot; tabindex=&quot;10&quot; /&gt;&lt;/label&gt;
  &lt;/p&gt;
  &lt;p&gt;
    &lt;label&gt;&lt;?php _e('Password') ?&gt;
    &lt;input type=&quot;password&quot; name=&quot;pwd&quot; id=&quot;user_pass&quot; class=&quot;input&quot; value=&quot;&quot; size=&quot;15&quot; tabindex=&quot;20&quot; /&gt;&lt;/label&gt;
  &lt;/p&gt;
  &lt;?php do_action('login_form'); ?&gt;
  &lt;input type=&quot;submit&quot; name=&quot;wp-submit&quot; id=&quot;wp-submit&quot; value=&quot;&lt;?php _e('Log In'); ?&gt;&quot; tabindex=&quot;100&quot; /&gt;
  &lt;input type=&quot;hidden&quot; name=&quot;redirect_to&quot; value=&quot;&lt;?php bloginfo('url'); ?&gt;/wp-admin&quot; /&gt;
  &lt;input type=&quot;hidden&quot; name=&quot;testcookie&quot; value=&quot;1&quot; /&gt;
&lt;/form&gt;
</pre>
<p>It is the last part of line 12 above that takes the user to the main blogs dashboard.  The problem here was that I wanted them to go to their own project log site rather than this one.  To do this I removed them as a user of the main blog through the Super Admin panel in the WordPress dashboard.  Once this was done it meant they we redirected to the dashboard of their primary site which was their own client or project log.</p>
<p>The final step here was that I wanted them to go straight to the front end of the site and not into the dashboard.  In fact there really is no need for the clients to see the dashboard of WordPress in this setup.  I Googled and searched for this for a long time but eventually settled on this rather botched way of doing it, using a javascript window redirect.  This code is placed in the P2 themes functions.php file in order to redirect none admin users from the dashboard to the live site:</p>
<pre class="brush: php;">
&lt;?php
// widget dashboard content
	function my_wp_dashboard_test() { ?&gt;
	&lt;?php if ( current_user_can('manage_options') ) { // checks whether the user is an admin ?&gt;
		&lt;p&gt;Welcome to this Equal Web Creative Project Log site.  As you are seeing this it means you are a site admin!&lt;/p&gt;
	&lt;?php } else { ?&gt;
		&lt;?php // if the currnet user is not an admin of the site then they are redirected to their primary sites homepage
			$user = wp_get_current_user();
			$details = get_active_blog_for_user( $user-&gt;ID );
			$addr = $details-&gt;siteurl;
        ?&gt;
        &lt;script type=&quot;text/javascript&quot;&gt;
        &lt;!--
        window.location = &quot;&lt;?php echo $addr; ?&gt;&quot;
        //--&gt;
        &lt;/script&gt;
    &lt;?php } ?&gt;
&lt;?php } ?&gt;
&lt;?php
// add Dashboard Widget via function wp_add_dashboard_widget()
	function my_wp_dashboard_setup() {
		wp_add_dashboard_widget( 'my_wp_dashboard_test', __( 'Site Information' ), 'my_wp_dashboard_test' );
	}
// use hook, to integrate new widget
	add_action('wp_dashboard_setup', 'my_wp_dashboard_setup');
?&gt;
</pre>
<p>Basically this code adds a new dashboard widget to the sites dashboard. In that widget it first checks to see if the user is an admin of the site.  If they are it simply outputs a paragraph telling them so.  If they are not an admin it gets their primary sites ID and then redirects them to that site using the javascript window.location function.</p>
<p>And there you have it.  No doubt there are several things within this that could be done better a neater and if you have any feedback on this then please let me know below.  I hope you find it useful.</p>
]]></content:encoded>
			<wfw:commentRss>http://equalmark.net/wordpress/wordpressclientlogs/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Welcome to equalmark.net</title>
		<link>http://equalmark.net/general/welcome/</link>
		<comments>http://equalmark.net/general/welcome/#comments</comments>
		<pubDate>Fri, 13 Aug 2010 16:04:36 +0000</pubDate>
		<dc:creator>Mark Wilkinson</dc:creator>
				<category><![CDATA[General]]></category>

		<guid isPermaLink="false">http://equalmark.net/?p=516</guid>
		<description><![CDATA[I would like to welcome you all to the long overdue new blog of Mark Wilkinson &#8211; equalmark.net.  It has been a while since I have done some serious blogging but I really want to get back into it over the coming months, to post some of the many things that I have been doing [...]]]></description>
			<content:encoded><![CDATA[<p class="intro">I would like to welcome you all to the long overdue new blog of Mark Wilkinson &#8211; equalmark.net.  It has been a while since I have done some serious blogging but I really want to get back into it over the coming months, to post some of the many things that I have been doing over the last few months in particular.</p>
<p>For a long time I blogged over at <a href="http://penny4them.com" target="_blank">penny4them.com</a>.  On that blog (designed by me) you will find all sorts of posts about anything and everything.  So why move the blog over to this new site and start a fresh you might be saying?  Well that is an excellent question so let me try and answer.</p>
<p><span id="more-516"></span></p>
<p>For a while now I have been looking for an online brand name.  Having a name like Mark Wilkinson, which is very very common means that I have no chance in obtaining my own domain name and even getting my own username for online facilities and services such as twitter and gmail is impossible.  Therefore I wanted to come up with something that would be good as well as being unique.</p>
<p>So why Equal Mark then?  Well I got the Equal part from my original freelance work that I did for Equal Design.  It seemed to sound good and all of the domains (except .com which I will come onto in a minute) where available.  I was also able to get almost all usernames for many online services with this name and so I went for that.  You will find me as &#8216;equalmark&#8217; as most things in and around the web.  I said every domain except the .com domain which has been bought by a company who are trying to sell it on.  They want a whopping $1600 for domain.  I offered them $300 about 9 months ago but they declined and it is still for sale today.  I reckon they would have been better off with my $300 in their account, but its not up to me, hence the reason why this blog is at .net and not .com.</p>
<h3>The Design</h3>
<p>I have pondered for ages over what design to use for this blog and finally settled on this one.  I think my main problem was that I just not had time to work on my own sites.  I have been so busy building <a href="http://equalwebcreative.com" target="_blank">WordPress websites</a> for others that I have not had any time to sit down on my own site.  So I came to the conclusion that I was going to use a theme already on the market and then do some minor changes to make it mine.</p>
<p>Last night I came across a new site from <a href="http://www.webdesignerwall.com/" target="_blank">Nick La</a> and a colleague that had been newly launched called <a href="http://themify.me" target="_blank">themify.me</a>. Knowing the designs that Nick has produced as well as some other WordPress themes I thought these were going to be something special.  I spotted the Sidepane theme and thought that it was just what I was after.  I purchased the theme and then got to work on some customization applying my own skin using their new framework which was easy enough. About 40 minutes I arrived at the look you are looking at now.</p>
<p>I am a little disappointed that I have not had the time to create this sites theme myself but I am pleased with the results and the sites does exactly as I want.</p>
<h3>The Content</h3>
<p>So what sort of content are we going to be posting on here?  Well I think the answers is really I am not sure, but I can say what I think will end up on here. I would like to post about the solutions that I have produced using WordPress on many of the client sites that I have created with <a href="http://equalwebcreative.com" target="_blank">equalwebcreative.com</a>.  I can also see me posting photos here and things to do with family life, so I suppose it is a classic personal blog with a mix of all sorts but with some distinct topics running throughout.</p>
<p>No doubt it will evolve over the next few weeks and shortly I shall be pulling some posts over from Equal Web Creatives blog as they have more relevance here I think.</p>
]]></content:encoded>
			<wfw:commentRss>http://equalmark.net/general/welcome/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Pre Load Hover Images with CSS</title>
		<link>http://equalmark.net/tutorials/preloadhoverimages/</link>
		<comments>http://equalmark.net/tutorials/preloadhoverimages/#comments</comments>
		<pubDate>Sun, 08 Aug 2010 15:06:22 +0000</pubDate>
		<dc:creator>Mark Wilkinson</dc:creator>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[HTML]]></category>
		<category><![CDATA[Images]]></category>

		<guid isPermaLink="false">http://equalwebcreative.com/?p=468</guid>
		<description><![CDATA[When using the CSS hover selector and using background images, these however background images do not load when the page loads, only when they are called on hover  and as a result give a delay before the image is displayed.  In this post I will explain how I get around this problem using some simple [...]]]></description>
			<content:encoded><![CDATA[<div>
<p class="intro">When using the CSS hover selector and using background images, these however background images do not load when the page loads, only when they are called on hover  and as a result give a delay before the image is displayed.  In this post I will explain how I get around this problem using some simple ideas with HTML and CSS.</p>
<p>Hover selectors are always a good idea to use as they give the user an indication of which link they are currently over and about to click.  In some more complex designs, perhaps where there are images of buttons in the navigation rather than just text, you will need to assign these as background images.  It is often the case that the background image needs to change when the user hover over the button and therefore you assign a different image to the :hover part of your CSS.</p>
<p><span id="more-535"></span></p>
<p>The problem arises when the user first rolls over the button as the hover image is only loaded with the browser when the user rolls over the image.  Therefore the user sees a rather ugly delay.  You can use javascript on order to get around this problem and pre-load the images, however I like to keep it simple and simply add the hover images in normal &lt;img&gt; tags right before the close of the web pages &lt;body&gt; tag.  When doing give them a class and name the class hidden.</p>
<p>Now create a CSS rule for the hidden class and simply give this display: none.  What this does is it means that these images are loaded when the page is loaded but you cannot see them because they have been hidden with CSS.  It also means of course that because they are already loaded, when a user hovers over the button which has the image as a hover image the images will load straight away.</p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://equalmark.net/tutorials/preloadhoverimages/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
	</channel>
</rss>
