Monthly Archives: July 2015

.imagesLoaded is not a function

I’m using mustache.js, masonry and I was trying to use imagesLoaded to avoid overlapping images.

My code was returning me .imagesLoaded is not a function
Some people on the interwebs said that disabling Rocket Loader in CloudFlare… didn’t work for me.

After more than 2 hours I got the solution – without using imagesLoaded -.

    $(window).load(function() {

      // Masonry Trigger
      var $container = $('#masonry-wrap');

         // options
         itemSelector: '.masonry-box', 
         columnWidth: 283 



Solution was taken from jQuery masonry with WordPress and imagesLoaded and given by McNab!

MacBook Pro, no battery performance hack

Almost one year ago, I’v removed my Macbook Pro battery…
Since that day… my laptop was f*cking slow.

This is how I’v solved it – following the article from

Find out our model’s name
MacBook-Pro-de-Paulo:~ PJunior$ system_profiler -detailLevel mini | grep "Model Identifier:"
 Model Identifier: MacBookPro5,1
Do the sh*t!

Lets move to root

sudo bash

Lets go to the right folder

bash-3.2# cd /System/Library/Extensions/IOPlatformPluginFamily.kext/Contents/PlugIns/ACPI_SMC_PlatformPlugin.kext/Contents/Resources/


Lets move the .plist of our model out of that folder…
– change the destination folder to your needs –

mv MacBookPro5_1.plist /Users/PJunior/

Reboot and it’s done.

All the credits go to

WARNING: local host name (digitalwhores) is not qualified; see cf/README: WHO AM I?

While installing sendmail, I got the following error…

WARNING: local host name (digitalwhores) is not qualified; see cf/README: WHO AM I?

Lets edit /etc/hostname and make it

sudo nano /etc/hostname

Lets run sendmailconfig

sudo sendmailconfig

I saw the solution @ – tnks to Jadeye for alerting me that I might need to restart the server.

Apache – client denied by server configuration

So, on my recent DO droplet I had to install Apache (2.4.10) to run a web application for a client.

[email protected]:/home/webroot# apache2 -v
Server version: Apache/2.4.10 (Ubuntu)
Server built: Mar 9 2015 11:53:48

After configuring the subdomain/virtual host I was getting a 403 for it.
This was the error on the error.log…

[Thu Jul 16 21:00:28.919036 2015] [authz_core:error] [pid 17411] [client 84.XXX.XXX.XXX:53565] AH01630: client denied by server configuration: /home/webroot/www/public/index.php

So, this is my current snap of my domain.conf – working -.

 <Directory /home/webroot/www/public/>
 Options Indexes FollowSymLinks MultiViews
 AllowOverride all
 #Order allow,deny
 #allow from all
 Require all granted


Disallowed Key Characters

I got some works made with CodeIgnitor framework…
Some of them were returning me

Disallowed Key Characters

The solution was, on system/core/Input.php make the following change

if ( ! preg_match("/^[a-z0-9:_\/-]+$/i", $str))
                      exit('Disallowed Key Characters.');


if ( ! preg_match("/^[a-z0-9:_\/-~]+$/i", $str))
                      exit('Disallowed Key Characters.');