Create Directory mkdir(“testdir”); Remove Directory rmdir(“testdir”); Open a Directory for Reading $dh = opendir(“testdir”);
Posts Tagged ‘PHP’
File operation in PHP
Open File fopen() returns false when the file can not be openned. if ($fp=fopen(“test.txt”, “w”)){ //do something } Close File fclose($fp);
php books
There are hundreds of PHP books. Which one do you want, if you already have a basic knowledge of PHP? Now you know which is my suggestion.
Upgrade phplist to 2.10.9
phplist has a very important security update. phpBB’s official site is hacked because of this issue for weeks. To upgrade phplist is simple. BACKUP your database! BACKUP your old config.php file, or optionally backup your whole PHPlist so you can rollback if something would go wrong. Replace your old PHPlist with the new version. Copy [...]
Why MySQL
Why I use MySQL? 1) The hosting compnay Dreamhost provides it. I can add unlimited MySQL database on it. 2) This Blog named as What A Lamp. The m of it stands for MySQL. 3) The other reasons I posted below are copied from MySQL official site. You can just treat it as an advertisement.
Why you want your own WordPress theme
To have a very sharp Blog, you need your own WordPress theme. There are five reasons official WordPress said you need your own WordPress theme. * To create your own unique WordPress site look * To take advantage of templates, template tags, and the WordPress Loop to generate different web page results and looks. * [...]
What a Lamp
This is the first post of this site. I, as a professional Blogger, have a lot of blogs. And they are running well. Now, I have an idea to merge two of them to improve the brand. The brand is WHATALAMP The meanin of this word is clear as blow. WordPress Hosting Ajax Theme Above [...]
Let php engine handle html as php
I have a site full of the html file. Later I added some php code into these html files. I don’t want to change the URL from .html to .php. It is not SEO friendly. So, I would like php engine can handle html same as php. Edit .htaccess file in the root. RemoveHandler .html [...]
strpos()
Using the strpos() function The strpos() function is used to search for a string or character within a string. If a match is found in the string, this function will return the position of the first match. If no match is found, it will return FALSE. Let’s see if we can find the string “world” [...]
strlen()
Using the strlen() function The strlen() function is used to find the length of a string. Let’s find the length of our string “Hello world!”: <?php echo strlen("Hello world!"); ?> The output of the code above will be: 12 The length of a string is often used in loops or other functions, when it is [...]

