Symfony Dom Crawler Component and UTF-8 HTML

I have used the Dom Crawler Component of Symfony to parse some result from Google SERP pages. After the first try, I learned that the result of <span class="lang:php decode:true crayon-inline ">$crawler->html()</span> is not as I expected: all UTF-8 characters was displayed incorrectly.  The problem can be reproduced easily via this script (supposed that all … Continue reading Symfony Dom Crawler Component and UTF-8 HTML

HTML Checkbox enhancement: iCheck and Shift-Click

iCheck plug-in When other HTML form elements can be formatting so easily, checkboxes and radio buttons need some javascript to be more beautiful. iCheck is a jQuery plug-in that: Highly customizable checkboxes and radio buttons for jQuery and Zepto. Damir Sultanov - iCheck author You can see how checkboxes and radio buttons are formatted by iCheck in … Continue reading HTML Checkbox enhancement: iCheck and Shift-Click

Update my ‘active’ package to support Laravel 4.2

It's about three months from my first release of hieu-le/active package. For someone does not know it, this package is created to allow developers display the active class easily based on the current route, controller, or, method of Laravel application. However, when the framework matures day by day, my package seems to be out of … Continue reading Update my ‘active’ package to support Laravel 4.2

Use “active” class for current route in Laravel 4

Updates: If you are using Laravel 5, read the documentation of the latest version instead. When working with Laravel 4 and Bootstrap framework, I usually need determine  which menu item is currently "selected" and add the active class into that item. After installing the dwightwatson/active package and founding that that package does not fit my … Continue reading Use “active” class for current route in Laravel 4

PHP – convert Vietnamese character between VNI and Unicode

Why I need it? VNI here stands for VNI Encoding, a way to store Vietnamese characters without using Unicode in 1990s ans 2000s. In fact, many Vietnamese old documents used it instead of Unicode. When working with a new web project, a client requires me to build their website with Unicode (of course!) but the … Continue reading PHP – convert Vietnamese character between VNI and Unicode

Handle mouse wheel event with jQuery jMouseWheel plugin

Recently, when answer this question on stackoverflow, I found that old way of cross-platform mouse wheel event detection have failed on new version of Firefox and Chrome. After some study on MDN, I have begun to write a new jQuery plugin to support the mouse wheel event call jMouseWheel. You can get the full source … Continue reading Handle mouse wheel event with jQuery jMouseWheel plugin

Sharing files and folders with Linux guest OS in VMWare player

One day, when preparing a virtual machine to study Hadoop, I have to find the way to share a files and folder between my Windows 8 machine with the Linux guest OS, more specific, I use LUbuntu as my guest OS. After a quick Googling and read the documentation, I was successful. Today, I want … Continue reading Sharing files and folders with Linux guest OS in VMWare player

The new responsive design for my website

After a long time, I have finally release my first responsive layout for this website. Let's see what is new in this version. Responsive layout with smart phone supported I've implemented three layout in this new design. One is designed for screen wider than 1280px - almost modern notebooks, one for 1024px-wide screen, the other … Continue reading The new responsive design for my website