<?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>gasolicious.com &#187;   &#8211; Website of Mark Gason &#8211; Gasolicious &#8211; design and E-commerce</title>
	<atom:link href="http://gasolicious.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://gasolicious.com</link>
	<description></description>
	<lastBuildDate>Fri, 18 May 2012 06:40:09 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
<xhtml:meta xmlns:xhtml="http://www.w3.org/1999/xhtml" name="robots" content="noindex" />
		<item>
		<title>Proportional thumbnails in Storefront Elegance theme</title>
		<link>http://gasolicious.com/web-design-wordpress-e-commerce-flash-blog/proportional-thumbnails-storefront/</link>
		<comments>http://gasolicious.com/web-design-wordpress-e-commerce-flash-blog/proportional-thumbnails-storefront/#comments</comments>
		<pubDate>Fri, 18 May 2012 05:13:57 +0000</pubDate>
		<dc:creator></dc:creator>
				<category><![CDATA[Blog]]></category>
		<category><![CDATA[Elegance]]></category>
		<category><![CDATA[Storefront Themes]]></category>
		<category><![CDATA[Wordpress]]></category>
		<category><![CDATA[WP e-Commerce]]></category>

		<guid isPermaLink="false">http://gasolicious.com/?p=1661</guid>
		<description><![CDATA[The Problem In the Storefront Themes, Elegance theme the thumbnails below the single product page image are always square. This is good in some ways because if you have uploaded images of varying shapes to your product gallery the layout will still be neat. If you have followed my mantra of uploading all of your [...]]]></description>
			<content:encoded><![CDATA[<h4>The Problem</h4>
<p>In the Storefront Themes, Elegance theme the thumbnails below the single product page image are always square. This is good in some ways because if you have uploaded images of varying shapes to your product gallery the layout will still be neat. If you have followed <a href="http://gasolicious.com/web-design-wordpress-e-commerce-flash-blog/commerce-choose-image-settings/" title="Choosing a good image size and aspect ratio for your WP e-Commerce site">my mantra of uploading all of your images the same aspect ratio</a> then you might wish that the gallery thumbnails were the same aspect ratio as your uploaded images. This can be achieved by bringing the image height into the calculations as well using the code below.</p>
<div  class ="note-panel">
<h4>NOTE:</h4>
<p>If you just have a problem with thumbnails overflowing the bottom of the post you can just implement the small change at the end of the post</p>
</div>
<h4>Solution</h4>
<p>You need to bring the image height into play as I said. We add the height in and then calculate the gallery height using that. You need to edit wpsc-single_product.php which is in the Elegance theme folder. If you have never edited PHP this can be done with simple cut and paste, so jump in and get your feet wet. See the editing PHP tools at the end of this post. remember to keep a safe copy of your original file, you can always swap back if you have a problem.<br />
So open wpsc-single_product.php and find on or around line 48 you should see</p>
<div class ="myCode">
<pre class="brush: php; first-line: 48; title: ; notranslate">
$featured_image = get_post_thumbnail_id($id);
</pre>
</div>
<p>Scroll down and find this around line line 71</p>
<div class ="myCode">
<pre class="brush: php; first-line: 71; title: ; notranslate">
&lt;/div&gt;&lt;!-- /END SINGLE PRODUCT GALLERY --&gt;
</pre>
</div>
<p>If you replace those 2 lines and everything in between with the block of code below you will be done. If you want to know a bit more about what changed and what is happening read on below the code.</p>
<div class ="myCode">
<pre class="brush: php; first-line: 48; highlight: [54,55,59,69]; title: ; notranslate">
$featured_image = get_post_thumbnail_id($id);
							$args = array( 'post_type' =&gt; 'attachment', 'orderby' =&gt; 'menu_order', 'order' =&gt; 'ASC', 'post_mime_type' =&gt; 'image' ,'offset' =&gt; '1' ,'post_status' =&gt; null, 'post_parent' =&gt; $post-&gt;ID, 'exclude' =&gt; $featured_image,'numberposts' =&gt; 999);
							$attachments = get_posts($args);
							$numposts = count($attachments);
							$roundheight = round($numposts / 2);
							$thumbwidth = $image_width / 2 - 12;
							$thumbheight = $image_height / 2;
							$galleryheight = $roundheight * $thumbheight + 85 + $image_height;
							if ($attachments) {$i = 0;
							foreach ( $attachments as $attachment ) {$i++;
							$thumbnail = wp_get_attachment_url( $attachment-&gt;ID , false );
							$image = vt_resize('', $thumbnail, $thumbwidth, $thumbheight, true);
							?&gt;
            &lt;style&gt;
#sft-single-product-gallery img.gallery {max-width:&lt;?php echo $thumbwidth;?&gt;px!important;}
&lt;/style&gt;
            &lt;a rel=&quot;&lt;?php echo str_replace(array(&quot; &quot;, '&quot;',&quot;'&quot;, '&amp;quot;','&amp;#039;'), array(&quot;_&quot;, &quot;&quot;, &quot;&quot;, &quot;&quot;,''), wpsc_the_product_title()); ?&gt;&quot; class=&quot;thickbox&quot; href=&quot;&lt;?php echo wp_get_attachment_url( $attachment-&gt;ID , false ); ?&gt;&quot;&gt;&lt;img class=&quot;gallery&quot; src=&quot;&lt;?php echo $image['url']; ?&gt;&quot; alt=&quot;&lt;?php the_title(); ?&gt;&quot; width=&quot;&lt;?php echo $thumbwidth;?&gt;&quot; height=&quot;&lt;?php echo $thumbwidth;?&gt;&quot; border=&quot;0&quot; /&gt;&lt;/a&gt;
            &lt;?php	}
							} ?&gt;
            &lt;?php $imagecolheight = $thumbwidth * $i / 2 + $image_height + 50;?&gt;
            &lt;style&gt;
								div.single_product_display div.textcol {min-height:&lt;?php echo $galleryheight;?&gt;px!important;}
								&lt;?php if ($numposts &gt; 1) {?&gt;div.single_product_display {min-height:&lt;?php echo $galleryheight + 90;?&gt;px!important;}&lt;?php } ?&gt;
							&lt;/style&gt;
            &lt;div class=&quot;clear&quot;&gt;&lt;/div&gt;
          &lt;/div&gt;
          &lt;!-- /END SINGLE PRODUCT GALLERY --&gt;
</pre>
</div>
<p>Line 54.<br />
Adds a thumbheight variable which stores the image height divided by 2, just as thumbwidth already does for the width. Yes obviously you could fiddle with these numbers and get 3 or 4 thumbnails per row instead of 2 below your main image. Some margin and padding adjustments may be required.<br />
Line 55.<br />
Use the height to calculate the height of the whole gallery instead of the width as it is by default. It is OK to use the width to do height in the default setup because the thumbnails are square.<br />
Line 59.<br />
Adds the height into the code that resizes the images into thumbnails, replacing one of the width variables. This code actually generates your thumbnails.<br />
Line 69.<br />
This is actually more of a bug fix. galleryheight is added here to stop the thumbnail gallery overflowing the container div into the footer. This sets the container to be tall enough to contain image and gallery.</p>
<p>Thats it, if you have done it right you should have proportional non square thumbnails and they should stay nicely in the content area and out of the footer.</p>
<h4>Just fix the overflow and keep square thumbs</h4>
<p>If you are happy with square thumbnails but have the problem mentioned earlier of the thumbnails overflowing into the footer, try this to fix it . Do not make any of the changes above. Find this line at or about 67</p>
<div class ="myCode">
<pre class="brush: php; first-line: 67; title: ; notranslate">
div.single_product_display div.textcol {min-height:&lt;?php echo $imagecolheight;?&gt;px!important;}
</pre>
</div>
<p>replace it with line 69 from the big block of code above.</p>
<div  class ="note-panel">
<h4>Tools:</h4>
<p>You must use an appropriate code editor NOT microsoft word or anything like that which adds a lot of invisible formatting and will be a disaster.<br />
If you do not have one, 2 excellent free ones are&#8230;<br />
TextWrangler for Mac, http://www.barebones.com/products/textwrangler/<br />
Notepad++ for the PC http://notepad-plus-plus.org/</p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://gasolicious.com/web-design-wordpress-e-commerce-flash-blog/proportional-thumbnails-storefront/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>WP e-Commerce, how to process $0.00 sales and 100% coupons which PayPal will not accept</title>
		<link>http://gasolicious.com/web-design-wordpress-e-commerce-flash-blog/commerce-process-sales-coupons/</link>
		<comments>http://gasolicious.com/web-design-wordpress-e-commerce-flash-blog/commerce-process-sales-coupons/#comments</comments>
		<pubDate>Tue, 15 May 2012 06:40:04 +0000</pubDate>
		<dc:creator></dc:creator>
				<category><![CDATA[Blog]]></category>
		<category><![CDATA[E-Commerce]]></category>
		<category><![CDATA[Elegance]]></category>
		<category><![CDATA[Storefront Themes]]></category>
		<category><![CDATA[Wordpress]]></category>
		<category><![CDATA[WP e-Commerce]]></category>

		<guid isPermaLink="false">http://gasolicious.com/?p=1650</guid>
		<description><![CDATA[The Problem I had a question recently about why a coupon was not being processed at the PayPal end. It turns out that PayPal will not process a $0.00 sale. If you have an item for $10.00 and a discount coupon for $10.00 the coupon is processed on the WP e-Commerce checkout page showing a [...]]]></description>
			<content:encoded><![CDATA[<h4>The Problem</h4>
<p>I had a question recently about why a coupon was not being processed at the PayPal end. It turns out that PayPal will not process a $0.00 sale. If you have an item for $10.00 and a discount coupon for $10.00 the coupon is processed on the WP e-Commerce checkout page showing a total of $0.00, but when the user gets to PayPal the coupon is totally ignored and the price is $10.00. Not good!<br />
If you reduce that coupon to $9.99 the sale would go through with a total of $0.01. That is not a very elegant solution. Many sites now have partnerships with coupon sale sites, these third party sites sell coupons which the user then expects to use to purchase at no cost. Some people have tried using the Test Gateway but this is only going to work if all of your sales are $0.00. You still want to send customers who have a cash balance to pay on to PayPal when they click Purchase.</p>
<h4>Solution</h4>
<p>Thanks to getShopped user dhtbrowne who supplied this solution http://getshopped.org/forums/topic/how-to-stop-free-products-redirecting-to-gateway/#post-268526</p>
<p>I will reproduce his code just as he wrote it and add a little explanation as things can be hard to find on the getShopped forums and even have a habit of disappearing completely. I have tested this with Storefront Themes, Elegance theme version 1.4.5, WordPress 3.3.1 and WP e-Commerce 3.8.7.6.2. It should work for most themes and hopefully newer WP e-Commerce versions. Please leave a comment if you test it in higher WP e-Commerce versions.<br />
The following solution will intercept any $0 purchase and the <span class="code-explanation">“wpsc_purchlog_edit_status()”</span> changes the order status to payment accepted, sends out all the necessary emails and deactivates coupons if they are set to use once.</p>
<p>STEP 1.<br />
First you need to make a page that says thank you, for users to be redirected to after they click purchase. Get the Page ID of the thank you page. To do this open it in WordPress for editing and look in the URL bar of your browser you will see a URL ending in something like this.<br />
wp-admin/post.php?post=492&#038;action=edit<br />
You need that number, in my case 492, it is the ID of the thank you page.</p>
<p>STEP 2.<br />
Here you need to edit a PHP file it is very easy, just pasting in some code, so you can avoid the whole code editor thing if you want and do this in WordPress. Go to Appearance/Editor, find functions.php on the file list and open it. Right BEFORE the very last ?> paste this code and change the 492 to the ID of your thank you page. When done make sure you have no blank space or lines after that final <span class="code-explanation">?></span></p>
<div class ="myCode">
<pre class="brush: php; first-line: 1; title: ; notranslate">
add_action('wpsc_submit_checkout', 'free_coupon_test');
function free_coupon_test($order_info) {
global $wpdb;
$purchaseID = $order_info['purchase_log_id'];
$rows = $wpdb-&gt;get_results(&quot;SELECT discount_data, totalprice FROM &quot; . $wpdb-&gt;prefix . &quot;wpsc_purchase_logs WHERE id=$purchaseID LIMIT 1&quot;);
require_once(ABSPATH.'/wp-content/plugins/wp-e-commerce/wpsc-admin/ajax-and-init.php');
if ($rows[0]-&gt;totalprice == 0 &amp;&amp; !$rows[0]-&gt;discount_data == '') {
wpsc_purchlog_edit_status($purchaseID, '3');
header(&quot;Location: &quot; . get_permalink(492));
die();
}
}
</pre>
</div>
<h4>Remember change the 492 to your thank you pages ID!</h4>
<p>Thats it, if you have done it right any $0 purchase should redirect to your thank you page. You should receive a purchase log and the customer receives a thank you receipt. To check it, try buying something yourself for $0 so that you get both emails.</p>
]]></content:encoded>
			<wfw:commentRss>http://gasolicious.com/web-design-wordpress-e-commerce-flash-blog/commerce-process-sales-coupons/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Storefront Elegance theme, add out of stock notice to grid view</title>
		<link>http://gasolicious.com/web-design-wordpress-e-commerce-flash-blog/storefront-elegance-theme-stock/</link>
		<comments>http://gasolicious.com/web-design-wordpress-e-commerce-flash-blog/storefront-elegance-theme-stock/#comments</comments>
		<pubDate>Sat, 12 May 2012 05:22:13 +0000</pubDate>
		<dc:creator></dc:creator>
				<category><![CDATA[Blog]]></category>
		<category><![CDATA[E-Commerce]]></category>
		<category><![CDATA[Elegance]]></category>
		<category><![CDATA[Storefront Themes]]></category>
		<category><![CDATA[WP e-Commerce]]></category>

		<guid isPermaLink="false">http://gasolicious.com/?p=1623</guid>
		<description><![CDATA[Question: Is there a way to keep the product in category view but with text &#8216;sold&#8217; instead of the price? With WP e-Commerce you have two options for out of stock products. If you check &#8220;I have limited stock for this Product&#8221; in the Products screen, you can show a out of stock message on [...]]]></description>
			<content:encoded><![CDATA[<h4>Question: Is there a way to keep the product in category view but with text &#8216;sold&#8217; instead of the price?</h4>
<p>With WP e-Commerce you have two options for out of stock products.</p>
<ol>
<li>If you check &#8220;I have limited stock for this Product&#8221; in the Products screen, you can show a out of stock message on the Single Product page by setting Settings/Store/Presentation tab &#8220;Show Stock Availability&#8221; to Yes. But this shows no message in Grid view on the products page</li>
<li>If you also check &#8220;Notify site owner and unpublish this Product if stock runs out&#8221; on the Products page AND set Settings/Store/Presentation tab &#8220;Show Stock Availability&#8221; to No the product will be set to draft and not appear on your site at all when it is out of stock.</li>
</ol>
<p>This user wants to keep the product displayed but have a message as you would get in option 1 on the Products page and Category pages. So we steal al little code from single products and patch it into the Products page.</p>
<p>You need to modify the theme PHP for this. You will need to maintain these changes in any theme update, so keep a record.<br />
These instructions are for Elegance 1.4.5 the principle should stay the same in newer versions but the line numbers may vary.<br />
This is pretty simple PHP editing, especially if you just cut and paste, so even if you have never done it before jump in, get your feet wet. Remember keep a safe copy of the files somewhere. You can always just restore the originals if you break something. See the notes on editing PHP at the end of this post.</p>
<h4>Find the code</h4>
<p>So the out of stock message is not included in the products page at all. How do we find the code to display that message? We could hunt the <a href="http://docs.getshopped.org/category/developer-documentation/" title="developer documentation for WP e-Commerce" target="_blank">WP e-Commerce docs</a>, we would eventually find it. Easier I think is to find where it is displayed, which is on the single products page. A little hunt inside the single product page code (wpsc-single_product.php) finds some pretty obvious code for checking if something is in stock&#8230;</p>
<div class ="myCode">
<pre class="brush: php; first-line: 141; title: ; notranslate">
&lt;?php if(wpsc_product_has_stock()) : ?&gt;
</pre>
</div>
<p>So lets copy that and include it into wpsc-products_page.php which is the file that displays both the products page and the product category pages.<br />
In wpsc-products_page.php around line 200 find this very long line which basically says if storefront grid view is selected and show price is selected create a div and span containing the price.</p>
<div class ="myCode">
<pre class="brush: php; first-line: 200; title: ; notranslate">
&lt;?php if ( get_option('storefront_gridview_price') == &quot;true&quot; &amp;&amp; get_option('storefront_gridview') == &quot;true&quot; ) {echo &quot;&lt;div class='sft-gridview-price'&gt;&lt;span class='sft-gridview-price-text'&gt;&quot;.wpsc_the_product_price().&quot;&lt;/span&gt;&lt;/div&gt;&quot;;} ?&gt;
</pre>
</div>
<h4>Code the out of stock message</h4>
<p>Now we still want to always show something if that is true, but now we want to add another condition to say if the product is in stock show the price and if not, show the out of stock message.<br />
So we need to put that inside our first if statement from line 200. I am going to take a little time here to explain the code for those new to it who may have some desire to understand what they are doing. If you already know your code jump down to the new code below.</p>
<p>Lets take a look at the structure of that statement. <a href="http://en.wikipedia.org/wiki/Conditional_(programming)" title="explanation of if statements" target="_blank">A if statement is made up of 2 parts</a>, the condition and what to do if the condition is true or not. <span class="code-explanation">if(condition){do this}</span>, condition in the parentheses () and action in the curly braces {}. In ordinary English our line 200 says&#8230;<br />
<span class="code-explanation">if(storefront gridview AND show price in gridview are both selected in the Storefront options panel){create some html and display the WP e-Commerce value wpsc_the_product_price in it}</span></p>
<p>So now we need to add our extra <span class="code-explanation">if</span> with <span class="code-explanation">else</span>, which is another possible part of an if statement which says what to do if the condition is not true.<br />
<span class="code-explanation">if(this is true){do this}else{do this}</span><br />
We need it to be considered inside the action area of the main line 200 if statement. By putting everything new inside the curly braces of the first if statement it only is considered if that is true. In a sense the first action of our fist condition becomes to consider another condition! In plain English again, and lets break it up on separate lines like we do in code for readability, although it would all work on one line.<br />
<span class="code-explanation">if(storefront gridview and show price in gridview are both selected in the Storefront options panel){<br />
&nbsp;&nbsp;&nbsp;if(we have stock of the product){<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;do the original action code to create some html and display the WP e-Commerce value wpsc_the_product_price in it}<br />
&nbsp;&nbsp;&nbsp;else {<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;create some html and write &#8216;this message&#8217; in it}<br />
}</span>this is the closing curly brace of the original line 200 if statement</p>
<p>So these 6 lines now replaces the original line 200.</p>
<div class ="myCode">
<pre class="brush: php; first-line: 200; title: ; notranslate">
&lt;?php if ( get_option('storefront_gridview_price') == &quot;true&quot; &amp;&amp; get_option('storefront_gridview') == &quot;true&quot;) {
							if(wpsc_product_has_stock()) { ?&gt;
							&lt;div class='sft-gridview-price'&gt;&lt;span class='sft-gridview-price-text'&gt;&lt;?php echo wpsc_the_product_price(); ?&gt;&lt;/span&gt;&lt;/div&gt; &lt;?php ;}
                            else { ?&gt;
								&lt;div class='sft-gridview-price'&gt;&lt;span class='sft-gridview-price-text'&gt; &lt;?php echo e_('Out of stock', 'storefront'); ?&gt; &lt;/span&gt;&lt;/div&gt;&lt;?php ;}
								}?&gt;
</pre>
</div>
<p>Save the file.<br />
Congratulations, your done.<br />
If you need  to change the message just change &#8216;Out of stock&#8217; to anything you want. It is just text. Wondering what all that echo e_(&#8216;Out of stock&#8217;, &#8216;storefront&#8217;) is about? Well you could in fact just write Out of stock there and it would work fine. That extra code makes &#8216;Out of stock&#8217; available to translation plugins.</p>
<div  class ="note-panel">
<h4>Tools:</h4>
<p>You must use an appropriate code editor NOT microsoft word or anything like that which adds a lot of invisible formatting and will be a disaster.<br />
If you do not have one, 2 excellent free ones are&#8230;<br />
TextWrangler for Mac, http://www.barebones.com/products/textwrangler/<br />
Notepad++ for the PC http://notepad-plus-plus.org/</p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://gasolicious.com/web-design-wordpress-e-commerce-flash-blog/storefront-elegance-theme-stock/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Paginated search results</title>
		<link>http://gasolicious.com/flash/paginated-search-results/</link>
		<comments>http://gasolicious.com/flash/paginated-search-results/#comments</comments>
		<pubDate>Thu, 10 May 2012 13:10:29 +0000</pubDate>
		<dc:creator></dc:creator>
				<category><![CDATA[Flash]]></category>

		<guid isPermaLink="false">http://gasolicious.com/?p=1617</guid>
		<description><![CDATA[Check out this link http://design.sparklette.net/teaches/how-to-add-wordpress-pagination-without-a-plugin/ I think it is a very nice solution for what you want, and it looks good in the theme as is. STEP 1 To avoid issues implementing this I suggest a couple of changes. In the code to add to functions.php change the class name to avoid any clash with [...]]]></description>
			<content:encoded><![CDATA[<p>Check out this link http://design.sparklette.net/teaches/how-to-add-wordpress-pagination-without-a-plugin/<br />
I think it is a very nice solution for what you want, and it looks good in the theme as is.</p>
<p>STEP 1<br />
To avoid issues implementing this I suggest a couple of changes. In the code to add to functions.php change the class name to avoid any clash with WP e-Commerce pagination<br />
For example `class=\&#8221;pagination-search\`<br />
STEP 2<br />
Then change all the .pagination in the CSS to .pagination-search<br />
STEP 3<br />
Not a change just the location<br />
The last 3 lines of search.php in the Mylo folder should be</p>
<div class ="myCode">
<pre class="brush: php; first-line: 133; title: ; notranslate">
&lt;/div&gt;

&lt;/div&gt;&lt;!-- end Container 12 --&gt;

&lt;?php get_footer(); ?&gt;
</pre>
</div>
<p>Put the code from step 3 right above those 3 lines</p>
<p>*********************</p>
<p>That will get you pagination. It will be one post per page as your blog is set. To return a certain number of results per page ignoring the reading setting you need to add this line of code in 2 places in search.php<br />
This is the line, change the number to what you want</p>
<div class ="myCode">
<pre class="brush: php; first-line: 27; title: ; notranslate">query_posts(&quot;$query_string . '&amp;posts_per_page=2'&quot;);</pre>
</div>
<p>Put it after this line, which is around 26</p>
<div class ="myCode">
<pre class="brush: php; first-line: 26; title: ; notranslate">query_posts($query_string . &quot;&amp;post_type=wpsc-product&quot; );</pre>
</div>
<p>and after this line which is around line 81</p>
<div class ="myCode">
<pre class="brush: php; first-line: 81; title: ; notranslate">query_posts($query_string . &quot;&amp;post_type=post&quot;);</pre>
</div>
<p>Just to be clear you will end up with something that looks like this each time except for post_type=post or wpsc-product</p>
<div class ="myCode">
<pre class="brush: php; first-line: 79; title: ; notranslate">
&lt;?php
		global $query_string; // grab the search query
                query_posts($query_string . &quot;&amp;post_type=post&quot;);
		query_posts(&quot;$query_string . '&amp;posts_per_page=2'&quot;);
		?&gt;
		&lt;?php if (have_posts()) : ?&gt;
</pre>
</div>
]]></content:encoded>
			<wfw:commentRss>http://gasolicious.com/flash/paginated-search-results/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Add a widget area to you WordPress theme.</title>
		<link>http://gasolicious.com/web-design-wordpress-e-commerce-flash-blog/widget-wordpress-theme/</link>
		<comments>http://gasolicious.com/web-design-wordpress-e-commerce-flash-blog/widget-wordpress-theme/#comments</comments>
		<pubDate>Mon, 23 Apr 2012 08:00:53 +0000</pubDate>
		<dc:creator></dc:creator>
				<category><![CDATA[Blog]]></category>
		<category><![CDATA[Gridport]]></category>
		<category><![CDATA[Storefront Themes]]></category>
		<category><![CDATA[Themes]]></category>
		<category><![CDATA[Wordpress]]></category>

		<guid isPermaLink="false">http://gasolicious.com/?p=1594</guid>
		<description><![CDATA[You need to modify the theme PHP for this. You will need to maintain these changes in any theme update, so keep a record. These instructions are for adding a widget area to the header of the Storefront themes Gridport Theme. The principals are the same for any theme and location though. This is pretty [...]]]></description>
			<content:encoded><![CDATA[<p>You need to modify the theme PHP for this. You will need to maintain these changes in any theme update, so keep a record.<br />
These instructions are for adding a widget area to the header of the Storefront themes Gridport Theme. The principals are the same for any theme and location though.<br />
This is pretty simple PHP editing, so even if you have never done it before jump in, get your feet wet. remember keep a safe copy of the files somewhere. You can always just restore the originals if you break something. See the notes on editing PHP at the end of this post.</p>
<h4>Creating the sidebar</h4>
<p>All widget areas are called sidebars whether on the side or not.<br />
You will be looking for the code that registers the existing sidebars, it will look like this</p>
<div class ="myCode">
<pre class="brush: php; first-line: 545; title: ; notranslate">
if ( function_exists('register_sidebar') )
</pre>
</div>
<p>Note that in most themes you will find this code in functions.php</p>
<p>In the Gridport theme folder open &#8216;theme-functions.php&#8217;. Find the code below. Starting around around line 545 you should find this which registers the last of the 4 footer widget areas.</p>
<div class ="myCode">
<pre class="brush: php; first-line: 545; title: ; notranslate">
if ( function_exists('register_sidebar') )

    register_sidebar(array(

    	'name'=&gt;'Footer 4',

        'before_widget' =&gt; '',

        'after_widget' =&gt; '',

        'before_title' =&gt; '&lt;h4&gt;',

        'after_title' =&gt; '&lt;/h4&gt;',

    ));
</pre>
</div>
<p>Copy all of that block and paste a copy right below it.<br />
Change &#8216;Footer 4&#8242; to &#8216;Header spot&#8217;<br />
Save the file.<br />
Congratulations, you have created a new sidebar! Go to the Appearance/Widgets area and you should see a new panel titled Header spot. You can add widgets but at this stage they will not appear on your site.</p>
<h4>Now you need to add the sidebar to the theme</h4>
<p>Just to be clear again, these instructions are for adding a sidebar to the header of the Gridport theme. For other themes and locations the principals are the same.</p>
<p>So in Gridport theme folder open header.php.and find the highlighted line around line 75. Add the rest of the code below right after line 75 as shown</p>
<div class ="myCode">
<pre class="brush: php; first-line: 75; highlight: [75]; html-script: true; title: ; notranslate">
&lt;/div&gt;&lt;!-- end of header-left --&gt;
&lt;div class=&quot;clear&quot;&gt;&lt;/div&gt;
&lt;div id=&quot;header-spot&quot;&gt;
&lt;?php if ( !function_exists('dynamic_sidebar') ||
           !dynamic_sidebar('Header spot') ) : ?&gt;
  This is where the Header spot Sidebar appears, This will be displayed only if the sidebar is empty
&lt;?php endif; ?&gt;&lt;/div&gt;
&lt;div class=&quot;clear&quot;&gt;&lt;/div&gt;
</pre>
</div>
<p>Save.<br />
You will now see that line of text &#8220;This is where the Header spot appears&#8230;.&#8221; in your site. Remove that line if you want nothing to appear when there are no widgets.<br />
Go to Appearance/Widgets in WordPress .<br />
Add a widget to your new &#8220;Header spot&#8221; widget area. Add 2 or 3 if you like.</p>
<div  class ="note-panel">
<h4>NOTE:</h4>
<p>I was asked if this could be done just on the Gridport Homepage. You can apply these concepts anywhere. As I answered that question already I may as well add the instructions here. This adds the content to just the homepage.<br />
The code above that you to add to header.php you would add to the tpl_home_products.php instead.<br />
You add it right AFTER this line which should be line 7</p>
<div class ="myCode">
<pre class="brush: php; first-line: 7; title: ; notranslate">&lt;?php get_header(); ?&gt;</pre>
</div>
</div>
<p>You can then style it with the id in the code using CSS such as</p>
<div class ="myCode">
<pre class="brush: css; first-line: 1; title: ; notranslate">
#header-spot{
width:30%;
height:200px;
display:block;
background:#666666;
}
</pre>
</div>
<h4>Why did you call it Header spot? that&#8217;s a strange name.</h4>
<p>Ok now there is one more bit which is optional. The original request for help with this was from someone who wanted to add designed content to the header, not just a calendar or some other basic widget.<br />
If you want to have really good control over what appears there, rather than just a simple text widget, I suggest you install the &#8220;spots&#8221; plugin<br />
This will give you a custom post type you can add to the area as a widget.<br />
You will get a full editing page just like posts/pages/products for &#8216;spots&#8217;, You can have text, images etc all with the full wysywig editor. You then assign a spot to a widget and add it to the Header Spot sidebar you just created. This way you can easily create new posts for the header, keep your old ones etc. Want to change the header content? Just drag the existing spot widget out of the widget area, add a new one and assign a different spot post.<br />
Get the &#8216;Spots&#8217; plugin by searching &#8220;spots&#8221; in the plugins page, it is By Robert O&#8217;Rourke.<br />
You can read more about Spots at the <a href="http://interconnectit.com/2364/announcing-spots/" title="interconnect Web site post about their WordPress Spots plugin" target="_blank">interconnect site</a>. There is another <a href="http://interconnectit.com/2906/spots-for-wordpress-developer-notes/" title="interconnect post for developers on their WordPress plugin Spots" target="_blank">post for developers</a><br />
<br/></p>
<div  class ="note-panel">
<h4>Tools:</h4>
<p>You must use an appropriate code editor NOT microsoft word or anything like that which adds a lot of invisible formatting and will be a disaster.<br />
If you do not have one, 2 excellent free ones are&#8230;<br />
TextWrangler for Mac, http://www.barebones.com/products/textwrangler/<br />
Notepad++ for the PC http://notepad-plus-plus.org/</p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://gasolicious.com/web-design-wordpress-e-commerce-flash-blog/widget-wordpress-theme/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Storefront Edge theme, change homepage Latest Products thumbnail size.</title>
		<link>http://gasolicious.com/web-design-wordpress-e-commerce-flash-blog/storefront-edge-change-homepage/</link>
		<comments>http://gasolicious.com/web-design-wordpress-e-commerce-flash-blog/storefront-edge-change-homepage/#comments</comments>
		<pubDate>Sun, 15 Apr 2012 11:29:24 +0000</pubDate>
		<dc:creator></dc:creator>
				<category><![CDATA[Blog]]></category>
		<category><![CDATA[Edge]]></category>
		<category><![CDATA[Storefront Themes]]></category>
		<category><![CDATA[post thumbnail]]></category>
		<category><![CDATA[Storefront]]></category>
		<category><![CDATA[thumbnail]]></category>

		<guid isPermaLink="false">http://gasolicious.com/?p=1564</guid>
		<description><![CDATA[Why are the thumbnails in the Homepage Latest Products grid badly cropped? Storefront themes Edge theme has two possible home page layouts. The Homepage #2 Template has a grid area below the slider titled &#8220;Latest Products&#8221;. This displays a grid of thumbnails showing, you guessed it, the most recently added products. Max 2 rows of [...]]]></description>
			<content:encoded><![CDATA[<h4>Why are the thumbnails in the Homepage Latest Products grid badly cropped?</h4>
<p>Storefront themes Edge theme has two possible home page layouts. The Homepage #2 Template has a grid area below the slider titled &#8220;Latest Products&#8221;. This displays a grid of thumbnails showing, you guessed it, the most recently added products. Max 2 rows of 3 thumbnails. The problem is these are hard coded to be 140&#215;140 pixels which can cause some pretty ugly cropping in a high visibility area if your product images are not square. So how to change this? Luckily this is easy.</p>
<p>Locate the <strong>home_template.php</strong> file which is in Edge theme folder. Make a safe copy somewhere in case you have problems. Really this one is so easy you could just do the edit by going to Appearance/Editor in WordPress, and clicking home_template.php on the file list.<br />
Around line 89 in Edge 1.0.5 you will find two numbers that set the width and height for these thumbnails. I have included enough code so you can find the correct section. The line numbers may vary slightly depending on your version.</p>
<div class ="myCode">
<pre class="brush: php; first-line: 89; title: ; notranslate">
		$width = '140';

		$height = '140';

	$latest_products = get_posts( array(
		'post_type'   =&gt; 'wpsc-product',
</pre>
</div>
<p>Change the numbers to suit your product images. You can use the <a href="http://andrew.hedges.name/experiments/aspect_ratio/" title="online aspect ratio calculator" target="_blank">handy online aspect ratio calculator</a> to work out the size. I suggest you stick with 140 wide and adjust the height. Web page layout is more flexible for height changes than width. For example if your single product page images are 300 wide x 400 high, to retain the same aspect ratio and keep the width of 140 pixels, you would use a height of 187 pixels.</p>
<p>The thumbnails will actually be regenerated at the new size when you reload the page, not just stretched by CSS!</p>
]]></content:encoded>
			<wfw:commentRss>http://gasolicious.com/web-design-wordpress-e-commerce-flash-blog/storefront-edge-change-homepage/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Translating Storefront Themes</title>
		<link>http://gasolicious.com/web-design-wordpress-e-commerce-flash-blog/translating-storefront-themes/</link>
		<comments>http://gasolicious.com/web-design-wordpress-e-commerce-flash-blog/translating-storefront-themes/#comments</comments>
		<pubDate>Sat, 14 Apr 2012 14:20:19 +0000</pubDate>
		<dc:creator></dc:creator>
				<category><![CDATA[Blog]]></category>
		<category><![CDATA[Echo]]></category>
		<category><![CDATA[Gridport]]></category>
		<category><![CDATA[Translation]]></category>
		<category><![CDATA[Wordpress]]></category>
		<category><![CDATA[WP e-Commerce]]></category>
		<category><![CDATA[international]]></category>
		<category><![CDATA[internationalization]]></category>
		<category><![CDATA[translation]]></category>

		<guid isPermaLink="false">http://gasolicious.com/?p=1553</guid>
		<description><![CDATA[How to translate a Storefront theme Hi this is the very beginning of an article on translating Storefront Themes e-Commerce themes. I will be adding more detail and screenshots to help soon. I will also start a collection of translated files for download. Volunteer Help out the Storefront community. If you have the skills in [...]]]></description>
			<content:encoded><![CDATA[<h4>How to translate a Storefront theme</h4>
<p>Hi this is the very beginning of an article on translating Storefront Themes e-Commerce themes. I will be adding more detail and screenshots to help soon. I will also start a collection of translated files for download.</p>
<h4>Volunteer</h4>
<p>Help out the Storefront community. If you have the skills in your language please volunteer to create a file for one or more themes via the contact form on this site. Most of theme ar every simple with less than 40 text strings to translate. You can take a file that is already translated and translate it to a new language then save with the correct name for the new language.</p>
<h4> Instructions</h4>
<p>These instructions refer to Gridport Theme but the process is exactly the same for all Storefront themes. Hopefully when updates are released the code change to functions.php will be included.</p>
<p>Your theme does not include many text strings. Most of the things like buttons are handled by the WP e-Commerce plugin. What buttons etc are not translating?<br />
It does have some parts that need translating. I have put up some .po (language) files for translation here.<br />
1.<br />
make a new folder under the theme folder called &#8220;lang&#8221; For example&#8230;<br />
wp-content/themes/storefront-gridport-1.0.6/lang</p>
<p>2.<br />
You can use the <a href="http://www.poedit.net/download.php" title="download link fro PoEdit translation program" target="_blank">free program PoEdit</a> which works on macs and Pc&#8217;s to translate your file<br />
You need to translate then save to the lang folder (or save and copy there) The program will make a .po and .mo file when you save. The .mo is the one that is actually read by WordPress. You need to name your file with the right language and country code. The not translated file I am supplying is named for French. Just change to the right name for your language.  You can find the country and language codes here.<br />
<a href="http://www.gnu.org/software/gettext/manual/html_chapter/gettext_16.html#Language-Codes" title="WordPress language codes" target="_blank">Language codes</a><br />
<a href="http://www.gnu.org/software/gettext/manual/html_chapter/gettext_16.html#Country-Codes" title="WordPress country codes" target="_blank">Country codes</a></p>
<p>There is some information on <a href="http://www.wpexplorer.com/localize-translate-your-wordpress-themes" title="make a wordpress theme translatable" target="_blank">translating with PoEdit here</a> with screen shots. You do not need to worry about the PHP code etc in the first part of the article. Just Step 5.</p>
<p>3.<br />
You also need to add a function to the themes functions.php file.</p>
<p>In the theme folder find functions.php and open it for editing. You can do this by going to Appearance/Editor and opening it from the file list as the change is very simple. Right BEFORE the very last line which is ?><br />
add this</p>
<div class ="myCode">
<pre class="brush: php; first-line: 56; title: ; notranslate">
/* Make Gridport available for translation.
	 * Translations can be added to the /lang/ directory.
	 */
	load_theme_textdomain( 'storefront', TEMPLATEPATH . '/lang' );
</pre>
</div>
<p>Make sure you have no blank lines or spaces at the end of the file and save.</p>
<p>In your site you may need to change your wp-config.php, which is in your WordPress install root directory file, to state your language It is probably already there if you have other translations working. Below is the line you change with the codes for French added.<br />
You probably already know your countries codes.</p>
<p>define (&#8216;WPLANG&#8217;, &#8216;fr_FR&#8217;);</p>
<p>There may still be some small issues with the translation files, I am not sure about some of the plural translation codes, it should be close. Let me know if you see any problems. If you translate it please get in touch via http://gasolicious.com/contact/<br />
I will try and build up a collection of translated .po files for different languages for all of the Storefront themes. If you are really good with languages please help by volunteering to translate some other themes .po files</p>
<h4>Translation files</h4>
<p><a href="http://gasolicious.com/wp-content/uploads/2012/04/gridport-1-0-6-translation.zip" title=".po file for Storefront Themes Gridport theme, not translated">Gridport theme version 1.0.6. Not translated.</a></p>
<p><a href="http://gasolicious.com/wp-content/uploads/2012/04/Echo-1-4-1-French-translation.zip" title="Link to .po translation file French Storefront Echo theme" target="_blank">Echo theme version 1.4.1 French translation</a></p>
]]></content:encoded>
			<wfw:commentRss>http://gasolicious.com/web-design-wordpress-e-commerce-flash-blog/translating-storefront-themes/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Add an Accordion menu for mobile devices to the Storefront Echo theme</title>
		<link>http://gasolicious.com/storefront-themes/storefront-echo-theme-mobile-menu/</link>
		<comments>http://gasolicious.com/storefront-themes/storefront-echo-theme-mobile-menu/#comments</comments>
		<pubDate>Sat, 14 Apr 2012 10:57:34 +0000</pubDate>
		<dc:creator></dc:creator>
				<category><![CDATA[Echo]]></category>
		<category><![CDATA[Storefront Themes]]></category>
		<category><![CDATA[Themes]]></category>

		<guid isPermaLink="false">http://gasolicious.com/?p=1525</guid>
		<description><![CDATA[My menus go off the screen, how can I have a multi-level menu on a small screen? Storefronts Echo theme is designed to be responsive as the current hip jargon goes. That is to say the layout changes to adapt to different devices and screen sizes. Designing for small screens, meaning mobile devices means juggling [...]]]></description>
			<content:encoded><![CDATA[<h4>My menus go off the screen, how can I have a multi-level menu on a small screen?</h4>
<p>Storefronts Echo theme is designed to be responsive as the current hip jargon goes. That is to say the layout changes to adapt to different devices and screen sizes. Designing for small screens, meaning mobile devices means juggling various priorities. When Echo was first released it only supported one level of menu, which seemed like a reasonable thing for working on mobile devices. Still people wanted multiple level menu support, so it was added. Then came the inevitable &#8220;why does my multiple level menu go off the screen.&#8221; Well obviously because the screen is very small is the answer, but what to do about it?</p>
<p>This may be a reasonable solution. I have yet to subject it to testing. It will do no harm and is easily removed, so give it a try, let me know in the comments if it works. As the title says this will require two components, a plugin and some code. Three if you want  to count the PHP and CSS code as separate items! This is quite easy even if you have never edited PHP before.</p>
<h4>First the plugin</h4>
<p>You will need to install the <a href="http://wordpress.org/extend/plugins/jquery-vertical-accordion-menu/" title="JQuery Accordion Menu Widget page at WordPress.org" target="_blank">JQuery Accordion Menu Widget</a>. Quite a mouthful. You can install from the WordPress plugins page as normal. Search for it by that exact name in the WordPress plugins page. You have the right one if it is made by Lee Chestnutt.<br />
For information on plugin installation, parameters and usage see <a href="http://www.designchemical.com/blog/index.php/wordpress-plugins/wordpress-plugin-jquery-vertical-accordion-menu-widget/" title="Instruction page for JQuery Accordion menu widget plugin" target="_blank">the plugin makers site</a>. </p>
<h4>OK it is installed, now what?</h4>
<p>So yet again it is time to make a little PHP change to add some functionality. One extremely simple PHP edit. If you have not done this before see the note &#8220;Tools&#8221; at the bottom of this post.</p>
<p>Locate the <strong>header.php</strong> file which is in Echo theme folder. Make a safe copy somewhere in case you have problems.<br />
Around line 98 in Echo 1.4.1 you will find a lot of divs being closed. I have included enough code so you can find the correct section. The line may vary slightly depending on your version. Find the right closing div, in this case line 98.</p>
<div class ="myCode">
<pre class="brush: php; first-line: 93; highlight: [98]; title: ; notranslate">
				&lt;?php get_search_form(); ?&gt;
				&lt;/div&gt;
			&lt;?php } ?&gt;
			&lt;div class=&quot;clear&quot;&gt;&lt;/div&gt;
			&lt;/div&gt;
		&lt;/div&gt;
		&lt;/div&gt;
		&lt;div class=&quot;clear&quot;&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;div id=&quot;main&quot;&gt;
</pre>
</div>
<p>Make a blank line after it and add the line of code highlighted as line 99 below. I have included the block of code from above to be clear. You are adding just the one highlighted line.</p>
<div class ="myCode">
<pre class="brush: php; first-line: 93; highlight: [99]; title: ; notranslate">
&lt;?php get_search_form(); ?&gt;
				&lt;/div&gt;
			&lt;?php } ?&gt;
			&lt;div class=&quot;clear&quot;&gt;&lt;/div&gt;
			&lt;/div&gt;
		&lt;/div&gt;
                &lt;div id=&quot;mobile-menu&quot;&gt;&lt;?php echo do_shortcode('[dcwp-jquery-accordion menu=&quot;MyMenu&quot; save=&quot;true&quot; expand=&quot;true&quot; animation=&quot;fast&quot; skin=&quot;graphite&quot;]'); ?&gt;&lt;/div&gt;
		&lt;/div&gt;
		&lt;div class=&quot;clear&quot;&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;div id=&quot;main&quot;&gt;
</pre>
</div>
<p>This adds the JQuery Accordion Menu to the theme. You must substitute the name of your WordPress  custom menu for &#8220;MyMenu&#8221; in the code above. You could have two custom menus in WordPress and choose to display a different one in the code above for small screens and another on larger screens.<br />
You will notice several options after the menu name.</p>
<h5>save=&#8221;true&#8221;</h5>
<p>Setting this allows the menu to remember its open/close state when browsing to a new page. It requires cookies. This way when a top level menu item is clicked the site will navigate to that page but keep the menu open. Remember mobile devices do not support hover. As I mentioned you could have a different menu for this by setting up a second menu in WordPress. You could avoid the page change when a top level item is clicked to reveal the sub menu by setting up non-navigating clickable top level items. Make a custom menu item and use the # tag as the menu URL. See my <a href="http://gasolicious.com/web-design-wordpress-e-commerce-flash-blog/wordpress-ecommerce-create-custom/" title="Creating Custom WordPress menus">custom menu post video</a>.</p>
<h5>animation=&#8221;fast&#8221;</h5>
<p>The speed at which the menu will open/close, your options are slow/normal/fast</p>
<h5>skin=&#8221;graphite&#8221;</h5>
<p>This is the CSS style. Graphite matches Echo very nicely. You can of course customize it with extra CSS or even write your own. The built in options are black/blue/clean/demo/graphite/grey</p>
<p>You can control several more options, these are I believe the best settings for the menu in this situation.</p>
<div  class ="note-panel">
<h4>JQuery Accordion Menu Widget plugin:</h4>
<p>Remember as the name implies this menu is a widget. You can also add it to any widget location in the normal manner in the WordPress Appearance/Widgets screen. You can also add it in the body of a post or page using a shortcode</p>
</div>
<p><br/></p>
<h4>Style it you said?</h4>
<p>Well actually we will not just style it with CSS we will control it as well. The menu has been added in a div with id &#8220;mobile-menu&#8221; Using media queries in CSS we can turn it on and off according to the size of the users screen. What size you use exactly is up to you, but below I am supplying some options. One would work well on iphone1, 2 and 3 (320 × 480 pixels), the other would include the menu on iphone 4 and 4S (640 × 960) as well, this may even include some small and old computers. For more on CSS Media Queries <a href="http://reference.sitepoint.com/css/mediaqueries" title="Article on CSS media Queries" target="_blank">read this article</a>, also searching will turn up lots of information.</p>
<p>I decided to keep the Cart $0.00 value display from the themes menu. Remember to show the cart in the menu you need to go to Storefront Options Panel/Navigation Tab and check &#8220;Show cart total tab in navigation?&#8221; As I was keeping that bar I decided also to do away with the free floating mobile search of the theme and retain the regular menu bar search on small screens. There is plenty of room for it with all of the normal menu items removed. Again you must have Search turned on in Storefront Options Panel/Navigation Tab.</p>
<p>The CSS code can be added to your custom.css file if you have one, or if you do not have much CSS just add it to the Storefront Options Panel/Style Tab Custom CSS box.</p>
<p>Under 540 will cover iPhone 1, 2 and 3 in both landscape and portrait mode</p>
<div class ="myCode">
<pre class="brush: css; title: ; notranslate">
/*if screen is below 540 wide*/
@media handheld, only screen and (max-width: 540px) {
#nav{display:none;}/*hide the regular menu*/
.mobilesearch{display:none !important;}/*hide the the themes mobile search*/
.navsearch{display:block !important;}/*show the regular search in theme menu*/
}
/*over 540 pixels wide*/
@media handheld, only screen and (min-width: 541px) {
#mobile-menu{display:none;}/*hide the JQuery menu*/
}
</pre>
</div>
<p>Change the numbers to 767 and 768 to make this work on iPhones up to the 4S in portrait mode. If you want to include landscape mode you will need to go with 960 and 961 but this will include quite a few computers.</p>
<h4>OK it is controlled now how about some style?</h4>
<p>You can style the menu, I am not going to get into all of the CSS here. If you are not happy with any of the inbuilt styles you need to learn some CSS and get to work. I did think one basic change was worth making. Adding the CSS below will make the height of the Accordion menu more closely match the height of the regular Echo menu. Be aware that the background of the Accordion menu is images. You would need to download the appropriate png file and alter it to change the color. In the case of the graphite style it is in the plugin folder skins/images/bg_black.png.</p>
<p>You must substitute the name of your menu in place of MyMenu, the plugin creates this class which includes your menus name. Watch out as the CSS is case sensitive. Although the custom menu is called MyMenu in the WordPress backend the plugin will write the class to the page all in lowercase. Use the real name MyMenu and it will not work.</p>
<div class ="myCode">
<pre class="brush: css; title: ; notranslate">
/*set height of menu items*/
.menu-mymenu-container {
  line-height:30px;
margin:bottom:25px;
}
/*add a little space belwo menu if you like it */
#mobile-menu {
     margin-bottom: 25px;
}
</pre>
</div>
<div  class ="note-panel">
<h4>Tools:</h4>
<p>For PHP editing you must use an appropriate code editor NOT microsoft word or anything like that which adds a lot of invisible formatting and will be a disaster.<br />
If you do not have one, 2 excellent free ones are&#8230;<br />
TextWrangler for Mac, http://www.barebones.com/products/textwrangler/<br />
Notepad++ for the PC http://notepad-plus-plus.org/</p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://gasolicious.com/storefront-themes/storefront-echo-theme-mobile-menu/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>WP e-Commerce add the Variation price to the Variation selector</title>
		<link>http://gasolicious.com/web-design-wordpress-e-commerce-flash-blog/commerce-variation-price-variation/</link>
		<comments>http://gasolicious.com/web-design-wordpress-e-commerce-flash-blog/commerce-variation-price-variation/#comments</comments>
		<pubDate>Sun, 08 Apr 2012 12:51:23 +0000</pubDate>
		<dc:creator></dc:creator>
				<category><![CDATA[Blog]]></category>
		<category><![CDATA[E-Commerce]]></category>
		<category><![CDATA[Echo]]></category>
		<category><![CDATA[Storefront Themes]]></category>
		<category><![CDATA[WP e-Commerce]]></category>

		<guid isPermaLink="false">http://gasolicious.com/?p=1509</guid>
		<description><![CDATA[The question &#8220;Is there was a way to display the price of each variation next to it in the drop down menu, that would be great?&#8221; I actually thought this would be quite difficult and involve hacking on the core plugin files. I hunted around in the plugin files without any luck. Then I took [...]]]></description>
			<content:encoded><![CDATA[<h4>The question</h4>
<p>&#8220;Is there was a way to display the price of each variation next to it in the drop down menu, that would be great?&#8221;</p>
<p>I actually thought this would be quite difficult and involve hacking on the core plugin files. I hunted around in the plugin files without any luck. Then I took a look at the single product page and realized it was really easy and could be accomplished in the theme. The instructions below are specifically for the <a href="http://storefrontthemes.com/themes/" title="Storefront Themes, themes for e-commerce" target="_blank">Storefront Themes</a> Echo theme, but should work with most WP e-Commerce themes. The line numbers will of course vary but the code should be very similar even identical.</p>
<p>Locate the <strong>wpsc-single_product.php</strong> file which is in the Echo theme folder. Make a safe copy somewhere in case you have problems. If you have never edited PHP before don&#8217;t worry this edit is a simple cut and paste, jump in! See the note at the end for good free tools to do this.</p>
<p>Find the code highlighted below. The example is from Echo version 1.4.1, you should be able to find it easily in any version.</p>
<div class ="myCode">
<pre class="brush: php; first-line: 131; highlight: [134]; title: ; notranslate">
										&lt;?php /** the variation HTML and loop */?&gt;
										&lt;td class=&quot;col2&quot;&gt;&lt;select class=&quot;wpsc_select_variation&quot; name=&quot;variation[&lt;?php echo wpsc_vargrp_id(); ?&gt;]&quot; id=&quot;&lt;?php echo wpsc_vargrp_form_id(); ?&gt;&quot;&gt;
										&lt;?php while (wpsc_have_variations()) : wpsc_the_variation(); ?&gt;
											&lt;option value=&quot;&lt;?php echo wpsc_the_variation_id(); ?&gt;&quot; &lt;?php echo wpsc_the_variation_out_of_stock(); ?&gt;&gt;&lt;?php echo wpsc_the_variation_name(); ?&gt;&lt;/option&gt;
										&lt;?php endwhile; ?&gt;
										&lt;/select&gt;&lt;/td&gt;&lt;/tr&gt;
									&lt;?php endwhile; ?&gt;
</pre>
</div>
<p>You just need to add space colon space after the variation name for looks and then the variable for the variation price. The change is to line 134, below is the new line you can find the change by looking for the colon, the change is remarkably simple. You can just copy and paste this line to replace the entire existing line 134.</p>
<div class ="myCode">
<pre class="brush: php; first-line: 134; title: ; notranslate">
&lt;option value=&quot;&lt;?php echo wpsc_the_variation_id(); ?&gt;&quot; &lt;?php echo wpsc_the_variation_out_of_stock(); ?&gt;&gt;&lt;?php echo wpsc_the_variation_name(); ?&gt; : &lt;?php echo wpsc_the_variation_price(); ?&gt;&lt;/option&gt;
</pre>
</div>
<p></p>
<div  class ="note-panel">
<h4>Tools:</h4>
<p>You must use an appropriate code editor NOT microsoft word or anything like that which adds a lot of invisible formatting and will be a disaster.<br />
If you do not have one, 2 excellent free ones are&#8230;<br />
TextWrangler for Mac, http://www.barebones.com/products/textwrangler/<br />
Notepad++ for the PC http://notepad-plus-plus.org/</p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://gasolicious.com/web-design-wordpress-e-commerce-flash-blog/commerce-variation-price-variation/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Creating a cufon font</title>
		<link>http://gasolicious.com/web-design-wordpress-e-commerce-flash-blog/creating-cufon/</link>
		<comments>http://gasolicious.com/web-design-wordpress-e-commerce-flash-blog/creating-cufon/#comments</comments>
		<pubDate>Fri, 06 Apr 2012 07:17:24 +0000</pubDate>
		<dc:creator></dc:creator>
				<category><![CDATA[Blog]]></category>
		<category><![CDATA[Cufon]]></category>
		<category><![CDATA[Storefront Themes]]></category>
		<category><![CDATA[Wordpress]]></category>

		<guid isPermaLink="false">http://gasolicious.com/?p=1475</guid>
		<description><![CDATA[What the heck is Cufón? Cufón consists of two individual parts – a font generator, which converts fonts to a proprietary format and a rendering engine written in JavaScript that renders them on your Web site. Cufón allows web developers to use non standard web fonts on their sites without worrying if the end user [...]]]></description>
			<content:encoded><![CDATA[<h4>What the heck is Cufón?</h4>
<p>Cufón consists of two individual parts – a font generator, which converts fonts to a proprietary format and a rendering engine written in JavaScript that renders them on your Web site. Cufón allows web developers to use non standard web fonts on their sites without worrying if the end user has that font on their computer. </p>
<p>You can make your own Cufón fonts or download some ready made ones.<br />
<a href="http://cufon.shoqolate.com/generate/" title="official cufon font generator and documentation" target="_blank">Make your own Cufón fonts, it is super easy.</a><br />
<a href="http://www.cufonfonts.com/" title="Download fonts that have already been converted to Cufon" target="_blank">Get some already Cufónized fonts here.</a></p>
<p>First you should consider do you even need one?<br />
<a href="http://www.webdesigndev.com/web-development/16-gorgeous-web-safe-fonts-to-use-with-css" title="16 Gorgeous web safe fonts to use with CSS" target="_blank">Maybe you could just use a standard web font and avoid all of this, what are the standard fonts? Read 16 gorgeous web fonts.</a></p>
<h4>You said it was super easy, for you maybe, how do I make one?!</h4>
<p>You need to know <a href="http://unicode.org/charts/" title="Character set Charts" target="_blank">what character sets are</a>. The basic Character set for English is known as Latin.<br />
Then you have&#8230;<br />
Latin extended supplement, or often just called Latin Extended<br />
Latin Extended A<br />
Latin Extended B<br />
Latin Extended C<br />
Latin Extended D<br />
Greek Extended<br />
Cyrillic Supplement<br />
Cyrillic Extended-A<br />
Cyrillic Extended-B</p>
<p>These are the ones that cover most European languages. Remember not all fonts contain all characters.</p>
<p>First make sure you have your font on your local computer, you need to have the font to make a cufon version. There are lots of font sites where you can download fonts, many are free. Check to see if it has the characters you want. Different operating systems have different ways of viewing all of the characters in a font. Or just try typing the characters into a word processing program in that font. Do they work? If they do you are good to go. If not search the web, see if you can find a version with a more complete character set.</p>
<div  class ="note-panel">
<h4>Storefront Themes Fonts</h4>
<p>There are two main reasons you may want to make a cufon font, because you want to use a new font or because the included font does not include some special characters that your language requires, for example È or Æ. If you are using a WordPress theme by Storefront Themes then your font is available online for free, search for it by name, you should not have trouble locating it. See the end of this post for a few I have already made into cufon with extended character sets.</p>
</div>
<p><br/></p>
<h4>Making the font</h4>
<p>The next step is to make the cufon font. Go to <a href="http://cufon.shoqolate.com/generate/" title="the official cufon font site" target="_blank">the cufon font site.</a></p>
<h5>On that page Section 1. &#8220;Select the font you&#8217;d like to use&#8221;</h5>
<p>You will be asked to upload your font and make various choices.<br />
First select the regular font and upload from your computer. Then decide if you need bold, italic etc versions and upload if you do. If you will not, leave them out and keep the file smaller.<br />
Ignore the text box. Confirm you have a licence by checking the box, you do right!</p>
<h5>Section 2. &#8220;Include the following glyphs (if available)&#8221;</h5>
<p>Select what Character sets you need to include. Do not include All, it will be a really big file which your users will not appreciate.<br />
You can select Basic Latin to get all of the basic Uppercase, Lowercase, Numerals, Punctuation. Then you need to choose what extended character sets you want. How do you know? <a href="http://unicode.org/charts/" title="Character set Charts" target="_blank">Check out these references</a> click a set to see what characters it includes. Check only the sets you need. If it is really only a couple of extra characters you need you can just select basic Latin and then enter those extra characters in the &#8220;add also these single characters &#8221; box</p>
<h5>Section 3. &#8220;Security&#8221;</h5>
<p>Add your domain to limit the file for use there.</p>
<h5>Section 4. &#8220;Performance and file size&#8221;</h5>
<p>Leave it at defaults.</p>
<h5>Section 5. &#8220;Customization (for 3rd-party scripts only)&#8221;</h5>
<p>Leave it default which is&#8230;<br />
Cufon.registerFont</p>
<h5>Section 6. &#8220;Terms&#8221;</h5>
<p>Check the box to Acknowledge.</p>
<p>Now you have done all of that click the &#8220;Let&#8217;s do this!&#8221; button. There will be a short wait and then a file will download to your computer. It will have the file extension .js. This is your cufon font file. I told you it was easy.</p>
<p>Add it to your theme. This is a a whole different topic. Some stuff to get you started can be found <a href="http://gasolicious.com/web-design-wordpress-e-commerce-flash-blog/cufon-storefront-gridport-theme/" title="How to add cufon fonts to the Storefront Gridport theme" target="_blank">here</a> which is specific to Storefronts Gridport Theme. It does give you a general idea though and includes links to more information. If you want to test your new font using a lot of the special characters at once <a href="http://www.alanwood.net/demos/ent4_frame.html" title="font character sets for copy and paste" target="_blank">you can copy and paste whole character sets</a>, drop them into a post and see if the characters render. You may need to wrap them in a heading tag to test in a Storefront theme as they only use cufon in headings.</p>
<div  class ="note-panel">
<h4>Storefront Themes Font downloads</h4>
<p>You will need to add these fonts to the appropriate location according to your theme. Usually they are found in the sub folder &#8220;fonts&#8221; or &#8220;js&#8221;. You need to find the font you wish to replace with your new extended version. Then give your new font the same name. Rename the existing font, for example add -original to the end and put your new font into the folder</p>
<h4>Museo</h4>
<p><a href="http://gasolicious.com/storefront-cufon/Museo_700_600_Basic-Latin-Extended.font.js.zip" title="download cufon Museo Latin and Latin Extended" target="_blank">Museo Latin Basic and Latin Extended.</a> The coverage seems pretty good.  Extended includes Pound and Yen currency symbols by default, I also added Euro.</p>
<p><a href="http://gasolicious.com/wp-content/uploads/2012/04/Museo_700_600_Basic-Latin-Extended-WP-punctuation.zip" title="Museo latin extended and wordpress texturized set" target="_blank">All of the characters in the set above plus</a> the <a href="http://codex.wordpress.org/User:Here/Texturize" title="information on texturized the WordPress punctuation set" target="_blank">WordPress punctuation set (texturized)</a>.</p>
<p><a href="http://gasolicious.com/wp-content/uploads/2012/04/Museo_700_600_Basic-Latin-Extended-A-B-WP-punctuation.zip" title="download cufon Museo Latin and Latin Extended WorePress punctuation Latin A &#038; B" target="_blank">Museo Latin Basic,  Latin Extended, WordPress punctuation, Latin A &#038; B</a> Includes all of the above plus coverage of Latin A is pretty complete, B only has about 5 characters. Museo can also include a couple of Greek characters, some Math operators and more. You can <a href="http://www.fonts2u.com/museo-500.font" title="Museo character set" target="_blank">see what it contains here</a>, although this is not the actual weight used.</p>
<h4>Droid Serif</h4>
<p><a href="http://gasolicious.com/storefront-cufon/Droid_Serif_700.font-Latin-basic-extended.js.zip" title="download cufon Droid serif Latin and Latin Extended" target="_blank">Droid Serif Latin Basic and Latin Extended.</a> The coverage seems pretty good. Extended includes Pound and Yen currency symbols by default, I also added Euro.</p>
<p><a http://gasolicious.com/wp-content/uploads/2012/04/Droid_Serif_700-basic-latin-extended-WP-punctuation.zip" title="Drooid latin extended and wordpress texturized set" target="_blank">All of the characters in the set above plus</a> the <a href="http://codex.wordpress.org/User:Here/Texturize" title="information on texturized the WordPress punctuation set" target="_blank">WordPress punctuation set (texturized)</a>.</p>
<p><a http://gasolicious.com/wp-content/uploads/2012/04/Droid_Serif_700-basic-latin-extended-A-B-WP-punctuation.zip" title="download cufon Droid serif Latin, WordPress punctuation and Latin Extended Latin A &#038; B" target="_blank">Droid serif Latin Basic, Latin Extended, WordPress punctuation and Latin A &#038; B</a> Includes all of the above plus coverage of Latin A is pretty complete, B only has about 10 characters. Droid serif can also include a 75 Greek characters, some Math operators and more. You can <a href="http://www.fonts2u.com/droid-serif-bold.font" title="Droid serif character set" target="_blank">see what it contains here</a>, although this is not the actual weight used.</p>
</div>
<p><br/></p>
]]></content:encoded>
			<wfw:commentRss>http://gasolicious.com/web-design-wordpress-e-commerce-flash-blog/creating-cufon/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

