Sign in with Twitter using PHP

With millions of registered users worldwide, twitter is one of the most used social networking website on the internet, we cannot overlook its importance, it can really boost registrations rate in your site. In this tutorial, we will be using Twitter API to register users on your website.

Get Percentage Function PHP

Sometimes we need to calculate the percentage of certain value in our project. In that circumstances you can use following PHP snippet to do that task.echo get_percentage(10, 100); //usage function get_percentage($percentage, $of) { //courtesy : http://stackoverflow.com/a/14880194 $percent = $percentage / $of; return number_format( $percent * 100, 2 ) . '%';; }

Working with PHP Sessions

PHP $_SESSION is basically variable that stores temporary information about current user, for example you are browsing a website, but the remote server doesn’t really know who you are, only way to identify current user assessing the site is using session, PHP $_SESSION allows us to store information about the user, which can be retrieved later from any page within the site, as long as the session is active.

Resize Multiple Images in a Folder using PHP

Sometimes we need to resize multiple images in a folder, using PHP script we can achieve just that. Just point to folder where your images are located and execute following PHP script to resize your images.