Send Email with Attachment in PHP
In this post i am showing you how you can send email with attachment in php. For time being we are using a pdf file as attachment that created using FPDF. so first we need to create and sample pdf …
Copy files from one folder to another using php
Inorder to copy files from one folder to another using php we can use the php’s inbuilt function called copy .Now we are creating an function in which we need only to specify the source directory and the destination directory …
Map integer to text string in mysql
We can use the functions CASE .. WHEN … to map integer to text string in mysql The example query is as shown below You can also use the ELSE clause to specify a default, e.g.
PHP array of all US States
$usStates = array( ‘AL’ => ‘Alabama’, ‘AK’ => ‘Alaska’, ‘AZ’ => ‘Arizona’, ‘AR’ => ‘Arkansas’, ‘CA’ => ‘California’, ‘CO’ => ‘Colorado’, ‘CT’ => ‘Connecticut’, ‘DE’ => ‘Delaware’, ‘FL’ => ‘Florida’, ‘GA’ => ‘Georgia’, ‘HI’ => ‘Hawaii’, ‘ID’ => ‘Idaho’, ‘IL’ …