Today I had to fix a script that sends an e-mail using PHPMailer. Here is the intital code: I had to send 2 different mails: one to the buyer and another one to administrator. If I tried to send another mail by using the same code, I got 2 recipients for e-mail. I’ve searched for the way in… Read More »
Since cookies are small files that are stored on user computers, you don’t have the ability to remove them as files. But you can delete them using a simple PHP script.
Recently I had to deal with Twitter avatar upload for a Twitter application. Everything went very well, but when I have prepared everything for the upload query, the only server response I got was Error 417. Since I used cURL, I tried to deal with different headers, but with no luck at all. I found the solution at… Read More »
If you need to work with Russian text in PHP, you may notice that functions that are related to CaSe are not working as expected. I mean strtolower, strtouper, ucwords, and so on. In order to get what you need I suggest to use mb_convert functions. Here is the example: You can check reference table for functions, I… Read More »
Just found one useful function and would kike to share it. If you often use strpos, you might find this useful. This function will be useful if you need to find whether ANY element of array is presented in the source string. Else you have to either modify it, or create another one.
php auto prepend using httpd.conf
How to check that a PHP variable is a mysql resource
How to determine the location of system binaries with PHP
Creating a blank db4 database
Regular expression used to validate URLs