<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:blogger='http://schemas.google.com/blogger/2008' xmlns:georss='http://www.georss.org/georss' xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-19309483</id><updated>2025-11-19T17:55:29.028-08:00</updated><title type='text'>devtime</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://devtime.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default?alt=atom&amp;redirect=false'/><link rel='alternate' type='text/html' href='http://devtime.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><link rel='next' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default?alt=atom&amp;start-index=26&amp;max-results=25&amp;redirect=false'/><author><name>Carlos</name><uri>http://www.blogger.com/profile/15934070138187932218</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8YZg9B2sudqF_GLHxWVbwatq4LzKml2t6eRZl71dctIx-hY_uY83F2VaZu_yS0cdRYLkEzmoaxZMBVP5FnwFGufo5bh9DZeKsJIKFDtDGB0PsgpIB2OlVf2AbBr-_7uY/s113/me.jpeg'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>55</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-19309483.post-1666691613288821036</id><published>2012-10-29T11:15:00.000-07:00</published><updated>2012-10-29T11:21:40.622-07:00</updated><title type='text'>Using Symfony2 with Backbone.js</title><content type='html'>&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjPFVGuSK3cIaZP2ekXvGuvrWMz5cvh6TwlTjKur4wsJwZ7yYjhZUK0jTdbAaAmcUMmvCAComECX8fovGeWcPcf2GNpPO0OuW-w_wQx_850i80FVKyOtMAvaRLBJeHYyTJ-lbZM/s1600/meme_backbone.jpg&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img alt=&quot;Symfony2 with Backbone.js&quot; border=&quot;0&quot; height=&quot;320&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjPFVGuSK3cIaZP2ekXvGuvrWMz5cvh6TwlTjKur4wsJwZ7yYjhZUK0jTdbAaAmcUMmvCAComECX8fovGeWcPcf2GNpPO0OuW-w_wQx_850i80FVKyOtMAvaRLBJeHYyTJ-lbZM/s320/meme_backbone.jpg&quot; title=&quot;&quot; width=&quot;192&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
Inspired by some of the Symfony Live San Francisco talks , I decided to create this bundle and become a better OSS contributor.&lt;br /&gt;
&lt;br /&gt;
This bundle allows you to easily start a backbone.js project with Symfony2, it creates a basic structure for your backbone files and also includes a generator to scaffold your backbone classes.&lt;br /&gt;
&lt;br /&gt;
All the installation steps can be found in the README: &lt;a href=&quot;https://github.com/gigo6000/DevtimeBackboneBundle&quot;&gt;https://github.com/gigo6000/DevtimeBackboneBundle&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
A simple Raffler app created with this bundle can be found here: &lt;a href=&quot;https://github.com/gigo6000/DevtimeRafflerBundle&quot;&gt;https://github.com/gigo6000/DevtimeRafflerBundle&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;div class=&quot;separator&quot; style=&quot;clear: both; text-align: center;&quot;&gt;
&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEic47YyK7UWyrDewUU3XDe2MAJJik7LIFoWB8U5Spn30wH-31UY-RWfvQ7NqENiSP3qIyIqZ9nvZABGKi9H1w3jD0vkNc6nwhXsrpAV30wn8L97gTeKu56xwqtCRh9GEzTDlTSb/s1600/Screen+Shot+2012-10-29+at+1.12.28+PM.png&quot; imageanchor=&quot;1&quot; style=&quot;margin-left: 1em; margin-right: 1em;&quot;&gt;&lt;img border=&quot;0&quot; height=&quot;145&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEic47YyK7UWyrDewUU3XDe2MAJJik7LIFoWB8U5Spn30wH-31UY-RWfvQ7NqENiSP3qIyIqZ9nvZABGKi9H1w3jD0vkNc6nwhXsrpAV30wn8L97gTeKu56xwqtCRh9GEzTDlTSb/s320/Screen+Shot+2012-10-29+at+1.12.28+PM.png&quot; width=&quot;320&quot; /&gt;&lt;/a&gt;&lt;/div&gt;
&lt;br /&gt;</content><link rel='replies' type='application/atom+xml' href='http://devtime.blogspot.com/feeds/1666691613288821036/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/19309483/1666691613288821036' title='5 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/1666691613288821036'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/1666691613288821036'/><link rel='alternate' type='text/html' href='http://devtime.blogspot.com/2012/10/using-symfony2-with-backbonejs.html' title='Using Symfony2 with Backbone.js'/><author><name>Carlos</name><uri>http://www.blogger.com/profile/15934070138187932218</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8YZg9B2sudqF_GLHxWVbwatq4LzKml2t6eRZl71dctIx-hY_uY83F2VaZu_yS0cdRYLkEzmoaxZMBVP5FnwFGufo5bh9DZeKsJIKFDtDGB0PsgpIB2OlVf2AbBr-_7uY/s113/me.jpeg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjPFVGuSK3cIaZP2ekXvGuvrWMz5cvh6TwlTjKur4wsJwZ7yYjhZUK0jTdbAaAmcUMmvCAComECX8fovGeWcPcf2GNpPO0OuW-w_wQx_850i80FVKyOtMAvaRLBJeHYyTJ-lbZM/s72-c/meme_backbone.jpg" height="72" width="72"/><thr:total>5</thr:total></entry><entry><id>tag:blogger.com,1999:blog-19309483.post-1363918874233369746</id><published>2011-11-09T21:43:00.000-08:00</published><updated>2011-11-09T22:23:43.710-08:00</updated><title type='text'>Symfony2 FOSTwitterBundle TwitterProvider</title><content type='html'>&lt;a href=&#39;http://cheezburger.com/View/5417609472&#39;&gt;&lt;img class=&#39;event-item-lol-image&#39; src=&#39;http://images.cheezburger.com/completestore/2011/11/9/9a61c9c0-8c7b-42ab-814b-04b4f47d4496.jpg&#39; id=&#39;_r_a_5417609472&#39; title=&quot;Symfony2 and Twittter&quot; alt=&quot;Symfony2 and Twittter&quot; /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;If you are trying to integrate Symfony2 with Twitter, you&#39;re probably trying to install FOSTwitterBundle, and you may have faced two problems, one is that you can&#39;t create a user session after you login with Twitter and the other one is that there is no TwitterProvider class available as example in the instructions.&lt;br /&gt;&lt;br /&gt;To help you with the second one here is a TwitterProvider class I made based on FacabookProvider.php&lt;br /&gt;&lt;br /&gt;&lt;script src=&quot;https://gist.github.com/1354209.js?file=TwitterProvider.php&quot;&gt;&lt;/script&gt;&lt;br /&gt;&lt;br /&gt;To solve the authentication problem on Symfony what I found is that Twitter anywhere only works at client level, so I decided to create a custom login button and built the authorization URL.&lt;br /&gt;&lt;br /&gt;Controller action:&lt;br /&gt;&lt;br /&gt;&lt;script src=&quot;https://gist.github.com/1354239.js?file=gistfile1.txt&quot;&gt;&lt;/script&gt;&lt;br /&gt;&lt;br /&gt;Twig template:&lt;br /&gt;&lt;br /&gt;&lt;script src=&quot;https://gist.github.com/1354241.js?file=gistfile1.txt&quot;&gt;&lt;/script&gt;&lt;br /&gt;&lt;br /&gt;Then after the user authenticates with Twitter, the custom TwitterProvider can get the authentication tokens from the session and authenticate the user in Symfony.</content><link rel='replies' type='application/atom+xml' href='http://devtime.blogspot.com/feeds/1363918874233369746/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/19309483/1363918874233369746' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/1363918874233369746'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/1363918874233369746'/><link rel='alternate' type='text/html' href='http://devtime.blogspot.com/2011/11/symfony2-fostwitterbundle.html' title='Symfony2 FOSTwitterBundle TwitterProvider'/><author><name>Carlos</name><uri>http://www.blogger.com/profile/15934070138187932218</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8YZg9B2sudqF_GLHxWVbwatq4LzKml2t6eRZl71dctIx-hY_uY83F2VaZu_yS0cdRYLkEzmoaxZMBVP5FnwFGufo5bh9DZeKsJIKFDtDGB0PsgpIB2OlVf2AbBr-_7uY/s113/me.jpeg'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-19309483.post-8446141990257766312</id><published>2011-06-28T19:56:00.000-07:00</published><updated>2011-06-29T12:08:47.465-07:00</updated><title type='text'>Capifony: Send an email after deployment</title><content type='html'>&lt;a onblur=&quot;try {parent.deselectBloggerImageGracefully();} catch(e) {}&quot; href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgqc-3s8P-ZKErNRgyQJJeYIlVp9S5rNfl9yQ_a_s8gG9CfEVWRsMybHC2JR1j7uLCzBIuSHOBg5ciHd-Kv12T69J0-4DNtQVpNaXwr0e0-JYyQhGjnjr6vIxl_6P1GgFcGTwC9/s1600/emailmeme.jpg&quot;&gt;&lt;img style=&quot;float:right; margin:0 0 10px 10px;cursor:pointer; cursor:hand;width: 200px; height: 200px;&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgqc-3s8P-ZKErNRgyQJJeYIlVp9S5rNfl9yQ_a_s8gG9CfEVWRsMybHC2JR1j7uLCzBIuSHOBg5ciHd-Kv12T69J0-4DNtQVpNaXwr0e0-JYyQhGjnjr6vIxl_6P1GgFcGTwC9/s200/emailmeme.jpg&quot; alt=&quot;&quot; id=&quot;BLOGGER_PHOTO_ID_5623646058479512018&quot; border=&quot;0&quot; /&gt;&lt;/a&gt;&lt;br /&gt;First, thanks to @cordoval at the #symfony channel for suggesting me to use a symfony2 command to do this.&lt;br /&gt;&lt;br /&gt;To use this command you must have the SwiftmailerBundle enabled. More info &lt;a href=&quot;http://symfony.com/doc/2.0/cookbook/email.html&quot;&gt;here&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;This is a simple Symfony2 command to send an email, you should add it to a &quot;Command&quot; directory inside your bundle and replace the namespace to fit your project bundle:&lt;br /&gt;&lt;br/&gt;&lt;br/&gt;&lt;br /&gt;&lt;script src=&quot;https://gist.github.com/1052884.js?file=SendEmailCommand.php&quot;&gt;&lt;/script&gt;&lt;br /&gt;&lt;br /&gt;The email body is just &quot;test&quot; but you can probably modified it you need to.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Test the new command by running the following:&lt;br /&gt;&lt;br /&gt;&lt;pre class=&quot;prettyprint&quot;&gt;php app/console capifony:sendemail emailfrom@server.com emailto@server.com subject&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;Finally, this task will run the capifony:sendemail command after the deployment is complete, be sure to add it to your Capifony script:&lt;br /&gt;&lt;br /&gt;&lt;script src=&quot;https://gist.github.com/1052938.js?file=staging.rb&quot;&gt;&lt;/script&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Want to learn more about Symfony2 console/command-line commands?&lt;br /&gt;&lt;br /&gt;&lt;a href=&quot;http://www.blogger.com/mfony2%20console/command-line%20commands?%20%20http://symfony.com/doc/current/cookbook/console.html&quot;&gt;http://symfony.com/doc/current/cookbook/console.html&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;a href=&quot;http://www.craftitonline.com/2011/06/calling-commands-within-commands-in-symfony2/&quot;&gt;&lt;br /&gt;http://www.craftitonline.com/2011/06/calling-commands-within-commands-in-symfony2/&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://devtime.blogspot.com/feeds/8446141990257766312/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/19309483/8446141990257766312' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/8446141990257766312'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/8446141990257766312'/><link rel='alternate' type='text/html' href='http://devtime.blogspot.com/2011/06/capifony-send-email-after-deployment.html' title='Capifony: Send an email after deployment'/><author><name>Carlos</name><uri>http://www.blogger.com/profile/15934070138187932218</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8YZg9B2sudqF_GLHxWVbwatq4LzKml2t6eRZl71dctIx-hY_uY83F2VaZu_yS0cdRYLkEzmoaxZMBVP5FnwFGufo5bh9DZeKsJIKFDtDGB0PsgpIB2OlVf2AbBr-_7uY/s113/me.jpeg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgqc-3s8P-ZKErNRgyQJJeYIlVp9S5rNfl9yQ_a_s8gG9CfEVWRsMybHC2JR1j7uLCzBIuSHOBg5ciHd-Kv12T69J0-4DNtQVpNaXwr0e0-JYyQhGjnjr6vIxl_6P1GgFcGTwC9/s72-c/emailmeme.jpg" height="72" width="72"/><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-19309483.post-3598979727250002733</id><published>2011-06-19T08:23:00.000-07:00</published><updated>2011-06-20T18:39:39.882-07:00</updated><title type='text'>How to enable the twig truncate filter (Text extension) in Symfony2 beta5</title><content type='html'>&lt;div style=&quot;text-align: center;&quot;&gt;&lt;a onblur=&quot;try {parent.deselectBloggerImageGracefully();} catch(e) {}&quot; href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhB-l0Xp4jT2HsCdTweOcXEvahSgLe0x2ugyCEesiUHxHAM-XhSar4VRpTwJAjLAa1yLzF5gYGb_N2wxtWO3too1Ithfd5hQRS4knWixbsAvonUMLhGi_9ppsUYbwhsBe4Eu0Wi/s1600/problem-officer-meme.jpg&quot;&gt;&lt;img style=&quot;display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 180px; height: 136px;&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhB-l0Xp4jT2HsCdTweOcXEvahSgLe0x2ugyCEesiUHxHAM-XhSar4VRpTwJAjLAa1yLzF5gYGb_N2wxtWO3too1Ithfd5hQRS4knWixbsAvonUMLhGi_9ppsUYbwhsBe4Eu0Wi/s320/problem-officer-meme.jpg&quot; alt=&quot;&quot; id=&quot;BLOGGER_PHOTO_ID_5619956687338281234&quot; border=&quot;0&quot; /&gt;&lt;/a&gt;&lt;a onblur=&quot;try {parent.deselectBloggerImageGracefully();} catch(e) {}&quot; href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgPJkBCLRpF1mHC7pKFzcVvwSnPgGso99vtYl7jQotiD9k1VgT6FCzN2MdMBtrdzfuQqRA2yp61Ywcvzwh8ZS63UlgDEF9zw0NjiDUVgLlWzZ5mWTyI2eApcf8ygE21DOZ0KvW4/s1600/Fuck-Yeah-meme.jpg&quot;&gt;&lt;br /&gt;&lt;/a&gt;&lt;span style=&quot;font-size:180%;&quot;&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;Problem ?&lt;/span&gt;&lt;/span&gt; &lt;/div&gt;&lt;br /&gt;&lt;br /&gt;In previous versions of Symfony2, to enable a extension you needed to add the Text and/or Debug extensions to an &quot;extensions&quot; array in your config.yml&lt;br /&gt;&lt;br /&gt;&lt;pre class=&quot;prettyprint&quot;&gt;//app/config/config.yml&lt;br /&gt;# Twig Configuration&lt;br /&gt;twig:&lt;br /&gt; debug:            %kernel.debug%&lt;br /&gt; strict_variables: %kernel.debug%&lt;br /&gt; extensions:&lt;br /&gt;     - twig.extension.debug&lt;br /&gt;     - twig.extension.text&lt;br /&gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;This was because the extensions were added to the twig.xml file&lt;br /&gt;&lt;pre class=&quot;prettyprint&quot;&gt;&lt;br /&gt;&lt;br /&gt;//vendor/symfony/src/Symfony/Bundle/TwigBundle/Resources/config/twig.xml&lt;br /&gt;...&lt;br /&gt;  &amp;lt;service id=&amp;quot;twig.extension.text&amp;quot; class=&amp;quot;Twig_Extensions_Extension_Text&amp;quot; public=&amp;quot;false&amp;quot;&amp;gt;&lt;br /&gt;&lt;br /&gt;     &amp;lt;service id=&amp;quot;twig.extension.debug&amp;quot; class=&amp;quot;Twig_Extensions_Extension_Debug&amp;quot; public=&amp;quot;false&amp;quot;&amp;gt;&lt;br /&gt;...&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;But,  this is the way to do it now :&lt;br /&gt;&lt;pre class=&quot;prettyprint&quot;&gt;&lt;br /&gt;// app/config/config.yml&lt;br /&gt;...&lt;br /&gt;services:&lt;br /&gt; twig.extension.text:&lt;br /&gt;     class: Twig_Extensions_Extension_Text&lt;br /&gt;     tags:&lt;br /&gt;         - { name: twig.extension }&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgPJkBCLRpF1mHC7pKFzcVvwSnPgGso99vtYl7jQotiD9k1VgT6FCzN2MdMBtrdzfuQqRA2yp61Ywcvzwh8ZS63UlgDEF9zw0NjiDUVgLlWzZ5mWTyI2eApcf8ygE21DOZ0KvW4/s1600/Fuck-Yeah-meme.jpg&quot;&gt;&lt;img style=&quot;display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 250px; height: 228px;&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgPJkBCLRpF1mHC7pKFzcVvwSnPgGso99vtYl7jQotiD9k1VgT6FCzN2MdMBtrdzfuQqRA2yp61Ywcvzwh8ZS63UlgDEF9zw0NjiDUVgLlWzZ5mWTyI2eApcf8ygE21DOZ0KvW4/s320/Fuck-Yeah-meme.jpg&quot; alt=&quot;&quot; id=&quot;BLOGGER_PHOTO_ID_5619957154024694770&quot; border=&quot;0&quot; /&gt;&lt;/a&gt;&lt;br /&gt;I spent some time trying to figure out how to do it, so I hope it helps someone.</content><link rel='replies' type='application/atom+xml' href='http://devtime.blogspot.com/feeds/3598979727250002733/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/19309483/3598979727250002733' title='13 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/3598979727250002733'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/3598979727250002733'/><link rel='alternate' type='text/html' href='http://devtime.blogspot.com/2011/06/how-to-enable-truncate-filter-text.html' title='How to enable the twig truncate filter (Text extension) in Symfony2 beta5'/><author><name>Carlos</name><uri>http://www.blogger.com/profile/15934070138187932218</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8YZg9B2sudqF_GLHxWVbwatq4LzKml2t6eRZl71dctIx-hY_uY83F2VaZu_yS0cdRYLkEzmoaxZMBVP5FnwFGufo5bh9DZeKsJIKFDtDGB0PsgpIB2OlVf2AbBr-_7uY/s113/me.jpeg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhB-l0Xp4jT2HsCdTweOcXEvahSgLe0x2ugyCEesiUHxHAM-XhSar4VRpTwJAjLAa1yLzF5gYGb_N2wxtWO3too1Ithfd5hQRS4knWixbsAvonUMLhGi_9ppsUYbwhsBe4Eu0Wi/s72-c/problem-officer-meme.jpg" height="72" width="72"/><thr:total>13</thr:total></entry><entry><id>tag:blogger.com,1999:blog-19309483.post-7355302878641085651</id><published>2011-05-23T21:38:00.000-07:00</published><updated>2011-05-25T09:08:04.146-07:00</updated><title type='text'>Symfony2 + Twig pagination class</title><content type='html'>I was looking for some pagination class to use with Symfony2, but most of the scripts that I found included html in the class, after some googling I found &lt;a href=&quot;http://inchoo.net/tools-frameworks/paginator-symfony2-beta/&quot;&gt;this  post&lt;/a&gt;, and it was very helpful to get  what I was looking for. I wanted something like the old digg pagination so I modified this class a little bit to get something like this:&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;a onblur=&quot;try {parent.deselectBloggerImageGracefully();} catch(e) {}&quot; href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh_AJlu3TnOC7uPMkivvCBuSTC2NN6Dcqcbhw_07HDvnMPw-9huV7tKH8m4lNE5iqk-jCvVupIy6KrX006p9HhAcgOlu6-eGN_-YSJyqB-evsQ8n22xOWGRLZ6PdLytGlO_xTsL/s1600/How+to+Paginate+Data+with+PHP+%257C+Nettuts%252B_1306213240746.png&quot;&gt;&lt;img style=&quot;display: block; margin: 0px auto 10px; text-align: center; cursor: pointer; width: 320px; height: 37px;&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh_AJlu3TnOC7uPMkivvCBuSTC2NN6Dcqcbhw_07HDvnMPw-9huV7tKH8m4lNE5iqk-jCvVupIy6KrX006p9HhAcgOlu6-eGN_-YSJyqB-evsQ8n22xOWGRLZ6PdLytGlO_xTsL/s320/How+to+Paginate+Data+with+PHP+%257C+Nettuts%252B_1306213240746.png&quot; alt=&quot;&quot; id=&quot;BLOGGER_PHOTO_ID_5610143368720753314&quot; border=&quot;0&quot; /&gt;&lt;br /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;The modifications I made:&lt;br /&gt;&lt;br /&gt;- Show a range of pages around the current page as in the old digg.&lt;br /&gt;- Parameters can be passed in a route, so you get a nice URL.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;This is the class after the modifications:&lt;br /&gt;&lt;br /&gt;&lt;pre class=&quot;prettyprint linenums&quot;&gt;&amp;lt;?php&lt;br /&gt;/**&lt;br /&gt;* Class to paginate a list of items in a old digg style&lt;br /&gt;*&lt;br /&gt;* @author Darko Gole%u0161&lt;br /&gt;* @author Carlos Mafla &amp;lt;gigo6000@hotmail.com&amp;gt;&lt;br /&gt;* @www.inchoo.net&lt;br /&gt;*/&lt;br /&gt;namespace Paginator;&lt;br /&gt;&lt;br /&gt;class Paginator {&lt;br /&gt;&lt;br /&gt;//current displayed page&lt;br /&gt;protected $currentpage;&lt;br /&gt;//limit items on one page&lt;br /&gt;protected $limit;&lt;br /&gt;//total number of pages that will be generated&lt;br /&gt;protected $numpages;&lt;br /&gt;//total items loaded from database&lt;br /&gt;protected $itemscount;&lt;br /&gt;//starting item number to be shown on page&lt;br /&gt;protected $offset;&lt;br /&gt;//pages to show at left and right of current page&lt;br /&gt;protected $mid_range;&lt;br /&gt;//range initial page&lt;br /&gt;protected $start_range;&lt;br /&gt;//range end page&lt;br /&gt;protected $end_range;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;function __construct($itemscount, $currentpage = 1,$limit = 20,$mid_range = 7) {&lt;br /&gt;   //set total items count from controller&lt;br /&gt;   $this-&amp;gt;itemscount = $itemscount;&lt;br /&gt;&lt;br /&gt;   $this-&amp;gt;currentpage = $currentpage;&lt;br /&gt;&lt;br /&gt;   $this-&amp;gt;limit = $limit;&lt;br /&gt;&lt;br /&gt;   $this-&amp;gt;mid_range= $mid_range;&lt;br /&gt;&lt;br /&gt;   //Set defaults&lt;br /&gt;   $this-&amp;gt;setDefaults();&lt;br /&gt;&lt;br /&gt;   //Calculate number of pages total&lt;br /&gt;   $this-&amp;gt;getInternalNumPages();&lt;br /&gt;   //Calculate first shown item on current page&lt;br /&gt;   $this-&amp;gt;calculateOffset();&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;   $this-&amp;gt;calculateRange();&lt;br /&gt;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;private function calculateRange() {&lt;br /&gt;&lt;br /&gt;        $this-&amp;gt;start_range = $this-&amp;gt;currentpage - floor($this-&amp;gt;mid_range/2);&lt;br /&gt;        $this-&amp;gt;end_range = $this-&amp;gt;currentpage   floor($this-&amp;gt;mid_range/2);&lt;br /&gt;&lt;br /&gt;        if($this-&amp;gt;start_range &amp;lt;= 0)&lt;br /&gt;        {&lt;br /&gt;            $this-&amp;gt;end_range  = abs($this-&amp;gt;start_range) 1;&lt;br /&gt;            $this-&amp;gt;start_range = 1;&lt;br /&gt;        }&lt;br /&gt;        if($this-&amp;gt;end_range &amp;gt; $this-&amp;gt;numpages)&lt;br /&gt;        {&lt;br /&gt;            $this-&amp;gt;start_range -= $this-&amp;gt;end_range-$this-&amp;gt;numpages;&lt;br /&gt;            $this-&amp;gt;end_range = $this-&amp;gt;numpages;&lt;br /&gt;        }&lt;br /&gt;        $this-&amp;gt;range = range($this-&amp;gt;start_range,$this-&amp;gt;end_range);&lt;br /&gt;&lt;br /&gt;&lt;br /&gt; }&lt;br /&gt;&lt;br /&gt;private function setDefaults() {&lt;br /&gt;   //If currentpage is set to null or is set to 0 or less&lt;br /&gt;   //set it to default (1)&lt;br /&gt;   if (($this-&amp;gt;currentpage == null) || ($this-&amp;gt;currentpage &amp;lt; 1)) {&lt;br /&gt;       $this-&amp;gt;currentpage = 1;&lt;br /&gt;   }&lt;br /&gt;   //if limit is set to null set it to default (20)&lt;br /&gt;   if (($this-&amp;gt;limit == null)) {&lt;br /&gt;       $this-&amp;gt;limit = 20;&lt;br /&gt;       //if limit is any number less than 1 then set it to 0 for displaying&lt;br /&gt;       //items without limit&lt;br /&gt;   } else if ($this-&amp;gt;limit &amp;lt; 1) {&lt;br /&gt;       $this-&amp;gt;limit = 0;&lt;br /&gt;   }&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;public function getNumpages() {&lt;br /&gt;   return $this-&amp;gt;numpages;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;private function getInternalNumPages() {&lt;br /&gt;   //If limit is set to 0 or set to number bigger then total items count&lt;br /&gt;   //display all in one page&lt;br /&gt;   if (($this-&amp;gt;limit &amp;lt; 1) || ($this-&amp;gt;limit &amp;gt; $this-&amp;gt;itemscount)) {&lt;br /&gt;       $this-&amp;gt;numpages = 1;&lt;br /&gt;   } else {&lt;br /&gt;       //Calculate rest numbers from dividing operation so we can add one&lt;br /&gt;       //more page for this items&lt;br /&gt;       $restItemsNum = $this-&amp;gt;itemscount % $this-&amp;gt;limit;&lt;br /&gt;       //if rest items &amp;gt; 0 then add one more page else just divide items&lt;br /&gt;       //by limit&lt;br /&gt;       $restItemsNum &amp;gt; 0 ? $this-&amp;gt;numpages = intval($this-&amp;gt;itemscount / $this-&amp;gt;limit)   1 : $this-&amp;gt;numpages = intval($this-&amp;gt;itemscount / $this-&amp;gt;limit);&lt;br /&gt;   }&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;private function calculateOffset() {&lt;br /&gt;   //Calculet offset for items based on current page number&lt;br /&gt;   $this-&amp;gt;offset = ($this-&amp;gt;currentpage - 1) * $this-&amp;gt;limit;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;public function getCurrentpage() {&lt;br /&gt;   return $this-&amp;gt;currentpage;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;public function getCurrentUrl() {&lt;br /&gt;   return $this-&amp;gt;currentUrl;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;   //For using from controller&lt;br /&gt;public function getLimit() {&lt;br /&gt;   return $this-&amp;gt;limit;&lt;br /&gt;}&lt;br /&gt;//For using from controller&lt;br /&gt;public function getOffset() {&lt;br /&gt;   return $this-&amp;gt;offset;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;public function getRange()&lt;br /&gt;{&lt;br /&gt;   return $this-&amp;gt;range;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;public function getMidRange()&lt;br /&gt;{&lt;br /&gt;   return $this-&amp;gt;mid_range;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;And this is how you can implement it in the controller:&lt;br /&gt;&lt;br /&gt;&lt;pre class=&quot;prettyprint linenums&quot;&gt;use Path\to\class\Paginator;&lt;br /&gt;&lt;br /&gt;class ListController extends SiteController&lt;br /&gt;{&lt;br /&gt;/**&lt;br /&gt;* @extra:Route(&quot;/{offset}&quot;, name=&quot;_items&quot;)&lt;br /&gt;* @extra:Template()&lt;br /&gt;*/&lt;br /&gt;public function listAction( $offset = 1)&lt;br /&gt;{&lt;br /&gt;  $repository = new ListRepository();&lt;br /&gt;&lt;br /&gt;  $limit = 20;&lt;br /&gt;  $midrange = 7;&lt;br /&gt;&lt;br /&gt;  $itemsCount = $repository-&amp;gt;getListCount();&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;  $paginator = new Paginator($itemsCount, $offset , $limit, $midrange);&lt;br /&gt;&lt;br /&gt;  $items = $repository-&amp;gt;getList ($offset);&lt;br /&gt;&lt;br /&gt;  .&lt;br /&gt;  .&lt;br /&gt;  .&lt;br /&gt;  return array(&#39;items&#39; =&amp;gt; $items, &#39;paginator&#39; =&amp;gt; $paginator);&lt;br /&gt;}&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;And this is an example of a twig template you can use:&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;pre class=&quot;prettyprint linenums&quot;&gt;&amp;lt;div class=&quot;paginator&quot;&amp;gt;&lt;br /&gt;&amp;lt;ul&amp;gt;&lt;br /&gt;   {% if paginator.currentpage != 1 %}&lt;br /&gt;       &amp;lt;li&amp;gt; &amp;lt;a class=&quot;previous&quot; href=&quot;{{ path(&#39;_items&#39;, {  &#39;offset&#39;: paginator.currentpage-1 }) }}&quot;&amp;gt;Previous&amp;lt;/a&amp;gt;&lt;br /&gt;&lt;br /&gt;   {% endif %}&lt;br /&gt;   {% for i in 1..paginator.numpages%}&lt;br /&gt;&lt;br /&gt;   {% if paginator.range.0 &amp;gt; 2 and i == paginator.range.0 %}&lt;br /&gt;         ...&lt;br /&gt;   {% endif %}&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;     {%  if(i==1 or i==paginator.numpages or i in paginator.range) %}&lt;br /&gt;&lt;br /&gt;       {% if i==paginator.currentpage %}&lt;br /&gt;       &amp;lt;li&amp;gt;&amp;lt;a class=&quot;active&quot; href=&quot;{{ path(&#39;_items&#39;, {  &#39;offset&#39;: i })}}&quot;&amp;gt;{{i}}&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;       {% else %}&lt;br /&gt;       &amp;lt;li&amp;gt;&amp;lt;a href=&quot;{{ path(&#39;_items&#39;, {  &#39;offset&#39;: i }) }}&quot;&amp;gt; {{i}}&amp;lt;/a&amp;gt;&amp;lt;/li&amp;gt;&lt;br /&gt;       {% endif %}&lt;br /&gt;     {% endif %}&lt;br /&gt;&lt;br /&gt;    {% if paginator.range[paginator.midrange -1] &amp;lt; paginator.numpages -1 and i == paginator.range[paginator.midrange-1] %}&lt;br /&gt;         ...&lt;br /&gt;    {% endif %}&lt;br /&gt;&lt;br /&gt;   {% endfor %}&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;       &amp;lt;li&amp;gt; &amp;lt;a class=&quot;next&quot; href=&quot;{{ path(&#39;_items&#39;, {  &#39;offset&#39;: paginator.currentpage 1 }) }}&quot;&amp;gt;Next&amp;lt;/a&amp;gt;&lt;br /&gt;&amp;lt;/ul&amp;gt;&lt;br /&gt;&amp;lt;/div&amp;gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;I&#39;m sure there are many improvements to be made, but it may help someone to have an idea.&lt;br /&gt;&lt;br /&gt;You can find the files on git:&lt;br /&gt;&lt;br /&gt;&lt;a href=&quot;https://github.com/gigo6000/Symfony2-Pagination-Class&quot;&gt;https://github.com/gigo6000/Symfony2-Pagination-Class&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://devtime.blogspot.com/feeds/7355302878641085651/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/19309483/7355302878641085651' title='6 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/7355302878641085651'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/7355302878641085651'/><link rel='alternate' type='text/html' href='http://devtime.blogspot.com/2011/05/symfony2-twig-pagination-class.html' title='Symfony2 + Twig pagination class'/><author><name>Carlos</name><uri>http://www.blogger.com/profile/15934070138187932218</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8YZg9B2sudqF_GLHxWVbwatq4LzKml2t6eRZl71dctIx-hY_uY83F2VaZu_yS0cdRYLkEzmoaxZMBVP5FnwFGufo5bh9DZeKsJIKFDtDGB0PsgpIB2OlVf2AbBr-_7uY/s113/me.jpeg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh_AJlu3TnOC7uPMkivvCBuSTC2NN6Dcqcbhw_07HDvnMPw-9huV7tKH8m4lNE5iqk-jCvVupIy6KrX006p9HhAcgOlu6-eGN_-YSJyqB-evsQ8n22xOWGRLZ6PdLytGlO_xTsL/s72-c/How+to+Paginate+Data+with+PHP+%257C+Nettuts%252B_1306213240746.png" height="72" width="72"/><thr:total>6</thr:total></entry><entry><id>tag:blogger.com,1999:blog-19309483.post-202462504044427024</id><published>2011-05-12T12:13:00.000-07:00</published><updated>2011-05-24T21:37:36.089-07:00</updated><title type='text'>Symfony2 Xzibit Meme</title><content type='html'>&lt;a href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEheQee0HpuagM7pCM47R4rOLZxiMSy52JqJP40hKQquxfjdjY9F0F_dDKyomhXH8bxzyKdOT7dRp6AURPz-DOPHF-A5jWjnKAN0lIcAoDeJo9-IZp2YWMPU-a6ui8M6qhhXSOb4/s1600/xzibit_meme.jpg&quot;&gt;&lt;img style=&quot;display: block; text-align: center; cursor: pointer; width: 400px; height: 266px;&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEheQee0HpuagM7pCM47R4rOLZxiMSy52JqJP40hKQquxfjdjY9F0F_dDKyomhXH8bxzyKdOT7dRp6AURPz-DOPHF-A5jWjnKAN0lIcAoDeJo9-IZp2YWMPU-a6ui8M6qhhXSOb4/s400/xzibit_meme.jpg&quot; alt=&quot;&quot; id=&quot;BLOGGER_PHOTO_ID_5605910137484692834&quot; border=&quot;0&quot; /&gt;&lt;/a&gt;&lt;a onblur=&quot;try {parent.deselectBloggerImageGracefully();} catch(e) {}&quot; href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEheQee0HpuagM7pCM47R4rOLZxiMSy52JqJP40hKQquxfjdjY9F0F_dDKyomhXH8bxzyKdOT7dRp6AURPz-DOPHF-A5jWjnKAN0lIcAoDeJo9-IZp2YWMPU-a6ui8M6qhhXSOb4/s1600/xzibit_meme.jpg&quot;&gt;&lt;br /&gt;&lt;/a&gt;A little meme for the Symfony2 Bundles :)</content><link rel='replies' type='application/atom+xml' href='http://devtime.blogspot.com/feeds/202462504044427024/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/19309483/202462504044427024' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/202462504044427024'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/202462504044427024'/><link rel='alternate' type='text/html' href='http://devtime.blogspot.com/2011/05/symfony2-xzibit-meme.html' title='Symfony2 Xzibit Meme'/><author><name>Carlos</name><uri>http://www.blogger.com/profile/15934070138187932218</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8YZg9B2sudqF_GLHxWVbwatq4LzKml2t6eRZl71dctIx-hY_uY83F2VaZu_yS0cdRYLkEzmoaxZMBVP5FnwFGufo5bh9DZeKsJIKFDtDGB0PsgpIB2OlVf2AbBr-_7uY/s113/me.jpeg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEheQee0HpuagM7pCM47R4rOLZxiMSy52JqJP40hKQquxfjdjY9F0F_dDKyomhXH8bxzyKdOT7dRp6AURPz-DOPHF-A5jWjnKAN0lIcAoDeJo9-IZp2YWMPU-a6ui8M6qhhXSOb4/s72-c/xzibit_meme.jpg" height="72" width="72"/><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-19309483.post-343033752978058400</id><published>2011-02-09T09:34:00.000-08:00</published><updated>2011-02-09T16:42:25.408-08:00</updated><title type='text'>Symfony live 2011 interesting links -  Symfony2 (day 2)</title><content type='html'>Fabien Potencier presentations:&lt;br /&gt;&lt;br /&gt;http://www.slideshare.net/fabpot&lt;br /&gt;&lt;br /&gt;Symfony2 from the trenches:&lt;br /&gt;&lt;br /&gt;&lt;a href=&quot;http://www.slideshare.net/jwage/symfony2-from-the-trenches&quot;&gt;http://www.slideshare.net/jwage/symfony2-from-the-trenches&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;div style=&quot;width: 425px;&quot; id=&quot;__ss_6865341&quot;&gt;&lt;strong style=&quot;display: block; margin: 12px 0pt 4px;&quot;&gt;&lt;a href=&quot;http://www.slideshare.net/jwage/symfony2-from-the-trenches&quot; title=&quot;Symfony2 from the Trenches&quot;&gt;Symfony2 from the Trenches&lt;/a&gt;&lt;/strong&gt;&lt;object id=&quot;__sse6865341&quot; height=&quot;355&quot; width=&quot;425&quot;&gt;&lt;param name=&quot;movie&quot; value=&quot;http://static.slidesharecdn.com/swf/ssplayer2.swf?doc=symfony2fromthetrenches-110209123435-phpapp01&amp;amp;stripped_title=symfony2-from-the-trenches&amp;amp;userName=jwage&quot;&gt;&lt;param name=&quot;allowFullScreen&quot; value=&quot;true&quot;&gt;&lt;param name=&quot;allowScriptAccess&quot; value=&quot;always&quot;&gt;&lt;embed name=&quot;__sse6865341&quot; src=&quot;http://static.slidesharecdn.com/swf/ssplayer2.swf?doc=symfony2fromthetrenches-110209123435-phpapp01&amp;amp;stripped_title=symfony2-from-the-trenches&amp;amp;userName=jwage&quot; type=&quot;application/x-shockwave-flash&quot; allowscriptaccess=&quot;always&quot; allowfullscreen=&quot;true&quot; height=&quot;355&quot; width=&quot;425&quot;&gt;&lt;/embed&gt;&lt;/object&gt;&lt;div style=&quot;padding: 5px 0pt 12px;&quot;&gt;View more &lt;a href=&quot;http://www.slideshare.net/&quot;&gt;presentations&lt;/a&gt; from &lt;a href=&quot;http://www.slideshare.net/jwage&quot;&gt;Jonathan Wage&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/div&gt;&lt;/div&gt;&lt;br /&gt;&lt;br /&gt;Being dangerous with Twig:&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;a href=&quot;Being dangerous with Twig:  http://www.slideshare.net/weaverryan/being-dangerous-with-twig&quot;&gt;http://www.slideshare.net/weaverryan/being-dangerous-with-twig&lt;/a&gt;&lt;br /&gt;&lt;div style=&quot;width:425px&quot; id=&quot;__ss_6866229&quot;&gt;&lt;strong style=&quot;display:block;margin:12px 0 4px&quot;&gt;&lt;a href=&quot;http://www.slideshare.net/weaverryan/being-dangerous-with-twig&quot; title=&quot;Being Dangerous with Twig&quot;&gt;Being Dangerous with Twig&lt;/a&gt;&lt;/strong&gt;&lt;object id=&quot;__sse6866229&quot; width=&quot;425&quot; height=&quot;355&quot;&gt;&lt;param name=&quot;movie&quot; value=&quot;http://static.slidesharecdn.com/swf/ssplayer2.swf?doc=twig-sflive-sanfran-2011-110209140501-phpapp02&amp;stripped_title=being-dangerous-with-twig&amp;userName=weaverryan&quot; /&gt;&lt;param name=&quot;allowFullScreen&quot; value=&quot;true&quot;/&gt;&lt;param name=&quot;allowScriptAccess&quot; value=&quot;always&quot;/&gt;&lt;embed name=&quot;__sse6866229&quot; src=&quot;http://static.slidesharecdn.com/swf/ssplayer2.swf?doc=twig-sflive-sanfran-2011-110209140501-phpapp02&amp;stripped_title=being-dangerous-with-twig&amp;userName=weaverryan&quot; type=&quot;application/x-shockwave-flash&quot; allowscriptaccess=&quot;always&quot; allowfullscreen=&quot;true&quot; width=&quot;425&quot; height=&quot;355&quot;&gt;&lt;/embed&gt;&lt;/object&gt;&lt;div style=&quot;padding:5px 0 12px&quot;&gt;View more &lt;a href=&quot;http://www.slideshare.net/&quot;&gt;presentations&lt;/a&gt; from &lt;a href=&quot;http://www.slideshare.net/weaverryan&quot;&gt;Ryan Weaver&lt;/a&gt;.&lt;/div&gt;&lt;/div&gt;&lt;br /&gt;&lt;br /&gt;Comment tag (do nothing):  {# Comment #}&lt;br /&gt;&lt;br /&gt;Print tag (show something): {{ &#39;print me&#39; }}&lt;br /&gt;&lt;br /&gt;Block tag (do something):   {% set foo = &#39;hola&#39; %}&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Introducing Assetic: Asset Management for PHP 5.3:&lt;br /&gt;&lt;br /&gt;&lt;div style=&quot;width:425px&quot; id=&quot;__ss_6869262&quot;&gt;&lt;strong style=&quot;display:block;margin:12px 0 4px&quot;&gt;&lt;a href=&quot;http://www.slideshare.net/kriswallsmith/introducing-assetic-asset-management-for-php-53&quot; title=&quot;Introducing Assetic: Asset Management for PHP 5.3&quot;&gt;Introducing Assetic: Asset Management for PHP 5.3&lt;/a&gt;&lt;/strong&gt;&lt;object id=&quot;__sse6869262&quot; width=&quot;425&quot; height=&quot;355&quot;&gt;&lt;param name=&quot;movie&quot; value=&quot;http://static.slidesharecdn.com/swf/ssplayer2.swf?doc=asseticsflive11sanfran-110209181138-phpapp01&amp;stripped_title=introducing-assetic-asset-management-for-php-53&amp;userName=kriswallsmith&quot; /&gt;&lt;param name=&quot;allowFullScreen&quot; value=&quot;true&quot;/&gt;&lt;param name=&quot;allowScriptAccess&quot; value=&quot;always&quot;/&gt;&lt;embed name=&quot;__sse6869262&quot; src=&quot;http://static.slidesharecdn.com/swf/ssplayer2.swf?doc=asseticsflive11sanfran-110209181138-phpapp01&amp;stripped_title=introducing-assetic-asset-management-for-php-53&amp;userName=kriswallsmith&quot; type=&quot;application/x-shockwave-flash&quot; allowscriptaccess=&quot;always&quot; allowfullscreen=&quot;true&quot; width=&quot;425&quot; height=&quot;355&quot;&gt;&lt;/embed&gt;&lt;/object&gt;&lt;div style=&quot;padding:5px 0 12px&quot;&gt;View more &lt;a href=&quot;http://www.slideshare.net/&quot;&gt;presentations&lt;/a&gt; from &lt;a href=&quot;http://www.slideshare.net/kriswallsmith&quot;&gt;Kris Wallsmith&lt;/a&gt;.&lt;/div&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://devtime.blogspot.com/feeds/343033752978058400/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/19309483/343033752978058400' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/343033752978058400'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/343033752978058400'/><link rel='alternate' type='text/html' href='http://devtime.blogspot.com/2011/02/symfony-live-2011-interesting-links_09.html' title='Symfony live 2011 interesting links -  Symfony2 (day 2)'/><author><name>Carlos</name><uri>http://www.blogger.com/profile/15934070138187932218</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8YZg9B2sudqF_GLHxWVbwatq4LzKml2t6eRZl71dctIx-hY_uY83F2VaZu_yS0cdRYLkEzmoaxZMBVP5FnwFGufo5bh9DZeKsJIKFDtDGB0PsgpIB2OlVf2AbBr-_7uY/s113/me.jpeg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-19309483.post-1677889466572907925</id><published>2011-02-08T11:10:00.000-08:00</published><updated>2011-02-08T21:32:37.942-08:00</updated><title type='text'>Symfony live 2011 (Symfony2) interesting links</title><content type='html'>Twitter tag #sflive2011:&lt;br /&gt;&lt;br /&gt;&lt;a href=&quot;https://twitter.com/#%21/search?q=%23sflive2011&quot;&gt;https://twitter.com/#!/search?q=%23sflive2011&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Slides for the first presentation of the day, The Path to Symfony in the USA:&lt;br /&gt;&lt;br /&gt;&lt;a href=&quot;http://www.slideshare.net/dustin.whittle/the-path-to-symfony-in-the-usa&quot;&gt;http://www.slideshare.net/dustin.whittle/the-path-to-symfony-in-the-usa&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Symfony2 bundle repository:&lt;br /&gt;&lt;br /&gt;&lt;a href=&quot;http://www.symfony2bundles.org/&quot;&gt;http://www.symfony2bundles.org/&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Symfony Questions / Anwers :&lt;br /&gt;&lt;br /&gt;&lt;a href=&quot;http://symfonyexperts.com/&quot;&gt;http://symfonyexperts.com/&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Apostrophe presentation:&lt;br /&gt;&lt;br /&gt;&lt;a href=&quot;http://www.slideshare.net/tompunk/apostrophe-6853364&quot;&gt;http://www.slideshare.net/tompunk/apostrophe-6853364&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Symfony Live blogging:&lt;br /&gt;&lt;br /&gt;&lt;a href=&quot;http://window.punkave.com/2011/02/08/liveblogging-symfony-live/&quot;&gt;http://window.punkave.com/2011/02/08/liveblogging-symfony-live/&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Doctine in the real world (opensky) :&lt;br /&gt;&lt;br /&gt;&lt;a href=&quot;http://www.slideshare.net/jwage/doctrine-intherealworldsf-live2011sanfran&quot;&gt;http://www.slideshare.net/jwage/doctrine-intherealworldsf-live2011sanfran&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;phpBB4 building end user applications with Symfony2:&lt;br /&gt;&lt;br /&gt;http://prezi.com/gxrdwsplwplf/phpbb4-building-end-user-applications-with-symfony2/</content><link rel='replies' type='application/atom+xml' href='http://devtime.blogspot.com/feeds/1677889466572907925/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/19309483/1677889466572907925' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/1677889466572907925'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/1677889466572907925'/><link rel='alternate' type='text/html' href='http://devtime.blogspot.com/2011/02/symfony-live-2011-interesting-links.html' title='Symfony live 2011 (Symfony2) interesting links'/><author><name>Carlos</name><uri>http://www.blogger.com/profile/15934070138187932218</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8YZg9B2sudqF_GLHxWVbwatq4LzKml2t6eRZl71dctIx-hY_uY83F2VaZu_yS0cdRYLkEzmoaxZMBVP5FnwFGufo5bh9DZeKsJIKFDtDGB0PsgpIB2OlVf2AbBr-_7uY/s113/me.jpeg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-19309483.post-3175624501015730481</id><published>2010-08-30T12:18:00.000-07:00</published><updated>2010-08-30T12:42:18.229-07:00</updated><title type='text'>PHP 5.3.3 short tags problem when upgrading</title><content type='html'>Recently after upgrading php to 5.3.3 I found a problem with short tags &amp;lt;?= and &amp;lt;? , it seems that you now must only use &amp;lt;?php as starting tag, and all my code with &amp;lt;?= was not processed by php. &lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Short tags looks nicer and cleaner but can be a problem for people using XML, find more info here:&lt;br /&gt;&lt;br /&gt;http://wiki.php.net/rfc/shortags&lt;br /&gt;&lt;br /&gt;Here is a useful command if you need to replace this tags in your old code:&lt;br /&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;grep -oiR &#39;&amp;lt;?=&#39; /path/to/dir | cut -d &quot;:&quot; -f 1 | xargs sed -i &#39;s/&amp;lt;?=/&amp;lt;?php echo /g&#39;&lt;br /&gt;&lt;/code&gt;</content><link rel='replies' type='application/atom+xml' href='http://devtime.blogspot.com/feeds/3175624501015730481/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/19309483/3175624501015730481' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/3175624501015730481'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/3175624501015730481'/><link rel='alternate' type='text/html' href='http://devtime.blogspot.com/2010/08/php-533-short-tags-problem-when.html' title='PHP 5.3.3 short tags problem when upgrading'/><author><name>Carlos</name><uri>http://www.blogger.com/profile/15934070138187932218</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8YZg9B2sudqF_GLHxWVbwatq4LzKml2t6eRZl71dctIx-hY_uY83F2VaZu_yS0cdRYLkEzmoaxZMBVP5FnwFGufo5bh9DZeKsJIKFDtDGB0PsgpIB2OlVf2AbBr-_7uY/s113/me.jpeg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-19309483.post-659893871837524276</id><published>2009-09-03T06:53:00.000-07:00</published><updated>2009-09-03T07:07:28.714-07:00</updated><title type='text'>How to resize or scale a list of images on linux</title><content type='html'>Here is a simple but powerful command when you got several images that you want to shrink:&lt;br /&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;mogrify -scale 50% *.jpg&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;This will reduce all the images by 50%&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Or if you just want to reduce one image to 200x200 pixels for example:&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;convert -scale 200x200 image.jpg image_small.jpg&lt;br /&gt;&lt;/code&gt;</content><link rel='replies' type='application/atom+xml' href='http://devtime.blogspot.com/feeds/659893871837524276/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/19309483/659893871837524276' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/659893871837524276'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/659893871837524276'/><link rel='alternate' type='text/html' href='http://devtime.blogspot.com/2009/09/how-to-resize-or-scale-list-of-images.html' title='How to resize or scale a list of images on linux'/><author><name>Carlos</name><uri>http://www.blogger.com/profile/15934070138187932218</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8YZg9B2sudqF_GLHxWVbwatq4LzKml2t6eRZl71dctIx-hY_uY83F2VaZu_yS0cdRYLkEzmoaxZMBVP5FnwFGufo5bh9DZeKsJIKFDtDGB0PsgpIB2OlVf2AbBr-_7uY/s113/me.jpeg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-19309483.post-276198976383598482</id><published>2009-08-21T21:04:00.000-07:00</published><updated>2010-08-30T13:05:41.824-07:00</updated><title type='text'>Installing virtualbox on Ubuntu 9.04</title><content type='html'>&lt;code&gt;&lt;br /&gt;# virtualbox&lt;br /&gt;WARNING: The character device /dev/vboxdrv does not exist.&lt;br /&gt;   Please install the virtualbox-ose-source package and the appropriate&lt;br /&gt;   headers, most likely  linux-headers-generic.&lt;br /&gt;&lt;br /&gt;   You will not be able to start VMs until this problem is fixed.&lt;br /&gt;&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;root@ubuntu-laptop:/home/camafla# apt-get install linux-headers-server&lt;br /&gt;Reading package lists... Done&lt;br /&gt;Building dependency tree    &lt;br /&gt;Reading state information... Done&lt;br /&gt;The following extra packages will be installed:&lt;br /&gt;linux-headers-2.6.28-11-server&lt;br /&gt;The following NEW packages will be installed:&lt;br /&gt;linux-headers-2.6.28-11-server linux-headers-server&lt;br /&gt;0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.&lt;br /&gt;Need to get 672kB of archives.&lt;br /&gt;After this operation, 8139kB of additional disk space will be used.&lt;br /&gt;Do you want to continue [Y/n]? y&lt;br /&gt;Get:1 http://archive.ubuntu.com jaunty/main linux-headers-2.6.28-11-server 2.6.28-11.42 [669kB]&lt;br /&gt;Get:2 http://archive.ubuntu.com jaunty/main linux-headers-server 2.6.28.11.15 [3388B]&lt;br /&gt;Fetched 672kB in 6s (104kB/s)                                               &lt;br /&gt;Selecting previously deselected package linux-headers-2.6.28-11-server.&lt;br /&gt;(Reading database ... 157949 files and directories currently installed.)&lt;br /&gt;Unpacking linux-headers-2.6.28-11-server (from .../linux-headers-2.6.28-11-server_2.6.28-11.42_i386.deb) ...&lt;br /&gt;Selecting previously deselected package linux-headers-server.&lt;br /&gt;Unpacking linux-headers-server (from .../linux-headers-server_2.6.28.11.15_i386.deb) ...&lt;br /&gt;Setting up linux-headers-2.6.28-11-server (2.6.28-11.42) ...&lt;br /&gt;Examining /etc/kernel/header_postinst.d.&lt;br /&gt;run-parts: executing /etc/kernel/header_postinst.d/dkms&lt;br /&gt;* Running DKMS auto installation service for kernel 2.6.28-11-server        &lt;br /&gt;*  vboxdrv (2.1.4)...                                                          vboxdrv (2.1.4): Installing module.&lt;br /&gt;.............&lt;br /&gt;......&lt;br /&gt;                                                                       [ OK ]&lt;br /&gt;*  vboxnetflt (2.1.4)...                                                       vboxnetflt (2.1.4): Installing module.&lt;br /&gt;............&lt;br /&gt;......&lt;br /&gt;                                                                       [ OK ]&lt;br /&gt;run-parts: executing /etc/kernel/header_postinst.d/nvidia-common&lt;br /&gt;&lt;br /&gt;Setting up linux-headers-server (2.6.28.11.15) ...&lt;br /&gt;&lt;br /&gt;&lt;/code&gt;</content><link rel='replies' type='application/atom+xml' href='http://devtime.blogspot.com/feeds/276198976383598482/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/19309483/276198976383598482' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/276198976383598482'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/276198976383598482'/><link rel='alternate' type='text/html' href='http://devtime.blogspot.com/2009/08/installing-virtualbox-on-ubuntu-904.html' title='Installing virtualbox on Ubuntu 9.04'/><author><name>Carlos</name><uri>http://www.blogger.com/profile/15934070138187932218</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8YZg9B2sudqF_GLHxWVbwatq4LzKml2t6eRZl71dctIx-hY_uY83F2VaZu_yS0cdRYLkEzmoaxZMBVP5FnwFGufo5bh9DZeKsJIKFDtDGB0PsgpIB2OlVf2AbBr-_7uY/s113/me.jpeg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-19309483.post-5330890202485820689</id><published>2009-06-08T18:27:00.000-07:00</published><updated>2009-06-09T10:00:29.789-07:00</updated><title type='text'>LPI 102 exam reference card (or cheat sheet if you like)</title><content type='html'>&lt;a onblur=&quot;try {parent.deselectBloggerImageGracefully();} catch(e) {}&quot; href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjSuuT9zX6IbJqlCxdr3iG3EHBRlsQyBW-r7JAQfeUaWAzv15Ivj1G2w1iOybO8UT6A_BtxClSCIsdIhfmhEl4HYz3XYmKExLyTE9wnfB986T5PoiG7dxcXPULZzIlmT08xfjei/s1600-h/lpi-102-reference-card-v1.png&quot;&gt;&lt;img style=&quot;margin: 0px auto 10px; display: block; text-align: center; cursor: pointer; width: 235px; height: 320px;&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjSuuT9zX6IbJqlCxdr3iG3EHBRlsQyBW-r7JAQfeUaWAzv15Ivj1G2w1iOybO8UT6A_BtxClSCIsdIhfmhEl4HYz3XYmKExLyTE9wnfB986T5PoiG7dxcXPULZzIlmT08xfjei/s320/lpi-102-reference-card-v1.png&quot; alt=&quot;&quot; id=&quot;BLOGGER_PHOTO_ID_5345137711115954770&quot; border=&quot;0&quot; /&gt;&lt;/a&gt;&lt;br /&gt;I recently cleared the &lt;a href=&quot;http://www.lpi.org/eng/certification/the_lpic_program/lpic_1&quot;&gt;LPIC-1 certification&lt;/a&gt; (LPI certification Level 1) , as an educational exercise to study for my second exam (&lt;a href=&quot;http://www.lpi.org/eng/certification/the_lpic_program/lpic_1/exam_102_detailed_objectives&quot;&gt;exam 102&lt;/a&gt;) I created a reference card that helped me remember some commands and key concepts for the exam.&lt;br /&gt;&lt;br /&gt;I want to share this to anyone interested in taking this exam or just anyone who wants a quick linux reference card to the objectives included in the exam.&lt;br /&gt;&lt;br /&gt;&lt;span style=&quot;font-weight: bold;&quot;&gt;Download&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;PNG version: &lt;a href=&quot;http://pruebas.calipso.com.co/camafla/lpi-102-reference-card-v1.png&quot;&gt;lpi-102-reference-card-v1.png&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;PDF version: &lt;a href=&quot;http://pruebas.calipso.com.co/camafla/lpi-102-reference-card-v1.pdf&quot;&gt;lpi-102-reference-card-v1.pdf&lt;/a&gt;</content><link rel='replies' type='application/atom+xml' href='http://devtime.blogspot.com/feeds/5330890202485820689/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/19309483/5330890202485820689' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/5330890202485820689'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/5330890202485820689'/><link rel='alternate' type='text/html' href='http://devtime.blogspot.com/2009/06/lpi-102-exam-reference-card-or-cheat.html' title='LPI 102 exam reference card (or cheat sheet if you like)'/><author><name>Carlos</name><uri>http://www.blogger.com/profile/15934070138187932218</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8YZg9B2sudqF_GLHxWVbwatq4LzKml2t6eRZl71dctIx-hY_uY83F2VaZu_yS0cdRYLkEzmoaxZMBVP5FnwFGufo5bh9DZeKsJIKFDtDGB0PsgpIB2OlVf2AbBr-_7uY/s113/me.jpeg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjSuuT9zX6IbJqlCxdr3iG3EHBRlsQyBW-r7JAQfeUaWAzv15Ivj1G2w1iOybO8UT6A_BtxClSCIsdIhfmhEl4HYz3XYmKExLyTE9wnfB986T5PoiG7dxcXPULZzIlmT08xfjei/s72-c/lpi-102-reference-card-v1.png" height="72" width="72"/><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-19309483.post-6778555439820976265</id><published>2009-01-28T08:54:00.000-08:00</published><updated>2009-01-28T15:05:49.836-08:00</updated><title type='text'>Installing Oracle OCI8 and PHP</title><content type='html'>I will describe here the steps I needed to install oracle connectivity for php. It&#39;s supposed you have php installed, in my case&lt;br /&gt;I had php 5.1.6 throught RPM:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;# rpm -qa  | grep php&lt;br /&gt;php-5.1.6-20.el5_2.1&lt;br /&gt;php-adodb-4.81-1.el5.rf&lt;br /&gt;php-pecl-mailparse-2.1.1-1.el5.rf&lt;br /&gt;phpmyadmin-2.11.8.1-1.el5.rf&lt;br /&gt;php-odbc-5.1.6-20.el5_2.1&lt;br /&gt;php-pecl-fileinfo-1.0.4-1.el5.rf&lt;br /&gt;php-cli-5.1.6-20.el5_2.1&lt;br /&gt;php-pear-file-1.2.2-1.el5.rf&lt;br /&gt;php-eaccelerator-5.1.6_0.9.5.2-4.el5.rf&lt;br /&gt;php-pecl-memcache-2.1.2-1.el5.rf&lt;br /&gt;php-pear-db-1.7.13-2.el5.rf&lt;br /&gt;php-common-5.1.6-20.el5_2.1&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;Distro:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;# cat /etc/redhat-release&lt;br /&gt;Red Hat Enterprise Linux Server release 5 (Tikanga)&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;1. Download and install the Instant Client rpms from oracle which you can get here &lt;a href=&quot;http://www.oracle.com/technology/tech/oci/instantclient/instantclient.html&quot;&gt;http://www.oracle.com/technology/tech/oci/instantclient/instantclient.html&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;This are the two files needed in my case:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;# rpm -ivh oracle-instantclient11.1-basic-11.1.0.7.0-1.x86_64.rpm&lt;br /&gt;&lt;br /&gt;# rpm -ivh oracle-instantclient11.1-devel-11.1.0.7.0-1.x86_64.rpm&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;2. Compile and install the oci8 extension:&lt;br /&gt;&lt;br /&gt;Make sure you have the proper packages to compile a script like:  php-devel, gcc,etc.&lt;br /&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;# pear install pecl/oci8&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;I used pear install pecl/oci8 instead of pear install oci8 because for some reason the second one returns an out of memory error and ignores the memory limit variable (memory_limit = XX ) from the&lt;br /&gt;php.ini file.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;When asked about this:&lt;br /&gt;&lt;br /&gt;Please provide the path to the ORACLE_HOME directory. Use &#39;instantclient,/path/to/instant/client/lib&#39; if you&#39;re compiling with Oracle Instant Client : autodetect&lt;br /&gt;&lt;br /&gt;If you have oracle installed in the same server just hit enter. If not (you just want to connect to another server) type:&lt;br /&gt;&lt;br /&gt;instantclient and enter or the path to the oracle libraries e.g: /usr/lib/oracle/11.1/client64/lib/.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;3. Finally, edit your php.ini file (/etc/php.ini) and add the extension=oci8.so in the Dynamic extensions section. Don&#39;t forget to restart apache so the changes take effect in apache.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Additional information can be found here: &lt;a href=&quot;http://www.oracle.com/technology/pub/notes/technote_php_instant.html&quot;&gt;http://www.oracle.com/technology/pub/notes/technote_php_instant.html&lt;/a&gt;.</content><link rel='replies' type='application/atom+xml' href='http://devtime.blogspot.com/feeds/6778555439820976265/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/19309483/6778555439820976265' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/6778555439820976265'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/6778555439820976265'/><link rel='alternate' type='text/html' href='http://devtime.blogspot.com/2009/01/installing-oracle-oci8-and-php.html' title='Installing Oracle OCI8 and PHP'/><author><name>Carlos</name><uri>http://www.blogger.com/profile/15934070138187932218</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8YZg9B2sudqF_GLHxWVbwatq4LzKml2t6eRZl71dctIx-hY_uY83F2VaZu_yS0cdRYLkEzmoaxZMBVP5FnwFGufo5bh9DZeKsJIKFDtDGB0PsgpIB2OlVf2AbBr-_7uY/s113/me.jpeg'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-19309483.post-6165539440868957975</id><published>2008-09-10T07:08:00.000-07:00</published><updated>2008-09-10T07:18:46.741-07:00</updated><title type='text'>How to solve no sound in flash videos ( fedora )</title><content type='html'>After installing flash-plugin-9.0.124.0-release.i386 rpm I just got the flash plugin in my firefox but didn&#39;t get any sound. Googling about it I found a solution that worked, you need to install libflashsupport rpm, restart firefox and that&#39;s it:&lt;br /&gt;&lt;br /&gt;just type this:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;yum install libflashsupport&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;I guess this may work in other red hat based distros.</content><link rel='replies' type='application/atom+xml' href='http://devtime.blogspot.com/feeds/6165539440868957975/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/19309483/6165539440868957975' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/6165539440868957975'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/6165539440868957975'/><link rel='alternate' type='text/html' href='http://devtime.blogspot.com/2008/09/how-to-solve-no-sound-in-flash-videos.html' title='How to solve no sound in flash videos ( fedora )'/><author><name>Carlos</name><uri>http://www.blogger.com/profile/15934070138187932218</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8YZg9B2sudqF_GLHxWVbwatq4LzKml2t6eRZl71dctIx-hY_uY83F2VaZu_yS0cdRYLkEzmoaxZMBVP5FnwFGufo5bh9DZeKsJIKFDtDGB0PsgpIB2OlVf2AbBr-_7uY/s113/me.jpeg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-19309483.post-2140229443988143650</id><published>2008-09-08T12:25:00.000-07:00</published><updated>2008-09-08T12:31:43.868-07:00</updated><title type='text'>PHP Fatal error:  Class &#39;DomDocument&#39; not found in ...</title><content type='html'>After running symfony propel-build-all on a new symfony installation got this error. The solution is to install the  php-xml rpm (deb).&lt;br /&gt;&lt;br /&gt; [root@devel2 cms]# symfony propel-build-all&lt;br /&gt;&gt;&gt; schema    converting &quot;/home/sfprojects/cm...lugin/config/schema.yml&quot; to XML&lt;br /&gt;&gt;&gt; schema    putting /home/sfprojects/cms/pl...erated-sfGuardPlugin-schema.xml&lt;br /&gt;&gt;&gt; file+     config/generated-sfGuardPlugin-schema.xml&lt;br /&gt;&gt;&gt; file-     /home/sfprojects/cms/plugins/sf...erated-sfGuardPlugin-schema.xml&lt;br /&gt;Buildfile: /usr/share/pear/symfony/vendor/propel-generator/build.xml&lt;br /&gt;[resolvepath] Resolved /home/sfprojects/cms/config to /home/sfprojects/cms/config&lt;br /&gt;&lt;br /&gt;propel-project-builder &gt; check-project-or-dir-set:&lt;br /&gt;&lt;br /&gt;propel-project-builder &gt; check-project-set:&lt;br /&gt;&lt;br /&gt;propel-project-builder &gt; set-project-dir:&lt;br /&gt;&lt;br /&gt;propel-project-builder &gt; check-buildprops-exists:&lt;br /&gt;&lt;br /&gt;propel-project-builder &gt; check-buildprops-for-propel-gen:&lt;br /&gt;&lt;br /&gt;propel-project-builder &gt; check-buildprops:&lt;br /&gt;&lt;br /&gt;propel-project-builder &gt; configure:&lt;br /&gt;     [echo] Loading project-specific props from /home/sfprojects/cms/config/propel.ini&lt;br /&gt; [property] Loading /home/sfprojects/cms/config/propel.ini&lt;br /&gt;&lt;br /&gt;propel-project-builder &gt; om:&lt;br /&gt;    [phing] Calling Buildfile &#39;/usr/share/pear/symfony/vendor/propel-generator/build-propel.xml&#39; with target &#39;om&#39;&lt;br /&gt; [property] Loading /usr/share/pear/symfony/vendor/propel-generator/./default.properties&lt;br /&gt;&lt;br /&gt;propel &gt; check-run-only-on-schema-change:&lt;br /&gt;&lt;br /&gt;propel &gt; om-check:&lt;br /&gt;&lt;br /&gt;propel &gt; om:&lt;br /&gt;     [echo] +------------------------------------------+&lt;br /&gt;     [echo] |                                          |&lt;br /&gt;     [echo] | Generating Peer-based Object Model for   |&lt;br /&gt;     [echo] | YOUR Propel project! (NEW OM BUILDERS)!  |&lt;br /&gt;     [echo] |                                          |&lt;br /&gt;     [echo] +------------------------------------------+&lt;br /&gt;[phingcall] Calling Buildfile &#39;/usr/share/pear/symfony/vendor/propel-generator/build-propel.xml&#39; with target &#39;om-template&#39;&lt;br /&gt; [property] Loading /usr/share/pear/symfony/vendor/propel-generator/./default.properties&lt;br /&gt;&lt;br /&gt;propel &gt; om-template:&lt;br /&gt;[propel-om] Target database type: mysql&lt;br /&gt;[propel-om] Target package: lib.model&lt;br /&gt;[propel-om] Using template path: /usr/share/pear/symfony/vendor/propel-generator/templates&lt;br /&gt;[propel-om] Output directory: /home/sfprojects/cms&lt;br /&gt;[propel-om] Processing: schema.xml&lt;br /&gt;PHP Fatal error:  Class &#39;DomDocument&#39; not found in /usr/share/pear/symfony/vendor/propel-generator/classes/propel/phing/AbstractPropelDataModelTask.php on line 406</content><link rel='replies' type='application/atom+xml' href='http://devtime.blogspot.com/feeds/2140229443988143650/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/19309483/2140229443988143650' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/2140229443988143650'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/2140229443988143650'/><link rel='alternate' type='text/html' href='http://devtime.blogspot.com/2008/09/php-fatal-error-class-domdocument-not.html' title='PHP Fatal error:  Class &#39;DomDocument&#39; not found in ...'/><author><name>Carlos</name><uri>http://www.blogger.com/profile/15934070138187932218</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8YZg9B2sudqF_GLHxWVbwatq4LzKml2t6eRZl71dctIx-hY_uY83F2VaZu_yS0cdRYLkEzmoaxZMBVP5FnwFGufo5bh9DZeKsJIKFDtDGB0PsgpIB2OlVf2AbBr-_7uY/s113/me.jpeg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-19309483.post-9061289666302272603</id><published>2008-06-21T15:14:00.000-07:00</published><updated>2008-06-21T15:25:27.455-07:00</updated><title type='text'>Mplayer crashes using beryl compiz-fusion</title><content type='html'>When you start to use compiz-fusion and all the fancy desktop effects you will notice a little problem, you can&#39;t watch videos!. There&#39;s a  bug that crashes mplayer, totem and all your video players. Hopefully there&#39;s a workaround for mplayer (not sure how to solve the problem with totem).&lt;br /&gt;&lt;br /&gt;1. Open mplayer.&lt;br /&gt;2. Right click over the window.&lt;br /&gt;3. Click on preferences.&lt;br /&gt;4. Click on the Video tab .&lt;br /&gt;5. Change the video driver from Xv to X11 and click Ok.&lt;br /&gt;&lt;br /&gt;You may have to restart mplayer to see the changes.</content><link rel='replies' type='application/atom+xml' href='http://devtime.blogspot.com/feeds/9061289666302272603/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/19309483/9061289666302272603' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/9061289666302272603'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/9061289666302272603'/><link rel='alternate' type='text/html' href='http://devtime.blogspot.com/2008/06/mplayer-crahes-using-beryl-compiz.html' title='Mplayer crashes using beryl compiz-fusion'/><author><name>Carlos</name><uri>http://www.blogger.com/profile/15934070138187932218</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8YZg9B2sudqF_GLHxWVbwatq4LzKml2t6eRZl71dctIx-hY_uY83F2VaZu_yS0cdRYLkEzmoaxZMBVP5FnwFGufo5bh9DZeKsJIKFDtDGB0PsgpIB2OlVf2AbBr-_7uY/s113/me.jpeg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-19309483.post-8555075367055302383</id><published>2008-06-18T19:17:00.000-07:00</published><updated>2008-12-11T17:14:35.736-08:00</updated><title type='text'>Vista Blue Screen of Death: STOP: 0x0000008E</title><content type='html'>&lt;a onblur=&quot;try {parent.deselectBloggerImageGracefully();} catch(e) {}&quot; href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh7PQMWLI1r362hiIQKHiBhqBGk0nib24typY2LfDI0uHR_rBw2IkZJf2trEbFTEeG0_S3CKSEkbxdQIZfYSqlVEUTI9ho_6g-MctqM-P6d-bmj2WbeyMPHAc0rlVK2IwZyGJN4/s1600-h/finde_junio+040.JPG&quot;&gt;&lt;img style=&quot;margin: 0px auto 10px; display: block; text-align: center; cursor: pointer;&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh7PQMWLI1r362hiIQKHiBhqBGk0nib24typY2LfDI0uHR_rBw2IkZJf2trEbFTEeG0_S3CKSEkbxdQIZfYSqlVEUTI9ho_6g-MctqM-P6d-bmj2WbeyMPHAc0rlVK2IwZyGJN4/s320/finde_junio+040.JPG&quot; alt=&quot;&quot; id=&quot;BLOGGER_PHOTO_ID_5213416149609299410&quot; border=&quot;0&quot; /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;The famous blue screen of death attacked me again (&lt;a href=&quot;http://devtime.blogspot.com/2005/12/bsod-blue-screen-of-death.html&quot;&gt;previous bsod&lt;/a&gt;), this time on Vista, on my Dell inspiron 1520. It&#39;s very annoying that you have to deal with this kind of errors on a laptop recently bought.  This error started to display a few seconds after logging in to the user account and with no clear reason of what could be the trigger of the error.&lt;br /&gt;&lt;br /&gt;The solution this time actually had nothing to do (directly) with Windows Vista but with the laptop BIOS, and the solution came from the dell support site &lt;a href=&quot;http://support.dell.com/support/topics/global.aspx/support/dsn/en/document?c=us&amp;amp;docid=33428502887DCFF7E040A68F5B2835B9&amp;amp;l=en&amp;amp;s=gen&quot;&gt;support.dell.com, &lt;/a&gt;the error itself suggested to update the BIOS , but I don&#39;t  pay too much attention to this general error messages. If you&#39;re having this same problem you could go and follow this &lt;a href=&quot;http://support.dell.com/support/topics/global.aspx/support/dsn/en/document?c=us&amp;amp;docid=33428502887DCFF7E040A68F5B2835B9&amp;amp;l=en&amp;amp;s=gen&quot;&gt;check list&lt;/a&gt; from dell, the BIOS upgrade was the second suggestion for a BSOF error and this was the one that worked for me, the file to do this is in the &quot;Drivers and Downloads&quot; section and you can select between all the different models.</content><link rel='replies' type='application/atom+xml' href='http://devtime.blogspot.com/feeds/8555075367055302383/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/19309483/8555075367055302383' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/8555075367055302383'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/8555075367055302383'/><link rel='alternate' type='text/html' href='http://devtime.blogspot.com/2008/06/blue-screen-of-death-stop-0x0000008e.html' title='Vista Blue Screen of Death: STOP: 0x0000008E'/><author><name>Carlos</name><uri>http://www.blogger.com/profile/15934070138187932218</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8YZg9B2sudqF_GLHxWVbwatq4LzKml2t6eRZl71dctIx-hY_uY83F2VaZu_yS0cdRYLkEzmoaxZMBVP5FnwFGufo5bh9DZeKsJIKFDtDGB0PsgpIB2OlVf2AbBr-_7uY/s113/me.jpeg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh7PQMWLI1r362hiIQKHiBhqBGk0nib24typY2LfDI0uHR_rBw2IkZJf2trEbFTEeG0_S3CKSEkbxdQIZfYSqlVEUTI9ho_6g-MctqM-P6d-bmj2WbeyMPHAc0rlVK2IwZyGJN4/s72-c/finde_junio+040.JPG" height="72" width="72"/><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-19309483.post-6981455676861938924</id><published>2008-06-18T09:17:00.000-07:00</published><updated>2008-06-18T09:32:45.202-07:00</updated><title type='text'>Subversion: MKCOL of &#39;...&#39; 405 Method Not Allowed</title><content type='html'>I was messing with the .svn/entries file in one of my local working copy folders, also I rm -rf a folder and regenerated again (I&#39;m using symfony admin generator) , long story, but the fact is that I think I screwed up something and started to get this error when trying to commit:&lt;br /&gt;&lt;br /&gt;# svn commit -m &quot;backend modifications&quot;&lt;br /&gt;Adding         apps/backend/modules/comment&lt;br /&gt;svn: Commit failed (details follow):&lt;br /&gt;svn: MKCOL of &#39;/projects/cms/!svn/wrk/5ca09002-f34f-0410-890e-9511925f86a5/trunk/apps/backend/modules/comment&#39;: 405 Method Not Allowed  (http://svn.calipso.com.co)&lt;br /&gt;&lt;br /&gt;After some googling, I found it could be some proxy problem, but I wasn&#39;t using a proxy. Later I found that this error could mean that&lt;br /&gt;the directory already existed in the repository and couldn&#39;t be recreated again, so my next step was to delete the folder from the repository (svn del ...) and try to do a fresh commit after recreating the folder and files included in it, and this worked ;).&lt;br /&gt;&lt;br /&gt;I hope this helps some lost soul out there.</content><link rel='replies' type='application/atom+xml' href='http://devtime.blogspot.com/feeds/6981455676861938924/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/19309483/6981455676861938924' title='11 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/6981455676861938924'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/6981455676861938924'/><link rel='alternate' type='text/html' href='http://devtime.blogspot.com/2008/06/subversion-mkcol-of-405-method-not.html' title='Subversion: MKCOL of &#39;...&#39; 405 Method Not Allowed'/><author><name>Carlos</name><uri>http://www.blogger.com/profile/15934070138187932218</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8YZg9B2sudqF_GLHxWVbwatq4LzKml2t6eRZl71dctIx-hY_uY83F2VaZu_yS0cdRYLkEzmoaxZMBVP5FnwFGufo5bh9DZeKsJIKFDtDGB0PsgpIB2OlVf2AbBr-_7uY/s113/me.jpeg'/></author><thr:total>11</thr:total></entry><entry><id>tag:blogger.com,1999:blog-19309483.post-4309100411020094183</id><published>2008-05-22T09:30:00.000-07:00</published><updated>2008-05-22T09:35:51.892-07:00</updated><title type='text'>Unable to write config cache for &quot;config/config_handlers.yml&quot;</title><content type='html'>After upgrading to symfony version 1.0.16 from 1.0.8 I started to get this error:&lt;br /&gt;&lt;br /&gt;Unable to write config cache for &quot;config/config_handlers.yml&quot;&lt;br /&gt;&lt;br /&gt;I tried to chmod 777 the cache and it didn&#39;t work. The solution for me was to disable SELinux.&lt;br /&gt;&lt;br /&gt;How to do that? edit your /etc/sysconfig/selinux file, and set SELINUX=disabled:&lt;br /&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;# This file controls the state of SELinux on the system.&lt;br /&gt;# SELINUX= can take one of these three values:&lt;br /&gt;#       enforcinfg - SELinux security policy is enforced.&lt;br /&gt;#       permissive - SELinux prints warnings instead of enforcing.&lt;br /&gt;#       disabled - No SELinux policy is loaded.&lt;br /&gt;SELINUX=disabled&lt;br /&gt;&lt;/code&gt;</content><link rel='replies' type='application/atom+xml' href='http://devtime.blogspot.com/feeds/4309100411020094183/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/19309483/4309100411020094183' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/4309100411020094183'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/4309100411020094183'/><link rel='alternate' type='text/html' href='http://devtime.blogspot.com/2008/05/unable-to-write-config-cache-for.html' title='Unable to write config cache for &quot;config/config_handlers.yml&quot;'/><author><name>Carlos</name><uri>http://www.blogger.com/profile/15934070138187932218</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8YZg9B2sudqF_GLHxWVbwatq4LzKml2t6eRZl71dctIx-hY_uY83F2VaZu_yS0cdRYLkEzmoaxZMBVP5FnwFGufo5bh9DZeKsJIKFDtDGB0PsgpIB2OlVf2AbBr-_7uY/s113/me.jpeg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-19309483.post-5781261299107321683</id><published>2008-02-21T06:36:00.000-08:00</published><updated>2011-05-25T08:28:06.632-07:00</updated><title type='text'>Page redirection in php with header(&#39;Location...&#39;) : Blank page vs Working redirection</title><content type='html'>This kind of errors are what make debugging sometimes a very frustrating part of the developement, if you&#39;re suffering a blank page when trying to make a header(&#39;Location..&#39;), give this a try:&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;This is a good redirection:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;&lt;?&lt;br /&gt;header(&#39;Location: http://www.example.com/&#39;);&lt;br /&gt;exit();&lt;br /&gt;?&gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;And this is a wrong redirection:&lt;br /&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;&lt;?&lt;br /&gt;header(&#39;Location : http://www.example.com/&#39;);&lt;br /&gt;exit();&lt;br /&gt;?&gt;&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;Notice a space between &#39;Location&#39; and &#39;:&#39; this makes the redirection not to work!!!!&lt;br /&gt;&lt;br /&gt;Simple errors likes this consume a lot of time :( , hope helps someone else...</content><link rel='replies' type='application/atom+xml' href='http://devtime.blogspot.com/feeds/5781261299107321683/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/19309483/5781261299107321683' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/5781261299107321683'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/5781261299107321683'/><link rel='alternate' type='text/html' href='http://devtime.blogspot.com/2008/02/page-redirection-in-php-with.html' title='Page redirection in php with header(&#39;Location...&#39;) : Blank page vs Working redirection'/><author><name>Carlos</name><uri>http://www.blogger.com/profile/15934070138187932218</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8YZg9B2sudqF_GLHxWVbwatq4LzKml2t6eRZl71dctIx-hY_uY83F2VaZu_yS0cdRYLkEzmoaxZMBVP5FnwFGufo5bh9DZeKsJIKFDtDGB0PsgpIB2OlVf2AbBr-_7uY/s113/me.jpeg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-19309483.post-5643187101459689905</id><published>2008-02-11T12:29:00.000-08:00</published><updated>2008-02-21T06:44:24.850-08:00</updated><title type='text'>.htaccess: order not allowed here</title><content type='html'>I was getting an 500 Internal Server Error when trying to access Drupal after installing it, when I checked the http error log it said : .htaccess: order not allowed here.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;After adding this to the httpd.conf and restarted apache it worked:&lt;br /&gt;&lt;br /&gt;&lt;code &gt;&lt;br /&gt;&amp;lt; directory &quot;/home/httpd/html/drupal&quot; &amp;gt;&lt;br /&gt;AllowOverride FileInfo Limit Options Indexes&lt;br /&gt;&amp;lt; /directory &amp;gt;&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;change &quot;/home/httpd/html/drupal&quot; to wherever your document root is.</content><link rel='replies' type='application/atom+xml' href='http://devtime.blogspot.com/feeds/5643187101459689905/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/19309483/5643187101459689905' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/5643187101459689905'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/5643187101459689905'/><link rel='alternate' type='text/html' href='http://devtime.blogspot.com/2008/02/htaccess-order-not-allowed-here.html' title='.htaccess: order not allowed here'/><author><name>Carlos</name><uri>http://www.blogger.com/profile/15934070138187932218</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8YZg9B2sudqF_GLHxWVbwatq4LzKml2t6eRZl71dctIx-hY_uY83F2VaZu_yS0cdRYLkEzmoaxZMBVP5FnwFGufo5bh9DZeKsJIKFDtDGB0PsgpIB2OlVf2AbBr-_7uY/s113/me.jpeg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-19309483.post-7510617945952296496</id><published>2008-02-08T13:30:00.000-08:00</published><updated>2008-02-08T13:35:13.611-08:00</updated><title type='text'>Apache Error: No space left on device</title><content type='html'>Apache doesn&#39;t start and the error log contains:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;[emerg] (28)No space left on device: Couldn&#39;t create accept lock&lt;br /&gt;or&lt;br /&gt;[crit] (28)No space left on device: mod_rewrite: could not create rewrite_log_lock Configuration Failed&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;After checking your disk it shows that you have plenty of space. The problem is that apache didn&#39;t shut down properly, and it&#39;s left myriads of semaphore-arrays left, owned by &#39;apache&#39; user. &lt;br /&gt;&lt;br /&gt;Run:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;ipcs -s | grep apache&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;Removing these semaphores immediately should solve the problem and allow apache to start.&lt;br /&gt;&lt;code&gt;&lt;br /&gt;ipcs -s | grep apache | perl -e &#39;while (&lt;STDIN&gt;) { @a=split(/\s+/); print `ipcrm sem $a[1]`}&#39;&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;where &#39;apache&#39; is the owner of the apache process, if that&#39;s not the name of the user on your server change it.</content><link rel='replies' type='application/atom+xml' href='http://devtime.blogspot.com/feeds/7510617945952296496/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/19309483/7510617945952296496' title='5 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/7510617945952296496'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/7510617945952296496'/><link rel='alternate' type='text/html' href='http://devtime.blogspot.com/2008/02/apache-error-no-space-left-on-device.html' title='Apache Error: No space left on device'/><author><name>Carlos</name><uri>http://www.blogger.com/profile/15934070138187932218</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8YZg9B2sudqF_GLHxWVbwatq4LzKml2t6eRZl71dctIx-hY_uY83F2VaZu_yS0cdRYLkEzmoaxZMBVP5FnwFGufo5bh9DZeKsJIKFDtDGB0PsgpIB2OlVf2AbBr-_7uY/s113/me.jpeg'/></author><thr:total>5</thr:total></entry><entry><id>tag:blogger.com,1999:blog-19309483.post-3741768319328665616</id><published>2008-02-08T13:07:00.000-08:00</published><updated>2008-02-08T13:24:05.722-08:00</updated><title type='text'>How to check running queries and stats in postgres ?</title><content type='html'>You want to know what query is slowing the database or want to check what&#39;s going on with a query you&lt;br /&gt;just run, well in mysql just need to type &#39;show processlist;&#39;, but in postgres you must enable two variables&lt;br /&gt;to check this and other stats.&lt;br /&gt;&lt;br /&gt;Edit your postgres.conf which should be on /var/lib/pgsql/data/postgresql.conf for *nix installations and add or change this:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;stats_start_collector = true&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;This must be set to true for the statistics collector to be launched at all.&lt;br /&gt;&lt;code&gt;&lt;br /&gt;stats_command_string = true&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;This enables monitoring of the current command being executed by any server process. The statistics collector subprocess need not be running to enable this feature.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;After restarting postgres the following query will show currently running queries&lt;br /&gt;&lt;code&gt;&lt;br /&gt;/etc/init.d/postgresql restart&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;psql -U postgres template1 -c &quot;select * from pg_stat_activity&quot;&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;only as user &quot;postgres&quot;</content><link rel='replies' type='application/atom+xml' href='http://devtime.blogspot.com/feeds/3741768319328665616/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/19309483/3741768319328665616' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/3741768319328665616'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/3741768319328665616'/><link rel='alternate' type='text/html' href='http://devtime.blogspot.com/2008/02/how-to-check-running-queries-and-stats.html' title='How to check running queries and stats in postgres ?'/><author><name>Carlos</name><uri>http://www.blogger.com/profile/15934070138187932218</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8YZg9B2sudqF_GLHxWVbwatq4LzKml2t6eRZl71dctIx-hY_uY83F2VaZu_yS0cdRYLkEzmoaxZMBVP5FnwFGufo5bh9DZeKsJIKFDtDGB0PsgpIB2OlVf2AbBr-_7uY/s113/me.jpeg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-19309483.post-5957613590005004277</id><published>2007-12-03T18:07:00.000-08:00</published><updated>2008-12-11T17:14:36.008-08:00</updated><title type='text'>How to create a DSL connection on ubuntu</title><content type='html'>If your router/modem is set in bridge mode and you need to dial to make a connection you must use pppoE (Point to Point Protocol Over Ethernet) it&#39;s similar to the usual modem dial-up connection, but the difference is that you use the network an not the land line to connect.&lt;br /&gt;&lt;br /&gt;In ubuntu you can run a little script called:&lt;br /&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;# pppoeconf&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;&lt;a onblur=&quot;try {parent.deselectBloggerImageGracefully();} catch(e) {}&quot; href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEix7gYJTIZ-bQb6HA-StODvAxNASMAkWG3vUQT1Q3SlVpR45EKGjM33gNyXQ3tnFZzI74I1_OcvzFmfV2Oeis5g87l5jiiVi6m4tyZY0dlLtf5XZ2cHPxjrs1j0_A5vfY2wkQgy/s1600-h/pppoeconf1.jpg&quot;&gt;&lt;img style=&quot;margin: 0px auto 10px; display: block; text-align: center; cursor: pointer;&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEix7gYJTIZ-bQb6HA-StODvAxNASMAkWG3vUQT1Q3SlVpR45EKGjM33gNyXQ3tnFZzI74I1_OcvzFmfV2Oeis5g87l5jiiVi6m4tyZY0dlLtf5XZ2cHPxjrs1j0_A5vfY2wkQgy/s320/pppoeconf1.jpg&quot; alt=&quot;&quot; id=&quot;BLOGGER_PHOTO_ID_5140139330713342210&quot; border=&quot;0&quot; /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Just accept the defaults an make sure you give the right username/password.&lt;br /&gt;&lt;br /&gt;it will edit this file:&lt;br /&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;# cat /etc/ppp/peers/dsl-provider&lt;br /&gt;&lt;br /&gt;# Minimalistic default options file for DSL/PPPoE connections&lt;br /&gt;&lt;br /&gt;noipdefault&lt;br /&gt;defaultroute&lt;br /&gt;replacedefaultroute&lt;br /&gt;hide-password&lt;br /&gt;#lcp-echo-interval 30&lt;br /&gt;#lcp-echo-failure 4&lt;br /&gt;noauth&lt;br /&gt;persist&lt;br /&gt;#mtu 1492&lt;br /&gt;usepeerdns&lt;br /&gt;plugin rp-pppoe.so&lt;br /&gt;nic-ath0&lt;br /&gt;user &quot;xxxxxxxxxxx&quot;&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Now to create a connection use:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;# pon dsl-provider&lt;br /&gt;&lt;br /&gt;Plugin rp-pppoe.so loaded.&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;&quot;dsl-provider&quot; is name I chose for the connection which is the default&lt;br /&gt;&lt;br /&gt;And to stop a connection use:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;# poff&lt;br /&gt;&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;To stop all processes:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;# poff -a&lt;br /&gt;&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;You can check the log using this commmand:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;# plog&lt;br /&gt;pppd[3928] : pppd 2.4.4 started by root, uid 0&lt;br /&gt;&lt;br /&gt;&lt;/code&gt;</content><link rel='replies' type='application/atom+xml' href='http://devtime.blogspot.com/feeds/5957613590005004277/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/19309483/5957613590005004277' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/5957613590005004277'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/5957613590005004277'/><link rel='alternate' type='text/html' href='http://devtime.blogspot.com/2007/12/how-to-create-dsl-connection-on-ubuntu.html' title='How to create a DSL connection on ubuntu'/><author><name>Carlos</name><uri>http://www.blogger.com/profile/15934070138187932218</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8YZg9B2sudqF_GLHxWVbwatq4LzKml2t6eRZl71dctIx-hY_uY83F2VaZu_yS0cdRYLkEzmoaxZMBVP5FnwFGufo5bh9DZeKsJIKFDtDGB0PsgpIB2OlVf2AbBr-_7uY/s113/me.jpeg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEix7gYJTIZ-bQb6HA-StODvAxNASMAkWG3vUQT1Q3SlVpR45EKGjM33gNyXQ3tnFZzI74I1_OcvzFmfV2Oeis5g87l5jiiVi6m4tyZY0dlLtf5XZ2cHPxjrs1j0_A5vfY2wkQgy/s72-c/pppoeconf1.jpg" height="72" width="72"/><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-19309483.post-3290639723105163066</id><published>2007-09-19T09:36:00.000-07:00</published><updated>2008-12-11T17:14:36.295-08:00</updated><title type='text'>My Firefox Toolbars are blank !</title><content type='html'>For some unknown reason my web developer and delicious firefox toobars disappeared, I could see the space where they used to be but no icons or anything was there. I tried with the view toolbars menu , checking and unchecking to hide and show them, but that didn&#39;t work. Finally I found the solution, firefox have an option called firefox safemode &lt;a href=&quot;http://kb.mozillazine.org/Safe_mode&quot; target=&quot;_blank&quot;&gt;http://kb.mozillazine.org/Safe_mode&lt;/a&gt; which allows  us to troubleshoot some problems (like this one), all you have to do is:&lt;br /&gt;&lt;br /&gt;1. Close any running intance of firefox.&lt;br /&gt;2. Type this command :&lt;br /&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;firefox -safe-mode&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;For more info for different OSs &lt;a href=&quot;http://kb.mozillazine.org/Safe_mode&quot; target=&quot;_blank&quot;&gt;check here&lt;/a&gt;&lt;br /&gt;3. Then check the box for &quot;Reset toolbars and controls&quot;&lt;br /&gt;&lt;a onblur=&quot;try {parent.deselectBloggerImageGracefully();} catch(e) {}&quot; href=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhPKohX86skJLJW4aZKy7CSJh1SNQBeuJ46V-_mDNqZVe1R2CFyVssRWN1WZkoD9tPIYz8VXhJXqNq6bBP4tKEGF8WFCzPkvQ05U7enQdupyiLrB_Hd86wM9u0UMJgofPfhJU7q/s1600-h/ffsm.jpg&quot;&gt;&lt;img style=&quot;margin: 0px auto 10px; display: block; text-align: center; cursor: pointer;&quot; src=&quot;https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhPKohX86skJLJW4aZKy7CSJh1SNQBeuJ46V-_mDNqZVe1R2CFyVssRWN1WZkoD9tPIYz8VXhJXqNq6bBP4tKEGF8WFCzPkvQ05U7enQdupyiLrB_Hd86wM9u0UMJgofPfhJU7q/s320/ffsm.jpg&quot; alt=&quot;&quot; id=&quot;BLOGGER_PHOTO_ID_5111994874775817314&quot; border=&quot;0&quot; /&gt;&lt;/a&gt;&lt;br /&gt;4. Click on &quot;Make changes and restart&quot;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;That&#39;s it... your toolbar icons should appear again.</content><link rel='replies' type='application/atom+xml' href='http://devtime.blogspot.com/feeds/3290639723105163066/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment/fullpage/post/19309483/3290639723105163066' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/3290639723105163066'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/19309483/posts/default/3290639723105163066'/><link rel='alternate' type='text/html' href='http://devtime.blogspot.com/2007/09/my-firefox-toolbars-are-blank.html' title='My Firefox Toolbars are blank !'/><author><name>Carlos</name><uri>http://www.blogger.com/profile/15934070138187932218</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='//blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh8YZg9B2sudqF_GLHxWVbwatq4LzKml2t6eRZl71dctIx-hY_uY83F2VaZu_yS0cdRYLkEzmoaxZMBVP5FnwFGufo5bh9DZeKsJIKFDtDGB0PsgpIB2OlVf2AbBr-_7uY/s113/me.jpeg'/></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhPKohX86skJLJW4aZKy7CSJh1SNQBeuJ46V-_mDNqZVe1R2CFyVssRWN1WZkoD9tPIYz8VXhJXqNq6bBP4tKEGF8WFCzPkvQ05U7enQdupyiLrB_Hd86wM9u0UMJgofPfhJU7q/s72-c/ffsm.jpg" height="72" width="72"/><thr:total>3</thr:total></entry></feed>