<?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>Grand Rapids Website Design Blog &#187; Website Design</title>
	<atom:link href="http://www.gr-webdesigns.com/blog/category/website-design/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.gr-webdesigns.com/blog</link>
	<description></description>
	<lastBuildDate>Wed, 14 Jul 2010 19:11:17 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Minify/Compress CSS using PHP</title>
		<link>http://www.gr-webdesigns.com/blog/minify-compress-css-using-php/</link>
		<comments>http://www.gr-webdesigns.com/blog/minify-compress-css-using-php/#comments</comments>
		<pubDate>Mon, 14 Dec 2009 19:05:08 +0000</pubDate>
		<dc:creator>Casey Henry</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[Website Design]]></category>

		<guid isPermaLink="false">http://www.gr-webdesigns.com/blog/?p=94</guid>
		<description><![CDATA[Google recently announced that site speed may be the next ranking factor.  With this in mind I am going to explain how to minify/compress your CSS files using PHP.  Many site use a few different CSS files to format their website, each one of these files requires a HTTP requests which an slow [...]]]></description>
			<content:encoded><![CDATA[<p>Google recently announced that <a href="http://searchengineland.com/site-speed-googles-next-ranking-factor-29793" target="_blank">site speed may be the next ranking factor</a>.  With this in mind I am going to explain how to minify/compress your CSS files using PHP.  Many site use a few different CSS files to format their website, each one of these files requires a HTTP requests which an slow things down.</p>
<p><span id="more-94"></span>First you will need to create a new php file that will act as a CSS files when it is called.</p>
<div class="codecolorer-container php mac-classic" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;"><div class="php codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #666666; font-style: italic;">// Sets the document type to be a CSS files.</span><br />
<span style="color: #990000;">header</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'Content-type: text/css'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #666666; font-style: italic;">// Since the documents is Static I set a future date to expire.</span><br />
<span style="color: #990000;">header</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;Expires: Thu, 15 Apr 2012 20:00:00 GMT&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></div></div>
<p>Now that you have your PHP document setup you need to create a function that will minify your current CSS files.  Minifying your CSS basically means to remove all unnecessary whitespace and symbols.  The function below will do that nicely.</p>
<div class="codecolorer-container php mac-classic" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;"><div class="php codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #000000; font-weight: bold;">function</span> minify<span style="color: #009900;">&#40;</span> <span style="color: #000088;">$css</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><br />
<span style="color: #000088;">$css</span> <span style="color: #339933;">=</span> <span style="color: #990000;">preg_replace</span><span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'#\s+#'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">' '</span><span style="color: #339933;">,</span> <span style="color: #000088;">$css</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #000088;">$css</span> <span style="color: #339933;">=</span> <span style="color: #990000;">preg_replace</span><span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'#/\*.*?\*/#s'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">''</span><span style="color: #339933;">,</span> <span style="color: #000088;">$css</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #000088;">$css</span> <span style="color: #339933;">=</span> <span style="color: #990000;">str_replace</span><span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'; '</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">';'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$css</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #000088;">$css</span> <span style="color: #339933;">=</span> <span style="color: #990000;">str_replace</span><span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">': '</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">':'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$css</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #000088;">$css</span> <span style="color: #339933;">=</span> <span style="color: #990000;">str_replace</span><span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">' {'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'{'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$css</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #000088;">$css</span> <span style="color: #339933;">=</span> <span style="color: #990000;">str_replace</span><span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'{ '</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'{'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$css</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #000088;">$css</span> <span style="color: #339933;">=</span> <span style="color: #990000;">str_replace</span><span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">', '</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">','</span><span style="color: #339933;">,</span> <span style="color: #000088;">$css</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #000088;">$css</span> <span style="color: #339933;">=</span> <span style="color: #990000;">str_replace</span><span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'} '</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'}'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$css</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #000088;">$css</span> <span style="color: #339933;">=</span> <span style="color: #990000;">str_replace</span><span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">';}'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'}'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$css</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<br />
<span style="color: #b1b100;">return</span> <span style="color: #990000;">trim</span><span style="color: #009900;">&#40;</span> <span style="color: #000088;">$css</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span></div></div>
<p>Now that you have your function to minify your CSS you must call your CSS files and have them minified.  The code below will get the contents of the CSS file, minify it, and display it to the browser.</p>
<div class="codecolorer-container php mac-classic" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;"><div class="php codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #666666; font-style: italic;">//Replace text.css with your file</span><br />
<br />
<span style="color: #000088;">$file</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'text.css'</span><span style="color: #339933;">;</span><br />
<span style="color: #000088;">$content</span> <span style="color: #339933;">=</span> <span style="color: #339933;">@</span><span style="color: #990000;">file_get_contents</span><span style="color: #009900;">&#40;</span> <span style="color: #000088;">$file</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #b1b100;">echo</span> minify<span style="color: #009900;">&#40;</span> <span style="color: #000088;">$content</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<br />
<span style="color: #666666; font-style: italic;">//Repeat those three lines of code for each CSS file</span></div></div>
<p>Minifying your CSS file is complete.  Now to compress the file using GZip.</p>
<p>A the beginning of your same PHP file, you need to add this line of code.</p>
<div class="codecolorer-container php mac-classic" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;"><div class="php codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #990000;">substr_count</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$_SERVER</span><span style="color: #009900;">&#91;</span><span style="color: #0000ff;">'HTTP_ACCEPT_ENCODING'</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'gzip'</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #990000;">ob_start</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;ob_gzhandler&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #b1b100;">else</span> <span style="color: #990000;">ob_start</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></div></div>
<p>At the end of your PHP file you need to add this line of code and you are complete.</p>
<div class="codecolorer-container php mac-classic" style="overflow:auto;white-space:nowrap;border: 1px solid #9F9F9F;width:435px;"><div class="php codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #990000;">ob_end_flush</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></div></div>
<p>Now in your main HTML file you need to reference the new PHP file we just created.</p>
<p><code class="codecolorer html4strict mac-classic"><span class="html4strict"><span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">link</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;/FILENAME.PHP&quot;</span> <span style="color: #000066;">rel</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;stylesheet&quot;</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text/css&quot;</span> <span style="color: #000066;">media</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;all&quot;</span> <span style="color: #66cc66;">/</span>&gt;</span></span></code></p>
<p>It may seem weird to link to a PHP files and say it&#8217;s a CSS file but in the first bit of code we wrote, we told the browser that it is a CSS file regardless of the extension.</p>
<p>Using this method on my website I was able to reduce my load time from 2.6 second to 1.46 second, an increase of 46%!  Think about what it can do to your website!</p>
<p>Feel free to ask questions in the comments below.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.gr-webdesigns.com/blog/minify-compress-css-using-php/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Time Spent On A Website</title>
		<link>http://www.gr-webdesigns.com/blog/time-spent-on-a-website/</link>
		<comments>http://www.gr-webdesigns.com/blog/time-spent-on-a-website/#comments</comments>
		<pubDate>Fri, 19 Dec 2008 18:26:20 +0000</pubDate>
		<dc:creator>Casey Henry</dc:creator>
				<category><![CDATA[Website Design]]></category>
		<category><![CDATA[GR Web Designs]]></category>
		<category><![CDATA[Grand Rapids]]></category>
		<category><![CDATA[Grand Rapids Small Business]]></category>
		<category><![CDATA[Helpful Hints]]></category>
		<category><![CDATA[Information]]></category>
		<category><![CDATA[Local Businesses]]></category>

		<guid isPermaLink="false">http://www.gr-webdesigns.com/blog/?p=65</guid>
		<description><![CDATA[How long do you spend looking at a page on a website.  For the average user, they will spend less than 40 seconds looking at content on a page.  What lesson can you learn from this?  Simple, try not to jam your pages with too much text.  Pages that have charts, [...]]]></description>
			<content:encoded><![CDATA[<p>How long do you spend looking at a page on a website.  For the average user, they will spend less than 40 seconds looking at content on a page.  What lesson can you learn from this?  Simple, try not to jam your pages with too much text.  Pages that have charts, graphs, or images along with some text will be more appealing to your website users.  The next time you are at a website, think about the time you spend on each page and relate that to your website.</p>
<p><span id="more-65"></span></p>
<p>GR Web Designs can help track the amount of time spent clients spend on your website.  Feel free to <a title="Contact GR Web Designs" rel="nofollow" href="http://www.gr-webdesigns.com/contact/">contact</a> us for a quote on a new website design or a redesign of your current website.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.gr-webdesigns.com/blog/time-spent-on-a-website/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Three Design Priorities</title>
		<link>http://www.gr-webdesigns.com/blog/three-design-priorities/</link>
		<comments>http://www.gr-webdesigns.com/blog/three-design-priorities/#comments</comments>
		<pubDate>Mon, 08 Dec 2008 22:41:12 +0000</pubDate>
		<dc:creator>Casey Henry</dc:creator>
				<category><![CDATA[Website Design]]></category>
		<category><![CDATA[Design Tips]]></category>
		<category><![CDATA[Helpful Hints]]></category>

		<guid isPermaLink="false">http://www.gr-webdesigns.com/blog/?p=38</guid>
		<description><![CDATA[For everyone who has created a website in the last 15 years, three things are always the same.  If these three priorities are not followed it could destroy any business website.  Follow these simply design priorities and you will be set:


 Communicating clearly. Users will make a decision about your website within 30 [...]]]></description>
			<content:encoded><![CDATA[<p>For everyone who has created a website in the last 15 years, three things are always the same.  If these three priorities are not followed it could destroy any business website.  Follow these simply design priorities and you will be set:<br />
<span id="more-38"></span></p>
<ul>
<li> <strong>Communicating clearly.</strong> Users will make a decision about your website within 30 seconds of visiting your first page.</li>
</ul>
<ul>
<li> <strong>Provide information users want.</strong> Don’t fill your website with pages and pages of information that no one will read or use.</li>
</ul>
<ul>
<li> <strong>Offer simple, consistent, and clear navigation and page design.</strong> Put things where users expect to find them and don’t veer to far from the website norm.</li>
</ul>
<p>Keeping with those three design priorities will help your site flourish in the web world!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.gr-webdesigns.com/blog/three-design-priorities/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Increase Your Businesses Local Sales</title>
		<link>http://www.gr-webdesigns.com/blog/increase-your-businesses-local-sales/</link>
		<comments>http://www.gr-webdesigns.com/blog/increase-your-businesses-local-sales/#comments</comments>
		<pubDate>Mon, 06 Oct 2008 11:31:56 +0000</pubDate>
		<dc:creator>Casey Henry</dc:creator>
				<category><![CDATA[Website Design]]></category>
		<category><![CDATA[Google Local]]></category>
		<category><![CDATA[Increase Sales]]></category>
		<category><![CDATA[Local Sales]]></category>

		<guid isPermaLink="false">http://www.gr-webdesigns.com/blog/?p=10</guid>
		<description><![CDATA[A simple way to increase the local sales on your business website  is to include your business in the major search engine’s local listings.

For example someone from Hudsonville, Michigan is searching for  website design and they go to Google and type in “Hudsonville Website Design”  they will get the listing in the [...]]]></description>
			<content:encoded><![CDATA[<p>A simple way to increase the local sales on your business website  is to include your business in the major search engine’s local listings.</p>
<p><span id="more-10"></span></p>
<p>For example someone from Hudsonville, Michigan is searching for  website design and they go to Google and type in “<a rel="nofollow" href="http://www.google.com/search?q=hudsonville+website+design">Hudsonville Website Design</a>”  they will get the listing in the image below.   These local business results appear before the regular search engine  results and could result in more visits to your website.</p>
<div id="attachment_9" class="wp-caption aligncenter" style="width: 310px"><a href="http://www.gr-webdesigns.com/blog/wp-content/uploads/2008/11/google-local.jpg"><img class="size-medium wp-image-9" title="Google Local" src="http://www.gr-webdesigns.com/blog/wp-content/uploads/2008/11/google-local-300x172.jpg" alt="Google Local" width="300" height="172" /></a><p class="wp-caption-text">Google Local</p></div>
<p>Below are a few links to the major local listings you should  submit your business to.</p>
<p><a rel="nofollow" href="http://www.google.com/local/add/">Google Local</a></p>
<p><a rel="nofollow" href="http://listings.local.yahoo.com/csubmit/index.php">Yahoo Local</a></p>
<p><a rel="nofollow" href="https://llc.local.live.com/ListingCenter.aspx">Live Local</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.gr-webdesigns.com/blog/increase-your-businesses-local-sales/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Basic Website Information</title>
		<link>http://www.gr-webdesigns.com/blog/basic-website-information/</link>
		<comments>http://www.gr-webdesigns.com/blog/basic-website-information/#comments</comments>
		<pubDate>Mon, 29 Sep 2008 21:08:07 +0000</pubDate>
		<dc:creator>Casey Henry</dc:creator>
				<category><![CDATA[Website Design]]></category>
		<category><![CDATA[Basic Website]]></category>
		<category><![CDATA[Information]]></category>

		<guid isPermaLink="false">http://www.gr-webdesigns.com/blog/?p=7</guid>
		<description><![CDATA[Obtaining a website can be a confusing process. This blog will help you understand what you need to get and keep your website up and running. Every website has three major components, the web page themselves, a hosting package, and a domain name.

The website consists of all the pages and code that create what you [...]]]></description>
			<content:encoded><![CDATA[<p>Obtaining a website can be a confusing process. This blog will help you understand what you need to get and keep your website up and running. Every website has three major components, the web page themselves, a hosting package, and a domain name.</p>
<p><span id="more-7"></span></p>
<p>The website consists of all the pages and code that create what you see on your computer. Each page is different and can be from very simple to quite complex. Websites can vary in price from very inexpensive to quite costly depending on who creates your site. Please contact us regarding any quotes you have received from other companies for a comparison price.</p>
<p>The hosting package is where your web pages are stored on the internet. Just like when you save your resume to a folder on your computer, your web pages need to be stored somewhere so the public can access them. There are many companies that will host your website for you at a variety of prices. Make sure you do your research and get what you need. If you need assistance with your hosting package please feel free to contact us.</p>
<p>A domain name is a unique address that tells your customer where your website is located on the internet. A domain name is typed into your customers address bar to get to your website such as gr-webdesigns.com. A domain name is registered with a registrar that tells the customer where your website is stored. You must renew your registration yearly or you can by them for a longer period such as 5 years. If you need help registering your domain or have questions please feel free to contact us.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.gr-webdesigns.com/blog/basic-website-information/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

