I get asked a lot how/what the selectors are in infinite-scroll and how to figure them out. So lets start from the beginning.. infinite-scroll uses jQuery selectors (which are based on CSS selectors) to find content and posts in order to load the content from the next page. Because web pages are different, we need to define ourselves what selectors infinite-scroll should use.
Infinite-Scroll uses four selectors, these are:
It’s probably easiest Continue reading Selectors in Infinite-Scroll
I spent a while trying to figure this out; but it’s quite simple (though I find rather counter-intuitive). Essentially when you create an object in PHP you are allocating memory for that object. When you want to remove that object you can use the unset() function (just like on most things in PHP). The problem occurs when there are variables stored inside the object — unset() doesn’t delete these from memory. This is because unset() doesn’t trigger the object’s destructor. A simple way around it is to explicitly call the destructor and then unset the object like so:
$myobject = new CrazySystem();
$myobject->LargeVariable = file_get_contents("VeryLargeFile.txt");
//Now we want to delete the object and everything it contains
//It's now all gone!
Hope that helps anyone who was wondering why unsetting object still wasn’t freeing memory!
There is one catch. Because Facebook now only loads a few of your friends at a time, you have to scroll all the way down the invite list until you hit the very bottom (all your friends are displayed). You then just paste the following into the URL bar and hit enter:
Happy inviting! (If the code doesn’t work then make sure you click “View Code” in the box above.)
This is just a note to myself really, below is the regular expression for a string or in my case password where you require it to have at least one letter, one number, a limited selection of special characters (optional) and a minimum of 8 characters in length:
When compiling PHP from source (in my case version 5.3.2) on CentOS 5.4 I kept getting the following error when trying to compile with mcrypt:
"/usr/bin/ld: cannot find -lltdl"
This seems to be due to a missing development library with the obscure name of libtool-ltdl-devel to fix this simply use:
yum install libtool-ltdl-devel
Which should include the package along with several dependencies.