Category: PHP
Managing Application Settings in PHP
There are multiple ways to save application settings/configurations in PHP. You can save them in INI, XML or PHP files as well as a database table. I prefer a combination of the latter two; saving the database connection details in a PHP file and the rest in a database table.
Download And Search Multiple Pages Using PHP
Here is a simple way to loop through a list of URLs, download the page and search the contents for a string.
Backup MySQL Databases to Amazon S3 Using PHP
With a few lines of PHP code and S3tool’s s3cmd command-line tool you can backup your MySQL databases automatically to Amazon’s S3. To use this script you’ll need SSH access to your server. First download s3cmd and upload it to your server. Installation is straight forward. The PHP code is simple:
Creating a Delicious Submission Link in PHP
Creating a Delicious (del.icio.us) submission link is similar to Digg’s, with the exception of the page title that can be sent to Delicious, which is not required, but you’ll save the users from having to type it or copy/paste it.
Creating a Digg Submission Link in PHP
Creating a Digg submission link in PHP is easy since all the parameters Digg expects are included in the URL. Digg like most other social bookmarking tools does not allow complete automation of submissions. It requires the visitor to manually click the submit button to prevent spamming.
Customizing the AddThis WordPress Plugin
My favorite WordPress plugin for bookmarking/sharing is AddThis. It looks good and provides comprehensive statistics. But unlike Shareaholic’s SexyBookmarks plugin, which allows you to display any number of the available services (bookmarking or sharing sites, e.g. Digg), AddThis plugin only displays 4. So I modified it by adding a few lines of code to make [...]



Connect