<?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>DocuView - document management system &#187; hack</title>
	<atom:link href="http://docuview.co.uk/index.php/tag/hack/feed/" rel="self" type="application/rss+xml" />
	<link>http://docuview.co.uk</link>
	<description>revolutionary web 2.0 document management system</description>
	<lastBuildDate>Fri, 25 Jun 2010 00:50:53 +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>customise the default size of avatars in WordPress 2.8+</title>
		<link>http://docuview.co.uk/index.php/2009/08/customise-the-default-size-of-avatars-in-wordpress-2-8/</link>
		<comments>http://docuview.co.uk/index.php/2009/08/customise-the-default-size-of-avatars-in-wordpress-2-8/#comments</comments>
		<pubDate>Mon, 31 Aug 2009 17:59:03 +0000</pubDate>
		<dc:creator>Martin Korych</dc:creator>
				<category><![CDATA[development]]></category>
		<category><![CDATA[troubleshooting]]></category>
		<category><![CDATA[avatar]]></category>
		<category><![CDATA[core]]></category>
		<category><![CDATA[docuview]]></category>
		<category><![CDATA[excerpt]]></category>
		<category><![CDATA[gravatar]]></category>
		<category><![CDATA[hack]]></category>
		<category><![CDATA[icons]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[recent posts]]></category>
		<category><![CDATA[upgrade]]></category>
		<category><![CDATA[widget]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://docuview.co.uk/?p=329</guid>
		<description><![CDATA[Customise your WordPress Avatar, gravatar or whichever icon you're using, in comments. Few easy steps.]]></description>
			<content:encoded><![CDATA[<p>You know the drill: backup, upgrade WordPress, check plugin compatibility, verify everything is up and running and&#8230; reapply your hacks to the core of WP. I have talked about <a title="post excerpt in wordpress recent posts widget" href="http://docuview.co.uk/index.php/2009/07/display-post-excerpt-in-recent-posts-widget-in-wordpress/">displaying the post excerpt in the recent posts widget</a> few weeks ago, today I&#8217;m going to talk about resizing the Avatar image file displayed in comments.</p>
<p><span id="more-329"></span>So you&#8217;ve just finished upgrading, everything went smooth and you now have some time to amend the core of WordPress to accommodate for the hacks and workarounds you have implemented over the time. You have styled, laid out and customised your comments, you have changed the default size of Gravatar, Avatar or any other user pictures you display only to find them going back to default (32px × 32px) as soon as you upgrade.</p>
<p>Worry not! In order to change it back to what it was, head to: &#8220;wp-includes/comment-template&#8221;, locate line #1322 (function wp_list_comments()) and change the defaults array value (&#8220;avatar_size&#8221;) from 32 to anything you like (we use 50px), so the result will read:</p>
<pre class="brush: php;">$defaults = array('walker' =&gt; null, 'max_depth' =&gt; '', 'style' =&gt; 'ul', 'callback' =&gt; null, 'end-callback' =&gt; null, 'type' =&gt; 'all',
'page' =&gt; '', 'per_page' =&gt; '', 'avatar_size' =&gt; 50, 'reverse_top_level' =&gt; null, 'reverse_children' =&gt; '');</pre>
<p>And zet is zit. Save and refresh your comments page and enjoy, your user icons and images are exactly big (or small) as intended.</p>
<p>Helpful? Drop me a line here.</p>
]]></content:encoded>
			<wfw:commentRss>http://docuview.co.uk/index.php/2009/08/customise-the-default-size-of-avatars-in-wordpress-2-8/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Sliding doors with transparent background (CSS) &#8211; Part 1</title>
		<link>http://docuview.co.uk/index.php/2008/04/sliding-doors-with-transparent-background-css-part-1/</link>
		<comments>http://docuview.co.uk/index.php/2008/04/sliding-doors-with-transparent-background-css-part-1/#comments</comments>
		<pubDate>Tue, 15 Apr 2008 23:25:23 +0000</pubDate>
		<dc:creator>Martin Korych</dc:creator>
				<category><![CDATA[design]]></category>
		<category><![CDATA[2008]]></category>
		<category><![CDATA[css]]></category>
		<category><![CDATA[document management system]]></category>
		<category><![CDATA[docuview]]></category>
		<category><![CDATA[fixed]]></category>
		<category><![CDATA[flexible]]></category>
		<category><![CDATA[hack]]></category>
		<category><![CDATA[heading]]></category>
		<category><![CDATA[png]]></category>
		<category><![CDATA[sliding doors]]></category>
		<category><![CDATA[transparent background]]></category>
		<category><![CDATA[update]]></category>
		<category><![CDATA[working]]></category>

		<guid isPermaLink="false">http://docuview.co.uk/blog/?p=8</guid>
		<description><![CDATA[We&#8217;ve undergone a major revamp of DocuView design (the blog is to follow). I have decided to make this post because I have been looking for a solution on the internet and couldn&#8217;t find a suitable up-to-date article describing what I needed. The obstacle I came accross this time was transforming fixed layout into a [...]]]></description>
			<content:encoded><![CDATA[<p>We&#8217;ve undergone a major revamp of DocuView design (the blog is to follow). I have decided to make this post because I have been looking for a solution on the internet and couldn&#8217;t find a suitable up-to-date article describing what I needed. The obstacle I came accross this time was transforming fixed layout into a flexible one, avoiding extra markup and utilising CSS to do the trick.</p>
<h2>Original design</h2>
<p>We&#8217;re working with a brilliant young designer Jay Murray, who&#8217;s contribution to the project is priceless. He came up with the following design:</p>
<p><a href="http://docuview.co.uk/wp-content/uploads/2008/04/new_design.png" target="_blank"><img class="alignnone size-medium wp-image-50" title="new_design" src="http://docuview.co.uk/wp-content/uploads/2008/04/new_design-300x174.png" alt="" width="300" height="174" /></a></p>
<p><span id="more-8"></span></p>
<h2>Three challenges there:</h2>
<ul>
<li>awesome headings that carry the logo design (shape and colours) throughout the site &#8211; turn them into flexible width as DocuView isn&#8217;t and won&#8217;t be using fixed layout</li>
<li>the same with subheadings and smaller sections</li>
<li>apply the background to menu items and turn them into 3Dish tabs (resembling filing folder &#8211; we are dealing with a document management system here after all</li>
</ul>
<h2>Sliding doors with transparent background (CSS) &#8211; headings + wrapper</h2>
<p>We&#8217;re using PNGs throughout the system, no hacks and workarounds for IE6 (yet &#8211; although not quite sure that in these days we should still care and optimise &#8211; probably an article on its own for the future). The issue here is we have a background applied to the &#8220;container&#8221; div and the heading is on top of the background and we want to keep the transparency.</p>
<p>I had a long thought as to how I&#8217;m going to tackle this. Slicing the heading, making it work on resolutions up to full HD (1920×1200) (for the sake of couple of kilobytes of cachable graphics it was actually a no brainer)&#8230;</p>
<h2>Preparing the images</h2>
<p>This is the default image I have extracted from Jay&#8217;s Illustrator files. Consists of three layers:</p>
<ul>
<li>container (with shadows)</li>
<li>heading (no shadows)</li>
<li>subheading (no shadow)</li>
</ul>
<p><a href="http://docuview.co.uk/wp-content/uploads/2008/04/default_layout.png" target="_blank"><img class="alignnone size-medium wp-image-40" title="default_layout" src="http://docuview.co.uk/wp-content/uploads/2008/04/default_layout-300x195.png" alt="" width="300" height="195" /></a></p>
<p>I came accross sliding doors in CSS layouts in the past, I&#8217;ve read articles on <a title="A List Apart - Sliding Doors of CSS" href="http://www.alistapart.com/articles/slidingdoors/" target="_blank">A List Apart</a> (+<a title="A List Apart - Sliding Doors of CSS, Part II" href="http://www.alistapart.com/articles/slidingdoors2/">part II</a>), which gave me an insight into the technique yet it did not fully covered what I was after since they&#8217;re describing a GIF-based method. Useful, but not exactly what I hoped for. Observing their technique I have decided to slice my background like this:</p>
<p><a href="http://docuview.co.uk/wp-content/uploads/2008/04/guides.png" target="_blank"><img class="alignnone size-medium wp-image-43" title="guides" src="http://docuview.co.uk/wp-content/uploads/2008/04/guides-300x194.png" alt="" width="300" height="194" /></a></p>
<p><em>Please note I took the screenshot with white background so it&#8217;s more obvious where the guides are and how the shadows work.</em></p>
<p>A List Apart recommends making the left hand side (LHS) slice as small as possible. That&#8217;s exactly what we&#8217;re doing here. Using the Eyedropper tool in Photoshop I have separated areas with consistent background (to avoid funny looking transitions) and began slicing.</p>
<p><a href="http://docuview.co.uk/wp-content/uploads/2008/04/slicing.png" target="_blank"><img class="alignnone size-medium wp-image-51" title="slicing" src="http://docuview.co.uk/wp-content/uploads/2008/04/slicing-300x194.png" alt="" width="300" height="194" /></a></p>
<p>First: disable the white background. Then chop it into pieces. We only care about slices 1, 2, 5, 7 and 8. Note that slice 5 varies slightly from the others. The reason behind that is when it comes down to actual coding of the page and efficiently laying it out, any subheading will be contained in a either <strong>fieldset </strong>or <strong>form </strong>(I haven&#8217;t decided yet). There is no need to export the subheading layer with the shadows at all. We&#8217;ll get to this.</p>
<p>You end up with 5 slices:</p>
<p><a href="http://docuview.co.uk/wp-content/uploads/2008/04/images_01.png" target="_blank"><img class="alignnone size-medium wp-image-45" title="images_01" src="http://docuview.co.uk/wp-content/uploads/2008/04/images_01.png" alt="" width="24" height="82" /></a> <em>(LHS of heading)</em></p>
<p><a href="http://docuview.co.uk/wp-content/uploads/2008/04/images_02.png" target="_blank"><img class="alignnone size-medium wp-image-46" title="images_02" src="http://docuview.co.uk/wp-content/uploads/2008/04/images_02-300x35.png" alt="" width="300" height="35" /></a><em>(RHS of heading)</em></p>
<p><a href="http://docuview.co.uk/wp-content/uploads/2008/04/images_05.png" target="_blank"><img class="alignnone size-medium wp-image-47" title="images_05" src="http://docuview.co.uk/wp-content/uploads/2008/04/images_05-300x11.png" alt="" width="300" height="11" /></a> <em>(subheading)</em></p>
<p><a href="http://docuview.co.uk/wp-content/uploads/2008/04/images_07.png" target="_blank"><img class="alignnone size-medium wp-image-48" title="images_07" src="http://docuview.co.uk/wp-content/uploads/2008/04/images_07.png" alt="" width="24" height="217" /></a> <em>(LHS of wrapper)</em></p>
<p><a href="http://docuview.co.uk/wp-content/uploads/2008/04/images_08.png" target="_blank"><img class="alignnone size-medium wp-image-49" title="images_08" src="http://docuview.co.uk/wp-content/uploads/2008/04/images_08-300x94.png" alt="" width="300" height="94" /></a> <em>(RHS of wrapper)</em></p>
<h2>Converting fixed images to work in flexible layout</h2>
<p>I now need to take slices 2, 5, 7 and 8 and extend them a bit to cope with bigger resolutions as I am limited by the size of the image when it comes down to displaying the content.</p>
<p>Go back to Photoshop and open the above mentioned slices that need reediting.</p>
<p><strong>Slice 2</strong> (RHS heading): Firstly we need to extend the canvas (Winows: ALT+CTRL+C, Mac: I need to find out). Except for slice 7 (LHS of wrapper) we will be extending horizontally.</p>
<p><a href="http://docuview.co.uk/wp-content/uploads/2008/04/canvas_size.png" target="_blank"><img class="alignnone size-medium wp-image-28" title="extend canvas size to accomodate bigger resolutions" src="http://docuview.co.uk/wp-content/uploads/2008/04/canvas_size-300x247.png" alt="" width="300" height="247" /></a></p>
<p><a href="http://docuview.co.uk/wp-content/uploads/2008/04/extended_heading.png" target="_blank"><img class="alignnone size-medium wp-image-54" title="extended_heading" src="http://docuview.co.uk/wp-content/uploads/2008/04/extended_heading-300x13.png" alt="" width="300" height="13" /></a></p>
<p>Using the Eyedropper tool (I) select the colour (#00cbe5 in my case) in the far left side of the heading: this is the colour we are going to repeat in the rest of the image in a matching rectangle we&#8217;ve created using the Marquee tool (M).</p>
<p>I forgot about the shadow above the heading the very first time I was doing this. In order to help me distinguish and copy the shadows over I have dropped in a new layer with white background and placed it underneath the layer I was working with. So now it&#8217;s just down to Marquee tool and some copying. I do not worry about the number of layers it takes to create as I&#8217;ll merge them (Win: CTRL+E, Mac: will update soon) in the end anyway&#8230;</p>
<p>Final product (again with white background just for demonstrating purposes):</p>
<p><a href="http://docuview.co.uk/wp-content/uploads/2008/04/final_heading.png" target="_blank"><img class="alignnone size-medium wp-image-53" title="final_heading" src="http://docuview.co.uk/wp-content/uploads/2008/04/final_heading-300x13.png" alt="" width="300" height="13" /></a></p>
<p>Now I need to do the same to the subheading (<strong>slice 5 </strong>- don&#8217;t forget no shadows there).</p>
<p><strong>Slice 8</strong> (RHS of wrapper): I have resized the canvas to be 1920×1200 from bottom right corner. I have copied both the side and bottom over so many times till it filled the whole screen. I think I dropped in a white layer just for testing purposes to help me distinguish overlaying of the copied layers. In the end (after disabling the white layer) I have painted the rectangle that I created in the top left part of the image (because I do actually want to have the background of the wrapper in white to give a good contrast to containg elements).</p>
<p><strong>Slice 7 </strong>(LHS of wrapper): resizing this one to be (whatever-the-width(24px in my case)×1200 (height) and repeated the process from expanding slice 8.</p>
<p>Final images:</p>
<p><a href="http://docuview.co.uk/wp-content/uploads/2008/04/images_01.png" target="_blank"><img class="alignnone size-medium wp-image-45" title="images_01" src="http://docuview.co.uk/wp-content/uploads/2008/04/images_01.png" alt="" width="24" height="82" /></a></p>
<p><a href="http://docuview.co.uk/wp-content/uploads/2008/04/heading_right.png" target="_blank"><img class="alignnone size-medium wp-image-44" title="heading_right" src="http://docuview.co.uk/wp-content/uploads/2008/04/heading_right.png" alt="" width="300" height="12" /></a></p>
<h2><a href="http://docuview.co.uk/wp-content/uploads/2008/04/subheading.png" target="_blank"><img class="alignnone size-medium wp-image-52" title="subheading" src="http://docuview.co.uk/wp-content/uploads/2008/04/subheading.png" alt="" width="300" height="4" /></a></h2>
<h2><a href="http://docuview.co.uk/wp-content/uploads/2008/04/form_left.png" target="_blank"><img class="alignnone size-medium wp-image-41" title="form_left" src="http://docuview.co.uk/wp-content/uploads/2008/04/form_left.png" alt="" width="3" height="300" /></a></h2>
<h2><a href="http://docuview.co.uk/wp-content/uploads/2008/04/form_right.png" target="_blank"><img class="alignnone size-medium wp-image-42" title="form_right" src="http://docuview.co.uk/wp-content/uploads/2008/04/form_right.png" alt="" /></a></h2>
<h2>Next time</h2>
<p>In part two I will be describing the combination of CSS and HTML to achieve sliding doors on flexible layouts using CSS.</p>
<p>Let me know your thoughts <img src='http://docuview.co.uk/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://docuview.co.uk/index.php/2008/04/sliding-doors-with-transparent-background-css-part-1/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
	</channel>
</rss>
