<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Laïla Atrmouh</title>
    <link>/en/</link>
    <description>Recent content on Laïla Atrmouh</description>
    <generator>Hugo</generator>
    <language>en</language>
    <copyright>&lt;a href=&#34;https://creativecommons.org/licenses/by-nc/4.0/&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;CC BY-NC 4.0&lt;/a&gt;</copyright>
    <lastBuildDate>Wed, 25 Mar 2026 10:14:15 +0000</lastBuildDate>
    <atom:link href="/en/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>Migrating from Chakra v2 to Chakra v3</title>
      <link>/en/posts/2026/03/migrating-from-chakra-v2-to-chakra-v3/</link>
      <pubDate>Wed, 25 Mar 2026 10:14:15 +0000</pubDate>
      <guid>/en/posts/2026/03/migrating-from-chakra-v2-to-chakra-v3/</guid>
      <description>Migrating to Chakra v3 turned out to be a pretty substantial upgrade.</description>
    </item>
    <item>
      <title>TIL 1</title>
      <link>/en/posts/2020/05/til-1/</link>
      <pubDate>Tue, 26 May 2020 20:14:34 +0200</pubDate>
      <guid>/en/posts/2020/05/til-1/</guid>
      <description>&lt;p&gt;I redesigned my blog. Again.&lt;/p&gt;&#xA;&lt;p&gt;I&amp;rsquo;ve been blogging for 8 years so far and boy, this blog has travelled.&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Simple HTML files hosted in a French server (Free) 👵🏼&lt;/li&gt;&#xA;&lt;li&gt;Wordpress hosted by 1&amp;amp;1&lt;/li&gt;&#xA;&lt;li&gt;Jekyll hosted on Github Pages&lt;/li&gt;&#xA;&lt;li&gt;Gatsby hosted on Github Pages&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;Today, this blog is powered by Hugo and hosted by Netlify. And, of course, even though I played with plenty of cool tools, I didn&amp;rsquo;t write articles.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Docker Cheatsheet</title>
      <link>/en/posts/2018/08/docker-cheatsheet/</link>
      <pubDate>Sat, 25 Aug 2018 19:23:42 +0000</pubDate>
      <guid>/en/posts/2018/08/docker-cheatsheet/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;Petit article mémo sur Docker&lt;/p&gt;&#xA;&lt;h1 id=&#34;getting-started&#34;&gt;Getting Started&lt;/h1&gt;&#xA;&lt;p&gt;make sure that client can talk to engine + current version&#xA;docker version&lt;/p&gt;&#xA;&lt;p&gt;An image is the application we want to run.&#xA;A container is an instance of the image running as a process.&lt;/p&gt;&#xA;&lt;h1 id=&#34;containers&#34;&gt;Containers&lt;/h1&gt;&#xA;&lt;p&gt;docker container run &amp;ndash;publish 80:80 nginx&#xA;Left number == Host port. Make sure it&amp;rsquo;s not already used (otherwise bind error)&lt;/p&gt;</description>
    </item>
    <item>
      <title>rm Argument list too long</title>
      <link>/en/posts/2018/08/rm-argument-list-too-long/</link>
      <pubDate>Wed, 01 Aug 2018 16:22:48 +0000</pubDate>
      <guid>/en/posts/2018/08/rm-argument-list-too-long/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;You can use this command :&lt;/p&gt;&#xA;&lt;p&gt;&lt;code&gt;find . -name &amp;quot;*.log&amp;quot; -exec rm {} \;&lt;/code&gt;&lt;/p&gt;</description>
    </item>
    <item>
      <title>WordPress Curl on page returns 200 but browser returns 404</title>
      <link>/en/posts/2018/03/wordpress-curl-on-page-returns-200-but-browser-returns-404/</link>
      <pubDate>Tue, 13 Mar 2018 17:37:20 +0000</pubDate>
      <guid>/en/posts/2018/03/wordpress-curl-on-page-returns-200-but-browser-returns-404/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;I had a weird issue on a PHP script. I was returning an error 404 on a WordPress page the following way :&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-php&#34; data-lang=&#34;php&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#75715e&#34;&gt;// At the beginning of a template page&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#75715e&#34;&gt;&lt;/span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;global&lt;/span&gt; $wp_query;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; ( $posts_query&lt;span style=&#34;color:#f92672&#34;&gt;-&amp;amp;&lt;/span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;gt&lt;/span&gt;;&lt;span style=&#34;color:#a6e22e&#34;&gt;post_count&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;0&lt;/span&gt; ) {&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    $wp_query&lt;span style=&#34;color:#f92672&#34;&gt;-&amp;amp;&lt;/span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;gt&lt;/span&gt;;&lt;span style=&#34;color:#a6e22e&#34;&gt;set_404&lt;/span&gt;();&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    &lt;span style=&#34;color:#a6e22e&#34;&gt;status_header&lt;/span&gt;(&lt;span style=&#34;color:#ae81ff&#34;&gt;404&lt;/span&gt;);&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    &lt;span style=&#34;color:#a6e22e&#34;&gt;get_template_part&lt;/span&gt;( &lt;span style=&#34;color:#ae81ff&#34;&gt;404&lt;/span&gt; ); &lt;span style=&#34;color:#66d9ef&#34;&gt;die&lt;/span&gt;();&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  }&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;When I was accessing the error page on the browser, It worked well, I had a 404 error page displayed + the correct status code when I inspected the page (Network tab).&lt;/p&gt;</description>
    </item>
    <item>
      <title>Permission issue with npm while installing react-devtools</title>
      <link>/en/posts/2018/02/permission-issue-with-npm-while-installing-react-devtools/</link>
      <pubDate>Tue, 27 Feb 2018 17:14:15 +0000</pubDate>
      <guid>/en/posts/2018/02/permission-issue-with-npm-while-installing-react-devtools/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;I had this error once while trying to install the npm package react-devtools.&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-shell&#34; data-lang=&#34;shell&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;leiluspocus$ npm i -g react-devtools&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;npm WARN checkPermissions Missing write access to /usr/local/lib/node_modules&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;npm ERR! path /usr/local/lib/node_modules&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;npm ERR! code EACCES&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;npm ERR! errno -13&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;npm ERR! syscall access&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;npm ERR! Error: EACCES: permission denied, access &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;/usr/local/lib/node_modules&amp;#39;&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;npm ERR!  &lt;span style=&#34;color:#f92672&#34;&gt;{&lt;/span&gt; Error: EACCES: permission denied, access &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;/usr/local/lib/node_modules&amp;#39;&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;npm ERR!   stack: &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;Error: EACCES: permission denied, access \&amp;#39;&lt;/span&gt;/usr/local/lib/node_modules&lt;span style=&#34;color:#ae81ff&#34;&gt;\&amp;#39;&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;,&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;npm ERR!   errno: -13,&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;npm ERR!   code: &amp;#39;&lt;/span&gt;EACCES&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;,&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;npm ERR!   syscall: &amp;#39;&lt;/span&gt;access&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;,&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;npm ERR!   path: &amp;#39;&lt;/span&gt;/usr/local/lib/node_modules&lt;span style=&#34;color:#960050;background-color:#1e0010&#34;&gt;&amp;#39;&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;}&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;npm ERR!&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;npm ERR! Please try running this command again as root/Administrator.&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;npm ERR! A complete log of this run can be found in:&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;npm ERR!     /Users/leiluspocus/.npm/_logs/2018-02-27T13_52_59_313Z-debug.log&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;The issue was that I was previously installing npm packages using the root user.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Getting started with React Native</title>
      <link>/en/posts/2017/09/getting-started-with-react-native/</link>
      <pubDate>Sat, 02 Sep 2017 17:31:47 +0000</pubDate>
      <guid>/en/posts/2017/09/getting-started-with-react-native/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;It’s pretty impressive how we can simply set up a development environment without XCode using Expo.&lt;/p&gt;&#xA;&lt;p&gt;Make sure you’re using the right Node and NPM versions and double check that there are no missing packages while doing the npm install.&lt;/p&gt;&#xA;&lt;p&gt;I had to run these commands before running npm start on my app (created through create-react-native-app ):&lt;/p&gt;</description>
    </item>
    <item>
      <title>Getting started with Magento</title>
      <link>/en/posts/2017/08/getting-started-with-magento/</link>
      <pubDate>Thu, 17 Aug 2017 23:36:15 +0000</pubDate>
      <guid>/en/posts/2017/08/getting-started-with-magento/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;When I started working with Magento 1, I was frightened by the quantity of files and modules. The clients I worked for had several modules and a lot of things needed to be refactored, both projects were on Magento 1.&lt;/p&gt;&#xA;&lt;p&gt;Here are some « baby steps » I followed when I began with Magento 1. I would like to remember them when I will get started on a Magento 2 project 🙂&lt;/p&gt;</description>
    </item>
    <item>
      <title>Symfony3 Importing JS / CSS assets from a bundle in your custom templates</title>
      <link>/en/posts/2017/06/symfony3-importing-js-/-css-assets-from-a-bundle-in-your-custom-templates/</link>
      <pubDate>Fri, 30 Jun 2017 11:50:44 +0000</pubDate>
      <guid>/en/posts/2017/06/symfony3-importing-js-/-css-assets-from-a-bundle-in-your-custom-templates/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;While implementing the PrestaImage bundle in a Symfony 3 project, I had to include the assets of the bundle in my custom template file. I had first copy / paste manually the files but I thought it was not an easy / clean way to maintain these files.&lt;/p&gt;&#xA;&lt;h3 id=&#34;install-the-assets-in-the-public-web-folder&#34;&gt;Install the assets in the public web folder&lt;/h3&gt;&#xA;&lt;p&gt;I used the magnificient CLI of Symfony :&lt;/p&gt;</description>
    </item>
    <item>
      <title>Git Workflow Cheatsheet</title>
      <link>/en/posts/2017/06/git-workflow-cheatsheet/</link>
      <pubDate>Sun, 18 Jun 2017 16:55:42 +0000</pubDate>
      <guid>/en/posts/2017/06/git-workflow-cheatsheet/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;I follow a pretty regular git workflow on my projects:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;All my features are derived from a master branch&lt;/li&gt;&#xA;&lt;li&gt;I merge my feature with master only after a code review (If I work with several people on the project, I ask them. Even If I’m alone on the project, I still use Github’s Pull Requests to review myself).&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h2 id=&#34;my-git-cheatsheet&#34;&gt;My Git Cheatsheet&lt;/h2&gt;&#xA;&lt;h3 id=&#34;delete-a-local--remote-branch&#34;&gt;Delete a local / remote branch&lt;/h3&gt;&#xA;&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;git branch -D branch_name #locally&#xA;git push origin --delete branch_name    #remote&#xA;&lt;/code&gt;&lt;/pre&gt;&lt;h3 id=&#34;create-a-branch-from-a-commit&#34;&gt;Create a branch from a commit&lt;/h3&gt;&#xA;&lt;p&gt;&lt;code&gt;git checkout -b branch_name a9c146a09505837ec03b&lt;/code&gt;&lt;/p&gt;</description>
    </item>
    <item>
      <title>PHP Customize excerpt in a WordPress post</title>
      <link>/en/posts/2016/11/php-customize-excerpt-in-a-wordpress-post/</link>
      <pubDate>Fri, 25 Nov 2016 09:05:28 +0000</pubDate>
      <guid>/en/posts/2016/11/php-customize-excerpt-in-a-wordpress-post/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-php&#34; data-lang=&#34;php&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;add_filter&lt;/span&gt;( &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;get_the_excerpt&amp;#39;&lt;/span&gt;, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;my_new_excerpt&amp;#39;&lt;/span&gt; );&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;function&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;my_new_excerpt&lt;/span&gt;( $format )&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;{&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    $format &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;__&lt;/span&gt;( &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39; Blabla&amp;#39;&lt;/span&gt; ); &lt;span style=&#34;color:#75715e&#34;&gt;// Modify this to your needs!&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#75715e&#34;&gt;&lt;/span&gt;    &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; $format;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;}&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Enjoy !&lt;/p&gt;</description>
    </item>
    <item>
      <title>Pentaho - FieldHelper cannot be cast to java.lang.String</title>
      <link>/en/posts/2016/09/pentaho-fieldhelper-cannot-be-cast-to-java.lang.string/</link>
      <pubDate>Thu, 01 Sep 2016 13:11:20 +0000</pubDate>
      <guid>/en/posts/2016/09/pentaho-fieldhelper-cannot-be-cast-to-java.lang.string/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;I had the following error in a « User Defined Java Class » step on Pentaho Data Integration.&lt;/p&gt;&#xA;&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;FieldHelper cannot be cast to java.lang.String&#xA;&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Indeed, you have to use the getRow() method to convert the field you’re getting into a String or any other variable type.&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-java&#34; data-lang=&#34;java&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;public&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;boolean&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;processRow&lt;/span&gt;(StepMetaInterface smi, StepDataInterface sdi) &lt;span style=&#34;color:#66d9ef&#34;&gt;throws&lt;/span&gt; KettleException, Exception&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;{&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  Object&lt;span style=&#34;color:#f92672&#34;&gt;[]&lt;/span&gt; r &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; getRow();&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;        &lt;span style=&#34;color:#66d9ef&#34;&gt;if&lt;/span&gt; (r &lt;span style=&#34;color:#f92672&#34;&gt;==&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;null&lt;/span&gt;) { &lt;span style=&#34;color:#66d9ef&#34;&gt;return&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;false&lt;/span&gt;; }&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;        String myString &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; get(Fields.&lt;span style=&#34;color:#a6e22e&#34;&gt;In&lt;/span&gt;, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;FeedSubmissionId&amp;#34;&lt;/span&gt;).&lt;span style=&#34;color:#a6e22e&#34;&gt;getString&lt;/span&gt;(r);&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;}&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    <item>
      <title>Can&#39;t login to Heroku from my mac</title>
      <link>/en/posts/2016/08/cant-login-to-heroku-from-my-mac/</link>
      <pubDate>Wed, 10 Aug 2016 18:42:11 +0000</pubDate>
      <guid>/en/posts/2016/08/cant-login-to-heroku-from-my-mac/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;Problem of the day : I wasn’t able to connect to Heroku from my mac. The process was blocked on the message « Installing CLI… » like if it couldn’t connect to Heroku.&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-shell&#34; data-lang=&#34;shell&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;MacBook-Air-de-Laila:shredder leiluspocus$ heroku login&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;heroku-cli: Installing CLI...&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;Error: getaddrinfo: nodename nor servname provided, or not known &lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;SocketError&lt;span style=&#34;color:#f92672&#34;&gt;)&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;/usr/local/heroku/vendor/gems/excon-0.51.0/lib/excon/socket.rb:100:in &lt;span style=&#34;color:#e6db74&#34;&gt;`&lt;/span&gt;getaddrinfo&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;/usr/local/heroku/vendor/gems/excon-0.51.0/lib/excon/socket.rb:100:in `connect&amp;#39;&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;/usr/local/heroku/vendor/gems/excon-0.51.0/lib/excon/ssl_socket.rb:146:in &lt;span style=&#34;color:#e6db74&#34;&gt;`&lt;/span&gt;connect&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;/usr/local/heroku/vendor/gems/excon-0.51.0/lib/excon/socket.rb:28:in `initialize&amp;#39;&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;/usr/local/heroku/vendor/gems/excon-0.51.0/lib/excon/ssl_socket.rb:8:in &lt;span style=&#34;color:#e6db74&#34;&gt;`&lt;/span&gt;initialize&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;/usr/local/heroku/vendor/gems/excon-0.51.0/lib/excon/connection.rb:404:in `new&amp;#39;&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;/usr/local/heroku/vendor/gems/excon-0.51.0/lib/excon/connection.rb:404:in &lt;span style=&#34;color:#e6db74&#34;&gt;`&lt;/span&gt;socket&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;/usr/local/heroku/vendor/gems/excon-0.51.0/lib/excon/connection.rb:106:in `request_call&amp;#39;&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;/usr/local/heroku/vendor/gems/excon-0.51.0/lib/excon/middlewares/mock.rb:47:in &lt;span style=&#34;color:#e6db74&#34;&gt;`&lt;/span&gt;request_call&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;/usr/local/heroku/vendor/gems/excon-0.51.0/lib/excon/middlewares/instrumentor.rb:25:in `request_call&amp;#39;&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;/usr/local/heroku/vendor/gems/excon-0.51.0/lib/excon/middlewares/base.rb:15:in &lt;span style=&#34;color:#e6db74&#34;&gt;`&lt;/span&gt;request_call&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;/usr/local/heroku/vendor/gems/excon-0.51.0/lib/excon/middlewares/base.rb:15:in `request_call&amp;#39;&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;/usr/local/heroku/vendor/gems/excon-0.51.0/lib/excon/middlewares/base.rb:15:in &lt;span style=&#34;color:#e6db74&#34;&gt;`&lt;/span&gt;request_call&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;/usr/local/heroku/vendor/gems/excon-0.51.0/lib/excon/connection.rb:250:in `request&amp;#39;&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;/usr/local/heroku/vendor/gems/excon-0.51.0/lib/excon.rb:238:in &lt;span style=&#34;color:#e6db74&#34;&gt;`&lt;/span&gt;get&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;/usr/local/heroku/lib/heroku/jsplugin.rb:246:in `manifest&amp;#39;&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;/usr/local/heroku/lib/heroku/jsplugin.rb:259:in &lt;span style=&#34;color:#e6db74&#34;&gt;`&lt;/span&gt;url&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;/usr/local/heroku/lib/heroku/jsplugin.rb:149:in `block (2 levels) in setup&amp;#39;&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;/usr/local/heroku/lib/heroku/jsplugin.rb:137:in &lt;span style=&#34;color:#e6db74&#34;&gt;`&lt;/span&gt;open&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;/usr/local/heroku/lib/heroku/jsplugin.rb:137:in `block in setup&amp;#39;&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;/usr/local/heroku/ruby/lib/ruby/1.9.1/tmpdir.rb:83:in &lt;span style=&#34;color:#e6db74&#34;&gt;`&lt;/span&gt;mktmpdir&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;/usr/local/heroku/lib/heroku/jsplugin.rb:135:in `setup&amp;#39;&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;/usr/local/heroku/lib/heroku/cli.rb:27:in &lt;span style=&#34;color:#e6db74&#34;&gt;`&lt;/span&gt;start&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;/usr/local/bin/heroku:24:in `&amp;lt;main&amp;gt;&amp;lt;/main&amp;gt;&amp;#39;&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;I noticed my Bluetooth was active. It worked after I disabled it.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Get XML Data won&#39;t parse XML object Pentaho</title>
      <link>/en/posts/2016/08/get-xml-data-wont-parse-xml-object-pentaho/</link>
      <pubDate>Mon, 01 Aug 2016 17:20:40 +0000</pubDate>
      <guid>/en/posts/2016/08/get-xml-data-wont-parse-xml-object-pentaho/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;I had an issue with Pentaho today. It wasn’t able to simply parse this XML that I was fetching from Amazon Marketplace Webservice.&lt;/p&gt;&#xA;&lt;p&gt;Here’s the data I got :&lt;/p&gt;&#xA;&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;&amp;lt;SubmitFeedResponse xmlns=&amp;#34;http://mws.amazonaws.com/doc/2009-01-01/&amp;#34;&amp;gt;&#xA;&amp;lt;SubmitFeedResult&amp;gt;&#xA;&amp;lt;FeedSubmissionInfo&amp;gt;&#xA;&amp;lt;FeedSubmissionId&amp;gt;MY_FEED_ID&amp;lt;/FeedSubmissionId&amp;gt;&#xA;&amp;lt;FeedType&amp;gt;_POST_INVENTORY_AVAILABILITY_DATA_&amp;lt;/FeedType&amp;gt;&#xA;&amp;lt;SubmittedDate&amp;gt;2016-08-01T19:28:30+00:00&amp;lt;/SubmittedDate&amp;gt;&#xA;&amp;lt;FeedProcessingStatus&amp;gt;_SUBMITTED_&amp;lt;/FeedProcessingStatus&amp;gt;&#xA;&amp;lt;/FeedSubmissionInfo&amp;gt;&#xA;&amp;lt;/SubmitFeedResult&amp;gt;&#xA;&amp;lt;ResponseMetadata&amp;gt;&#xA;&amp;lt;RequestId&amp;gt;MY_REQUEST_ID&amp;lt;/RequestId&amp;gt;&#xA;&amp;lt;/ResponseMetadata&amp;gt;&#xA;&amp;lt;/SubmitFeedResponse&amp;gt;&#xA;&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;The step « Get XML Data » couldn’t parse it because of the xmlns attribute tag. So I had to add a step « Replace in string » that would delete this attribute.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Write a new task using Capistrano</title>
      <link>/en/posts/2016/07/write-a-new-task-using-capistrano/</link>
      <pubDate>Mon, 18 Jul 2016 16:31:43 +0000</pubDate>
      <guid>/en/posts/2016/07/write-a-new-task-using-capistrano/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;Capistrano can be a great tool to run a task on several servers. It can be a task like uploading a maintenance page or deleting some logs :&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-ruby&#34; data-lang=&#34;ruby&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;task &lt;span style=&#34;color:#e6db74&#34;&gt;:NAME_OF_YOUR_TASK&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;do&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;desc &lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;lt;&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;lt;&lt;span style=&#34;color:#f92672&#34;&gt;-&lt;/span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;DESC&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;This&lt;/span&gt; is my awesome task&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;Description&lt;/span&gt; appears &lt;span style=&#34;color:#66d9ef&#34;&gt;in&lt;/span&gt; help so write it carefully&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;DESC&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;run &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;rm -rf &lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;#{&lt;/span&gt;logs_folder&lt;span style=&#34;color:#e6db74&#34;&gt;}&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;run &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;mkdir &lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;#{&lt;/span&gt;destination_folder&lt;span style=&#34;color:#e6db74&#34;&gt;}&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;top&lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt;upload(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;index.html&amp;#34;&lt;/span&gt;, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;#{&lt;/span&gt;destination_folder&lt;span style=&#34;color:#e6db74&#34;&gt;}&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;/index.html&amp;#34;&lt;/span&gt;)&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;end&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;You can read more about writing Capistrano tasks &lt;a href=&#34;http://vladigleba.com/blog/2014/04/10/deploying-rails-apps-part-6-writing-capistrano-tasks/&#34;&gt;here&lt;/a&gt;.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Quickbooks SDK - Authentification failed error (Web connector)</title>
      <link>/en/posts/2016/07/quickbooks-sdk-authentification-failed-error-web-connector/</link>
      <pubDate>Sat, 09 Jul 2016 12:32:38 +0000</pubDate>
      <guid>/en/posts/2016/07/quickbooks-sdk-authentification-failed-error-web-connector/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;I used &lt;a href=&#34;https://github.com/consolibyte/quickbooks-php&#34;&gt;this SDK&lt;/a&gt; to develop an API that connects directly to Quickbooks.&lt;/p&gt;&#xA;&lt;p&gt;I had this error once: Authentification failed when I tried to fetch data from the API. My identifiers were correct.&lt;/p&gt;&#xA;&lt;p&gt;The problem came from some warnings I had in my program.&lt;/p&gt;&#xA;&lt;p&gt;It may sound obvious but make sure you have no PHP errors or warning in your application. Otherwise, the web connector of Quickbooks won’t be able to read data from your API.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Using observers in Magento 1.13 can lead to slow loading issues</title>
      <link>/en/posts/2016/06/using-observers-in-magento-1.13-can-lead-to-slow-loading-issues/</link>
      <pubDate>Sat, 18 Jun 2016 16:02:24 +0000</pubDate>
      <guid>/en/posts/2016/06/using-observers-in-magento-1.13-can-lead-to-slow-loading-issues/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;For one of the Magento projects I worked on, I had to implement a new action in the dropdown list of actions in the back-end.&lt;/p&gt;&#xA;&lt;p&gt;I tried the Observer option described in this tutorial:&#xA;&lt;!-- raw HTML omitted --&gt;Adding new mass action to admin grid in Magento&lt;!-- raw HTML omitted --&gt;&lt;/p&gt;&#xA;&lt;p&gt;However, it slowed down the application because the event I was observing core_block_abstract_prepare_layout_before was triggered too many times. The Sales admin page could take around 5 to 10 seconds to load. I finally opted for the Block override option, much more elegant.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Create a copy of a Vagrant machine</title>
      <link>/en/posts/2016/06/create-a-copy-of-a-vagrant-machine/</link>
      <pubDate>Thu, 02 Jun 2016 18:09:22 +0000</pubDate>
      <guid>/en/posts/2016/06/create-a-copy-of-a-vagrant-machine/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;ol&gt;&#xA;&lt;li&gt;Stop your vagrant machine&lt;/li&gt;&#xA;&lt;/ol&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-shell&#34; data-lang=&#34;shell&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;vagrant halt&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;ol start=&#34;2&#34;&gt;&#xA;&lt;li&gt;Create the copy (it can take sometime)&lt;/li&gt;&#xA;&lt;/ol&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-shell&#34; data-lang=&#34;shell&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;vagrant package --base name_of_your_machine  --output path/to/newly/created/package&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;The machine name is on Virtual Box 🙂&lt;/p&gt;</description>
    </item>
    <item>
      <title>Prototype Cheat Sheet</title>
      <link>/en/posts/2016/05/prototype-cheat-sheet/</link>
      <pubDate>Fri, 13 May 2016 20:37:49 +0000</pubDate>
      <guid>/en/posts/2016/05/prototype-cheat-sheet/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;I had to deal with Prototype while working with Magento. Here’s a little cheat sheet of some very simple stuff I had to do.&lt;/p&gt;&#xA;&lt;h2 id=&#34;make-an-ajax-requestwithparameters&#34;&gt;Make an Ajax Request with parameters&lt;/h2&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-javascript&#34; data-lang=&#34;javascript&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;new&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;Ajax&lt;/span&gt;.&lt;span style=&#34;color:#a6e22e&#34;&gt;Request&lt;/span&gt;(&lt;span style=&#34;color:#a6e22e&#34;&gt;url&lt;/span&gt;, {&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;                   &lt;span style=&#34;color:#a6e22e&#34;&gt;method&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;:&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;get&amp;#39;&lt;/span&gt;,&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;                   &lt;span style=&#34;color:#a6e22e&#34;&gt;params&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;:&lt;/span&gt; { &lt;span style=&#34;color:#a6e22e&#34;&gt;data1&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;:&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;myParam&amp;#39;&lt;/span&gt; }&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;                   &lt;span style=&#34;color:#a6e22e&#34;&gt;onSuccess&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;:&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;function&lt;/span&gt;(&lt;span style=&#34;color:#a6e22e&#34;&gt;xhr&lt;/span&gt;){&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;                    &lt;span style=&#34;color:#a6e22e&#34;&gt;console&lt;/span&gt;.&lt;span style=&#34;color:#a6e22e&#34;&gt;log&lt;/span&gt;(&lt;span style=&#34;color:#a6e22e&#34;&gt;xhr&lt;/span&gt;.&lt;span style=&#34;color:#a6e22e&#34;&gt;responseText&lt;/span&gt;); &#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;                    &lt;span style=&#34;color:#66d9ef&#34;&gt;var&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;json&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;JSON&lt;/span&gt;.&lt;span style=&#34;color:#a6e22e&#34;&gt;parse&lt;/span&gt;(&lt;span style=&#34;color:#a6e22e&#34;&gt;transport&lt;/span&gt;.&lt;span style=&#34;color:#a6e22e&#34;&gt;responseText&lt;/span&gt;);&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;                    }&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;});&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;h2 id=&#34;change-value-of-an-input&#34;&gt;Change value of an input&lt;/h2&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-javascript&#34; data-lang=&#34;javascript&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;$&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;ID OF THE ELEMENT&amp;#39;&lt;/span&gt;).&lt;span style=&#34;color:#a6e22e&#34;&gt;setValue&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;The new value&amp;#39;&lt;/span&gt;);&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;h2 id=&#34;change-data-within-a-span-tag&#34;&gt;Change data within a span tag&lt;/h2&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-javascript&#34; data-lang=&#34;javascript&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;$&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;ID OF THE ELEMENT&amp;#39;&lt;/span&gt;).&lt;span style=&#34;color:#a6e22e&#34;&gt;update&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;Your new data&amp;#39;&lt;/span&gt;);&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    <item>
      <title>Magento Custom routing</title>
      <link>/en/posts/2016/05/magento-custom-routing/</link>
      <pubDate>Sun, 08 May 2016 19:58:55 +0000</pubDate>
      <guid>/en/posts/2016/05/magento-custom-routing/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;If you implemented several store views in your Magento shop (let’s say for French and English), if you implement a new router, he will be associated to this views.&lt;/p&gt;&#xA;&lt;p&gt;&lt;!-- raw HTML omitted --&gt;Ex&lt;!-- raw HTML omitted --&gt;: In Magento’s default behavior,&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-shell&#34; data-lang=&#34;shell&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;your-store.com/my_router &lt;span style=&#34;color:#75715e&#34;&gt;# KO &lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;your-store.com/fr/my_router &lt;span style=&#34;color:#75715e&#34;&gt;# OK &lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;your-store.com/en/my_router &lt;span style=&#34;color:#75715e&#34;&gt;# OK&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;The solution to this problem is to implement &lt;strong&gt;custom routing&lt;/strong&gt;. &lt;a href=&#34;http://inchoo.net/magento/custom-router-in-magento/&#34;&gt;Inchoo wrote an awesome article about it&lt;/a&gt;.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Use Meld as an external viewer for git diff on Ubuntu</title>
      <link>/en/posts/2016/04/use-meld-as-an-external-viewer-for-git-diff-on-ubuntu/</link>
      <pubDate>Wed, 20 Apr 2016 16:50:53 +0000</pubDate>
      <guid>/en/posts/2016/04/use-meld-as-an-external-viewer-for-git-diff-on-ubuntu/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;&lt;a href=&#34;https://nathanhoad.net/how-to-meld-for-git-diffs-in-ubuntu-hardy&#34;&gt;This article&lt;/a&gt; explains very well how to use Meld as an external viewer for « git diff » on Ubuntu. Once done, you won’t have any valid excuses to escape code reviews 😉&lt;/p&gt;</description>
    </item>
    <item>
      <title>Increase security on a WordPress site</title>
      <link>/en/posts/2016/04/increase-security-on-a-wordpress-site/</link>
      <pubDate>Mon, 18 Apr 2016 16:34:14 +0000</pubDate>
      <guid>/en/posts/2016/04/increase-security-on-a-wordpress-site/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;WordPress is an extremely popular framework, which makes it easier to hack. Here are couple of ways to increase the security of your WordPress installation :&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Hide your admin back-end to a list of whitelisted IPs through server rules on Apache / Nginx&lt;/li&gt;&#xA;&lt;li&gt;Change the path to your admin back-end&lt;/li&gt;&#xA;&lt;li&gt;Protect the wp-login.php script&lt;/li&gt;&#xA;&lt;li&gt;Change the prefix of your tables&lt;/li&gt;&#xA;&lt;li&gt;Use complicated passwords and change them often&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;For people who are not necessarily developers, the plugin « iThemes Security » does some of the steps I mentioned pretty well.&lt;/p&gt;</description>
    </item>
    <item>
      <title>NoMethodError /Ruby/Gems/2.0.0/gems/sass-3.4.8/lib/sass/plugin/compiler.rb Undefined method start</title>
      <link>/en/posts/2016/04/nomethoderror-/ruby/gems/2.0.0/gems/sass-3.4.8/lib/sass/plugin/compiler.rb-undefined-method-start/</link>
      <pubDate>Sat, 09 Apr 2016 16:15:08 +0000</pubDate>
      <guid>/en/posts/2016/04/nomethoderror-/ruby/gems/2.0.0/gems/sass-3.4.8/lib/sass/plugin/compiler.rb-undefined-method-start/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;I had the weirdest issue when initializing my compass project for Greenie.&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-shell&#34; data-lang=&#34;shell&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&amp;gt;&amp;gt;&amp;gt; Compass is watching &lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; changes. Press Ctrl-C to Stop.&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;NoMethodError on line &lt;span style=&#34;color:#f92672&#34;&gt;[&lt;/span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;402&amp;#34;&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;]&lt;/span&gt; of /Library/Ruby/Gems/2.0.0/gems/sass-3.4.8/lib/sass/plugin/compiler.rb: undefined method &lt;span style=&#34;color:#e6db74&#34;&gt;`&lt;/span&gt;start&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39; for #&amp;lt;Thread:0x007f90d1afd098 sleep&amp;gt;&amp;lt;/Thread:0x007f90d1afd098&amp;gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;  /Library/Ruby/Gems/2.0.0/gems/sass-3.4.8/lib/sass/plugin/compiler.rb:402:in `map&amp;#39;&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  /Library/Ruby/Gems/2.0.0/gems/sass-3.4.8/lib/sass/plugin/compiler.rb:402:in &lt;span style=&#34;color:#e6db74&#34;&gt;`&lt;/span&gt;listen_to&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;  /Library/Ruby/Gems/2.0.0/gems/sass-3.4.8/lib/sass/plugin/compiler.rb:338:in `watch&amp;#39;&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  /Library/Ruby/Gems/2.0.0/gems/compass-1.0.3/lib/compass/sass_compiler.rb:46:in &lt;span style=&#34;color:#e6db74&#34;&gt;`&lt;/span&gt;watch!&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;  /Library/Ruby/Gems/2.0.0/gems/compass-1.0.3/lib/compass/commands/watch_project.rb:41:in `perform&amp;#39;&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  /Library/Ruby/Gems/2.0.0/gems/compass-1.0.3/lib/compass/commands/base.rb:18:in &lt;span style=&#34;color:#e6db74&#34;&gt;`&lt;/span&gt;execute&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;  /Library/Ruby/Gems/2.0.0/gems/compass-1.0.3/lib/compass/commands/project_base.rb:19:in `execute&amp;#39;&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  /Library/Ruby/Gems/2.0.0/gems/compass-1.0.3/lib/compass/exec/sub_command_ui.rb:43:in &lt;span style=&#34;color:#e6db74&#34;&gt;`&lt;/span&gt;perform!&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;  /Library/Ruby/Gems/2.0.0/gems/compass-1.0.3/lib/compass/exec/sub_command_ui.rb:15:in `run!&amp;#39;&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  /Library/Ruby/Gems/2.0.0/gems/compass-1.0.3/bin/compass:30:in &lt;span style=&#34;color:#e6db74&#34;&gt;`&lt;/span&gt;block in &amp;lt;top &lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;required&lt;span style=&#34;color:#f92672&#34;&gt;)&lt;/span&gt;&amp;gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;  /Library/Ruby/Gems/2.0.0/gems/compass-1.0.3/bin/compass:44:in `call&amp;#39;&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  /Library/Ruby/Gems/2.0.0/gems/compass-1.0.3/bin/compass:44:in &lt;span style=&#34;color:#e6db74&#34;&gt;`&lt;/span&gt;&amp;lt;top &lt;span style=&#34;color:#f92672&#34;&gt;(&lt;/span&gt;required&lt;span style=&#34;color:#f92672&#34;&gt;)&lt;/span&gt;&amp;gt;&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;  /usr/local/bin/compass:23:in `load&amp;#39;&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  /usr/local/bin/compass:23:in &lt;span style=&#34;color:#e6db74&#34;&gt;`&lt;/span&gt;&amp;lt;main&amp;gt;&lt;span style=&#34;color:#960050;background-color:#1e0010&#34;&gt;&amp;#39;&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;I solved it &lt;a href=&#34;http://code.tutsplus.com/tutorials/how-to-install-ruby-on-a-mac--net-21664&#34;&gt;by using a more recent version of Ruby using RVM&lt;/a&gt;. RVM is pretty cool because you can switch your Ruby versions very easily. Note that I had to re-install compass afterwards.&lt;/p&gt;</description>
    </item>
    <item>
      <title>How to add a new stock option in Woocommerce</title>
      <link>/en/posts/2016/03/how-to-add-a-new-stock-option-in-woocommerce/</link>
      <pubDate>Tue, 22 Mar 2016 18:53:53 +0000</pubDate>
      <guid>/en/posts/2016/03/how-to-add-a-new-stock-option-in-woocommerce/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;Sometimes, clients can come up with some pretty creative ways to handle their inventory … It was the case for me with a customer who was using WooCommerce.&lt;/p&gt;&#xA;&lt;p&gt;I had to add a third option but the stock options was not customizable. I ended up deleting the native dropdown of stock options and I implemented a custom field.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Look for a word in a group of div using only jQuery</title>
      <link>/en/posts/2016/03/look-for-a-word-in-a-group-of-div-using-only-jquery/</link>
      <pubDate>Tue, 22 Mar 2016 18:44:23 +0000</pubDate>
      <guid>/en/posts/2016/03/look-for-a-word-in-a-group-of-div-using-only-jquery/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;For an old project, I had to implement a search tool in a static page. No option for me to use any server side language, I had to implement that search tool using Javascript / jQuery.&lt;/p&gt;&#xA;&lt;p&gt;The following function&amp;rsquo;s purpose is to :&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Search amongst a group of divs that have the class qa-faqs if a word is present in the content&lt;/li&gt;&#xA;&lt;li&gt;Exclude stop-words in french and in english from the query entered by the user&lt;/li&gt;&#xA;&lt;li&gt;List of words to exclude is in the var words_to_exclude&lt;/li&gt;&#xA;&lt;li&gt;Order the divs by data-relevance (times the searched word appears in each div)&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;Please note that the following function uses the awesome plugin &lt;a href=&#34;http://bartaz.github.io/sandbox.js/jquery.highlight.html&#34;&gt;jQuery.highlight&lt;/a&gt;&lt;/p&gt;</description>
    </item>
    <item>
      <title>VirtualBox CheatSheet</title>
      <link>/en/posts/2016/02/virtualbox-cheatsheet/</link>
      <pubDate>Thu, 18 Feb 2016 16:08:10 +0000</pubDate>
      <guid>/en/posts/2016/02/virtualbox-cheatsheet/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;Here is a couple of commands I’ve used in a previous life while trying to resize a Vagrant machine.&lt;/p&gt;&#xA;&lt;h4 id=&#34;list-the-virtual-disk-images-used-by-virtual-box&#34;&gt;List the virtual disk images used by Virtual Box&lt;/h4&gt;&#xA;&lt;p&gt;&lt;code&gt;vboxmanage list hdds&lt;/code&gt;&lt;/p&gt;&#xA;&lt;h4 id=&#34;remove-a-hard-disk-from-a-virtual-box-registry&#34;&gt;Remove a hard disk from a Virtual Box registry&lt;/h4&gt;&#xA;&lt;p&gt;&lt;code&gt;vboxmanage closemedium disk a5bad1ba-5ff7-4b83-87ff-adb18f05269a --delete&lt;/code&gt;&lt;/p&gt;&#xA;&lt;h4 id=&#34;how-to-resize-a-hard-disk-for-a-virtual-machine-8211-tutorialhttpsgistgithubcomchristopher-hopper9755310&#34;&gt;&lt;a href=&#34;https://gist.github.com/christopher-hopper/9755310&#34;&gt;How to resize a hard disk for a Virtual Machine – Tutorial&lt;/a&gt;&lt;/h4&gt;</description>
    </item>
    <item>
      <title>Folders not appearing in the tree on the left panel - PHP Storm</title>
      <link>/en/posts/2016/01/folders-not-appearing-in-the-tree-on-the-left-panel-php-storm/</link>
      <pubDate>Tue, 12 Jan 2016 12:05:17 +0000</pubDate>
      <guid>/en/posts/2016/01/folders-not-appearing-in-the-tree-on-the-left-panel-php-storm/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;At some point, my folders were not appearing anymore in my Tree on the left Panel like this fellow below.&lt;/p&gt;&#xA;&lt;p&gt;&lt;a href=&#34;https://devnet.jetbrains.com/message/5448105?tstart=0&#34;&gt;https://devnet.jetbrains.com/message/5448105?tstart=0&lt;/a&gt;&lt;/p&gt;&#xA;&lt;p&gt;I ended up reading online that it occurs when you hit « Cancel » during the load of a project. I restarted PHPStorm and let it load all the components of the project and it worked.&lt;/p&gt;</description>
    </item>
    <item>
      <title>How to indent a large XML file (Ubuntu)</title>
      <link>/en/posts/2016/01/how-to-indent-a-large-xml-file-ubuntu/</link>
      <pubDate>Mon, 11 Jan 2016 15:59:23 +0000</pubDate>
      <guid>/en/posts/2016/01/how-to-indent-a-large-xml-file-ubuntu/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;I had to indent an extremely large XML file today. I tried to use different IDE (PHPStorm, Sublime Text 3), however the file was way too large and it took a long time to process.&lt;/p&gt;&#xA;&lt;p&gt;Best way to do that is by using command line.&lt;/p&gt;&#xA;&lt;p&gt;&lt;code&gt;xmllint --format input.xml -o indented-output.xml&lt;/code&gt;&lt;/p&gt;</description>
    </item>
    <item>
      <title>Extract characters after the last dash of a String RegExp</title>
      <link>/en/posts/2016/01/extract-characters-after-the-last-dash-of-a-string-regexp/</link>
      <pubDate>Sun, 10 Jan 2016 16:51:21 +0000</pubDate>
      <guid>/en/posts/2016/01/extract-characters-after-the-last-dash-of-a-string-regexp/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;I wanted to extract characters after the last dash of a string. Regular expression are such a powerful tool to use in these cases. Here’s the one I needed for my problem :&lt;/p&gt;&#xA;&lt;p&gt;&lt;code&gt;(\w+)[^-]*$&lt;/code&gt;&lt;/p&gt;&#xA;&lt;p&gt;Please note that with PHP, you need to use the preg_match method and surround the regexp with slashes.&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-php&#34; data-lang=&#34;php&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;preg_match&lt;/span&gt; (&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;/(\w+)[^-]*$/&amp;#39;&lt;/span&gt;, &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;cgo3020-red-xs&amp;#39;&lt;/span&gt;, $results); &lt;span style=&#34;color:#75715e&#34;&gt;// returns xs in $results[0]&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Here’s a pretty convenient tool to test your regexp:  https://regex101.com/&lt;/p&gt;</description>
    </item>
    <item>
      <title>PHP / Magento - Direct SQL Queries</title>
      <link>/en/posts/2015/12/php-/-magento-direct-sql-queries/</link>
      <pubDate>Tue, 22 Dec 2015 11:37:54 +0000</pubDate>
      <guid>/en/posts/2015/12/php-/-magento-direct-sql-queries/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;Not the cleanest but here’s a quick solution to do a direct query on Magento. Might be faster than calling Magento’s objects ?&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-php&#34; data-lang=&#34;php&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;/**&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;   * Get the resource model&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;   */&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;$resource &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;Mage&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;::&lt;/span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;getSingleton&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;core/resource&amp;#39;&lt;/span&gt;);&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;     &#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;/**&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;  * Acccess to the database in read only&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;  */&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;$readConnection &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; $resource&lt;span style=&#34;color:#f92672&#34;&gt;-&amp;amp;&lt;/span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;gt&lt;/span&gt;;&lt;span style=&#34;color:#a6e22e&#34;&gt;getConnection&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;core_read&amp;#39;&lt;/span&gt;);&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;     &#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;$query &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;SELECT * FROM &amp;#39;&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;.&lt;/span&gt; $resource&lt;span style=&#34;color:#f92672&#34;&gt;-&amp;amp;&lt;/span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;gt&lt;/span&gt;;&lt;span style=&#34;color:#a6e22e&#34;&gt;getTableName&lt;/span&gt;(&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;catalog/product&amp;#39;&lt;/span&gt;);&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;     &#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt;/**&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt; * Execute the query  &#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#e6db74&#34;&gt; */&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;$results &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; $readConnection&lt;span style=&#34;color:#f92672&#34;&gt;-&amp;amp;&lt;/span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;gt&lt;/span&gt;;&lt;span style=&#34;color:#a6e22e&#34;&gt;fetchAll&lt;/span&gt;($query);&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;&lt;a href=&#34;http://www.devproblems.com/magento-direct-sql-queries/&#34;&gt;Thank you DevProblems !&lt;/a&gt;&lt;/p&gt;</description>
    </item>
    <item>
      <title>SQL Magento - Get store credit balance</title>
      <link>/en/posts/2015/12/sql-magento-get-store-credit-balance/</link>
      <pubDate>Mon, 21 Dec 2015 17:48:06 +0000</pubDate>
      <guid>/en/posts/2015/12/sql-magento-get-store-credit-balance/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;Valid for Magento EE 1 only. The feature of store credits isn’t native in CE edition.&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-SQL&#34; data-lang=&#34;SQL&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;select&lt;/span&gt; amount &#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;from&lt;/span&gt; enterprise_customerbalance &#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;where&lt;/span&gt; customer_id &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;@&lt;/span&gt;customer_id ;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    <item>
      <title>SQL Magento Get the list of SKUs that are in a catalog_price_rule</title>
      <link>/en/posts/2015/11/sql-magento-get-the-list-of-skus-that-are-in-a-catalog_price_rule/</link>
      <pubDate>Tue, 24 Nov 2015 12:16:55 +0000</pubDate>
      <guid>/en/posts/2015/11/sql-magento-get-the-list-of-skus-that-are-in-a-catalog_price_rule/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;The parameter « rule_id » can be viewed in the URL when you are editing the catalog price rule.&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-SQL&#34; data-lang=&#34;SQL&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;select&lt;/span&gt; sku&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;from&lt;/span&gt; catalog_product_entity&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;where&lt;/span&gt; entity_id &lt;span style=&#34;color:#66d9ef&#34;&gt;in&lt;/span&gt; (&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;SELECT&lt;/span&gt; &lt;span style=&#34;color:#66d9ef&#34;&gt;DISTINCT&lt;/span&gt; product_id &#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;FROM&lt;/span&gt; catalogrule_product &#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;WHERE&lt;/span&gt; rule_id&lt;span style=&#34;color:#f92672&#34;&gt;=&amp;amp;&lt;/span&gt;lt;rule_id&lt;span style=&#34;color:#f92672&#34;&gt;&amp;amp;&lt;/span&gt;gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;);&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    <item>
      <title>Couple of books to read for a developer</title>
      <link>/en/posts/2014/09/couple-of-books-to-read-for-a-developer/</link>
      <pubDate>Sun, 21 Sep 2014 18:14:45 +0000</pubDate>
      <guid>/en/posts/2014/09/couple-of-books-to-read-for-a-developer/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;Some co-workers recommended me some development books. I added comments in the This list will be updated and feel free to add your suggestions in the comments 🙂&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;a href=&#34;http://www.amazon.ca/Lean-In-Women-Work-Will/dp/0385349947&#34;&gt;Lean In – Women, Work, and the Will to Lead&lt;/a&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Life changing book for me. It’s a must read for every women working or not in IT. Men will be interested as well !&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&lt;a href=&#34;http://www.amazon.ca/Cracking-Coding-Interview-Programming-Questions/dp/098478280X&#34;&gt;Cracking the coding interview&lt;/a&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;I always prepare my interviews with this book ! It has pretty good soft-skills questions too.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt; &lt;/p&gt;</description>
    </item>
    <item>
      <title>Django Cheat Sheet</title>
      <link>/en/posts/2013/12/django-cheat-sheet/</link>
      <pubDate>Sun, 22 Dec 2013 23:28:23 +0000</pubDate>
      <guid>/en/posts/2013/12/django-cheat-sheet/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;Here are couple of useful commands / tutorials (in french sorry!) to get started easily with Django.&lt;/p&gt;&#xA;&lt;p&gt;&lt;strong&gt;Create a project&lt;/strong&gt;&lt;/p&gt;&#xA;&lt;p&gt;&lt;code&gt;python django-admin.py startproject project_name&lt;/code&gt;&lt;/p&gt;&#xA;&lt;p&gt;Manually create a subfolder for HTML templates&lt;/p&gt;&#xA;&lt;p&gt;&lt;strong&gt;Running servers&lt;/strong&gt;&lt;/p&gt;&#xA;&lt;p&gt;&lt;code&gt;python manage.py runserver&lt;/code&gt;&lt;/p&gt;&#xA;&lt;p&gt;&lt;strong&gt;Create an application (inside of a project)&lt;/strong&gt;&lt;/p&gt;&#xA;&lt;p&gt;&lt;code&gt;python manage.py startapp blog&lt;/code&gt;&lt;/p&gt;&#xA;&lt;p&gt;You should also read &lt;a href=&#34;http://openclassrooms.com/courses/developpez-votre-site-web-avec-le-framework-django&#34;&gt;the Django course of Open Classrooms&lt;/a&gt;   to get started smoothly 🙂&lt;/p&gt;</description>
    </item>
    <item>
      <title>Convert an image into a base64 string Javascript</title>
      <link>/en/posts/2013/12/convert-an-image-into-a-base64-string-javascript/</link>
      <pubDate>Sun, 22 Dec 2013 23:26:54 +0000</pubDate>
      <guid>/en/posts/2013/12/convert-an-image-into-a-base64-string-javascript/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;Here is a little function I did to convert an image into a base64 string (JavaScript only): &lt;a href=&#34;http://pastebin.com/Dfb8TR4g&#34;&gt;http://pastebin.com/Dfb8TR4g&lt;/a&gt;&lt;/p&gt;</description>
    </item>
    <item>
      <title>Parsing errors JSON</title>
      <link>/en/posts/2013/06/parsing-errors-json/</link>
      <pubDate>Tue, 25 Jun 2013 23:26:03 +0000</pubDate>
      <guid>/en/posts/2013/06/parsing-errors-json/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;Parsing JSON with the jQuery method &lt;code&gt;$.parseJSON&lt;/code&gt; can be tricky to debug, specially when you’re using a mobile device.&lt;/p&gt;&#xA;&lt;p&gt;Here is a list of errors I encoutered, and the reason why they were raised.&lt;/p&gt;&#xA;&lt;p&gt;&lt;strong&gt;Unexpected token u&lt;/strong&gt;&#xA;The method tries to parse a undefined variable&lt;/p&gt;&#xA;&lt;p&gt;&lt;strong&gt;Unexpected token o&lt;/strong&gt;&#xA;The method tries to parse [Object object]&lt;/p&gt;</description>
    </item>
    <item>
      <title>Sessions keep refreshing CodeIgniter</title>
      <link>/en/posts/2013/06/sessions-keep-refreshing-codeigniter/</link>
      <pubDate>Wed, 05 Jun 2013 23:22:47 +0000</pubDate>
      <guid>/en/posts/2013/06/sessions-keep-refreshing-codeigniter/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;I had a bug once, the sessions kept expiring even though the token was still valid.&lt;/p&gt;&#xA;&lt;p&gt;I found out that CI_sessions were refreshing the session_id all the time. This was a database issue, be careful on the length of the columns in the database. The column that stored the session_id was too short and the token kept being re-generated since the old one couldn’t be recognized.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Create a JSON array dynamically Javascript</title>
      <link>/en/posts/2013/03/create-a-json-array-dynamically-javascript/</link>
      <pubDate>Wed, 20 Mar 2013 23:21:59 +0000</pubDate>
      <guid>/en/posts/2013/03/create-a-json-array-dynamically-javascript/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;Using only Javascript&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-javascript&#34; data-lang=&#34;javascript&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;var&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;res&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; [];&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#66d9ef&#34;&gt;for&lt;/span&gt; (&lt;span style=&#34;color:#66d9ef&#34;&gt;var&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;i&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#ae81ff&#34;&gt;0&lt;/span&gt;; &lt;span style=&#34;color:#a6e22e&#34;&gt;i&lt;/span&gt; &lt;span style=&#34;color:#f92672&#34;&gt;&amp;lt;&lt;/span&gt; &lt;span style=&#34;color:#a6e22e&#34;&gt;results&lt;/span&gt;.&lt;span style=&#34;color:#a6e22e&#34;&gt;rows&lt;/span&gt;.&lt;span style=&#34;color:#a6e22e&#34;&gt;length&lt;/span&gt;; &lt;span style=&#34;color:#a6e22e&#34;&gt;i&lt;/span&gt;&lt;span style=&#34;color:#f92672&#34;&gt;++&lt;/span&gt;) {&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    &lt;span style=&#34;color:#a6e22e&#34;&gt;res&lt;/span&gt;[&lt;span style=&#34;color:#a6e22e&#34;&gt;i&lt;/span&gt;] &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; {};&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    &lt;span style=&#34;color:#a6e22e&#34;&gt;res&lt;/span&gt;[&lt;span style=&#34;color:#a6e22e&#34;&gt;i&lt;/span&gt;][&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;id&amp;#39;&lt;/span&gt;] &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;foo&amp;#34;&lt;/span&gt;;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    &lt;span style=&#34;color:#a6e22e&#34;&gt;res&lt;/span&gt;[&lt;span style=&#34;color:#a6e22e&#34;&gt;i&lt;/span&gt;][&lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#39;name&amp;#39;&lt;/span&gt;] &lt;span style=&#34;color:#f92672&#34;&gt;=&lt;/span&gt; &lt;span style=&#34;color:#e6db74&#34;&gt;&amp;#34;woohoo&amp;#34;&lt;/span&gt;;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;}&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;</description>
    </item>
    <item>
      <title>Best ways to debug Javascript</title>
      <link>/en/posts/2013/03/best-ways-to-debug-javascript/</link>
      <pubDate>Mon, 18 Mar 2013 23:20:37 +0000</pubDate>
      <guid>/en/posts/2013/03/best-ways-to-debug-javascript/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;I was looking for an equivalent of PHP’s print_r to debug Javascript Objects and I found this very cool method:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;&#34;&gt;&lt;code class=&#34;language-javascript&#34; data-lang=&#34;javascript&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#a6e22e&#34;&gt;JSON&lt;/span&gt;.&lt;span style=&#34;color:#a6e22e&#34;&gt;stringify&lt;/span&gt;(&lt;span style=&#34;color:#a6e22e&#34;&gt;whatever_obj&lt;/span&gt;);&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;How about you ? How do you debug objects in Javascript ?&lt;/p&gt;</description>
    </item>
    <item>
      <title>Passing arguments in an event handler Javascript</title>
      <link>/en/posts/2013/02/passing-arguments-in-an-event-handler-javascript/</link>
      <pubDate>Tue, 26 Feb 2013 23:19:15 +0000</pubDate>
      <guid>/en/posts/2013/02/passing-arguments-in-an-event-handler-javascript/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Careful&lt;/em&gt; You&amp;rsquo;re reading an old article ! Some links might be broken and content may be outdated&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;I had this problem while working on Leaflet but I think it can be generalized to the issue of passing parameters to an event handler in Javascript. With the « bind » method of jQuery, you can pass parameters by using the data property of event (the object sent when an event is triggered) :&lt;/p&gt;</description>
    </item>
    <item>
      <title>Connect a Gumstix via Serial Eclipse Ubuntu</title>
      <link>/en/posts/2012/11/connect-a-gumstix-via-serial-eclipse-ubuntu/</link>
      <pubDate>Thu, 29 Nov 2012 23:10:47 +0000</pubDate>
      <guid>/en/posts/2012/11/connect-a-gumstix-via-serial-eclipse-ubuntu/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Attention&lt;/em&gt; Cet article a quelques années et n&amp;rsquo;est peut-être plus à jour !&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;I was following this well-written &lt;!-- raw HTML omitted --&gt;tutorial&lt;!-- raw HTML omitted --&gt; to set up eclipse for my gumstix when I came to the part « Connect your gumstix » (with the Eclipse Terminal). Before setting up the terminal connection on Eclipse, make sure that Eclipse will have the permissions to access to the folder. I didn’t have the permissions and I had the error « /dev/ttyUSB0: No such folder error » even if my board was plugged.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Installing Bluetooth library Java Interpreter</title>
      <link>/en/posts/2012/10/installing-bluetooth-library-java-interpreter/</link>
      <pubDate>Mon, 22 Oct 2012 23:11:53 +0000</pubDate>
      <guid>/en/posts/2012/10/installing-bluetooth-library-java-interpreter/</guid>
      <description>&lt;blockquote&gt;&#xA;&lt;p&gt;👴 &lt;em&gt;Attention&lt;/em&gt; Cet article a quelques années et n&amp;rsquo;est peut-être plus à jour !&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;When I was installing the bluetooth library, i was told to type the directory where Java Interpreter was installed.&lt;/p&gt;&#xA;&lt;p&gt;Run the command:&lt;/p&gt;&#xA;&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;  which java&#xA;&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;It’s gonna answer you « /usr/bin/java », type only « /usr/bin » in the shell line and you’re good 🙂 (Mac OS X Lion)&lt;/p&gt;</description>
    </item>
  </channel>
</rss>
