<?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>Sunsetsurf Techblog &#187; Wordpress / Joomla stuffs</title>
	<atom:link href="http://techblog.sunsetsurf.co.uk/category/wordpressjoomla/feed/" rel="self" type="application/rss+xml" />
	<link>http://techblog.sunsetsurf.co.uk</link>
	<description>Random tech bloggidge</description>
	<lastBuildDate>Fri, 09 Jul 2010 10:00:38 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>Adding category index to wordpress.</title>
		<link>http://techblog.sunsetsurf.co.uk/2009/06/adding-category-index-to-wordpress/</link>
		<comments>http://techblog.sunsetsurf.co.uk/2009/06/adding-category-index-to-wordpress/#comments</comments>
		<pubDate>Tue, 23 Jun 2009 09:55:02 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Wordpress / Joomla stuffs]]></category>

		<guid isPermaLink="false">http://techblog.sunsetsurf.co.uk/?p=66</guid>
		<description><![CDATA[I wanted to change wordpress so that when people click on my categorys they get a nice index page with all the possible posts.. There were a few ways you could achieve this, but I plumped for modifiying archive.php, mostly because I like playing. To do this, you need to edit wp-content/themes/yourthemename/archive.php. In archive.php you [...]]]></description>
			<content:encoded><![CDATA[<p>I wanted to change wordpress so that when people click on my categorys they get a nice index page with all the possible posts..</p>
<p>There were a few ways you could achieve this, but I plumped for modifiying archive.php, mostly because I like playing.</p>
<p>To do this, you need to edit wp-content/themes/yourthemename/archive.php.</p>
<p>In archive.php you will see a number of lines, find the one that has the following:</p>
<p>&lt;?php if (have_posts()) : ?&gt;</p>
<p>For me in my theme it was under a load of if elseif loops setting up the archive type.</p>
<p>Once you have found that part, insert the following ABOVE that line.</p>
<p>&lt;?php<br />
    $temp_category = single_cat_title(&#8221;,false);<br />
  //  if (!empty($temp_category)){<br />
    // give index<br />
   // ?&gt;<br />
    &lt;h1&gt;&lt;?php single_cat_title(); ?&gt;&lt;/h1&gt;<br />
    &lt;p&gt;&lt;?php echo(category_description(the_category_ID(false))); ?&gt;&lt;/p&gt;<br />
&lt;?php query_posts(&#8216;posts_per_page=-1&amp;cat=&#8217;.$cat); ?&gt;<br />
        &lt;?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?&gt;</p>
<p>        &lt;a href=&#8221;&lt;?php the_permalink() ?&gt;&#8221;&gt;&lt;?php the_title(); ?&gt;&lt;/a&gt;&lt;br&gt;&lt;br&gt;&lt;?php echo $the_post; ?&gt;&lt;/br&gt;<br />
    &lt;?php endwhile; else: ?&gt;<br />
    &lt;p&gt;&lt;?php _e(&#8216;Sorry, no posts matched your criteria.&#8217;); ?&gt;&lt;/p&gt;<br />
   &lt;?php endif; ?&gt;<br />
    &lt;?php<br />
//   }else{ // give details or single post<br />
    ?&gt;</p>
<p> &lt;?php query_posts(&#8216;posts_per_page=3&amp;cat=&#8217;.$cat); ?&gt;</p>
<p> </p>
<p>The line &lt;?php query_posts(&#8216;posts_per_page=-1&amp;cat=&#8217;.$cat); ?&gt; basically says dont limit the number of post headings that is displayed, I have it set to -1 which means all, but if you wanted you could limit this to whatever number you fancy &#8211; 10, 20 etc..</p>
<p>The line at the bottom &#8211; &lt;?php query_posts(&#8216;posts_per_page=3&amp;cat=&#8217;.$cat); ?&gt; says show the first 3 articles below for the category you are in, again you might want to increase or decrease this number.</p>
<p>You will also need to close things up at the end, parentheses and if statements.</p>
<p>Its hard to post this as  each template is different, so drop me a comment if you have trouble.</p>
<p>You will know if you haven&#8217;t closed as you will get an unexpected error when you try to view your page.</p>
<p><map name='google_ad_map_66_17841dedafa0ad63'>
<area shape='rect' href='http://imageads.googleadservices.com/pagead/imgclick/66?pos=0' coords='1,2,367,28' />
<area shape='rect' href='http://services.google.com/feedback/abg' coords='384,10,453,23'/></map>
<img usemap='#google_ad_map_66_17841dedafa0ad63' border='0' src='http://imageads.googleadservices.com/pagead/ads?format=468x30_aff_img&amp;client=&amp;channel=&amp;output=png&amp;cuid=66&amp;url= http%3A%2F%2Ftechblog.sunsetsurf.co.uk%2F2009%2F06%2Fadding-category-index-to-wordpress%2F' /></p>]]></content:encoded>
			<wfw:commentRss>http://techblog.sunsetsurf.co.uk/2009/06/adding-category-index-to-wordpress/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Change sort order of blogroll from name in wordpress</title>
		<link>http://techblog.sunsetsurf.co.uk/2009/06/change-sort-order-of-blogroll-from-name/</link>
		<comments>http://techblog.sunsetsurf.co.uk/2009/06/change-sort-order-of-blogroll-from-name/#comments</comments>
		<pubDate>Mon, 22 Jun 2009 09:58:56 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Wordpress / Joomla stuffs]]></category>

		<guid isPermaLink="false">http://techblog.sunsetsurf.co.uk/?p=56</guid>
		<description><![CDATA[I dont think im the only one who doesnt neccesarily want my wordpress blogroll list to be sorted by name, i&#8217;d sooner be able to choose the order. For me, I added the bookmarks in the order I wanted so the link_id column in the database was the one I wanted it to be sorted [...]]]></description>
			<content:encoded><![CDATA[<p>I dont think im the only one who doesnt neccesarily want my wordpress blogroll list to be sorted by name, i&#8217;d sooner be able to choose the order.</p>
<p>For me, I added the bookmarks in the order I wanted so the link_id column in the database was the one I wanted it to be sorted by.</p>
<p>To do this you need to modify the file wp-includes/bookmark-template.php</p>
<p>I&#8217;d suggest you make a backup of this file before you edit it, just incase, and dont forget to leave the last extention as php so it can&#8217;t be accessed by anyone whilst its there &#8211; i.e bookmark-template.bak.php etc..</p>
<p>find the line in that file that says</p>
<div id="_mcePaste" style="position: absolute; overflow-x: hidden; overflow-y: hidden; width: 1px; height: 1px; top: 48px; left: -10000px;">function wp_list_bookmarks($args = &#8221;) {</div>
<div id="_mcePaste" style="position: absolute; overflow-x: hidden; overflow-y: hidden; width: 1px; height: 1px; top: 48px; left: -10000px;">$defaults = array(</div>
<div id="_mcePaste" style="position: absolute; overflow-x: hidden; overflow-y: hidden; width: 1px; height: 1px; top: 48px; left: -10000px;">&#8216;orderby&#8217; =&gt; &#8216;id&#8217;, &#8216;order&#8217; =&gt; &#8216;ASC&#8217;,</div>
<p>function wp_list_bookmarks($args = &#8221;) {</p>
<p>$defaults = array(</p>
<p>&#8216;orderby&#8217; =&gt; &#8216;name&#8217;, &#8216;order&#8217; =&gt; &#8216;ASC&#8217;,</p>
<p>You want to change name to be id, and that will sort your blogroll by ID rather than Name.</p>
<p><map name='google_ad_map_56_17841dedafa0ad63'>
<area shape='rect' href='http://imageads.googleadservices.com/pagead/imgclick/56?pos=0' coords='1,2,367,28' />
<area shape='rect' href='http://services.google.com/feedback/abg' coords='384,10,453,23'/></map>
<img usemap='#google_ad_map_56_17841dedafa0ad63' border='0' src='http://imageads.googleadservices.com/pagead/ads?format=468x30_aff_img&amp;client=&amp;channel=&amp;output=png&amp;cuid=56&amp;url= http%3A%2F%2Ftechblog.sunsetsurf.co.uk%2F2009%2F06%2Fchange-sort-order-of-blogroll-from-name%2F' /></p>]]></content:encoded>
			<wfw:commentRss>http://techblog.sunsetsurf.co.uk/2009/06/change-sort-order-of-blogroll-from-name/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Problem with show_image_in_imgtag.php in virtuemart missing images.</title>
		<link>http://techblog.sunsetsurf.co.uk/2009/06/problem-with-show_image_in_imgtagphp-in-virtuemart-missing-images/</link>
		<comments>http://techblog.sunsetsurf.co.uk/2009/06/problem-with-show_image_in_imgtagphp-in-virtuemart-missing-images/#comments</comments>
		<pubDate>Wed, 10 Jun 2009 21:43:18 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Wordpress / Joomla stuffs]]></category>

		<guid isPermaLink="false">http://techblog.sunsetsurf.co.uk/?p=41</guid>
		<description><![CDATA[Well this was one that took me ages to fix.. But annoyingly I think I was being told about the problem in many other virtuemart posts, but im not sure. I &#8220;thought&#8221; I had tried all the permissions fixes going, but still couldnt get it to work, but anyway here&#8217;s what I needed to do.. [...]]]></description>
			<content:encoded><![CDATA[<p>Well this was one that took me ages to fix..</p>
<p>But annoyingly I think I was being told about the problem in many other virtuemart posts, but im not sure.</p>
<p>I &#8220;thought&#8221; I had tried all the permissions fixes going, but still couldnt get it to work, but anyway here&#8217;s what I needed to do..</p>
<p>The problem that was occuring was virtuemart was failing to display the image thumbnails under the category section. The product image and thumbnail were fine, but the one on the category page wasn&#8217;t. Looking at the link it was calling the show_image_in_imgtag.php script but for some reason, if I called it manually to debug, it was giving me an internal server error.</p>
<p>Unfortunatly to make things harder because it was running on a cpanel install I didnt have access to all the files I would have liked to.</p>
<p>Anyway, the bottom line &#8211; the fix.</p>
<p>in your webroot directory where you have joomla or mambo installed there will be a components directory, I needed to chmod this 755. Once this was done, the images just kicked in.</p>
<p>Hope this saves someone some time!</p>
<p><map name='google_ad_map_41_17841dedafa0ad63'>
<area shape='rect' href='http://imageads.googleadservices.com/pagead/imgclick/41?pos=0' coords='1,2,367,28' />
<area shape='rect' href='http://services.google.com/feedback/abg' coords='384,10,453,23'/></map>
<img usemap='#google_ad_map_41_17841dedafa0ad63' border='0' src='http://imageads.googleadservices.com/pagead/ads?format=468x30_aff_img&amp;client=&amp;channel=&amp;output=png&amp;cuid=41&amp;url= http%3A%2F%2Ftechblog.sunsetsurf.co.uk%2F2009%2F06%2Fproblem-with-show_image_in_imgtagphp-in-virtuemart-missing-images%2F' /></p>]]></content:encoded>
			<wfw:commentRss>http://techblog.sunsetsurf.co.uk/2009/06/problem-with-show_image_in_imgtagphp-in-virtuemart-missing-images/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Joomla Metamod positioning problem</title>
		<link>http://techblog.sunsetsurf.co.uk/2009/06/joomla-metamod-positioning-problem/</link>
		<comments>http://techblog.sunsetsurf.co.uk/2009/06/joomla-metamod-positioning-problem/#comments</comments>
		<pubDate>Fri, 05 Jun 2009 17:58:20 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Wordpress / Joomla stuffs]]></category>

		<guid isPermaLink="false">http://techblog.sunsetsurf.co.uk/?p=18</guid>
		<description><![CDATA[After trawling google, I came across Metamod which seemed like it would do exactly what I wanted &#8211; display modules depending on criteria I set. I only have a smallish page, and one of my other pages was too big, and was pushing one of my modules off the side&#8230; most irritating, and my php [...]]]></description>
			<content:encoded><![CDATA[<p>After trawling google, I came across Metamod which seemed like it would do exactly what I wanted &#8211; display modules depending on criteria I set.</p>
<p>I only have a smallish page, and one of my other pages was too big, and was pushing one of my modules off the side&#8230; most irritating, and my php / css skills are not good enough to get around it a clever way.. (feel free to suggest)</p>
<p>So Metamod seemed to allow me to say, if x then display Module y otherwise dont etc..</p>
<p>Great&#8230; except I ran into a problem. Metamod worked fine inasmuch as it did what it said on the tin, but the trouble I had was I couldnt get the module to not display from the normal layout. So for example, I set up a rule which said if article id != x then display module y. The trouble was when that criteria was met, i.e most of the time, it would display the module twice! Once for Metamod and once for the normal layout rules.</p>
<p>So I switched the module off thinking Metamod would handle it.. nope, Metamod complained about not being able to load the module.</p>
<p>I googled a bit (not a lot to be honest, so there is probaby a very elegant and easy solution out there!) but couldnt find anything. So I thought if I could edit the position of the module to nothing, it would be active but not displayed anywhere. </p>
<p>So using mysql direct I set the position of the module to blank. Bingo, Metamod still loaded it, but because it didnt have a position it wasn&#8217;t loaded anywhere else&#8230;</p>
<p>Bit of a bodge workaround I fancy, but it worked for me&#8230;</p>
<p><map name='google_ad_map_18_17841dedafa0ad63'>
<area shape='rect' href='http://imageads.googleadservices.com/pagead/imgclick/18?pos=0' coords='1,2,367,28' />
<area shape='rect' href='http://services.google.com/feedback/abg' coords='384,10,453,23'/></map>
<img usemap='#google_ad_map_18_17841dedafa0ad63' border='0' src='http://imageads.googleadservices.com/pagead/ads?format=468x30_aff_img&amp;client=&amp;channel=&amp;output=png&amp;cuid=18&amp;url= http%3A%2F%2Ftechblog.sunsetsurf.co.uk%2F2009%2F06%2Fjoomla-metamod-positioning-problem%2F' /></p>]]></content:encoded>
			<wfw:commentRss>http://techblog.sunsetsurf.co.uk/2009/06/joomla-metamod-positioning-problem/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
	</channel>
</rss>
