<?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>El Blog del Antonio &#187; PHP</title>
	<atom:link href="http://www.ramirezcobos.com/category/php/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.ramirezcobos.com</link>
	<description>Programming Web with PHP, CSS, Javascript and ∞</description>
	<lastBuildDate>Wed, 14 Jul 2010 14:03:05 +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>PalmStudios Model Agency</title>
		<link>http://www.ramirezcobos.com/2010/07/14/palmstudios-model-agency/</link>
		<comments>http://www.ramirezcobos.com/2010/07/14/palmstudios-model-agency/#comments</comments>
		<pubDate>Wed, 14 Jul 2010 14:03:03 +0000</pubDate>
		<dc:creator>Antonio Ramirez</dc:creator>
				<category><![CDATA[CSS]]></category>
		<category><![CDATA[Design]]></category>
		<category><![CDATA[JQuery]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[Jobs]]></category>

		<guid isPermaLink="false">http://www.ramirezcobos.com/?p=489</guid>
		<description><![CDATA[Hi there, I would like to introduce you my last web project: http://www.palmstudios.com For this project I have developed a sort of MVC (Model View Controller) over the RedBeanPHP DB library (PHP 5.3.2).  This project even though it looks quite simple it has a very power CMS (Content Management System) on its backend that allows]]></description>
			<content:encoded><![CDATA[<p><a rel="attachment wp-att-490" href="http://www.ramirezcobos.com/2010/07/14/palmstudios-model-agency/captura-de-pantalla-2010-07-12-a-las-16-03-00/"><img class="alignright size-medium wp-image-490" title="Captura de pantalla 2010-07-12 a las 16.03.00" src="http://www.ramirezcobos.com/wp-content/uploads/2010/07/Captura-de-pantalla-2010-07-12-a-las-16.03.00-300x248.png" alt="" width="300" height="248" /></a>Hi there,</p>
<p>I would like to introduce you my last web project: <a title="Palmstudios Model Agency" href="http://www.palmstudios.com" target="_blank">http://www.palmstudios.com</a></p>
<p>For this project I have developed a sort of MVC (Model View Controller) over the <a title="RedBean PHP" href="http://www.redbeanphp.com" target="_blank">RedBeanPHP</a> DB library (PHP 5.3.2).  This project even though it looks quite simple it has a very power CMS (Content Management System) on its backend that allows the model agency to control most of the aspects of its business:</p>
<ol>
<li>- Clients Management</li>
<li>- Models Management (Men, Women, Children &amp; Extras) -contact details, measurements, pictures, and so on&#8230;</li>
<li>- Promotional Packages Management &#8211; this is a special addon which allows the agency to create model promotional bundles to send to its clients</li>
</ol>
<p>There is a ton of client and server libraries that this application makes use of, such as:</p>
<ul>
<li>JQuery FancyBox</li>
<li>JQuery Livequery</li>
<li>JQuery AjaxQ</li>
<li>PHPMailer</li>
<li>RedBeanPHP</li>
<li>Savant3 Template Engine</li>
<li>PHPThumb</li>
<li>TinyMCE</li>
</ul>
<p>The CMS has a configuration section where site administrator can configure:</p>
<ul>
<li>Web site languages (has multiple language support)</li>
<li>Web site translations (you can even ask GOOGLE about a translation depending of the languages installed on the system)</li>
<li>Model properties (size, height, waist, etc&#8230;)</li>
<li>Hair Colors</li>
<li>Eye Colors</li>
<li>Users</li>
</ul>
<p>Here is a snapshot gallery of the Site and its CMS</p>

<a href='http://www.ramirezcobos.com/2010/07/14/palmstudios-model-agency/captura-de-pantalla-2010-07-12-a-las-16-03-00/' title='Captura de pantalla 2010-07-12 a las 16.03.00'><img width="120" height="120" src="http://www.ramirezcobos.com/wp-content/uploads/2010/07/Captura-de-pantalla-2010-07-12-a-las-16.03.00-120x120.png" class="attachment-thumbnail" alt="Captura de pantalla 2010-07-12 a las 16.03.00" title="Captura de pantalla 2010-07-12 a las 16.03.00" /></a>
<a href='http://www.ramirezcobos.com/2010/07/14/palmstudios-model-agency/captura-de-pantalla-2010-07-12-a-las-16-07-44/' title='Captura de pantalla 2010-07-12 a las 16.07.44'><img width="120" height="120" src="http://www.ramirezcobos.com/wp-content/uploads/2010/07/Captura-de-pantalla-2010-07-12-a-las-16.07.44-120x120.png" class="attachment-thumbnail" alt="Captura de pantalla 2010-07-12 a las 16.07.44" title="Captura de pantalla 2010-07-12 a las 16.07.44" /></a>
<a href='http://www.ramirezcobos.com/2010/07/14/palmstudios-model-agency/captura-de-pantalla-2010-07-12-a-las-16-08-21/' title='Captura de pantalla 2010-07-12 a las 16.08.21'><img width="120" height="120" src="http://www.ramirezcobos.com/wp-content/uploads/2010/07/Captura-de-pantalla-2010-07-12-a-las-16.08.21-120x120.png" class="attachment-thumbnail" alt="Captura de pantalla 2010-07-12 a las 16.08.21" title="Captura de pantalla 2010-07-12 a las 16.08.21" /></a>
<a href='http://www.ramirezcobos.com/2010/07/14/palmstudios-model-agency/captura-de-pantalla-2010-07-12-a-las-16-09-01/' title='Captura de pantalla 2010-07-12 a las 16.09.01'><img width="120" height="120" src="http://www.ramirezcobos.com/wp-content/uploads/2010/07/Captura-de-pantalla-2010-07-12-a-las-16.09.01-120x120.png" class="attachment-thumbnail" alt="Captura de pantalla 2010-07-12 a las 16.09.01" title="Captura de pantalla 2010-07-12 a las 16.09.01" /></a>
<a href='http://www.ramirezcobos.com/2010/07/14/palmstudios-model-agency/captura-de-pantalla-2010-07-12-a-las-16-09-27/' title='Captura de pantalla 2010-07-12 a las 16.09.27'><img width="120" height="120" src="http://www.ramirezcobos.com/wp-content/uploads/2010/07/Captura-de-pantalla-2010-07-12-a-las-16.09.27-120x120.png" class="attachment-thumbnail" alt="Captura de pantalla 2010-07-12 a las 16.09.27" title="Captura de pantalla 2010-07-12 a las 16.09.27" /></a>
<a href='http://www.ramirezcobos.com/2010/07/14/palmstudios-model-agency/captura-de-pantalla-2010-07-12-a-las-16-03-31/' title='Captura de pantalla 2010-07-12 a las 16.03.31'><img width="120" height="120" src="http://www.ramirezcobos.com/wp-content/uploads/2010/07/Captura-de-pantalla-2010-07-12-a-las-16.03.31-120x120.png" class="attachment-thumbnail" alt="Captura de pantalla 2010-07-12 a las 16.03.31" title="Captura de pantalla 2010-07-12 a las 16.03.31" /></a>
<a href='http://www.ramirezcobos.com/2010/07/14/palmstudios-model-agency/captura-de-pantalla-2010-07-12-a-las-16-03-53/' title='Captura de pantalla 2010-07-12 a las 16.03.53'><img width="120" height="120" src="http://www.ramirezcobos.com/wp-content/uploads/2010/07/Captura-de-pantalla-2010-07-12-a-las-16.03.53-120x120.png" class="attachment-thumbnail" alt="Captura de pantalla 2010-07-12 a las 16.03.53" title="Captura de pantalla 2010-07-12 a las 16.03.53" /></a>

<h2>I am open for Freelance Jobs</h2>
<p>If any of you would like to create a model agency application like this, let me know, I will be more than happy to collaborate with you on it. I will also sell the source code of its panel for any of you who is interested.</p>
<p><center><br />
<script type="text/javascript"><!--
google_ad_client = "pub-7060132287364604";
/* 468x60, creado 16/03/10 */
google_ad_slot = "9029910384";
google_ad_width = 468;
google_ad_height = 60;
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script><br />
</center></p>
]]></content:encoded>
			<wfw:commentRss>http://www.ramirezcobos.com/2010/07/14/palmstudios-model-agency/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Yii Framework -Final Decision</title>
		<link>http://www.ramirezcobos.com/2010/06/19/yii-framework-final-decision/</link>
		<comments>http://www.ramirezcobos.com/2010/06/19/yii-framework-final-decision/#comments</comments>
		<pubDate>Sat, 19 Jun 2010 18:43:51 +0000</pubDate>
		<dc:creator>Antonio Ramirez</dc:creator>
				<category><![CDATA[On The Web]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[Tools]]></category>
		<category><![CDATA[Frameowrk]]></category>
		<category><![CDATA[MVC]]></category>

		<guid isPermaLink="false">http://www.ramirezcobos.com/?p=481</guid>
		<description><![CDATA[I never felt comfortable with external libraries, those created by other people. Always, since my old times with Visual Basic, have created my own and until now, everything I created was good enough but&#8230; Suddenly, after I found that marvellous library called RedBean, I found my self re-programming all my libraries and end up creating]]></description>
			<content:encoded><![CDATA[<p><a rel="attachment wp-att-483" href="http://www.ramirezcobos.com/2010/06/19/yii-framework-final-decision/yii_logo-300x300/"><img class="alignright size-full wp-image-483" title="Yii Framework" src="http://www.ramirezcobos.com/wp-content/uploads/2010/06/yii_logo-300x300.jpg" alt="" width="300" height="300" /></a>I never felt comfortable with external libraries, those created by other people. Always, since my old times with Visual Basic, have created my own and until now, everything I created was good enough but&#8230; Suddenly, after I found that marvellous library called <a href="http://www.redbeanphp.com" target="_blank">RedBean</a>, I found my self re-programming all my libraries and end up creating a controller and a base model class for a sort of MVC library &#8211; I will post it one of these days so you guys can look at it and find out how easy is to implement that incredible library is (thanks Gabor de Mooij!) on your libraries.</p>
<p>But, as a programmer, I started to think that, even though my own libraries speed up my development processes, I want it to be hands on a bigger and more ambitious projects -that happened long time a go but never felt impressed by any library out there. My libraries lacked on scalable development architecture and had to find for a better solution for a much bigger project I am jumping right now. I google around and found interesting offers as exposed on <a href="http://www.ramirezcobos.com/2010/01/26/php-frameworks/" target="_blank">one of my old posts</a>:</p>
<ul>
<li><a href="http://www.codeigniter.com" target="_blank">CodeIgniter</a></li>
<li><a href="http://www.yiiframework.com/">Yii</a></li>
<li><a href="http://www.cakephp.org" target="_blank">CakePHP</a></li>
<li><a href="http://framework.zend.com/home" target="_blank">Zend</a></li>
<li><a href="http://www.symfony-project.com/" target="_blank">Symfony</a></li>
<li><a href="http://www.phpdevshell.org/" target="_blank">PHPDevShell</a></li>
<li><a href="http://www.pradosoft.com/" target="_blank">Prado</a></li>
<li><a href="http://www.akelos.org/" target="_blank">Akelos</a></li>
<li><a href="http://www.akelos.org/" target="_blank">ZooP</a></li>
<li><a href="http://qphp.net/" target="_blank">QPHP</a></li>
<li><a href="http://www.ez.no/ezcomponents" target="_blank">ezComponents</a></li>
<li><a href="http://www.doophp.com/" target="_blank">DooPHP</a></li>
</ul>
<p>Actually, far too many, so I took my time to decide for one to suit all my needs. Checked around and read some good articles about Yii framework and then, telling the truth, I was very impressed with (information taken from <a href="http://programmersnotes.info/2009/02/24/yii_framework_of_my_choice/" target="_self">http://programmersnotes.info</a>:</p>
<ul>
<li>100% OO architecture. It is really good application design.</li>
<li>Authentication &amp; roles mechanism</li>
<li>Caching techniques</li>
<li>DB access, which is based on PDO</li>
<li>Active record and relational active record implementation</li>
<li>Validation – that is really, really nice. To create quite complex  register form (check if login is unique, if email is unique, email match  with confirmation, passwords match, validate integer/string values,  check empty fields and give nice error messages for each field you need  only template (view) and model with rules defined. It took me 10-15 mins  to do that!)</li>
<li>Component concept. Just to give an idea, why is it nice – you can  define getter and setter methods for properties, you can define  read-only properties for components, define and invoke events, attach  event handlers and additional features to the class without modifying  it, just by attaching additional behaviour to it</li>
<li>Also, check its graphical benchmarking against other MVC frameworks <a href="http://www.yiiframework.com/performance" target="_blank">http://www.yiiframework.com/performance</a>.</li>
</ul>
<p>Wondering whether <a href="http://www.doophp.com">DooPHP</a> (claiming is the fastest at the moment) or <a href="http://www.yiiframework.com/" target="_blank">Yii</a>, I finally decided to use the latest due that DooPHP is quite new and Yii has a huge amount of features and tweaks that, even its documentation is not the best (I just read their Definitive Guide and I think I will have to read to a couple of hundreds articles more to be &#8216;good&#8217; at it), I think at the end will become the Toolset for highly scalable projects -using its automation tool called <a href="http://www.yiiframework.com/doc/guide/topics.gii" target="_blank">Gii</a>, I did the skeleton of a project in less than 30 seconds -duh!.</p>
<p>In addition. last but not least, you can integrate <a href="http://framework.zend.com/manual/components">Zend components</a> easily and <a href="http://www.jquery.com" target="_blank">jQuery</a> is nativelly implemented -and I loooooove jQuery.</p>
<p>For the small ones I still like my own libraries though <img src='http://www.ramirezcobos.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /><br />
<script type="text/javascript"><!--
google_ad_client = "pub-7060132287364604";
/* 468x60, creado 16/03/10 */
google_ad_slot = "9029910384";
google_ad_width = 468;
google_ad_height = 60;
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script></p>
]]></content:encoded>
			<wfw:commentRss>http://www.ramirezcobos.com/2010/06/19/yii-framework-final-decision/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Uri Class for PHP</title>
		<link>http://www.ramirezcobos.com/2010/06/10/uri-class-for-php/</link>
		<comments>http://www.ramirezcobos.com/2010/06/10/uri-class-for-php/#comments</comments>
		<pubDate>Thu, 10 Jun 2010 07:38:15 +0000</pubDate>
		<dc:creator>Antonio Ramirez</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[Tools]]></category>
		<category><![CDATA[Open Source]]></category>

		<guid isPermaLink="false">http://www.ramirezcobos.com/?p=466</guid>
		<description><![CDATA[For years, we developers tend to keep functions that we find useful into our projects, after certain time they become obsolete or you move one to higher level ways of programming. Some of us, can&#8217;t get rid of the code that was once collected-created and I thought let&#8217;s see if I post one of my]]></description>
			<content:encoded><![CDATA[<p style="text-align: justify;"><a rel="attachment wp-att-467" href="http://www.ramirezcobos.com/2010/06/10/uri-class-for-php/open-source/"><img class="alignright size-medium wp-image-467" title="open-source" src="http://www.ramirezcobos.com/wp-content/uploads/2010/06/open-source-300x258.png" alt="" width="300" height="258" /></a>For years, we developers tend to keep functions that we find useful into our projects, after certain time they become obsolete or you move one to higher level ways of programming. Some of us, can&#8217;t get rid of the code that was once collected-created and I thought let&#8217;s see if I post one of my silly old classes what can we get out of it? Let&#8217;s make it open source hahahaha.</p>
<p style="text-align: justify;">I propose you the following: Here is my small old good set of Uri PHP functions encapsulated into one class, I know is not a great deal but, let&#8217;s see what can we all do with it. For every programmer that posts a function, I will write his reference into the class and post his/her site link in this post.</p>
<p style="text-align: justify;">There are certain rules though:</p>
<ol style="text-align: justify;">
<li>Functions cannot be greater than 20 lines of code</li>
<li>Functions cannot depend of far too many external components (maximum one)</li>
<li>If functions depend of an external component/class, a URL indicating its reference must be provided</li>
<li>Functions are not to be repetitive, if there is one better written that the ones exposes we will replace it</li>
</ol>
<h3 style="text-align: justify;">The Uri Class</h3>
<p style="text-align: justify;">Here is my class:</p>
<p style="text-align: justify;">
<pre class="brush: php;">
&lt;?php
/**
 * @author Antonio Ramirez &lt;contactme@atmyblog.com&gt;
 * @license http://opensource.org/licenses/gpl-license.php GNU Public License
 * @link http://www.ramirezcobos.com/
 *
 *
 */
class Uri
{
	/**
	 * Encodes the parameter to hide
	 * its contents to user
	 *
	 * @param string $val
	 */
	function uriEncode($val)
	{
		return rawurlencode(base64_encode($val));
	}
	/**
	 * Decodes a parameter string that
	 * was previously encoded with uriEncode
	 * function
	 *
	 * @param string $val
	 */
	function uriDecode($val){
		return base64_decode(rawurldecode($val));
	}
	/**
	 * Translates a given url to
	 * tinyurl version -curl required
	 *
	 * @param string $url
	 * @access public
	 * @return string $data
	 */
	function getTinyUrl($url){
		$ch = curl_init();
		$timeout = 5;
		curl_setopt($ch,CURLOPT_URL,'http://tinyurl.com/api-create.php?url='.$url);
		curl_setopt($ch,CURLOPT_RETURNTRANSFER,1);
		curl_setopt($ch,CURLOPT_CONNECTTIMEOUT,$timeout);
		$data = curl_exec($ch);
		curl_close($ch);
		return $data;
	}
	/**
	 * Translates a given url to
	 * ToLyUrl version -curl required
	 *
	 * @param string $url
	 * @access public
	 * @return string $data
	 */
	function getToLyUrl($url){
		$ch = curl_init();

		curl_setopt($ch, CURLOPT_URL, 'http://to.ly/api.php?longurl='.urlencode($url));
		curl_setopt($ch, CURLOPT_RETURNTRANSFER,1);
		curl_setopt($ch, CURLOPT_HEADER, 0);

		$data = curl_exec ($ch);
		curl_close ($ch);

		return $data;
	}
	/**
     * Gets Request param
     *
     * @param string $paramName
     * @param string $slash
     * @access public
     * @return string $param or boolean $false
     */
	function getParam($paramName, $slash=false)
	{
		return (isset($_REQUEST[$paramName])?($slash?addslashes($_REQUEST[$paramName]):$_REQUEST[$paramName]):false);
	}
	/**
     * Serializes Request params
     *
     * @param string $notThisOne
     * @access public
     * @return string $query_string
     */
	function getParams($notThisOne=false)
  	{
		global $REQUEST_METHOD, $HTTP_GET_VARS, $HTTP_POST_VARS;
		$query_string='';
		if (strpos($_SERVER['REQUEST_URI'],&quot;?&quot;))
		{
			list($fullfile, $voided) = explode(&quot;?&quot;, $_SERVER['REQUEST_URI']);
			$cgi = $_SERVER['REQUEST_METHOD'] == 'GET' ? $HTTP_GET_VARS : $HTTP_POST_VARS;
			reset ($cgi);
			while (list($key, $value) = each($cgi)) {
			  if ($key != $notThisOne)
				$query_string .= &quot;&amp;&quot; . $key . &quot;=&quot; . $value;
			}
		}
		return $query_string;
  	}
	/**
     * Makes a Soap Call
     *
     * @param string $uri
     * @param string $command
     * @param string $xml
     * @access public
     * @return string $response
     *
     * Requires Soap
     */
	function makeSoapCall($uri,$command,$xml)
	{

		try{

			ini_set('default_socket_timeout',10); // ten seconds, that is all we wait

			$client = new SoapClient($uri,array(&quot;connection_timeout&quot;=&gt;10));

			$response =  $client-&gt;__soapCall($command,array(new SoapParam($xml,'Peticion')));
		}
		catch(Exception $e){

			$response = false;
		}
		return $response;
	}
	/**
	 * Parses a given $url for validation
	 *
	 * @param string $url
	 * @access public
	 * @return $parsed_url
	 */
	function getParsedUrl($url)
	{
		$parsed_url = parse_url($url);

		if (!isset($parsed_url['scheme']) or $parsed_url['scheme'] != 'http'){
			echo 'Unsupported URL sheme given, please just use &quot;HTTP&quot;.';
			exit();
		}
		if (!isset($parsed_url['host']) or $parsed_url['host'] == ''){
			echo 'Invalid URL given!';
			exit();
		}

		$host = $parsed_url['host'];
		$host .= (isset($parsed_url['port']) and  !empty($parsed_url['port'])) ? ':'.$parsed_url['port'] : '';
		$path = (isset($parsed_url['path']) and  !empty($parsed_url['path'])) ? $parsed_url['path'] : '/';
		$path .= (isset($parsed_url['query']) and  !empty($parsed_url['query'])) ? '?'.$parsed_url['query'] : '';

		return 'http://' . $host . $path;
	}
	/**
     * Requests a Url and returns its contents
     *
     * @param string $url
     * @access public
     * @return string $query_string
     * @uses Snoopy class http://sourceforge.net/projects/snoopy/
     */
	function getUrlContent($url)
	{
		App::import('component','snoopy');

		$url = Uri::getParsedUrl($url);

		$snoopy = new Snoopy();
		$snoopy-&gt;agent = 'Mozilla/5.0 (Macintosh; U; Intel Mac OS X; es-ES; rv:1.8.1.12) Gecko/20080201 Firefox/2.0.0.12';
		$snoopy-&gt;referer = '';

		$results = false;

		if($snoopy-&gt;fetch($url)){

			$results = $snoopy-&gt;results;
			// empty buffer:
			$snoopy-&gt;results = '';
		}

		return $results;
	}
}
?&gt;
</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.ramirezcobos.com/2010/06/10/uri-class-for-php/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>RedBean ORM</title>
		<link>http://www.ramirezcobos.com/2010/06/07/redbean-orm/</link>
		<comments>http://www.ramirezcobos.com/2010/06/07/redbean-orm/#comments</comments>
		<pubDate>Mon, 07 Jun 2010 09:34:21 +0000</pubDate>
		<dc:creator>Antonio Ramirez</dc:creator>
				<category><![CDATA[On The Web]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">http://www.ramirezcobos.com/?p=457</guid>
		<description><![CDATA[I was breaking my head towards to find a better ORM approach for my own written framework. I used, and was very happy with P.O.R.K., for quite long time but, as most of us, I was looking for something that could improve the speed of my projects. P.O.R.K. configuration is not hard at all, it]]></description>
			<content:encoded><![CDATA[<p><a rel="attachment wp-att-458" href="http://www.ramirezcobos.com/2010/06/07/redbean-orm/redb/"><img class="alignright size-medium wp-image-458" title="redB" src="http://www.ramirezcobos.com/wp-content/uploads/2010/06/redB-300x180.jpg" alt="" width="300" height="180" /></a>I was breaking my head towards to find a better <a href="http://en.wikipedia.org/wiki/Object-relational_mapping" target="_blank">ORM</a> approach for my own written framework. I used, and was very happy with <a href="http://www.schizofreend.nl/Pork.dbObject" target="_blank">P.O.R.K.</a>, for quite long time but, as most of us, I was looking for something that could improve the speed of my projects. <a href="http://www.schizofreend.nl/Pork.dbObject" target="_blank">P.O.R.K.</a> configuration is not hard at all, it is compound of a set of classes encapsulated in three files that allowed me to create <a href="http://en.wikipedia.org/wiki/Model%E2%80%93view%E2%80%93controller">models</a> in sort of ActiveRecord style and was really, really good when I first started.</p>
<p>Now my projects are bigger, require a lot more of database analysis and those sometimes go up to 30 tables or more. That means that once analysed a project, I had to create those tables in the database, specify their fields and so on&#8230; you know.</p>
<p>I found my self into the lazyness mode and I was already thinking that it could be great to create a set of libraries that do not require any configuration files at all and could manipulate my databases in such a way that not only queries for data but also dynamically creates the tables for me if they do not exists. That could save me around one or two days of work I thought&#8230;</p>
<p>Before creating anything I ask mr &#8216;Google&#8217; if there was something around that could match my concept (never reinvent the wheel) and OH MY&#8230; I found it, its name is <a href="http://redbeanphp.com/" target="_blank">RedBean</a> and I have to say that is one of the greatest libraries that have ever came across.</p>
<p><strong>How it works</strong></p>
<p>Create a database</p>
<p>Include the required files to work with RedBean -one file: redbean.inc.php</p>
<pre class="brush: php;">

include('mypathto/redbean.inc.php&quot;);
</pre>
<p>Access its core:</p>
<pre class="brush: php;">
//Assemble a database connection string (DSN)
$dsn = &quot;mysql:host=localhost;dbname=mydatabasename&quot;;

//Connect to database and fetch the toolbox; either with password
$toolbox = RedBean_Setup::kickstartDev($dsn, $username, $password);
</pre>
<p>Now, just for this example: creating one Bean</p>
<pre class="brush: php;">

$rb = $toolbox-&gt;getRedBean();

// lets create one object that we didnt even declared anywhere <img src='http://www.ramirezcobos.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />
$post = $rb-&gt;dispense('post');

// set some variables -fields
$post-&gt;title = 'This is magic';
$post-&gt;created = date('Y-m-d');

// save newly created object to database (how come?)
$rb-&gt;store($post);
</pre>
<p>If we were to look onto our database, we will find now that a new table is created called &#8216;post&#8217; and your bean has successfully saved its properties.</p>
<p>Of course, this is a silly example, in my case I am using redbean on a MVC &#8216;modified&#8217; pattern (I don&#8217;t like the &#8216;View&#8217; part as it is implemented in modern frameworks and for small projects I use my own approach). Please, have a look to its manual, trust me, it is <a href="http://redbeanphp.com/#/beans" target="_blank">worth</a> a try.</p>
<p>From the deep of my heart, THANKS for such a great job to his developer mr (Gabor) de Mooij. At last, one EASY yet POWERFULL library for our projects that really help us saving developing time.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ramirezcobos.com/2010/06/07/redbean-orm/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Zend Server CE Personal Experience</title>
		<link>http://www.ramirezcobos.com/2010/06/03/zend-server-ce-personal-experience/</link>
		<comments>http://www.ramirezcobos.com/2010/06/03/zend-server-ce-personal-experience/#comments</comments>
		<pubDate>Thu, 03 Jun 2010 11:30:22 +0000</pubDate>
		<dc:creator>Antonio Ramirez</dc:creator>
				<category><![CDATA[On The Web]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[Tools]]></category>

		<guid isPermaLink="false">http://www.ramirezcobos.com/?p=449</guid>
		<description><![CDATA[I would like to tell you all about my &#8216;incredible&#8217; experience with one of the new Zend Tools called &#8216;Zend Server&#8217;.  The experience was &#8216;so great&#8217; that it took me six days to recover my self, if I tell you the truth guys, I nearly got into depression. Have you ever experience a series of]]></description>
			<content:encoded><![CDATA[<p><a rel="attachment wp-att-450" href="http://www.ramirezcobos.com/2010/06/03/zend-server-ce-personal-experience/captura-de-pantalla-2010-06-03-a-las-12-54-16/"><img class="alignright size-medium wp-image-450" title="Captura de pantalla 2010-06-03 a las 12.54.16" src="http://www.ramirezcobos.com/wp-content/uploads/2010/06/Captura-de-pantalla-2010-06-03-a-las-12.54.16-300x227.png" alt="" width="300" height="227" /></a>I would like to tell you all about my &#8216;incredible&#8217; experience with one of the new Zend Tools called &#8216;Zend Server&#8217;.  The experience was &#8216;so great&#8217; that it took me six days to recover my self, if I tell you the truth guys, I nearly got into depression.</p>
<p>Have you ever experience a series of &#8216;impossible things&#8217; that happened one after the other without any comprehension? Well, that happens to me with Zend Server CE.</p>
<p>I am currently running a MacOSX Snow Leopard on a 17 inch MacBook Pro for the development of my projects and I have the built in Apache, PHP 5.3.1, and MySQL 5.1 as a backend DB. I do work with Dreamweaber CS4 to develop the GUI interfaces together with PhotoShop and Fireworks (all from Adobe Creative Studio CS4) and use Eclipse modified for PHP and Javascript developments (it is free but Zend calls it Zend Studio, implements some gadgets here and there a voilá, a 400 dollars product) . To debug my client-side code I do have Firebug and that&#8217;s it.</p>
<p>If I tell you the truth everything was working fine, but I wanted to tweak a bit more the performance of my code (we all do that), so I checked the Zend Tool Zend Server CE. Its documentation was quite good and for the comments of the rest of the programmers I thought was worth a try. This is what happened:</p>
<ol>
<li>download and install Zend CE Server</li>
<li>restarted my computer</li>
<li>started Zend Server</li>
<li>damn, nothing works here, nothing! my computer suddenly slows down, what is happening?</li>
<li>looked at the processes, my God! mr Zend Server had five PHP opened at the same time as a service! And also a service controller that doesnt allow me to stop any of the Services!</li>
<li>this is crap! how should i stop this? info: <a href="http://files.zend.com/help/Zend-Server-Community-Edition/mac_osx_installation.htm">http://files.zend.com/help/Zend-Server-Community-Edition/mac_osx_installation.htm</a></li>
<li>this info is even worst, where is installed? where all those scripts that the documentation is talking about? on the Applications folder (where is installed) there is nothing as what they are saying</li>
<li>found it (have to view hidden files in my Mac, done -defaults write com.apple.finder AppleShowAllFiles FALSE) with a full Mac Search (thanks spotlight)</li>
<li>uninstalling application</li>
<li>restarted computer</li>
<li>going to code a bit, going to Applications folder&#8230; diablo! my Finder crashes!</li>
<li>found tones of info, none of them worked -.DStore, .launch Services, .Onyx, etc, reinstall Snow on top, not a fresh install&#8230; reboot, Finder still crashes</li>
<li>building backups (Time Machine is quite old -a week?), whilst in the process&#8230; see next</li>
<li>looked onto Apache XAMPP install (I do not use it anymore), what??!! htpdocs and all mysql databases GONE!</li>
<li>i rund around my house screaming, yelling, and asking God why this is happening to me thousand times! -dont laugh, you probably did it a couple of times too</li>
<li>Worked with Data Recovery, FileSavage, and some data recovery programs that didn&#8217;t help at all&#8230; where are all those files?</li>
<li>last solution: fresh install Snow Leopard, Carbon Copy Cloner and TimeMachine working together for a scheduled daily backups.</li>
</ol>
<p>Well, thank you very much Zend Server, you obviously helped me to improve the performance of my code as I had to rebuild all those libraries that weren&#8217;t backed up before making my code faster, cleaner and easy to implement and use&#8230; woaw, unreal.</p>
<p>Also, thanks Zend Server CE as I reinstall my OS, having only those apps that really are part of my development process and making me buy a 1.5 TB external drive to have all my backups saved daily. If it wasnt for you I wouldn&#8217;t bother spending my money on such things. You rock Zend Server!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ramirezcobos.com/2010/06/03/zend-server-ce-personal-experience/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>Restaurant Casablanca</title>
		<link>http://www.ramirezcobos.com/2010/05/14/restaurant-casablanca/</link>
		<comments>http://www.ramirezcobos.com/2010/05/14/restaurant-casablanca/#comments</comments>
		<pubDate>Fri, 14 May 2010 10:12:57 +0000</pubDate>
		<dc:creator>Antonio Ramirez</dc:creator>
				<category><![CDATA[JQuery]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[Portfolio]]></category>

		<guid isPermaLink="false">http://www.ramirezcobos.com/?p=423</guid>
		<description><![CDATA[Another site finished: www.brunocasablanca.com Yeah, is a restaurant business, located in one of the most beautiful places in the Balearic Islands: Betlem, in La Colonia de San Pedro, Majorca, Spain. The site uses a web panel to control: Picture Galleries Web site content Translations Events Suggestions In this site I make use of one of]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.ramirezcobos.com/wp-content/uploads/2010/02/Imagen-5.png"></a><a href="http://www.ramirezcobos.com/wp-content/uploads/2010/03/Imagen-5-300x274.png"></a><a href="http://www.ramirezcobos.com/wp-content/uploads/2010/02/Imagen-5-300x274.png"></a><strong><span style="font-weight: normal;"> </span></strong></p>
<div id="attachment_410" class="wp-caption alignright" style="width: 310px"><a rel="attachment wp-att-410" href="http://www.ramirezcobos.com/2010/03/31/torrenova-rentacar/picture-1-5/"><a rel="attachment wp-att-425" href="http://www.ramirezcobos.com/2010/05/14/restaurant-casablanca/screen-shot-2010-05-14-at-11-59-50/"><img class="alignright size-medium wp-image-425" title="Screen shot 2010-05-14 at 11.59.50" src="http://www.ramirezcobos.com/wp-content/uploads/2010/05/Screen-shot-2010-05-14-at-11.59.50-300x214.png" alt="" width="300" height="214" /></a></a><p class="wp-caption-text">Bruno Casablanca Restaurant and Pizzeria</p></div>
<p><em>Another site finished: <a href="http://www.brunocasablanca.com" target="_blank">www.brunocasablanca.com</a></em></p>
<p>Yeah, is a restaurant business, located in one of the most beautiful places in the Balearic Islands: Betlem, in La Colonia de San Pedro, Majorca, Spain. The site uses a web panel to control:</p>
<ul>
<li>Picture Galleries</li>
<li>Web site content</li>
<li>Translations</li>
<li>Events</li>
<li>Suggestions</li>
</ul>
<p>In this site I make use of one of the greatest galleries around <a href="http://www.pirolab.it/pirobox/" target="_blank">Pirobox</a>, <a href="http://blog.philipbrown.id.au/2009/04/boxen-a-jquery-iframe-plugin/" target="_blank">boxen</a> -to display the menu, and <a href="http://page-flip.com/products/" target="_blank">FlippingBook HTML Edition</a> for the menu viewing. You can check the website and see how I implemented these three cool tools, feel free to ask me any doubt related to them in case you wish to use it in any of your sites.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ramirezcobos.com/2010/05/14/restaurant-casablanca/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Bookakar.com Finally!</title>
		<link>http://www.ramirezcobos.com/2010/02/24/bookakar-com-finally/</link>
		<comments>http://www.ramirezcobos.com/2010/02/24/bookakar-com-finally/#comments</comments>
		<pubDate>Wed, 24 Feb 2010 09:03:55 +0000</pubDate>
		<dc:creator>Antonio Ramirez</dc:creator>
				<category><![CDATA[Ajax]]></category>
		<category><![CDATA[CSS]]></category>
		<category><![CDATA[Design]]></category>
		<category><![CDATA[On The Web]]></category>
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://www.ramirezcobos.com/?p=279</guid>
		<description><![CDATA[Finally, after long time of work, the first release of my own company: bookakar.com. I have implemented lots of concepts widely spread throughout the Internet and I truly hope that they all work. Still, lot of work to do but as soon as I have spare time I will share with all of you guys]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.ramirezcobos.com/wp-content/uploads/2010/02/Imagen-5.png"></a><a href="http://www.ramirezcobos.com/wp-content/uploads/2010/03/Imagen-5-300x274.png"></a><a href="http://www.ramirezcobos.com/wp-content/uploads/2010/02/Imagen-5-300x274.png"><img class="alignright size-full wp-image-381" title="Imagen-5-300x274" src="http://www.ramirezcobos.com/wp-content/uploads/2010/02/Imagen-5-300x274.png" alt="" width="300" height="274" /></a><strong><em>Finally, after long time of work, the first release of my own company: <a href="http://www.bookakar.com" target="_blank">bookakar.com</a>. </em></strong></p>
<p>I have implemented lots of concepts widely spread throughout the Internet and I truly hope that they all work. Still, lot of work to do but as soon as I have spare time I will share with all of you guys lots of PHP and JS bits and pieces that I hope we, all together, could improve in order to make a great Open Source Resource for everybody to use.</p>
<p>For example, I have developed a set of PHP classes that help PHP programmers to implement GMaps without the need of Javascript knowledge.</p>
<p>I can wait to share&#8230;</p>
<p>Anyway, any feedback related to my site will be highly appreciated. One more thing and very important: <a href="http://ie6funeral.com/" target="_blank">I DO NOT SUPPORT INTERNET EXPLORER</a> due to its security pitfalls on the bank payment gateway and its sillly way of understanding CSS rendering and styles -and I don&#8217;t mention its JS engine at all.</p>
<p><a href="http://www.bookakar.com" target="_blank">Bookakar.com</a> works only on two Spanish areas: Alicante and Ibiza, but it will grow to other areas very soon.
<a href='http://www.ramirezcobos.com/2010/02/24/bookakar-com-finally/imagen-5-300x274-2/' title='Imagen-5-300x274'><img width="120" height="120" src="http://www.ramirezcobos.com/wp-content/uploads/2010/02/Imagen-5-300x274-120x120.png" class="attachment-thumbnail" alt="Imagen-5-300x274" title="Imagen-5-300x274" /></a>
<a href='http://www.ramirezcobos.com/2010/02/24/bookakar-com-finally/imagen-5-300x274/' title='Imagen-5-300x274'><img width="120" height="120" src="http://www.ramirezcobos.com/wp-content/uploads/2010/03/Imagen-5-300x274-150x150.png" class="attachment-thumbnail" alt="Imagen-5-300x274" title="Imagen-5-300x274" /></a>
</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ramirezcobos.com/2010/02/24/bookakar-com-finally/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Hip Hop for PHP?</title>
		<link>http://www.ramirezcobos.com/2010/02/03/hip-hop/</link>
		<comments>http://www.ramirezcobos.com/2010/02/03/hip-hop/#comments</comments>
		<pubDate>Wed, 03 Feb 2010 16:04:50 +0000</pubDate>
		<dc:creator>Antonio Ramirez</dc:creator>
				<category><![CDATA[On The Web]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[Tools]]></category>
		<category><![CDATA[News]]></category>

		<guid isPermaLink="false">http://www.ramirezcobos.com/?p=270</guid>
		<description><![CDATA[Guys, it seems that the days of breaking your head towards how to protect your PHP code is about to end. Following a great article from the Web explaining what happens nowadays with PHP Hip Hop Facebook&#8217;s approach. The open source dynamic scripting language PHP is widely deployed across the Web, powering countless Web sites]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.ramirezcobos.com/wp-content/uploads/2010/02/Imagen-1.png"></a><a href="http://www.ramirezcobos.com/wp-content/uploads/2010/03/Imagen-1-300x201.png"></a><a href="http://www.ramirezcobos.com/wp-content/uploads/2010/03/Imagen-1-300x201.png"></a><a href="http://www.ramirezcobos.com/wp-content/uploads/2010/02/Imagen-1.png"><img class="alignright size-medium wp-image-379" title="Imagen-1" src="http://www.ramirezcobos.com/wp-content/uploads/2010/02/Imagen-1-300x201.png" alt="" width="300" height="201" /></a>Guys, it seems that the days of breaking your head towards how to protect your PHP code is about to end. Following a great article from the Web explaining what happens nowadays with PHP Hip Hop Facebook&#8217;s approach.</p>
<p>The open source dynamic scripting language PHP is widely deployed across the Web, powering countless Web sites (including the Internet.com network). Now Facebook is aiming to change the game with today&#8217;s release of a major new PHP effort called HipHop.</p>
<p>With HipHop, Facebook is providing a new runtime that is intended to improve PHP use in large-scale deployments. The HipHop effort, which also includes a new Web server, has already been in use by Facebook for the past six months, though the project is just being made public today.</p>
<p>Facebook developers say the HipHop effort isn&#8217;t an attempt to fork the PHP community, but rather, a move to help PHP scale.</p>
<p>&#8220;There are two different pieces to keep in mind, one is the PHP language itself, then there is the runtime that actually goes and interprets the language and runs it,&#8221; David Recordon, Facebook&#8217;s senior open programs manager, told <em>InternetNews.com</em>. &#8220;What we&#8217;ve done is we&#8217;ve implemented the PHP 5.2 language with a few features removed. Our plan is to keep the language the same, but what we&#8217;ve changed is the underlying runtime and the process of going and transforming the source code into C++ and then compiling it and pushing out the compiled binary.&#8221;</p>
<p><script type="text/javascript">// <![CDATA[
 			initArticleMenu(document.getElementById("toolBoxShareMenu"));
// ]]&gt;</script>Facebook said the results of using HipHop have been dramatic. CPU usage on Facebook servers has dropped by an average of 50 percent as the HipHop PHP engine reduced the load on Facebook&#8217;s infrastructure.</p>
<p>The results have proven to be compelling enough that Facebook now uses HipHop to deliver more than 90 percent of its production server traffic.</p>
<p>HipHop isn&#8217;t just a new code transformation tool, either. The overall effort also includes a new Web server to deploy PHP as well. Typically, in open source deployments, PHP is served with Apache Web servers.</p>
<p>&#8220;In general, Apache is a great Web server, but when we were looking at how we get the next half percent or percent of performance, we didn&#8217;t need all the features that Apache offers,&#8221; Recordon said. He added, however, that he hopes an open source project will one day emerge around making HipHop work with Apache Web servers.</p>
<p>The idea of optimizing the PHP runtime is not a new one, with multiple solutions in the market today including eAccelerator and <a href="http://www.internetnews.com/dev-news/article.php/3814126">commercial PHP products from Zend</a>. Zend is one of the lead commercial sponsors behind PHP.</p>
<p>&#8220;HipHop looks like an interesting project,&#8221; Zend CEO Andi Gutmans told <em>InternetNews.com</em>. &#8220;We have been briefed by Facebook but will certainly take a closer look now. There have been other such projects but most have been targeting managed runtimes such as Java and .NET with various degrees of success. We welcome any innovation that will help PHP extend its leadership position in Web application development.&#8221;</p>
<p>Gutmans added that, as is the case with all runtimes, it is important to continue innovating and the PHP runtime has continued to evolve over the years.</p>
<p>&#8220;I think it is important to continue to fold in new ideas and innovations into the community-based runtime and it&#8217;ll be interesting to learn what HipHop concepts could be relevant to the existing PHP community,&#8221; Gutmans said.</p>
<p>With some PHP runtime optimization solutions, the optimization is often a simple matter of a module load and a line change in the php.ini configuration file.</p>
<p>It&#8217;s not quite that easy with HipHop.</p>
<p>&#8220;This is not an extension to PHP &#8212; this is pretty different,&#8221; Recordon said. &#8220;Right now, the process is once you build and compile HipHop, it comes with a tool that will go through the transformation process and output the binary, and that&#8217;s what you actually use to run it.&#8221;</p>
<p>With HipHop, Facebook said its aim is not to split the PHP community but rather to help grow it. According to Recordon, HipHop will help to solidify PHP&#8217;s position as a great language for doing Web site development.</p>
<p>&#8220;There is definitely the piece in there that HipHop is designed for larger PHP deployments and not necessarily for individuals hosting their own blog or small Web site,&#8221; Recordon said. &#8220;The proof of the effect of HipHop will be over the next year as we start to make deployment tools easier, and as we start to build a successful community around it and start working with others on its future development and solving problems for companies beyond just Facebook.&#8221;<br />
<script type="text/javascript"><!--
google_ad_client = "pub-7060132287364604";
/* 468x60, creado 16/03/10 */
google_ad_slot = "9029910384";
google_ad_width = 468;
google_ad_height = 60;
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script></p>
]]></content:encoded>
			<wfw:commentRss>http://www.ramirezcobos.com/2010/02/03/hip-hop/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Handling Timeouts with PHP5 SoapClient Extension</title>
		<link>http://www.ramirezcobos.com/2010/02/02/handling-timeouts-with-php5-soapclient-extension/</link>
		<comments>http://www.ramirezcobos.com/2010/02/02/handling-timeouts-with-php5-soapclient-extension/#comments</comments>
		<pubDate>Wed, 03 Feb 2010 01:37:10 +0000</pubDate>
		<dc:creator>Antonio Ramirez</dc:creator>
				<category><![CDATA[How To]]></category>
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://www.ramirezcobos.com/?p=266</guid>
		<description><![CDATA[I was breaking my head towards a silly thing around SoapClient Calls. My actual project requires Soap Calls to certain providers and everytime I was calling the external server, I had to wait for the server response (if any) and if the server failed to respond accordingly&#8230; damn&#8230; Warnings and/or Errors displayed and boom&#8230; My]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.ramirezcobos.com/wp-content/uploads/2010/02/Imagen-2.png"></a><a href="http://www.ramirezcobos.com/wp-content/uploads/2010/03/Imagen-2-300x197.png"></a><a href="http://www.ramirezcobos.com/wp-content/uploads/2010/03/Imagen-2-300x197.png"></a><a href="http://www.ramirezcobos.com/wp-content/uploads/2010/02/Imagen-2-300x197.png"><img class="alignright size-full wp-image-387" title="Imagen-2-300x197" src="http://www.ramirezcobos.com/wp-content/uploads/2010/02/Imagen-2-300x197.png" alt="" width="300" height="197" /></a>I was breaking my head towards a silly thing around SoapClient Calls. My actual project requires Soap Calls to certain providers and everytime I was calling the external server, I had to wait for the server response (if any) and if the server failed to respond accordingly&#8230; damn&#8230; Warnings and/or Errors displayed and boom&#8230; My great application just looked like&#8230; well, forget it, I just used the try and catch statements for that&#8230; not big deal.</p>
<p>So I jump over Google&#8217;s horse and looked around implementing timeouts! because that was a true issue. Can you imagine? A user makes a request I looked around my DB and suddenly that single SOAP call takes me one minute to respond. No good, time for a solution.</p>
<p>Found the way to do it, by setting a hidden parameter (not documented) named &#8216;connection_timeout&#8217;:</p>
<pre class="brush: php;">
//
// setting a connection timeout (five seconds on the example)
//
$client = new SoapClient($wsdl, array(&quot;connection_timeout&quot;=&gt;15));
</pre>
<p>The above says wait 15 seconds before returning a fault if you cannot connect properly to the host. The parameter &#8216;connection_timeout&#8217; addresses the time it takes to wait to connect to your host.</p>
<p>As Jim Plush&#8217;s said:</p>
<blockquote><p>You&#8217;d have two timeouts set in your application one for how long it should take to actually connect to your remote host and a timeout for how long the socket connection should wait for a response from the server.</p></blockquote>
<p>So, now we need to set the time we wait for a server response with the following:</p>
<pre class="brush: php;">

ini_set('default_socket_timeout', 180);
</pre>
<p>With these two configuration options we control the time to wait for a Soap host connection and the time waiting for a Soap Service response. Just perfect.<br />
<script type="text/javascript"><!--
google_ad_client = "pub-7060132287364604";
/* 468x60, creado 16/03/10 */
google_ad_slot = "9029910384";
google_ad_width = 468;
google_ad_height = 60;
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script>
<a href='http://www.ramirezcobos.com/2010/02/02/handling-timeouts-with-php5-soapclient-extension/imagen-2-300x197-2/' title='Imagen-2-300x197'><img width="120" height="120" src="http://www.ramirezcobos.com/wp-content/uploads/2010/02/Imagen-2-300x197-120x120.png" class="attachment-thumbnail" alt="Imagen-2-300x197" title="Imagen-2-300x197" /></a>
</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ramirezcobos.com/2010/02/02/handling-timeouts-with-php5-soapclient-extension/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Php Frameworks</title>
		<link>http://www.ramirezcobos.com/2010/01/26/php-frameworks/</link>
		<comments>http://www.ramirezcobos.com/2010/01/26/php-frameworks/#comments</comments>
		<pubDate>Tue, 26 Jan 2010 16:25:54 +0000</pubDate>
		<dc:creator>Antonio Ramirez</dc:creator>
				<category><![CDATA[On The Web]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[Tools]]></category>
		<category><![CDATA[News]]></category>

		<guid isPermaLink="false">http://www.ramirezcobos.com/?p=258</guid>
		<description><![CDATA[I decided to jump over the MVC (Model View Controller) pattern and on one of my linkedin groups I drop a question: Which one is best? A huge amount of PHP programmers started to join this discussion writing their personal PHP Framework tastes, providing me with a huge list of Frameworks I would like to]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.ramirezcobos.com/wp-content/uploads/2010/01/php_frameworks.png"></a><a href="http://www.ramirezcobos.com/wp-content/uploads/2010/03/php_frameworks-300x200.png"><img class="alignright size-full wp-image-299" title="php_frameworks-300x200" src="http://www.ramirezcobos.com/wp-content/uploads/2010/03/php_frameworks-300x200.png" alt="" width="300" height="200" /></a>I decided to jump over the MVC (Model View Controller) pattern and on one of my linkedin groups I drop a question:</p>
<p><em>Which one is best? </em></p>
<p>A huge amount of PHP programmers started to join this discussion writing their personal PHP Framework tastes, providing me with a huge list of Frameworks I would like to share with you. I don&#8217;t say that one is best that another, as one of the members said, there is no &#8216;best PHP MVC Framework, is whatever suits you best on your project goals&#8217;.</p>
<ul>
<li><a href="http://www.codeigniter.com" target="_blank">CodeIgniter</a></li>
<li><a href="http://www.yiiframework.com/">Yii</a></li>
<li><a href="http://www.cakephp.org" target="_blank">CakePHP</a></li>
<li><a href="http://framework.zend.com/home" target="_blank">Zend</a></li>
<li><a href="http://www.symfony-project.com/" target="_blank">Symfony</a></li>
<li><a href="http://www.phpdevshell.org/" target="_blank">PHPDevShell</a></li>
<li><a href="http://www.pradosoft.com/" target="_blank">Prado</a></li>
<li><a href="http://www.akelos.org/" target="_blank">Akelos</a></li>
<li><a href="http://www.akelos.org/" target="_blank">ZooP</a></li>
<li><a href="http://qphp.net/" target="_blank">QPHP</a></li>
<li><a href="http://www.ez.no/ezcomponents" target="_blank">ezComponents</a></li>
</ul>
<p>I know the list could be much bigger, if you know more PHP Frameworks to add to this list, please comment and I will update it.<br />
<script type="text/javascript"><!--
google_ad_client = "pub-7060132287364604";
/* 468x60, creado 16/03/10 */
google_ad_slot = "9029910384";
google_ad_width = 468;
google_ad_height = 60;
//-->
</script>
<script type="text/javascript"
src="http://pagead2.googlesyndication.com/pagead/show_ads.js">
</script></p>
]]></content:encoded>
			<wfw:commentRss>http://www.ramirezcobos.com/2010/01/26/php-frameworks/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
