<?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>Point 47</title>
	<atom:link href="http://point47.com/journal/feed/" rel="self" type="application/rss+xml" />
	<link>http://point47.com/journal</link>
	<description>CSS, PHP and ActionScript 3 tutorials</description>
	<lastBuildDate>Tue, 06 Jul 2010 19:11:55 +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>Quickly build a jQuery dropdown menu</title>
		<link>http://point47.com/journal/2010/07/quickly-build-a-jquery-dropdown-menu/</link>
		<comments>http://point47.com/journal/2010/07/quickly-build-a-jquery-dropdown-menu/#comments</comments>
		<pubDate>Tue, 06 Jul 2010 19:09:31 +0000</pubDate>
		<dc:creator>Sorin</dc:creator>
				<category><![CDATA[jQuery]]></category>

		<guid isPermaLink="false">http://point47.com/journal/?p=145</guid>
		<description><![CDATA[Full demo here: jQuery Drop Down Menu jQuery 1234567891011$(document).ready(function(){ &#160; &#160; $('#navigation li').hover( function() &#160; &#160; { &#160; &#160; &#160; &#160; $(this).children('ul').not(':animated').slideDown('#navigation li ul'); &#160; &#160; }, function() &#160; &#160; { &#160; &#160; &#160; &#160; $(this).children('ul').slideUp('#navigation li ul'); &#160; &#160; }); &#160; &#160; }); HTML 123456789101112131415&#60;ul id=&#34;navigation&#34;&#62; &#160; &#160; &#160; &#160; &#60;li&#62;&#60;a href=&#34;#&#34;&#62;Home&#60;/a&#62;&#60;/li&#62; &#160; &#160;]]></description>
			<content:encoded><![CDATA[<p>Full demo here: <a href="http://point47.com/journal/demo/jquery_drop_down.html" target="_blank">jQuery Drop Down Menu</a></p>
<p><strong>jQuery</strong></p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:610px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">$(document).ready(function(){<br />
<br />
&nbsp; &nbsp; $('#navigation li').hover( function()<br />
&nbsp; &nbsp; {<br />
&nbsp; &nbsp; &nbsp; &nbsp; $(this).children('ul').not(':animated').slideDown('#navigation li ul');<br />
&nbsp; &nbsp; }, function()<br />
&nbsp; &nbsp; {<br />
&nbsp; &nbsp; &nbsp; &nbsp; $(this).children('ul').slideUp('#navigation li ul');<br />
&nbsp; &nbsp; });<br />
&nbsp; &nbsp; <br />
});</div></td></tr></tbody></table></div>
<p><strong>HTML</strong></p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:610px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br />12<br />13<br />14<br />15<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">&lt;ul id=&quot;navigation&quot;&gt;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &lt;li&gt;&lt;a href=&quot;#&quot;&gt;Home&lt;/a&gt;&lt;/li&gt;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &lt;li&gt;&lt;a href=&quot;#&quot;&gt;About&lt;/a&gt;<br />
&nbsp; &nbsp; &nbsp; &nbsp; <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &lt;ul&gt;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &lt;li&gt;&lt;a href=&quot;#&quot;&gt;About us&lt;/a&gt;&lt;/li&gt;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &lt;li&gt;&lt;a href=&quot;#&quot;&gt;More info about&lt;/a&gt;&lt;/li&gt;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &lt;li&gt;&lt;a href=&quot;#&quot;&gt;Even more info&lt;/a&gt;&lt;/li&gt;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &lt;/ul&gt;<br />
&nbsp; &nbsp; &nbsp; &nbsp; <br />
&nbsp; &nbsp; &nbsp; &nbsp; &lt;/li&gt;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &lt;li&gt;&lt;a href=&quot;#&quot;&gt;Services&lt;/a&gt;&lt;/li&gt;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &lt;li&gt;&lt;a href=&quot;#&quot;&gt;Contact&lt;/a&gt;&lt;/li&gt;<br />
<br />
&nbsp; &nbsp; &lt;/ul&gt;</div></td></tr></tbody></table></div>
<p>CSS</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:610px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">#navigation {position: relative;float: left;display: inline;}<br />
#navigation li {position: relative;float: left;display: inline;}<br />
#navigation li a {float: left;display: inline;text-decoration: none;color: blue;padding: 4px 10px 4px 10px;}<br />
<br />
#navigation li ul {position: absolute;top: 26px;left: 0px;margin: 0;padding: 0;background: #cccccc;display: none;width: 180px;}<br />
#navigation li ul li {float: left;width: 100%;margin: 0;padding: 0;border-bottom: 1px dotted #959595; &nbsp; }<br />
#navigation li ul li &nbsp;a {float: left;width: 100%}</div></td></tr></tbody></table></div>
<p>Full demo here: <a href="http://point47.com/journal/demo/jquery_drop_down.html" target="_blank">jQuery Drop Down Menu</a></p>
<p>Enjoy!</p>
<p>Hey did you know about this?<br />
<a href="http://themeforest.net?ref=forapathy" title="wordpress themes, site templates, psd" target="_blank"><img src="http://envato.s3.amazonaws.com/referrer_adverts/tf_468x60_v4.gif" alt="wordpress themes, site templates" /></a></p>
<img src="http://point47.com/journal/?ak_action=api_record_view&id=145&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://point47.com/journal/2010/07/quickly-build-a-jquery-dropdown-menu/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Post data from Actionscript 3 to PHP</title>
		<link>http://point47.com/journal/2010/06/post-data-from-actionscript-3-to-php/</link>
		<comments>http://point47.com/journal/2010/06/post-data-from-actionscript-3-to-php/#comments</comments>
		<pubDate>Fri, 25 Jun 2010 09:39:39 +0000</pubDate>
		<dc:creator>Sorin</dc:creator>
				<category><![CDATA[ActionScript]]></category>
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://point47.com/journal/?p=123</guid>
		<description><![CDATA[If you need to send some data to a PHP script and don&#8217;t want to use services like Zend_AMF you can try posting that data directly to the PHP script. With the code bellow I&#8217;ll actually send an email. // ActionScript 3 Code // PostToPHP.as 123456789101112131415161718192021222324252627282930313233343536373839404142package &#123; &#160; &#160; &#160; &#160; import flash.events.Event; &#160; &#160;]]></description>
			<content:encoded><![CDATA[<p>If you need to send some data to a PHP script and don&#8217;t want to use services like <a href="http://framework.zend.com/download/amf" target="_blank">Zend_AMF</a> you can try posting that data directly to the PHP script.<br />
With the code bellow I&#8217;ll actually send an email.</p>
<p>// ActionScript 3 Code<br />
// PostToPHP.as</p>
<div class="codecolorer-container actionscript3 default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:610px;height:400px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br />12<br />13<br />14<br />15<br />16<br />17<br />18<br />19<br />20<br />21<br />22<br />23<br />24<br />25<br />26<br />27<br />28<br />29<br />30<br />31<br />32<br />33<br />34<br />35<br />36<br />37<br />38<br />39<br />40<br />41<br />42<br /></div></td><td><div class="actionscript3 codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #9900cc; font-weight: bold;">package</span> <br />
<span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0033ff; font-weight: bold;">import</span> <span style="color: #004993;">flash.events</span><span style="color: #000066; font-weight: bold;">.</span><a href="http://www.google.com/search?q=event%20inurl:http://livedocs.adobe.com/flex/201/langref/%20inurl:event.html"><span style="color: #004993;">Event</span></a><span style="color: #000066; font-weight: bold;">;</span><br />
&nbsp; &nbsp; <span style="color: #0033ff; font-weight: bold;">import</span> <span style="color: #004993;">flash.events</span><span style="color: #000066; font-weight: bold;">.</span><a href="http://www.google.com/search?q=httpstatusevent%20inurl:http://livedocs.adobe.com/flex/201/langref/%20inurl:httpstatusevent.html"><span style="color: #004993;">HTTPStatusEvent</span></a><span style="color: #000066; font-weight: bold;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0033ff; font-weight: bold;">import</span> <span style="color: #004993;">flash.net</span><span style="color: #000066; font-weight: bold;">.</span><a href="http://www.google.com/search?q=urlloader%20inurl:http://livedocs.adobe.com/flex/201/langref/%20inurl:urlloader.html"><span style="color: #004993;">URLLoader</span></a><span style="color: #000066; font-weight: bold;">;</span><br />
&nbsp; &nbsp; <span style="color: #0033ff; font-weight: bold;">import</span> <span style="color: #004993;">flash.net</span><span style="color: #000066; font-weight: bold;">.</span><a href="http://www.google.com/search?q=urlloaderdataformat%20inurl:http://livedocs.adobe.com/flex/201/langref/%20inurl:urlloaderdataformat.html"><span style="color: #004993;">URLLoaderDataFormat</span></a><span style="color: #000066; font-weight: bold;">;</span><br />
&nbsp; &nbsp; <span style="color: #0033ff; font-weight: bold;">import</span> <span style="color: #004993;">flash.net</span><span style="color: #000066; font-weight: bold;">.</span><a href="http://www.google.com/search?q=urlrequest%20inurl:http://livedocs.adobe.com/flex/201/langref/%20inurl:urlrequest.html"><span style="color: #004993;">URLRequest</span></a><span style="color: #000066; font-weight: bold;">;</span><br />
&nbsp; &nbsp; <span style="color: #0033ff; font-weight: bold;">import</span> <span style="color: #004993;">flash.net</span><span style="color: #000066; font-weight: bold;">.</span><a href="http://www.google.com/search?q=urlrequestmethod%20inurl:http://livedocs.adobe.com/flex/201/langref/%20inurl:urlrequestmethod.html"><span style="color: #004993;">URLRequestMethod</span></a><span style="color: #000066; font-weight: bold;">;</span><br />
&nbsp; &nbsp; <span style="color: #0033ff; font-weight: bold;">import</span> <span style="color: #004993;">flash.net</span><span style="color: #000066; font-weight: bold;">.</span><a href="http://www.google.com/search?q=urlvariables%20inurl:http://livedocs.adobe.com/flex/201/langref/%20inurl:urlvariables.html"><span style="color: #004993;">URLVariables</span></a><span style="color: #000066; font-weight: bold;">;</span><br />
<br />
&nbsp; &nbsp; <span style="color: #0033ff; font-weight: bold;">public</span> <span style="color: #9900cc; font-weight: bold;">class</span> PostToPHP<br />
&nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900; font-style: italic;">// url to post</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0033ff; font-weight: bold;">private</span> <span style="color: #6699cc; font-weight: bold;">var</span> postToURL<span style="color: #000066; font-weight: bold;">:</span><a href="http://www.google.com/search?q=string%20inurl:http://livedocs.adobe.com/flex/201/langref/%20inurl:string.html"><span style="color: #004993;">String</span></a> = <span style="color: #990000;">&quot;http://www.yourdomain.tld/post_receiver.php&quot;</span><span style="color: #000066; font-weight: bold;">;</span><br />
<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #0033ff; font-weight: bold;">public</span> <span style="color: #339966; font-weight: bold;">function</span> PostToPHP<span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900; font-style: italic;">// create request</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #6699cc; font-weight: bold;">var</span> request<span style="color: #000066; font-weight: bold;">:</span><a href="http://www.google.com/search?q=urlrequest%20inurl:http://livedocs.adobe.com/flex/201/langref/%20inurl:urlrequest.html"><span style="color: #004993;">URLRequest</span></a> = <span style="color: #0033ff; font-weight: bold;">new</span> <a href="http://www.google.com/search?q=urlrequest%20inurl:http://livedocs.adobe.com/flex/201/langref/%20inurl:urlrequest.html"><span style="color: #004993;">URLRequest</span></a><span style="color: #000000;">&#40;</span> postToURL <span style="color: #000000;">&#41;</span><span style="color: #000066; font-weight: bold;">;</span><br />
<br />
&nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900; font-style: italic;">// set post variables</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #6699cc; font-weight: bold;">var</span> requestVars<span style="color: #000066; font-weight: bold;">:</span><a href="http://www.google.com/search?q=urlvariables%20inurl:http://livedocs.adobe.com/flex/201/langref/%20inurl:urlvariables.html"><span style="color: #004993;">URLVariables</span></a> = <span style="color: #0033ff; font-weight: bold;">new</span> <a href="http://www.google.com/search?q=urlvariables%20inurl:http://livedocs.adobe.com/flex/201/langref/%20inurl:urlvariables.html"><span style="color: #004993;">URLVariables</span></a><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #000066; font-weight: bold;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; requestVars<span style="color: #000066; font-weight: bold;">.</span>emailTo &nbsp; &nbsp; &nbsp;= <span style="color: #990000;">'email.address@mailservice.tld'</span><span style="color: #000066; font-weight: bold;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; requestVars<span style="color: #000066; font-weight: bold;">.</span>subject &nbsp; &nbsp; &nbsp;= <span style="color: #990000;">'This is a test email'</span><span style="color: #000066; font-weight: bold;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; requestVars<span style="color: #000066; font-weight: bold;">.</span><span style="color: #004993;">message</span> = <span style="color: #990000;">'An this is the content of the message.'</span><span style="color: #000066; font-weight: bold;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900; font-style: italic;">// assign variables to the request and set request method type&nbsp; </span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; request<span style="color: #000066; font-weight: bold;">.</span><span style="color: #004993;">data</span> &nbsp; &nbsp; = requestVars<span style="color: #000066; font-weight: bold;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; request<span style="color: #000066; font-weight: bold;">.</span><span style="color: #004993;">method</span> = <a href="http://www.google.com/search?q=urlrequestmethod%20inurl:http://livedocs.adobe.com/flex/201/langref/%20inurl:urlrequestmethod.html"><span style="color: #004993;">URLRequestMethod</span></a><span style="color: #000066; font-weight: bold;">.</span><span style="color: #004993;">POST</span><span style="color: #000066; font-weight: bold;">;</span><br />
&nbsp; &nbsp; <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #009900; font-style: italic;">// load the request and listen for a response from the PHP script</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #6699cc; font-weight: bold;">var</span> urlLoader<span style="color: #000066; font-weight: bold;">:</span><a href="http://www.google.com/search?q=urlloader%20inurl:http://livedocs.adobe.com/flex/201/langref/%20inurl:urlloader.html"><span style="color: #004993;">URLLoader</span></a> = <span style="color: #0033ff; font-weight: bold;">new</span> <a href="http://www.google.com/search?q=urlloader%20inurl:http://livedocs.adobe.com/flex/201/langref/%20inurl:urlloader.html"><span style="color: #004993;">URLLoader</span></a><span style="color: #000000;">&#40;</span><span style="color: #000000;">&#41;</span><span style="color: #000066; font-weight: bold;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; urlLoader<span style="color: #000066; font-weight: bold;">.</span><span style="color: #004993;">dataFormat</span> = <span style="color: #990000;">&quot;text&quot;</span><span style="color: #000066; font-weight: bold;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; urlLoader<span style="color: #000066; font-weight: bold;">.</span><span style="color: #004993;">addEventListener</span><span style="color: #000000;">&#40;</span><a href="http://www.google.com/search?q=event%20inurl:http://livedocs.adobe.com/flex/201/langref/%20inurl:event.html"><span style="color: #004993;">Event</span></a><span style="color: #000066; font-weight: bold;">.</span><span style="color: #004993;">COMPLETE</span><span style="color: #000066; font-weight: bold;">,</span> urlLoader_handler<span style="color: #000066; font-weight: bold;">,</span> <span style="color: #0033ff; font-weight: bold;">false</span><span style="color: #000066; font-weight: bold;">,</span> <span style="color: #000000; font-weight:bold;">0</span><span style="color: #000066; font-weight: bold;">,</span> <span style="color: #0033ff; font-weight: bold;">true</span><span style="color: #000000;">&#41;</span><span style="color: #000066; font-weight: bold;">;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; urlLoader<span style="color: #000066; font-weight: bold;">.</span><span style="color: #004993;">load</span><span style="color: #000000;">&#40;</span>request<span style="color: #000000;">&#41;</span><span style="color: #000066; font-weight: bold;">;</span><br />
&nbsp; &nbsp; <span style="color: #000000;">&#125;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; <br />
&nbsp; &nbsp; <span style="color: #0033ff; font-weight: bold;">private</span> <span style="color: #339966; font-weight: bold;">function</span> urlLoader_handler<span style="color: #000000;">&#40;</span>e<span style="color: #000066; font-weight: bold;">:</span><a href="http://www.google.com/search?q=object%20inurl:http://livedocs.adobe.com/flex/201/langref/%20inurl:object.html"><span style="color: #004993;">Object</span></a><span style="color: #000000;">&#41;</span><span style="color: #000066; font-weight: bold;">:</span><span style="color: #0033ff; font-weight: bold;">void</span><br />
&nbsp; &nbsp; <span style="color: #000000;">&#123;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #009900; font-style: italic;">// the response given from the PHP script will be traced here</span><br />
&nbsp; &nbsp; &nbsp; &nbsp;<span style="color: #004993;">trace</span><span style="color: #000000;">&#40;</span>e<span style="color: #000066; font-weight: bold;">.</span><span style="color: #004993;">target</span><span style="color: #000066; font-weight: bold;">.</span><span style="color: #004993;">data</span><span style="color: #000000;">&#41;</span><span style="color: #000066; font-weight: bold;">;</span><br />
&nbsp; &nbsp; <span style="color: #000000;">&#125;</span></div></td></tr></tbody></table></div>
<p>// PHP code<br />
// post_receiver.php</p>
<div class="codecolorer-container php default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:610px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br />12<br />13<br />14<br />15<br />16<br />17<br />18<br />19<br /></div></td><td><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;">// assign POST variables and clean them</span><br />
<span style="color: #666666; font-style: italic;">// filter_var() is available from PHP 5.2.0</span><br />
<span style="color: #000088;">$emailTo</span> &nbsp; &nbsp;<span style="color: #339933;">=</span> <a href="http://www.php.net/filter_var"><span style="color: #990000;">filter_var</span></a><span style="color: #009900;">&#40;</span><span style="color: #000088;">$_POST</span><span style="color: #009900;">&#91;</span><span style="color: #0000ff;">'emailTo'</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">,</span> FILTER_SANITIZE_EMAIL<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #000088;">$subject</span> &nbsp; &nbsp;<span style="color: #339933;">=</span> <a href="http://www.php.net/filter_var"><span style="color: #990000;">filter_var</span></a><span style="color: #009900;">&#40;</span><span style="color: #000088;">$_POST</span><span style="color: #009900;">&#91;</span><span style="color: #0000ff;">'subject'</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">,</span> FILTER_SANITIZE_STRING<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<span style="color: #000088;">$message</span> &nbsp; <span style="color: #339933;">=</span> <a href="http://www.php.net/filter_var"><span style="color: #990000;">filter_var</span></a><span style="color: #009900;">&#40;</span><span style="color: #000088;">$_POST</span><span style="color: #009900;">&#91;</span><span style="color: #0000ff;">'message'</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">,</span> FILTER_SANITIZE_STRING<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<br />
<span style="color: #666666; font-style: italic;">// send mail and remember function response</span><br />
<span style="color: #666666; font-style: italic;">// boolean response</span><br />
<span style="color: #000088;">$mailSent</span> <span style="color: #339933;">=</span> <a href="http://www.php.net/mail"><span style="color: #990000;">mail</span></a><span style="color: #009900;">&#40;</span><span style="color: #000088;">$emailTo</span><span style="color: #339933;">,</span> <span style="color: #000088;">$subject</span><span style="color: #339933;">,</span> <span style="color: #000088;">$message</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span><br />
<br />
<span style="color: #666666; font-style: italic;">// the echoed response will be traced in actionscript</span><br />
<span style="color: #b1b100;">if</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$mailSent</span> <span style="color: #339933;">==</span> <span style="color: #009900; font-weight: bold;">true</span><span style="color: #009900;">&#41;</span><br />
<span style="color: #009900;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #b1b100;">echo</span> <span style="color: #0000ff;">'mail sent'</span><span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span><br />
<span style="color: #b1b100;">else</span><br />
<span style="color: #009900;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #b1b100;">echo</span> <span style="color: #0000ff;">'mail NOT sent'</span><span style="color: #339933;">;</span><br />
<span style="color: #009900;">&#125;</span></div></td></tr></tbody></table></div>
<p>Simple.</p>
<img src="http://point47.com/journal/?ak_action=api_record_view&id=123&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://point47.com/journal/2010/06/post-data-from-actionscript-3-to-php/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Modal box on page load with jquery fancy box and cookie plugin</title>
		<link>http://point47.com/journal/2010/06/modal-box-on-page-load-with-jquery-fancy-box-and-cookie-plugin/</link>
		<comments>http://point47.com/journal/2010/06/modal-box-on-page-load-with-jquery-fancy-box-and-cookie-plugin/#comments</comments>
		<pubDate>Thu, 24 Jun 2010 09:37:49 +0000</pubDate>
		<dc:creator>Sorin</dc:creator>
				<category><![CDATA[jQuery]]></category>

		<guid isPermaLink="false">http://point47.com/journal/?p=127</guid>
		<description><![CDATA[What I want to do? I want to show a message or an image on the first visit on my website. What I need to do this? - FancyBox jQuery plugin that you can get from here: http://fancybox.net/. I use this plugin as a better alternative to the old LightBox plugin because it resizes the]]></description>
			<content:encoded><![CDATA[<p><strong>What I want to do?</strong><br />
I want to show a message or an image on the first visit on my website.</p>
<p><strong>What I need to do this?</strong><br />
- FancyBox jQuery plugin that you can get from here: <a href="http://fancybox.net/" target="_blank">http://fancybox.net/</a>.<br />
I use this plugin as a better alternative to the old LightBox plugin because it resizes the loaded image to the current page size.<br />
- jQuery Cookie plugin that you can get from here: <a href="http://plugins.jquery.com/project/cookie" target="_blank">http://plugins.jquery.com/project/cookie</a><br />
This one I will use to remember if the modal box was already shown. I want to show the modal box only on the first visit on the site. No on every page load <img src='http://point47.com/journal/wp-includes/images/smilies/icon_razz.gif' alt=':P' class='wp-smiley' /> .<br />
- oh and of course the jQuery library: <a href="http://jquery.com/" target="_blank">http://jquery.com/</a></p>
<p><strong>How I do this?</strong><br />
Put this in the head section of the html code.</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:610px;height:400px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br />12<br />13<br />14<br />15<br />16<br />17<br />18<br />19<br />20<br />21<br />22<br />23<br />24<br />25<br />26<br />27<br />28<br />29<br />30<br />31<br />32<br />33<br />34<br />35<br />36<br />37<br />38<br />39<br />40<br />41<br />42<br />43<br />44<br />45<br />46<br />47<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">// load all the libraries<br />
// i like to put them in a folder called &quot;public&quot; then &quot;js&quot;<br />
&lt;link rel=&quot;stylesheet&quot; type=&quot;text/css&quot; href=&quot;public/js/fancybox/jquery.fancybox-1.3.1.css&quot; media=&quot;screen&quot; /&gt;<br />
&lt;script type=&quot;text/javascript&quot; src=&quot;public/js/jquery.min.js&quot;&gt;&lt;/script&gt;<br />
&lt;script type=&quot;text/javascript&quot; src=&quot;public/js/fancybox/jquery.mousewheel-3.0.2.pack.js&quot;&gt;&lt;/script&gt;<br />
&lt;script type=&quot;text/javascript&quot; src=&quot;public/js/fancybox/jquery.fancybox-1.3.1.js&quot;&gt;&lt;/script&gt;<br />
&lt;script type=&quot;text/javascript&quot; src=&quot;public/js/jquery.cookie.js&quot;&gt;&lt;/script&gt; <br />
<br />
$(document).ready(function(){<br />
<br />
/**<br />
&nbsp; &nbsp; &nbsp; * &nbsp;MODAL BOX<br />
&nbsp; &nbsp; &nbsp; */<br />
&nbsp; &nbsp; // if the requested cookie does not have the value I am looking for show the modal box<br />
&nbsp; &nbsp; if($.cookie(&quot;modal&quot;) != 'true')<br />
&nbsp; &nbsp; {<br />
&nbsp; &nbsp; &nbsp; &nbsp; var _message_to_show = '&lt;h2&gt;Hi!&lt;/h2&gt;&lt;p&gt;Lorem ipsum dolor sit amet, consectetur adipiscing elit. Etiam quis mi eu elit tempor facilisis id et neque&lt;/p&gt; &lt;br /&gt;&lt;br /&gt;&lt;a href=&quot;#&quot; id=&quot;modal_close&quot;&gt;ENTER&lt;/a&gt; &lt;a href=&quot;http://www.google.com&quot; id=&quot;modal_exit&quot;&gt;EXIT&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;';<br />
&nbsp; &nbsp; &nbsp; &nbsp; <br />
&nbsp; &nbsp; &nbsp; &nbsp; // on page load show the modal box<br />
&nbsp; &nbsp; &nbsp; &nbsp; // more info about the options you can find on the fancybox site<br />
&nbsp; &nbsp; &nbsp; &nbsp; $.fancybox(<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; _message_to_show,<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 'width' &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; : 350,<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 'height' &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;: 300,<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 'transitionIn' &nbsp; &nbsp; &nbsp;: 'none',<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 'transitionOut' &nbsp; &nbsp; : 'elastic',<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 'centerOnScroll' &nbsp; &nbsp;: 'true',<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 'overlayOpacity' &nbsp; &nbsp;: 0.9,<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 'overlayColor' &nbsp; &nbsp; &nbsp;: '#000',<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 'modal' &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; : 'true'<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }<br />
&nbsp; &nbsp; &nbsp; &nbsp; );<br />
&nbsp; &nbsp; &nbsp; &nbsp; <br />
&nbsp; &nbsp; &nbsp; &nbsp; // in the message is a link with the id &quot;modal_close&quot;<br />
&nbsp; &nbsp; &nbsp; &nbsp; // when you click on that link the modal will close and the cookie is set to &quot;true&quot;<br />
&nbsp; &nbsp; &nbsp; &nbsp; // path &quot;/&quot; means it's active for the entire root site.. if you set it to &quot;/admin&quot; will be active on the &quot;admin&quot; folder<br />
&nbsp; &nbsp; &nbsp; &nbsp; // expires in 7 days<br />
&nbsp; &nbsp; &nbsp; &nbsp; // &quot;modal&quot; is the name i gave the cookie.. you can name it anything you want<br />
&nbsp; &nbsp; &nbsp; &nbsp; $('#modal_close').live('click', function(e) {<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; e.preventDefault();<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $.cookie(&quot;modal&quot;, &quot;true&quot;, { path: '/', expires: 7 }); &nbsp; &nbsp;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $.fancybox.close()<br />
&nbsp; &nbsp; &nbsp; &nbsp; });<br />
&nbsp; &nbsp; } &nbsp; &nbsp;<br />
&nbsp; &nbsp; <br />
});</div></td></tr></tbody></table></div>
<p>Oh the live demo is <a href="http://point47.com/journal/demo/modalbox.html" target="_blank">HERE</a>!</p>
<p>And that&#8217;s it! Enjoy!</p>
<p>Hey did you know about this?<br />
<a href="http://themeforest.net?ref=forapathy" title="wordpress themes, site templates, psd" target="_blank"><img src="http://envato.s3.amazonaws.com/referrer_adverts/tf_468x60_v4.gif" alt="wordpress themes, site templates" /></a></p>
<img src="http://point47.com/journal/?ak_action=api_record_view&id=127&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://point47.com/journal/2010/06/modal-box-on-page-load-with-jquery-fancy-box-and-cookie-plugin/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>Tips about writing CSS</title>
		<link>http://point47.com/journal/2010/04/tips-about-writing-css/</link>
		<comments>http://point47.com/journal/2010/04/tips-about-writing-css/#comments</comments>
		<pubDate>Thu, 08 Apr 2010 11:21:50 +0000</pubDate>
		<dc:creator>Sorin</dc:creator>
				<category><![CDATA[CSS]]></category>

		<guid isPermaLink="false">http://point47.com/journal/?p=94</guid>
		<description><![CDATA[Here are some random tips that I think can be useful to anyone who starts playing with CSS or already is doing that. 1. Reset HTML elements for all browsers. The first thing I do is reset the default styles that the browsers set on elements. I consider this the most important thing to do]]></description>
			<content:encoded><![CDATA[<p>Here are some random tips that I think can be useful to anyone who starts playing with CSS or already is doing that.</p>
<h4>1. Reset HTML elements for all browsers.</h4>
<p>The first thing I do is reset the default styles that the browsers set on elements. I consider this the most important thing to do before starting writing the actual CSS styles for the layout. For example Internet Explorer sets bigger margin values for elements like &#8220;input&#8221;, &#8220;textarea&#8221; and so on, than Firefox or Chrome.<br />
To reset the styles I prefer to use <a href="http://developer.yahoo.com/yui/reset/" target="_blank">Yahoo Reset</a> or you could try writing your own.</p>
<h4>2. Centering elements with CSS</h4>
<p>To center elements with CSS first you need to set the elements &#8220;width&#8221; and then setting their margins.<br />
So.. we want to center the design/layout of our site in the browser.<br />
We have this HTML</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:610px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">&lt;body&gt;<br />
&lt;div id=&quot;layoutWrapper&quot;&gt;site content&lt;/div&gt;<br />
&lt;/body&gt;</div></td></tr></tbody></table></div>
<p>and the CSS to center the <em>layoutWrapper</em> div is:</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:610px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">#layoutWrapper<br />
{<br />
&nbsp; &nbsp; width: 960px;<br />
&nbsp; &nbsp; margin: 0px auto;<br />
}</div></td></tr></tbody></table></div>
<p>Now the <em>layoutWrapper</em> div is centered with a top margin of 0 and the other margins are set to auto.</p>
<h4>3. Quick fix for the double margin bug in Internet Explorer 6</h4>
<p>The problem is that if you set margin or padding on a floated element those values are doubled in IE6 and get a f*ucked up layout.<br />
To solve this problem there are a lot of tricks but the most easiest and straight forward is to set also &#8220;display:inline&#8221; on the floated elements.<br />
This code will get you a margin left of 40px in Internet Explorer 6.</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:610px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">.element<br />
{<br />
&nbsp; &nbsp;float:left;<br />
&nbsp; &nbsp;width: 200px<br />
&nbsp; &nbsp;margin-left: 20px; <br />
}</div></td></tr></tbody></table></div>
<p>By adding display:inline now margin-left is also 20px in IE6</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:610px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">.element<br />
{<br />
&nbsp; &nbsp;display:inline;<br />
&nbsp; &nbsp;float:left;<br />
&nbsp; &nbsp;width: 200px;<br />
&nbsp; &nbsp;margin-left: 20px; <br />
}</div></td></tr></tbody></table></div>
<h4>4. Font size in EM or PX?</h4>
<p>For a period of time I used em&#8217;s to size the fonts because in IE6 you can&#8217;t re-size the font if it&#8217;s in pixels.<br />
So if a title was 21px in font size.. in IE6 it will remain in 21px if you select text size to be larger. If it was in em&#8217;s for example<br />
that title will get larger.<br />
A trick that I used to easier set sizes in em&#8217;s is I was setting the body font size to 62.5%.</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:610px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">body { font-size: 62.5%; }</div></td></tr></tbody></table></div>
<p>So now if you set a font size of 2.1em it will be the same as 21px.</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:610px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">h1{font-size: 2.1em;}<br />
h2{font-size: 21px;}</div></td></tr></tbody></table></div>
<p>The sizes of the H1 and H2 will be the same 21px.<br />
For some time now I don&#8217;t care so much for IE6 users because there are 9 years since it was released and there are 4 years since version 7 was released.<br />
So if it&#8217;s not plain stupidity I really believe it&#8217;s plain ignorance.</p>
<h4>5. ID&#8217;s or Classes? When to use?</h4>
<p>Simple. Use id&#8217;s to target single elements or classes to target elements that are repeating in the page.<br />
More complex would be that elements with and id should be unique or else you cannot validate your HTML document.<br />
By using classes on elements you can use the same class to target multiple elements or also you can use multiple classes to target the same element.</p>
<h4>6. The equal columns trick</h4>
<p>This is a trick that I use rarely because it&#8217;s kind of an hack and hacks are never a good idea <img src='http://point47.com/journal/wp-includes/images/smilies/icon_razz.gif' alt=':P' class='wp-smiley' /> .<br />
More info for this trick you can find <a href="http://www.ejeliot.com/blog/61" target="_blank">here</a>.<br />
There are also a lot of variations but I find this one the easiest to implement.</p>
<h4>7. Containers and children widths</h4>
<p>I usually set width only to container elements and for the children I set margins and padding or width of 100%.<br />
So if I need to change the width of the container the children automatically change their size also.</p>
<h4>8. IE6 PNG transparency problem (isn&#8217;t really a CSS related but like.. who cares)</h4>
<p>Everybody loves PNG&#8217;s. And how can you not? Full quality, transparency support, smaller size files on graphics (jpeg&#8217;s are still better for big images).<br />
But IE6 doesn&#8217;t like them at all. So we must use some tricks.. and there are a lot.<br />
From that &#8220;a lot&#8221; I prefer one: <a href="http://www.dillerdesign.com/experiment/DD_belatedPNG/" target="_blank">DD_belatedPNG by Drew Diller</a><br />
This one is the best I could find out there. And I tested a lot of them bad scripts <img src='http://point47.com/journal/wp-includes/images/smilies/icon_razz.gif' alt=':P' class='wp-smiley' /> </p>
<img src="http://point47.com/journal/?ak_action=api_record_view&id=94&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://point47.com/journal/2010/04/tips-about-writing-css/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Virtual URL &#8211; link shorten service</title>
		<link>http://point47.com/journal/2010/02/virtual-url-link-shorten-service/</link>
		<comments>http://point47.com/journal/2010/02/virtual-url-link-shorten-service/#comments</comments>
		<pubDate>Sat, 20 Feb 2010 17:22:52 +0000</pubDate>
		<dc:creator>Sorin</dc:creator>
				<category><![CDATA[Bulk]]></category>

		<guid isPermaLink="false">http://point47.com/journal/?p=91</guid>
		<description><![CDATA[VUS.me is a new and very simple link shorten service made with simplicity and quick access in mind. Looks very promising so give it a try.. or more . http://vus.me]]></description>
			<content:encoded><![CDATA[<p><a href="http://vus.me" target="_blank">VUS.me</a> is a new and very simple link shorten service made with simplicity and quick access in mind.<br />
Looks very promising so give it a try.. or more <img src='http://point47.com/journal/wp-includes/images/smilies/icon_biggrin.gif' alt=':D' class='wp-smiley' /> . </p>
<p><a href=" http://vus.me" target="_blank">http://vus.me</a></p>
<img src="http://point47.com/journal/?ak_action=api_record_view&id=91&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://point47.com/journal/2010/02/virtual-url-link-shorten-service/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How To Setup WordPress MU with Domain Mapping</title>
		<link>http://point47.com/journal/2009/12/how-to-setup-wordpress-mu-with-domain-mapping/</link>
		<comments>http://point47.com/journal/2009/12/how-to-setup-wordpress-mu-with-domain-mapping/#comments</comments>
		<pubDate>Thu, 17 Dec 2009 14:41:07 +0000</pubDate>
		<dc:creator>Sorin</dc:creator>
				<category><![CDATA[Wordpress]]></category>

		<guid isPermaLink="false">http://point47.com/journal/?p=61</guid>
		<description><![CDATA[NOTE! Since WordPress 3.0 this post is outdated. In the new WordPress 3.0 the MU wordpress is already integrated. Here is explained how I made my WordPress MU install to work with domain mapping. There are some tutorials out there but they are plain crap and very poorly explained. And the explanations for the domain]]></description>
			<content:encoded><![CDATA[<p><strong>NOTE! Since WordPress 3.0 this post is outdated. In the new WordPress 3.0 the MU wordpress is already integrated.</strong></p>
<p>Here is explained how I made my WordPress MU install to work with domain mapping. There are some tutorials out there but they are plain crap and very poorly explained. And the explanations for the domain mapping plugins are even worse. But I managed to make it work in around two days with a lot of testing and trial and error.<br />
These are the steps that I followed. Well.. not really.. but in the end these would have been the steps that I should have followed.</p>
<p><em><strong>NOTE! This tutorial is based on the fact that you know how to install and configure a simple WordPress version because I will not offer detailed info about database creation and ftp uploading.</strong></em></p>
<h4>What we want to do here?</h4>
<p>- We want to have WordPress MU so we can create multiple WordPress blogs but with one main Administration area.<br />
- Create as many sub-domains as we want.<br />
- Map those sub-domains to other domains. (<em>subdomain.master-example.com</em> should be accessible from <em>addon-example.com</em> )</p>
<h4>I. Configure domains</h4>
<ul>
<li> First you need some domains, for this tutorial at least 2. One to be the master domain which we will call here <em>master-example.com</em> and the other domain that we will map to the blog created as a subdomain on master-example.com whitch we will call <em>addon-example.com</em>.</li>
<li>Next you need hosting witch offers <strong>WHM with CPanel</strong>. WHM not really needed I think. I added the domains and parked them from WHM but that can be done in CPanel also.</li>
<li>After you have the main domain configured on a hosting and you have acces to the CPanel you need to go to &#8220;<strong>Subdomains</strong>&#8221; and set the subdomains on a wildcard(<strong>*</strong>). So where it says &#8220;<strong>Create a Subdomain</strong>&#8221; enter <strong>*</strong> , check if your master domain is selected in the next drop down and in Document root is &#8220;<em>public_html/</em>&#8221; and click Create. </li>
<li>In the list of sub-domains now should be:<strong> &#8220;*  	.master-example.com  	Home/public_html  not redirected&#8221;</strong> . What this does it lets WordPress MU create any kind of sub-domain without first adding it manually in the CPanel.</li>
<li> Now we need to add the <em>addon-example.com</em> domain. Go to: &#8220;<strong>Parked Domains</strong>&#8221; and enter <em>addon-example.com</em> in the box and press &#8220;<strong>Add Domain</strong>&#8220;. This should park <em>addon-example.com</em> on top of<em>master-example.com</em>. Until I used the Park domain option my domain mapping in WordPress didn&#8217;t work.</li>
<li>Now go to <strong>&#8220;Simple DNS Zone Editor&#8221;</strong> and here you have to set an A record for <em>addon-example.com</em>. So select the addon domain <em>addon-example.com</em> and where it says <strong>Add an A Record </strong> in the <strong>&#8220;Name:&#8221;</strong> field write <strong>*.addon-example.com</strong>  and on the <strong>&#8220;Address&#8221; </strong>field put the <strong>master domain IP</strong> (you should find it in the left sidebar in CPanel.. for example: <strong>&#8220;Shared Ip Address: 127.0.0.20&#8243; </strong>.). Click <strong>&#8220;Add A Record&#8221;. </strong></li>
<li>Great. Now you are ready to install WordPress MU!</li>
</ul>
<p><strong>Note!</strong><em> I made all of this in the WHM administration but I saw those modifications in CPanel also and I checked if they correspond and it seems that it can be done from CPanel too. For WHM just use &#8220;Park a Domain&#8221; and &#8220;Edit DNS Zone&#8221; buttons and make the above modifications.</em></p>
<h4>II. Install WordPress MU.</h4>
<ul>
<li>Create a database and a user in CPanel .. or whatever.</li>
<li>Download the WordPress MU sources from <a href="http://mu.wordpress.org/download/">here</a> </li>
<li>Copy the files to your main domain. I uploaded them to my domain root but they say it can be installed to a folder or a sub-domain too.</li>
<li>Now navigate to your domain (master-example.com) and you should see the installation page. There are some errors for sure and the usual error is that you need to make some folder writable by WordPress. That means to give those folders 777 permission and you&#8217;ll have to reset those to 755 after successful install. </li>
<li>Just follow the steps and be careful to specify where it says Blog addresses <strong>to use sub-domains</strong> and at <strong>Server Address your domain without www or http://</strong></li>
<li>And, this is very important, after install go to Admin menu (upper right corner) in the WordPress admin interface and <strong>change your password</strong> to something you can remember. And don&#8217;t forget to change the folder permissions back to 755</li>
<li>Now is the time to see if it works. Go to Site <strong>Admin -> Blogs</strong> and add a new blog. Let&#8217;s say <em>subdomain.master-example.com</em>. If the email address is different from the one you used at install a new user will be created when you add a new blog. And this happens every time you use a different email address.</li>
<li>OK. Now navigate to: <strong>subdomain.master-example.com</strong> (or whatever you created) and you should see your blog. Congrats! Now you have a working installation of WordPress MU. If it doesn&#8217;t work repeat the above steps with more attention or if you just registered your domains wait a few hours for DNS registrations.</li>
</ul>
<h4>III. Install the Domain Mapping plugin and map a domain</h4>
<ul>
<li>First download the plugin <a href="http://wordpress.org/extend/plugins/wordpress-mu-domain-mapping/">WordPress MU Domain Mapping</a> (http://wordpress.org/extend/plugins/wordpress-mu-domain-mapping/). I used version 0.5. <strong>Many many thanks to those guys for creating this awesome plugin.</strong></li>
<li>Copy <strong>sunrise.php</strong> into wp-content/</li>
<li>Copy <strong>domain_mapping.php</strong> into wp-content/mu-plugins/</li>
<li>Edit <strong>wp-config.php</strong> and uncomment the SUNRISE definition line: <strong>define( &#8216;SUNRISE&#8217;, &#8216;on&#8217; );</strong></li>
<li>Now go to Plugins and activate the mapping plugin for the main domain.</li>
<li>After you done those login as the MU admin and go to <strong>Site Admin->Domain Mapping</strong> and set the server IP address. (you should know this from when you added the A record)
<li>Now this is the tricky part on what I wasted a lot of hours. Go to <strong>Site Admin -> Options</strong> and scroll down at the bottom. And after where it says <strong>&#8220;Site Wide Settings&#8221;</strong> click on the check box for the Plugins and click Update Options. This activates the plugins for the sub-domains. If you don&#8217;t do this you can&#8217;t map domains to the specific sub-domain because you will not see the plugin on your sub-domains admin area. (First I actually edited this directly in the database until I realized this.) </li>
<li>Now go to <strong>Site admin -> Blogs</strong> and when you hover over the added sub-domain some link will appear. Click on <strong>&#8220;Backend&#8221;</strong>. This will redirect you to that sub-domain WordPress administration panel.</li>
<li>While in this panel go to <strong>Plugins</strong> and you should see the mapping plugin. Activate it.</li>
<li>And now go to <strong>Tools -> Domain mapping</strong>. And here is the part that we worked so hard to get to. Under <strong>&#8220;Add new domain&#8221;</strong> write the domain that you want to map to this sub-domain.</li>
<li>After you clicked <strong>&#8220;Add&#8221;</strong> go to the domain that you wanted to map (<em>addon-example.com</em>) and you will see the contents of <em>subdomain.master-example.com</em></li>
</ul>
<p>Kind of a long tutorial but hopefully I didn&#8217;t forgot anything in the process.<br />
Let me know in the comments if it helped you or if you still got problems with the install flow.</p>
<p>Cheers!</p>
<img src="http://point47.com/journal/?ak_action=api_record_view&id=61&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://point47.com/journal/2009/12/how-to-setup-wordpress-mu-with-domain-mapping/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>CKEditor 3.0 Send and Receive data with AJAX</title>
		<link>http://point47.com/journal/2009/09/ckeditor-3-0-send-and-receive-data-with-ajax/</link>
		<comments>http://point47.com/journal/2009/09/ckeditor-3-0-send-and-receive-data-with-ajax/#comments</comments>
		<pubDate>Tue, 01 Sep 2009 09:50:11 +0000</pubDate>
		<dc:creator>Sorin</dc:creator>
				<category><![CDATA[AJAX]]></category>
		<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://point47.com/journal/?p=49</guid>
		<description><![CDATA[Attention: This is a quick tutorial and no in depth information will be provided. Use Google or whatever you want to learn more about PHP, Javascript and AJAX calls. Also on the CKEditor site you can find more info about the editor itself. The old FCKEditor is now called CKEditor 3.0 and it&#8217;s: CKEditor is]]></description>
			<content:encoded><![CDATA[<p><em>Attention: This is a quick tutorial and no in depth information will be provided. Use Google or whatever you want to learn more about PHP, Javascript and AJAX calls. Also on the CKEditor site you can find more info about the editor itself. </em></p>
<p>The old FCKEditor is now called CKEditor 3.0 and it&#8217;s:</p>
<blockquote><p>CKEditor is a text editor to be used inside web pages. It&#8217;s a WYSIWYG editor, which means that the text being edited on it looks as similar as possible to the results users have when publishing it. It brings to the web common editing features found on desktop editing applications like Microsoft Word and OpenOffice.</p></blockquote>
<p>You can download it from here: <a href="http://ckeditor.com">http://ckeditor.com</a>.</p>
<p>OK.. so I wanted to edit some HTML template files from an Admin area module and the new CKEditor looks pretty nice so I gave it a try.<br />
First I install the CKEditor and this is pretty easy to do, just download the editor and copy the files to the server.</p>
<p>Create a link to the editor:</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:610px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">&lt;script type=&quot;text/javascript&quot; src=&quot;/ckeditor/ckeditor.js&quot;&gt;&lt;/script&gt;</div></td></tr></tbody></table></div>
<p>and then creat a text field area:</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:610px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">&lt;textarea name=&quot;template_body&quot; id=&quot;template_body&quot; &gt;page content here&lt;/textarea&gt;</div></td></tr></tbody></table></div>
<p>and add the javascript code to load the editor:</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:610px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">&lt;script type=&quot;text/javascript&quot;&gt;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; CKEDITOR.replace( 'template_body' );<br />
&nbsp; &nbsp; &nbsp; &nbsp; &lt;/script&gt;</div></td></tr></tbody></table></div>
<p>I added also a div to hold the received messages from the AJAX calls:</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:610px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">&lt;div id=&quot;saveButton&quot; style=&quot;font-weight:bold&quot;&gt;&lt;/div&gt;</div></td></tr></tbody></table></div>
<p>Then I generated a tree/file view of all the template files(for sake of simplicity I will not show you how to do that).<br />
The links are generated like this:</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:610px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">&lt;a href=&quot;&quot; onclick=&quot;getFile('test.html'); return false;&quot; id=&quot;file&quot; &gt;test.html&lt;/a&gt;</div></td></tr></tbody></table></div>
<p>The return false is so than I won&#8217;t need to use the stupid # on the href=&#8221;" so that the page won&#8217;t refresh.</p>
<p>And the two Javascript functions that make the Ajax calls are:</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:610px;height:400px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br />12<br />13<br />14<br />15<br />16<br />17<br />18<br />19<br />20<br />21<br />22<br />23<br />24<br />25<br />26<br />27<br />28<br />29<br />30<br />31<br />32<br />33<br />34<br />35<br />36<br />37<br />38<br />39<br />40<br />41<br />42<br />43<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">&lt;script type=&quot;text/javascript&quot;&gt;<br />
function getFile(file)<br />
{ &nbsp; &nbsp; &nbsp; <br />
&nbsp; &nbsp; var httpRequest = (!window.XMLHttpRequest)? new ActiveXObject(&quot;Microsoft.XMLHTTP&quot;) : new XMLHttpRequest();<br />
&nbsp; &nbsp; httpRequest.onreadystatechange = function()<br />
&nbsp; &nbsp; {<br />
&nbsp; &nbsp; &nbsp; &nbsp; if(httpRequest.readyState == 4)<br />
&nbsp; &nbsp; &nbsp; &nbsp; {<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; // send info to editor<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; CKEDITOR.instances.template_body.setData(httpRequest.responseText);<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; document.getElementById('saveButton').innerHTML = '&lt;a href=&quot;&quot; onclick=&quot;saveFile(\'' + file + '\'); return false;&quot; &gt;SAVE TEMPLATE&lt;/a&gt;';<br />
&nbsp; &nbsp; &nbsp; &nbsp; }<br />
&nbsp; &nbsp; }<br />
&nbsp; &nbsp; httpRequest.open(&quot;GET&quot;,&quot;/ajax/get_file.php?file=&quot;+file,true);<br />
&nbsp; &nbsp; httpRequest.send(null); &nbsp; &nbsp; &nbsp;<br />
}<br />
<br />
function saveFile(filename)<br />
{ &nbsp; &nbsp;<br />
&nbsp; &nbsp; // get info from editor<br />
&nbsp; &nbsp; var editordata = CKEDITOR.instances.template_body.getData();<br />
<br />
&nbsp; &nbsp; var httpRequest = (!window.XMLHttpRequest)? new ActiveXObject(&quot;Microsoft.XMLHTTP&quot;) : new XMLHttpRequest();<br />
&nbsp; &nbsp; httpRequest.onreadystatechange = function()<br />
&nbsp; &nbsp; {<br />
&nbsp; &nbsp; &nbsp; &nbsp; if(httpRequest.readyState == 4)<br />
&nbsp; &nbsp; &nbsp; &nbsp; {<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; if(httpRequest.responseText == &quot;success&quot;)<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; document.getElementById('saveButton').innerHTML = '&lt;span style=&quot;color:red&quot;&gt;Template saved&lt;/span&gt;';<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; else<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; document.getElementById('saveButton').innerHTML = httpRequest.responseText;<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; }<br />
&nbsp; &nbsp; &nbsp; &nbsp; }<br />
&nbsp; &nbsp; }<br />
&nbsp; &nbsp; var passingData = &quot;file=&quot;+filename+&quot;&amp;template_body=&quot;+ escape(editordata)<br />
&nbsp; &nbsp; httpRequest.open(&quot;POST&quot;, &quot;/ajax/save_file.php?&quot;+passingData, true);<br />
&nbsp; &nbsp; httpRequest.setRequestHeader(&quot;Content-type&quot;, &quot;application/x-www-form-urlencoded&quot;); &nbsp; &nbsp; &nbsp; &nbsp; <br />
&nbsp; &nbsp; httpRequest.send(passingData);<br />
}<br />
&lt;/script&gt;</div></td></tr></tbody></table></div>
<p>The first function <strong>getFile()</strong>, gets the name of the file to load and send the response text from the PHP script to the editor.<br />
The PHP script gets the name of the file and with file_get_contents function I retrieve that template&#8217;s contents.</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:610px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">echo file_get_contents('/templates/'.$_GET['file']);</div></td></tr></tbody></table></div>
<p>The editor shows the received data with the command:</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:610px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">CKEDITOR.instances.template_body.setData(httpRequest.responseText);</div></td></tr></tbody></table></div>
<p>&#8220;template_body&#8221; is the name of the text field that is replaced by the CKEditor.<br />
In this function I also add a new link to the page with innerHTML that makes the reference to the second function: <strong>saveFile()</strong>.</p>
<p>The second function <strong>saveFile()</strong> get the current name of the loaded template (test.html for example) and saves the data from the editor to<br />
a variable &#8220;editordata&#8221; with the call:</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:610px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">CKEDITOR.instances.template_body.getData();</div></td></tr></tbody></table></div>
<p>The editor data is sent to the PHP script, escaped and urlencoded with POST.</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:610px;height:400px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br />8<br />9<br />10<br />11<br />12<br />13<br />14<br />15<br />16<br />17<br />18<br />19<br />20<br />21<br />22<br />23<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">// write content to file <br />
$filename = '/templates/'.$_POST['file'];<br />
$template_body = $_POST['template_body'];<br />
<br />
if (is_writable($filename)) // check file first<br />
{<br />
&nbsp; &nbsp; if (!$handle = fopen($filename, 'w')) &nbsp;// open file<br />
&nbsp; &nbsp; {<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;echo 'fail open';<br />
&nbsp; &nbsp; }<br />
<br />
&nbsp; &nbsp; if (fwrite($handle, $template_body) === FALSE) // write file<br />
&nbsp; &nbsp; {<br />
&nbsp; &nbsp; &nbsp; &nbsp; echo 'fail write';<br />
&nbsp; &nbsp; }<br />
<br />
&nbsp; &nbsp; fclose($handle); // and close the file<br />
&nbsp; &nbsp; echo 'success';<br />
} <br />
else <br />
{<br />
&nbsp; &nbsp; echo 'fail not writable';<br />
}</div></td></tr></tbody></table></div>
<p>The PHP code is straight forward: open file, write contents to file, close file.<br />
If success is returned then with innerHTML we write that the template was saved if not the specific fail message will be shown.<br />
(usually those errors appear if the file is missing or the file path is wrong or the file permissions are wrong.)</p>
<p>So here you have it an browser based template editor.<br />
Oh and if your template has</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:610px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">&lt;html&gt;, &lt;body&gt;</div></td></tr></tbody></table></div>
<p>tags they will be deleted by the editor. Don&#8217;t know how to override that shit functionality.</p>
<p>Over and out.</p>
<p>Hey did you know about this?<br />
<a href="http://themeforest.net?ref=forapathy" title="wordpress themes, site templates, psd" target="_blank"><img src="http://envato.s3.amazonaws.com/referrer_adverts/tf_728x90_v5.gif" alt="wordpress themes, site templates" /></a></p>
<img src="http://point47.com/journal/?ak_action=api_record_view&id=49&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://point47.com/journal/2009/09/ckeditor-3-0-send-and-receive-data-with-ajax/feed/</wfw:commentRss>
		<slash:comments>18</slash:comments>
		</item>
		<item>
		<title>How to block spamm comments in WordPress</title>
		<link>http://point47.com/journal/2009/04/how-to-block-spamm-comments-in-wordpress/</link>
		<comments>http://point47.com/journal/2009/04/how-to-block-spamm-comments-in-wordpress/#comments</comments>
		<pubDate>Wed, 22 Apr 2009 10:06:42 +0000</pubDate>
		<dc:creator>Sorin</dc:creator>
				<category><![CDATA[Wordpress]]></category>

		<guid isPermaLink="false">http://point47.com/journal/?p=43</guid>
		<description><![CDATA[1. Activate Akismet 2. Add this in the .htaccess file. 123456RewriteEngine On RewriteCond %{REQUEST_METHOD} POST RewriteCond %{REQUEST_URI} .wp-comments-post\.php* RewriteCond %{HTTP_REFERER} !.*yourblog.com.* [OR] RewriteCond %{HTTP_USER_AGENT} ^$ RewriteRule (.*) ^http://%{REMOTE_ADDR}/$ [R=301,L] Replace yourblog.com with your blog address. It block all comments from direct access to wp-comments-post.php. 3. Add this to the .htaccess file also. Block all spammer]]></description>
			<content:encoded><![CDATA[<p>1. Activate Akismet<br />
2. Add this in the .htaccess file.</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:610px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">RewriteEngine On<br />
RewriteCond %{REQUEST_METHOD} POST<br />
RewriteCond %{REQUEST_URI} .wp-comments-post\.php*<br />
RewriteCond %{HTTP_REFERER} !.*yourblog.com.* [OR]<br />
RewriteCond %{HTTP_USER_AGENT} ^$<br />
RewriteRule (.*) ^http://%{REMOTE_ADDR}/$ [R=301,L]</div></td></tr></tbody></table></div>
<p>Replace <strong>yourblog.com</strong> with your blog address.<br />
It block all comments from direct access to wp-comments-post.php.</p>
<p>3. Add this to the .htaccess file also.<br />
Block all spammer IP&#8217;s one by one:</p>
<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:610px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">&lt;Limit GET POST&gt;<br />
order allow,deny<br />
deny from 78.133.218.68<br />
deny from 219.159.67.187<br />
deny from 77.41.123.182<br />
allow from all<br />
&lt;/Limit&gt;</div></td></tr></tbody></table></div>
<p>Just add more IP to this list.</p>
<img src="http://point47.com/journal/?ak_action=api_record_view&id=43&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://point47.com/journal/2009/04/how-to-block-spamm-comments-in-wordpress/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Anti link/email spam script</title>
		<link>http://point47.com/journal/2009/03/anti-linkemail-spam-script/</link>
		<comments>http://point47.com/journal/2009/03/anti-linkemail-spam-script/#comments</comments>
		<pubDate>Fri, 13 Mar 2009 10:24:44 +0000</pubDate>
		<dc:creator>Sorin</dc:creator>
				<category><![CDATA[JavaScript]]></category>

		<guid isPermaLink="false">http://point47.com/journal/?p=38</guid>
		<description><![CDATA[123456&#60;script type='text/javascript'&#62; &#160; &#160;function nerf_email(){ &#160; &#160; &#160; return 'offi'.replace(/i/, 'ice') + '@' + 'point'.replace(/t/, 't47.com'); &#160; &#160;} &#160; &#160;document.write(nerf_email()); &#60;/script&#62; The above script will show: office @ point47.com]]></description>
			<content:encoded><![CDATA[<div class="codecolorer-container text default" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:610px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">&lt;script type='text/javascript'&gt;<br />
&nbsp; &nbsp;function nerf_email(){<br />
&nbsp; &nbsp; &nbsp; return 'offi'.replace(/i/, 'ice') + '@' + 'point'.replace(/t/, 't47.com');<br />
&nbsp; &nbsp;}<br />
&nbsp; &nbsp;document.write(nerf_email());<br />
&lt;/script&gt;</div></td></tr></tbody></table></div>
<p>The above script will show: office @ point47.com</p>
<img src="http://point47.com/journal/?ak_action=api_record_view&id=38&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://point47.com/journal/2009/03/anti-linkemail-spam-script/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Cute Bubbles &#8211; WordPress Theme &#8211; Updated</title>
		<link>http://point47.com/journal/2009/01/cute-bubbles-wordpress-theme/</link>
		<comments>http://point47.com/journal/2009/01/cute-bubbles-wordpress-theme/#comments</comments>
		<pubDate>Tue, 27 Jan 2009 09:37:19 +0000</pubDate>
		<dc:creator>Sorin</dc:creator>
				<category><![CDATA[Wordpress]]></category>

		<guid isPermaLink="false">http://point47.com/journal/?p=29</guid>
		<description><![CDATA[Version 1.0 is live and it has full IE6 support, improved header graphic and some more tweaks here and there. You can download the theme from here Cute Bubbles WordPress Theme. Get some more premium templates from here:]]></description>
			<content:encoded><![CDATA[<p>Version 1.0 is live and it has full IE6 support, improved header graphic and some more tweaks here and there. </p>
<p><img src="http://wp-themes.com/wp-content/themes/cute-bubbles/screenshot.png" border="0" alt="cute bubbes wordpress theme" /></p>
<p>You can download the theme from here <a href="http://wp-themes.com/wp-content/themes/cute-bubbles/screenshot.png">Cute Bubbles WordPress Theme</a>.</p>
<p>Get some more premium templates from here:<br />
<a href="http://themeforest.net?ref=forapathy" title="wordpress themes, site templates, psd" target="_blank"><img src="http://envato.s3.amazonaws.com/referrer_adverts/tf_728x90_v2.gif" alt="wordpress themes, site templates" /></a></p>
<img src="http://point47.com/journal/?ak_action=api_record_view&id=29&type=feed" alt="" />]]></content:encoded>
			<wfw:commentRss>http://point47.com/journal/2009/01/cute-bubbles-wordpress-theme/feed/</wfw:commentRss>
		<slash:comments>28</slash:comments>
		</item>
	</channel>
</rss>
