<?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>Tomos Wyn</title>
	<atom:link href="http://tomoswyn.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://tomoswyn.com</link>
	<description>Serial ramblings of a freelancer and newbie marketer</description>
	<lastBuildDate>Tue, 18 Jun 2013 15:31:23 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.6</generator>
		<item>
		<title>Creating individual page sliders with Genesis</title>
		<link>http://tomoswyn.com/genesis/creating-individual-page-sliders-with-genesis/</link>
		<comments>http://tomoswyn.com/genesis/creating-individual-page-sliders-with-genesis/#respond</comments>
		<pubDate>Fri, 18 Nov 2011 13:47:08 +0000</pubDate>
		<dc:creator>tomoswyn</dc:creator>
				<category><![CDATA[Genesis]]></category>

		<guid isPermaLink="false">http://tomoswyn.com/?p=212</guid>
		<description><![CDATA[I&#8217;ve recently started to work with the Genesis Framework for WordPress. I still love Thesis, but I thought why not start working with Genesis too. It was a good idea, and I&#8217;ve already landed a project or two developing with Genesis, and the last project I&#8217;ve worked on required something I hadn&#8217;t done before. The [&#8230;]]]></description>
				<content:encoded><![CDATA[<p>I&#8217;ve recently started to work with the <a href="http://tomoswyn.com/go/genesis/">Genesis Framework</a> for WordPress. I still love <a href="http://tomoswyn.com/go/thesis-theme/">Thesis</a>, but I thought why not start working with Genesis too. It was a good idea, and I&#8217;ve already landed a project or two developing with Genesis, and the last project I&#8217;ve worked on required something I hadn&#8217;t done before.</p>
<p>The client wanted the option to have the option of having a unique <a href="https://github.com/mathiasbynens/Simplest-jQuery-Slideshow">jQuery slider</a> on each page of the website. Whilst I&#8217;m sure that there are slider plugins that can do this pretty easily, I thought why not try something different. So that&#8217;s what I did. I used <a href="http://www.farinspace.com/wpalchemy-metabox/">WPAlchemy</a> to handle the metabox in the backend, and I&#8217;m pretty happy with how it turned out. Watch the video below as I walk you through how I created it.</p>
<p><span id="more-212"></span></p>
<div class="video-embed">
<iframe width="540" height="396" src="http://www.youtube.com/embed/UB3kk0FpmHc" frameborder="0" allowfullscreen></iframe>
</div>
<p>I&#8217;ve also included the code below for you:</p>
<div class="notice">
<p><strong>This code is tested using Genesis v1.7.1</strong>.</p>
<p>If people are interested, I can update the code to work with Thesis.</p>
</div>
<p><strong>functions.php</strong></p>
<pre class="brush: php; title: ; notranslate">
/*
 * Include WPAlchemy Scripts
 */
include_once 'metaboxes/setup.php';
include_once 'metaboxes/simple-spec.php';


/*
 * Enqueue Scripts
 */
add_action('get_header', 'my_load_scripts');
function my_load_scripts() {
    wp_enqueue_script('jquery.slideshow', CHILD_URL.'/lib/js/jquery.slideshow.js', array('jquery'), '1', TRUE);
}


/*
 * Start the slider
 */
add_action( 'wp_head', 'homepage_slider' );
function homepage_slider() { ?&gt;
	    
	&lt;?php if(is_page()) {		
		
		global $custom_metabox;
		$custom_metabox-&gt;the_meta();
	
		if ($custom_metabox-&gt;get_the_value('show-slider') == 'yes') { 
	
	?&gt; 
		
		&lt;script type=&quot;text/javascript&quot;&gt;
		jQuery(document).ready(function($) { 
		$('.slideshow').slideshow({ timeout: 4000, speed: 400 }); 
		})
		&lt;/script&gt; 
	
	&lt;?php 
		
	    } //close IF() statement
	
	} //close IS_PAGE() statement 
		
}//close function


/*
 * Show the slider
 */
add_action( 'genesis_before_post_content', 'inner_page_slider' );
function inner_page_slider() {?&gt;

	&lt;?php if(is_page()) {
	
		global $custom_metabox;
		$custom_metabox-&gt;the_meta();
				
		if ($custom_metabox-&gt;get_the_value('show-slider') == 'yes') { ?&gt;
		
			&lt;div class=&quot;slider&quot;&gt;
				&lt;ul class=&quot;slideshow&quot;&gt;
					&lt;li&gt;&lt;img src=&quot;&lt;?php $custom_metabox-&gt;the_value('image-1'); ?&gt;&quot; /&gt;&lt;/li&gt;
					&lt;li&gt;&lt;img src=&quot;&lt;?php $custom_metabox-&gt;the_value('image-2'); ?&gt;&quot; /&gt;&lt;/li&gt;
					&lt;li&gt;&lt;img src=&quot;&lt;?php $custom_metabox-&gt;the_value('image-3'); ?&gt;&quot; /&gt;&lt;/li&gt;
					&lt;li&gt;&lt;img src=&quot;&lt;?php $custom_metabox-&gt;the_value('image-4'); ?&gt;&quot; /&gt;&lt;/li&gt;
				&lt;/ul&gt;
			&lt;/div&gt;
		
		&lt;?php 
		}			
	}		
}
</pre>
<p><strong>/metaboxes/simple-meta.php</strong></p>
<pre class="brush: php; title: ; notranslate">
&lt;div class=&quot;my_meta_control custom-bf-slider&quot;&gt;
 
	&lt;p class=&quot;intro&quot;&gt;If you want to show off some work, use a slider. Upload the images you want &lt;strong&gt;[500px wide / 200px high]&lt;/strong&gt; using the WordPress Media Manager, and paste the link to the images in the fields below.&lt;/p&gt;

	
	&lt;?php $selected = ' selected=&quot;selected&quot;'; ?&gt;
 
	&lt;p&gt;
		&lt;span&gt;Show the Slider?&lt;/span&gt;
		&lt;?php $mb-&gt;the_field('show-slider'); ?&gt;
		&lt;select name=&quot;&lt;?php $mb-&gt;the_name(); ?&gt;&quot;&gt;
		&lt;option value=&quot;&quot;&gt;&lt;/option&gt;
		&lt;option value=&quot;yes&quot;&lt;?php if ($mb-&gt;get_the_value() == 'yes') echo $selected; ?&gt;&gt;Yes&lt;/option&gt;
		&lt;option value=&quot;no&quot;&lt;?php if ($mb-&gt;get_the_value() == 'no') echo $selected; ?&gt;&gt;No&lt;/option&gt;
		&lt;/select&gt;
	&lt;/p&gt;
 
	&lt;p&gt;
		&lt;span&gt;Image 1 URL:&lt;/span&gt;
		&lt;?php $mb-&gt;the_field('image-1'); ?&gt;
		&lt;input type=&quot;text&quot; name=&quot;&lt;?php $mb-&gt;the_name(); ?&gt;&quot; value=&quot;&lt;?php $mb-&gt;the_value(); ?&gt;&quot;/&gt;
	&lt;/p&gt;
 
	&lt;p&gt;
		&lt;span&gt;Image 2 URL:&lt;/span&gt;
		&lt;?php $mb-&gt;the_field('image-2'); ?&gt;
		&lt;input type=&quot;text&quot; name=&quot;&lt;?php $mb-&gt;the_name(); ?&gt;&quot; value=&quot;&lt;?php $mb-&gt;the_value(); ?&gt;&quot;/&gt;
	&lt;/p&gt;
	
	&lt;p&gt;
		&lt;span&gt;Image 3 URL:&lt;/span&gt;
		&lt;?php $mb-&gt;the_field('image-3'); ?&gt;
		&lt;input type=&quot;text&quot; name=&quot;&lt;?php $mb-&gt;the_name(); ?&gt;&quot; value=&quot;&lt;?php $mb-&gt;the_value(); ?&gt;&quot;/&gt;
	&lt;/p&gt;
	
	&lt;p&gt;
		&lt;span&gt;Image 4 URL:&lt;/span&gt;
		&lt;?php $mb-&gt;the_field('image-4'); ?&gt;
		&lt;input type=&quot;text&quot; name=&quot;&lt;?php $mb-&gt;the_name(); ?&gt;&quot; value=&quot;&lt;?php $mb-&gt;the_value(); ?&gt;&quot;/&gt;
	&lt;/p&gt; 

&lt;/div&gt;
</pre>
]]></content:encoded>
			<wfw:commentRss>http://tomoswyn.com/genesis/creating-individual-page-sliders-with-genesis/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Using Thesis and WPAlchemy</title>
		<link>http://tomoswyn.com/thesis/using-thesis-and-wpalchemy/</link>
		<comments>http://tomoswyn.com/thesis/using-thesis-and-wpalchemy/#comments</comments>
		<pubDate>Tue, 15 Nov 2011 11:15:46 +0000</pubDate>
		<dc:creator>tomoswyn</dc:creator>
				<category><![CDATA[Thesis]]></category>

		<guid isPermaLink="false">http://tomoswyn.com/?p=194</guid>
		<description><![CDATA[I&#8217;m currently working on a Thesis project where I need to work with custom metaboxes. WPAlchemy jumped out as a pretty good solution, so I went ahead and downloaded/install it as instructed &#8211; but it didn&#8217;t work. Well when I say it didn&#8217;t work, what I mean is that the fields and styles for the [&#8230;]]]></description>
				<content:encoded><![CDATA[<p>I&#8217;m currently working on a <a href="http://tomoswyn.com/go/thesis/">Thesis</a> project where I need to work with custom metaboxes. <a href="http://www.farinspace.com/wpalchemy-metabox/">WPAlchemy</a> jumped out as a pretty good solution, so I went ahead and downloaded/install it as instructed &#8211; but it didn&#8217;t work. Well when I say it didn&#8217;t work, what I mean is that the fields and styles for the fields within the metabox wouldn&#8217;t show up. I found a fix for it. Here it is.</p>
<p><span id="more-194"></span></p>
<p>By default, this is what WPAlchemy&#8217;s <code>/metaboxes/setup.php</code> looks like:</p>
<pre class="brush: php; title: ; notranslate">
&lt;?php

include_once WP_CONTENT_DIR . '/wpalchemy/MetaBox.php';
 
// global styles for the meta boxes
if (is_admin()) wp_enqueue_style('wpalchemy-metabox', get_stylesheet_directory_uri() . '/metaboxes/meta.css');

/* eof */
</pre>
<p>Now the issue here is that <code>get_stylesheet_directory_uri()</code> returns:</p>
<p><code>http://yourdomain.com/wp-content/themes/yourtheme</code> (<a href="http://codex.wordpress.org/Function_Reference/get_stylesheet_directory_uri">Function Reference/get stylesheet directory uri</a>). </p>
<p>As we know, when working with Thesis, all your custom Thesis files reside in the <code>/custom/</code> directory, and therein lies the problem. Changing the code to the following worked for me:</p>
<pre class="brush: php; title: ; notranslate">
&lt;?php

include_once WP_CONTENT_DIR . '/wpalchemy/MetaBox.php';
 
// global styles for the meta boxes
if (is_admin()) wp_enqueue_style('wpalchemy-metabox', get_stylesheet_directory_uri() . '/custom/metaboxes/meta.css');

/* eof */
</pre>
<p>Notice the inclusion of the custom directory in the code. It now loads the stylesheet to format the metaboxes elements. Win.</p>
<p>But there&#8217;s one more issue &#8211; the same code is used to call the content of your metabox. The same principle needs to be applied here, but with a slightly different change. If you open up <code>metaboxes/simple-spec.php</code>, then you&#8217;ll see this as the default code:</p>
<pre class="brush: php; title: ; notranslate">
&lt;?php

$custom_metabox = $simple_mb = new WPAlchemy_MetaBox(array
(
	'id' =&gt; '_custom_meta',
	'title' =&gt; 'My Custom Meta',
	'template' =&gt; get_stylesheet_directory() . '/metaboxes/simple-meta.php',
));

/* eof */
</pre>
<p>Notice that <code>/custom/</code> is missing. The function <code>get_stylesheet_directory()</code> returns something like so:</p>
<p><code>/var/www/html/myblog/wp-content/themes/my_theme</code> (<a href="http://codex.wordpress.org/Function_Reference/get_stylesheet_directory">Function Reference/get stylesheet directory</a>)</p>
<p>So simply amending the function like so to include the <code>/custom/</code> directory like so makes it work:</p>
<pre class="brush: php; title: ; notranslate">
&lt;?php

$custom_metabox = $simple_mb = new WPAlchemy_MetaBox(array
(
	'id' =&gt; '_custom_meta',
	'title' =&gt; 'My Custom Meta',
	'template' =&gt; get_stylesheet_directory() . '/custom/metaboxes/simple-meta.php',
));

/* eof */
</pre>
<p>And there you have it, WPAlchemy should now be working with Thesis for you. </p>
<p>On a final note, I&#8217;m only using the <code>simple-spec.php</code> file here. If your using any of the other metaboxes files, i.e. one of these:</p>
<pre class="brush: php; title: ; notranslate">

include_once 'metaboxes/full-spec.php';

include_once 'metaboxes/checkbox-spec.php';

include_once 'metaboxes/radio-spec.php';

include_once 'metaboxes/select-spec.php';

</pre>
<p>then your going to need to repeat the process of appending the custom directory to the array as shown above.</p>
<div class="notice">
<p>Yes, I know you could just put the <code>/metaboxes/</code> folder in your thesis folder, but I prefer to put any files that I work with in the <code>/custom</code> directory as that&#8217;s where you normally place any custom code &amp; files.</p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://tomoswyn.com/thesis/using-thesis-and-wpalchemy/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Using Thesis body classes to target browsers</title>
		<link>http://tomoswyn.com/thesis/using-thesis-body-classes-to-target-browsers/</link>
		<comments>http://tomoswyn.com/thesis/using-thesis-body-classes-to-target-browsers/#comments</comments>
		<pubDate>Fri, 21 Oct 2011 20:29:56 +0000</pubDate>
		<dc:creator>tomoswyn</dc:creator>
				<category><![CDATA[Thesis]]></category>

		<guid isPermaLink="false">http://tomoswyn.com/?p=171</guid>
		<description><![CDATA[There have been situations where I&#8217;ve been coding something in Thesis, and there are cross-browser issues. Don&#8217;t get me wrong &#8211; 99% of the time this doesn&#8217;t happen, but on the rare occasions they do crop up, I&#8217;ve come up with a solution. Now, you could go down the classic route, and add conditional stylesheets [&#8230;]]]></description>
				<content:encoded><![CDATA[<p>There have been situations where I&#8217;ve been coding something in Thesis, and there are cross-browser issues. Don&#8217;t get me wrong &#8211; 99% of the time this doesn&#8217;t happen, but on the rare occasions they do crop up, I&#8217;ve come up with a solution.</p>
<p><span id="more-171"></span></p>
<p>Now, you could go down the classic route, and add conditional stylesheets to the header like so:</p>
<pre class="brush: php; title: ; notranslate">
/*
 * function custom_conditional_statements()
 *
 * @desc: Conditional IE Statements
 *
 */
function custom_conditional_statements() {
?&gt;

  &lt;!-- IE6 Only --&gt;
  &lt;!--[if lt IE 7]&gt;
          ... IE6 Styles ---
  &lt;![endif]--&gt;

&lt;?php
}
add_action( 'wp_head', 'custom_conditional_statements');
</pre>
<p>And this is great, but there have been rare situations where there have been small issues in other browsers, like opera and firefox. For this I turned to body classes. I first came across this <a href="http://www.artofblog.com/thesis-body-classes/">article on artofblog</a> showing you how to add custom classes to the body tag. I used this article as a basis. I also looked through countless stackoverflow threads for tips on getting the user agent. Now I did come across some other websites with a similar solution to mine &#8211; and my code is based upon that written by <a href="http://thesis-blogs.com/how-to-use-conditional-ie-only-stylesheets-in-thesis/">Thesis Blogs</a>. Their solution deals with the Internet Explorer family, and I extended it to grab other user agents.</p>
<pre class="brush: php; title: ; notranslate">
/*
 * function custom_body_classes()
 *
 * @desc: Add custom classes to the &lt;body&gt; tag
 *
 */
function custom_body_classes($classes) {

  $browser = $_SERVER['HTTP_USER_AGENT'];

  if (preg_match('/mozilla.*rv:([0-9a-z\+\-\.]+).*gecko.*/si', $browser)) {
  	$classes[] = 'firefox';
  }
  elseif (preg_match('/mozilla.*opera ([0-9a-z\+\-\.]+).*/si', $browser) || preg_match('/^opera\/([0-9a-z\+\-\.]+).*/si', $browser)) {
  	$classes[] = 'opera';
  }
  elseif (preg_match(&quot;/MSIE/&quot;, $browser)) {
  $classes[] .= 'ie';
    if (preg_match(&quot;/MSIE 6.0/&quot;, $browser))
	  $classes[] .= 'ie6';
    elseif (preg_match(&quot;/MSIE 7.0/&quot;, $browser))
	  $classes[] .= 'ie7';
    elseif (preg_match(&quot;/MSIE 8.0/&quot;, $browser))
	  $classes[] .= 'ie8';
    elseif (preg_match(&quot;/MSIE 9.0/&quot;, $browser))
	  $classes[] .= 'ie9';
  }
  return $classes;
}
add_filter('thesis_body_classes', 'custom_body_classes');
</pre>
<p>Now this method isn&#8217;t 100% foolproof as you can spoof your user agent. But for most situations, it should suffice. You&#8217;d target the browser like so in your custom.css file:</p>
<pre class="brush: css; title: ; notranslate">
/* IE6 Specific Menu Styles */
.ie6 .menu {
  background: #fafafa;
  color: #444;
  }
</pre>
<p>I&#8217;d be interested in hearing how you target other browsers in &#8211; please leave a comment below sharing your method.</p>
]]></content:encoded>
			<wfw:commentRss>http://tomoswyn.com/thesis/using-thesis-body-classes-to-target-browsers/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>WordPress 404 error and Mod_Security</title>
		<link>http://tomoswyn.com/wordpress/wordpress-404-error-and-mod_security/</link>
		<comments>http://tomoswyn.com/wordpress/wordpress-404-error-and-mod_security/#comments</comments>
		<pubDate>Fri, 21 Oct 2011 13:48:01 +0000</pubDate>
		<dc:creator>tomoswyn</dc:creator>
				<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://tomoswyn.com/?p=167</guid>
		<description><![CDATA[I&#8217;ve recently been having a pretty annoying problem with WordPress. I&#8217;d write a post. Sometimes it would publish, and other times I&#8217;d be shown the WordPress 404 error page. Strange? I thought so too. At first I thought it was something to do with with my code &#8211; and as I use the Thesis theme, [&#8230;]]]></description>
				<content:encoded><![CDATA[<p>I&#8217;ve recently been having a pretty annoying problem with WordPress.</p>
<p>I&#8217;d write a post. Sometimes it would publish, and other times I&#8217;d be shown the WordPress 404 error page. Strange? I thought so too. At first I thought it was something to do with with my code &#8211; and as I use the Thesis theme, I checked the custom_functions.php file. Nope, nothing wrong there.</p>
<p>I disabled my plugins, one by one, and nothing changed either. I installed the WP-Optimize plugin thinking there were too many post revisions and autosaves &#8211; it didn&#8217;t change anything. I&#8217;d still be randomly thrown the 404 error page when posting, saving, or previewing post/page.</p>
<p>Google to the rescue. It threw up several links to the WordPress support forums (<a href="http://wordpress.org/support/topic/404-error-after-edit-gt-update-post">here</a> and <a href="http://wordpress.org/support/topic/update-post-and-update-page-shows-404-error-page">here</a>). It suggested some kind of issue with mod_security. More searching led me to this post by <a href="http://blog.mattrudge.net/2010/06/30/wordpress_404_error/">Matt Rudge</a>, detailing what was happening and how to fix it. I&#8217;d highly recommend you submit a support ticket with your webhost to see if they can fix the issue if it arises. Also, I&#8217;d recommend you check Matt&#8217;s the article out if WordPress gives you a 404 error when your trying to post or publish something.</p>
]]></content:encoded>
			<wfw:commentRss>http://tomoswyn.com/wordpress/wordpress-404-error-and-mod_security/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Please comment your code</title>
		<link>http://tomoswyn.com/thesis/please-comment-your-code/</link>
		<comments>http://tomoswyn.com/thesis/please-comment-your-code/#comments</comments>
		<pubDate>Fri, 21 Oct 2011 13:34:23 +0000</pubDate>
		<dc:creator>tomoswyn</dc:creator>
				<category><![CDATA[Thesis]]></category>

		<guid isPermaLink="false">http://tomoswyn.com/?p=108</guid>
		<description><![CDATA[I&#8217;m begging you &#8211; for the love of god please include some kind of comments or documentation with your code, may it be a user manual detailing how your code works or code comments. It would make my life and that of countless other developers much much easier. Phew. Now the shameless begging is over, [&#8230;]]]></description>
				<content:encoded><![CDATA[<p>I&#8217;m begging you &#8211; for the love of god please include some kind of comments or documentation with your code, may it be a user manual detailing how your code works or code comments. It would make my life and that of countless other developers much much easier.</p>
<p>Phew. Now the shameless begging is over, let me share with you why I&#8217;m writing about this topic.</p>
<p>First and foremost I&#8217;m a <a title="Thesis Developer" href="http://viavee.com">Thesis Developer</a> &#8211; if your unaware what this means, I make awesome things with the <a title="Thesis theme by DIYThemes" href="http://tomoswyn.com/go/thesis-theme/">Thesis WordPress theme</a>. What I like about Thesis is that the files I need to work with (custom.css and custom_functions.php) are a blank canvas &#8211; it lets me do whatever I want, however I want.</p>
<p>I&#8217;ve been commenting code pretty much since I started on the web (anybody remember WordPress 1.6?), but I really started taking notice of commenting when I started University. As you may or may not know, I studied for a BSc in Business Information Technology, and a whole heap of the course revolved around programming. We were pretty lucky to have some really good lecturers who kept on drumming in the importance of documenting and commenting your code.</p>
<p><span id="more-108"></span></p>
<p>I document and comment my code for various reasons.</p>
<ol>
<li>What happens if I want to make changes to my code some time down the line. No way is it still going to be fresh in my mind what each line does. Comments &amp; documentation solves this problem.</li>
<li>What happens when I hand over the files and the client finds a new developer down the line. Their going to be confused and probably won&#8217;t be happy having to dig through somebody else&#8217;s code. Comments &amp; documentation solves this, as they have something to reference when they are working with my files.</li>
</ol>
<p>Now this blog post comes about after some recent <a title="Thesis Developer" href="http://viavee.com">Thesis</a> projects I&#8217;ve worked on for clients. The client themselves are awesome, but the code not so much. In one project, we&#8217;re talking about 780+ lines of CSS and 450+ lines of PHP &#8211; unformatted and with a handful of comments thrown in for good measure. It doesn&#8217;t sound so bad, but when you start looking into the code, you soon start thinking what have I got myself into? Im pretty sure that in some situations I&#8217;ve actually spent more time trying to figure out what the code did than I spent coding.</p>
<h2>How I deal with code I don&#8217;t know</h2>
<p>But there are ways I&#8217;ve found to help with this. I use Chrome&#8217;s inspector tool and CSSEdit when I&#8217;m developing, and it allows me to get right into the code and see what is what.</p>
<p><img class="aligncenter size-full wp-image-129" title="chrome-cssedit" src="http://tomoswyn.com/wp-content/uploads/2011/10/chrome-cssedit.jpg" alt="" width="554" height="238" /></p>
<p>In Chrome&#8217;s case, the inspector tools let me click on the HTML I want, and it will show on the right hand side the corresponding styles it finds in the stylesheets associated with your website. The beauty here is that you can play around with the CSS in a non-destructive manner, meaning you can make changes in the inspector tool and see them applied in real-time on the website. Extremely handy.</p>
<p>CSSEdit is a tool I use in much the same way as Chrome&#8217;s developer tool. It lets me load up a website, and extract any stylesheet I want, and modify it. Any changes are instantly reflected in CSSEdit, making life much much easier. The main difference between these two tools is that CSSEdit shows the website itself, allowing you to click on elements, and it then shows you where in the CSS files the corresponding code is as opposed to clicking on the HTML in Chrome&#8217;s inspector tool. This makes it a good tool for those new to CSS or those who prefer a more visual approach.</p>
<h2>How I document my code</h2>
<p>I feel that it would be stupid to rant and talk about why I want more people to take note of how they comment and document their code without actually showing or sharing how I do it. Now I&#8217;m not saying that my way is right &#8211; far from it to tell the truth. This is how I do it, and it works for me. Heck, if clients who don&#8217;t normally code can understand and know where to make basic changes I must be doing something right.</p>
<p>An example of how I&#8217;d comment my CSS code would be:</p>
<pre class="brush: css; title: ; notranslate">
/**************************************************
 *
 * This would be a section comment
 *
 **************************************************/

/*
 * I might also comment a section like so
 * ----------------------------------------------*/

/* I'll use something like this for a small, sub-comment */
</pre>
<p>And a PHP example:</p>
<pre class="brush: php; title: ; notranslate">
/*
 * @name: function_name_here();
 *
 * @desc: function description would go here
 *
 */

// I might use an inline comment every now and again
</pre>
<p>As you can see, it&#8217;s nothing fancy but it does the job.</p>
<p>In the case of CSS, I&#8217;ll normally use a large comment to define each major website element (i.e. header, navigation, content, sidebar, footer) and use smaller comments then to clarify things even further.</p>
<p>I take the same approach when it comes to PHP. I separate each function with a comment, giving the developer the function name, a description of what it does, and if I need to include anything else, like variables, I&#8217;ll add it in the comments there as well. I&#8217;ll also throw in some comments throughout the code to highlight what&#8217;s going on.</p>
<h2>Too much of a good thing can be bad</h2>
<p>Although it might seem contradictory, too much commenting can be a bad thing. I have seen some people comment every other line in their code, and it hampered trying to read through the code. It&#8217;s up to you to find the right balance of comments vs code, and when you find it, stick with it.</p>
<p>Please let me know in the comments below what you think about working with un-commented code and how you go about this process yourself.</p>
]]></content:encoded>
			<wfw:commentRss>http://tomoswyn.com/thesis/please-comment-your-code/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
		<item>
		<title>Optimum Nutrition 100% Whey Gold Standard Review</title>
		<link>http://tomoswyn.com/reviews/optimum-nutrition-100-whey-gold-standard-review/</link>
		<comments>http://tomoswyn.com/reviews/optimum-nutrition-100-whey-gold-standard-review/#comments</comments>
		<pubDate>Wed, 17 Aug 2011 18:26:48 +0000</pubDate>
		<dc:creator>tomoswyn</dc:creator>
				<category><![CDATA[Reviews]]></category>

		<guid isPermaLink="false">http://tomoswyn.com/?p=52</guid>
		<description><![CDATA[Optimum Nutrition 100% Whey Gold Standard is one of many products created by Optimum Nutrition, and I&#8217;ve been meaning to write a review of Optimum Nutrition&#8217;s 100% Whey for some time now, and since I&#8217;m on my fourth tub now might be a good time to write it. This review will be looking at 100% [&#8230;]]]></description>
				<content:encoded><![CDATA[<p><strong>Optimum Nutrition 100% Whey Gold Standard</strong> is one of many products created by Optimum Nutrition, and I&#8217;ve been meaning to write a review of <strong>Optimum Nutrition&#8217;s 100% Whey</strong> for some time now, and since I&#8217;m on my fourth tub now might be a good time to write it. This review will be looking at 100% Whey &#8211; French Vanilla Creme flavour, as it&#8217;s the one I&#8217;m currently using.</p>
<p>No matter what a company produces, it&#8217;s important that the company has a good image within its retrospective industry. In this case, Optimum Nutrition have won a range of supplement awards and sponsor several winning teams and athletes, including such teams as Heineken Cup champions Leinster and WBFF winner Rob Riches.</p>
<p><span id="more-52"></span></p>
<h3 id="taste">Taste</h3>
<p>Since I started using 100% Whey from Optimum Nutrition, I&#8217;ve gone through 4 different flavours:</p>
<ul>
<li>Strawberry</li>
<li>Double Chocolate</li>
<li>Rocky Road</li>
<li>French Vanilla Creme</li>
</ul>
<p>My personal favourite so far is the last one &#8211; french vanilla creme, and I&#8217;m currently on my second tub of it. Taste-wise, it&#8217;s something I actually look forward to taking after working out. When mixed with water it has a vanilla ice cream flavour, reminding me of Carte D&#8217;or vanilla ice cream. </p>
<p><strong>Score:</strong> 9.5/10</p>
<h3 id="mixability">Mixability</h3>
<p>Mixability is pretty important to me no matter what supplement I take. I mix my protein straight up with water &#8211; I put a scoop in a shaker and shake for around 20 seconds and it doesn&#8217;t clump at all. There&#8217;s nothing worse than drinking your shake and having lumps of protein powder in your mouth. Even the texture is nice, it&#8217;s not too thin yet not too thick. </p>
<p><strong>Score:</strong> 9.5/10</p>
<h3 id="cost">Cost</h3>
<p>Now on to what some might consider the most important factor. On Optimum Nutrition&#8217;s UK website, a 908g tub will set you back £19.79 (currently on sale at the time of writing), and will give you 29 servings per tub if you stick to the 1 scoop serving. Therefore it works out at about 68p per serving &#8211; not too bad in my opinion. </p>
<p>Sure there are cheaper powders available, but at the end of the day, you get what you pay for. Optimum Nutrition has won several awards during the past few years, including several over at bodybuilding.com (2010: Best Protein Powder &amp; Best Supplement honours).</p>
<p><strong>Score:</strong> 9/10</p>
<p>Overall I&#8217;d give this product a <strong>solid 9.5/10</strong>. The reason it&#8217;s not a full 10 is because I haven&#8217;t tried all the products on the market &#8211; but I&#8217;m sure that none will come close.</p>
<div class="products">
<div class="on-left">
<a href="http://www.onacademy.co.uk/catalogue/products/gold-standard-100-whey"><br />
<img src="http://tomoswyn.com/wp-content/uploads/2011/08/on-on.jpg" title="Buy at Optimum Nutrition" alt="Buy at Optimum Nutrition" /><br />
</a>
</div>
<div class="am-right">
<a href="http://www.amazon.co.uk/s?ie=UTF8&#038;ref_=nb_sb_ss_i_3_40&#038;rh=i%3Aaps%2Ck%3Aoptimum%20nutrition%20100%20whey%20gold%20standard&#038;field-keywords=optimum%20nutrition%20100%20whey%20gold%20standard&#038;url=search-alias%3Daps&#038;sprefix=optimum%20nutrition%20100%20whey%20gold%20standard&#038;ajr=2#?_encoding=UTF8&#038;tag=tomwyn-21&#038;linkCode=ur2&#038;camp=1634&#038;creative=19450"><br />
<img src="http://tomoswyn.com/wp-content/uploads/2011/08/on-amazon.jpg" title="Buy at Amazon" alt="Buy at Amazon" /><br />
</a>
</div>
<p><img src="https://www.assoc-amazon.co.uk/e/ir?t=tomwyn-21&#038;l=ur2&#038;o=2" width="1" height="1" border="0" alt="" style="border:none !important; margin:0px !important;" /></p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://tomoswyn.com/reviews/optimum-nutrition-100-whey-gold-standard-review/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Time for a change: Website refresh and looking to the future</title>
		<link>http://tomoswyn.com/updates/website-refresh/</link>
		<comments>http://tomoswyn.com/updates/website-refresh/#comments</comments>
		<pubDate>Mon, 11 Jul 2011 08:41:35 +0000</pubDate>
		<dc:creator>tomoswyn</dc:creator>
				<category><![CDATA[Updates]]></category>

		<guid isPermaLink="false">http://tomoswyn.com/?p=20</guid>
		<description><![CDATA[University is nearly over with &#8211; I have my BSc in Business IT, and pending I pass my final year report and this accounting resit then I will also have a MSc to my name. With this, I think it&#8217;s time to focus more on my blog. I have some plans for it, including: Documenting [&#8230;]]]></description>
				<content:encoded><![CDATA[<p>University is nearly over with &#8211; I have my BSc in Business IT, and pending I pass my final year report and this accounting resit then I will also have a MSc to my name.</p>
<p>With this, I think it&#8217;s time to focus more on my blog. I have some plans for it, including:</p>
<ul>
<li>Documenting my progress whilst writing my final year report</li>
<li>Writing about business related topics</li>
<li>Reviews</li>
</ul>
<p>With regards to reviews, I have several products that I will review, including the supplements I&#8217;m taking to help my transform my body.</p>
<p>I&#8217;m also planing to start looking into Internet Marketing, as I have a decent understanding of how it works behind the scenes. The journey has already started, as I have some web properties set up for this sole purpose. I&#8217;m also an Amazon affiliate, so I&#8217;ll be looking to increase my knowledge of Amazon marketing. I also landed my first commission with the <a title="Thesis Framework" href="http://tomoswyn.com/go/thesis-theme/">DIYThemes affiliate program</a>.</p>
<p>The site refresh is neraly complete too &#8211; it&#8217;s built on top of the awesome <a title="Thesis Framework" href="http://tomoswyn.com/go/thesis-theme/">Thesis framework for WordPress</a>, I&#8217;d definitely recommend checking it out. The design is done, I just have a few things left to tweak on the site, such as the logo e.t.c.</p>
]]></content:encoded>
			<wfw:commentRss>http://tomoswyn.com/updates/website-refresh/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Aberystwyth University Private Accomodation</title>
		<link>http://tomoswyn.com/university/aberystwyth-university-private-accomodation/</link>
		<comments>http://tomoswyn.com/university/aberystwyth-university-private-accomodation/#respond</comments>
		<pubDate>Fri, 09 Jul 2010 18:45:00 +0000</pubDate>
		<dc:creator>tomoswyn</dc:creator>
				<category><![CDATA[University]]></category>

		<guid isPermaLink="false">http://tomoswyn.com/?p=10</guid>
		<description><![CDATA[Aberystwyth University, possibly the best University ever, but I might be bias, as I’m currently a student there and having the time a whale of a time there studying for a degree in Business Information Technology. Hey there &#8211; you probably arrived here through looking for information about private student accommodation at Aberystwyth. I&#8217;ve just launched a new [&#8230;]]]></description>
				<content:encoded><![CDATA[<p><a href="http://www.aber.ac.uk/">Aberystwyth <strong>University</strong></a>, possibly the best <strong>University</strong> ever, but I might be bias, as I’m currently a student there and having the time a whale of a time there studying for a degree in Business Information Technology.</p>
<div class="notice">
<p style="font-family:Arial; margin-bottom:18px;"><strong>Hey there &#8211; you probably arrived here through looking for information about private student accommodation at Aberystwyth.</strong></p>
<p style="font-family:Arial">I&#8217;ve just launched a new project &#8211; <strong><a href="http://studentletreviews.com">Student Let Reviews</a></strong> which houses reviews about those providing private accommodation for students in Aberystwyth. Go check it out.</p>
</div>
<p>I’m writing this post about the <strong>Accommodation</strong> that Aberystwyth has to offer. Although I will be mentioning the University’s <strong>accommodation</strong> practices, this will only be brief, as the bulk of this article will focus on the private <strong>accommodation</strong> that’s available.</p>
<p>To start off with, there are two types of <strong>accommodation</strong> at Aberystwyth. These <strong>accommodation</strong> types are:</p>
<ul>
<li><strong><strong>University</strong> <strong>Accommodation</strong>:</strong> This is <strong>accommodation</strong> that is managed by the <strong>University</strong></li>
<li><strong>Private <strong>Accommodation</strong>:</strong> This is <strong>accommodation</strong> outside of the <strong>University</strong>, for example by Landlords or Letting Agents</li>
</ul>
<p>OK, so now we have the definitions out of the way, let’s talk about <strong>accommodation</strong> practices.</p>
<p><span id="more-10"></span></p>
<h2>First Year <strong>Accommodation</strong>:</h2>
<p>Aberystwyth <strong>University</strong> has in place an <strong><a href="http://www.aber.ac.uk/residential/en/accommodation/guarantees.shtml"><strong>accommodation</strong> guarantee</a></strong> This basically means that if you you are a going into your first year, and apply before a certain date (August 1st), then you are guaranteed an<strong>accommodation</strong> place within the <strong>University</strong>. This is helpful for new students as they are on campus, and can build new friendships with new people, some of whom you may go on to share <strong>accommodation</strong>with in the 2nd year.</p>
<p>It is not unheard of for first year students to find private <strong>accommodation</strong> – indeed this was the case with one of my friends, who started <strong>University</strong> a year after myself and shared a house with me in when I was in my 2nd year.</p>
<h2>Second Year <strong>Accommodation</strong>:</h2>
<div class="notice">
<p style="font-family:Arial">I&#8217;ve just launched a new project &#8211; <strong><a href="http://studentletreviews.com">Student Let Reviews</a></strong> which houses reviews about those providing private accommodation for students in Aberystwyth. Go check it out.</p>
</div>
<p>When you are in your 2nd year, it is common practice for students to find <strong>private <strong>accommodation</strong></strong>. There are two main types of private <strong>accommodation</strong> available in Aberystwyth, and they are:</p>
<ul>
<li><strong>Letting Agents</strong></li>
<li><strong>Landlords:</strong> This is where you deal directly with a landlord, cutting out the letting Agents.</li>
</ul>
<h3><strong>Accommodation</strong> Costs:</h3>
<p>Costs for private <strong>accommodation</strong> can vary at Aberystwyth. This section gives an overview of these costs.</p>
<h4>The basic weekly rate:</h4>
<p>For example, in this academic year, our contract with a Letting Agent sets us back £65 per week, excluding bills. This is the basic rate for student <strong>accommodation</strong>, and is set to rise for the next academic year to £70 per week.</p>
<p>The amount a student pays when they take a house directly with a landlord is usually the same price, but can be a bit lower, or higher.</p>
<h4>Utilities:</h4>
<p>Utilities is a cost that you must factor into your budget. You should check to see whether your contract comes with utilities included, or whether they are separate.</p>
<p>From personal experience, it would seem that there is a higher chance for utilities to be included when a contract is taken out with a landlord as opposed with a letting agent.</p>
<h4>Deposit:</h4>
<p>No matter whether you take a contract out directly with a Landlord, or with a Letting Agency, you will be required to pay a deposit. The deposit is normally around the £300 mark for letting agencies, whilst it may be lower if you go with a Landlord.</p>
<p>All Letting Agents &amp; Landlords should immediately place your deposit with the DPS (Deposit Protection Service):</p>
<blockquote><p>As part of the Housing Act 2004 the Government is introducing tenancy deposit protection for all assured shorthold tenancies (ASTs) in England and Wales where a deposit is taken. From April 6th 2007, all deposits paid under an AST have had to be protected within 14 calendar days of receipt by the landlord.</p>
<p>The legislation aims to ensure that tenants who have paid a deposit to a landlord or letting agent and are entitled to receive all or part of it back at the end of that tenancy, actually get it.</p></blockquote>
<p><strong>Always check your contract to see what you will have to pay</strong>.</p>
<h4>Summer Rent:</h4>
<p>Summer rent is, simply put, a rent you have to pay to pay to keep the property over summer. It currently stands at 50% of your monthly rent, but is set to increase this year. <strong>Always check your contract to see what you will have to pay</strong>.</p>
<h3><strong>Accommodation</strong> Quality:</h3>
<p>The quality of private <strong>accommodation</strong> in Aberystwyth can and will vary. The earlier you typically find your <strong>accommodation</strong>, the better the quality of your <strong>accommodation</strong>.</p>
<p>Most houses come with the basics, such as:</p>
<ul>
<li>Bedroom: Bed, desk, chair, wardrobe, cabinet.</li>
<li>Kitchen: Basics, but you might need to provide your own kettle, toaster, microwave, dishes &amp; utensils.</li>
</ul>
<p>You can find out all of these details when your talking either with the Landlord or with the Letting Agent.</p>
<p>You should also remember that the Landlord or Letting Agent are bound by legislation to keep the let (house, flat, whatever you want to call it) in a decent state. If they do not keep their word, then you have the right to take things further. The <a href="http://www.citizensadvice.org.uk/">Citizens Advice Bureau</a> or <a href="http://aberguild.co.uk/">Student Guild</a> can help you with any issues you may have.</p>
<h2>Finding <strong>Accommodation</strong>:</h2>
<p>Finding your <strong>accommodation</strong> at Aberystwyth is not really hard. No matter which street you walk down, you will be in sight of either an Estate Agent or some form of student let house.</p>
<p>Estate Agents will normally have signs up in their windows notifying when student property lists are released, and when all the properties they have are let out.</p>
<p>If you are interested in pursuing the landlord route, then there are several ways of doing this. The easiest way is to just walk around the town, looking in windows. Houses will normally have the contact details of the owners, or adverts for student properties in them. The second way is to use a website provided by the <strong>University</strong> – <a href="http://aberaccom.aber.ac.uk/en/index.php">AberAccom</a>. This website lets you easily search private <strong>accommodation</strong>, but the emphasis is down to you to contact the owners for more details. I must point out one weakness here, and that is the fact that some properties are still left on the website even when they have actually been let out – so that is something to bear in mind.</p>
<h2>Conclusion:</h2>
<p>To summarize, question everything. Query how much you will have to pay, question when issues will be fixed (if there are any). Question if they are registered with the DPS and if they are licensed to let properties.</p>
<p>If you feel if I have left anything out, or want to know anything more, then feel free to comment.</p>
<div class="notice">
<p style="font-family:Arial">I&#8217;ve just launched a new project &#8211; <strong><a href="http://studentletreviews.com">Student Let Reviews</a></strong> which houses reviews about those providing private accommodation for students in Aberystwyth. Go check it out.</p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://tomoswyn.com/university/aberystwyth-university-private-accomodation/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
