Posts

Validate Email Address in Two Ways

This is a little code example that will validate an email address in two ways: - first the general syntax of the string is checked with a regular expression - then the domain substring (after the '@') is checked using the 'checkdnsrr' function function  validate_email ( $email ){     $exp  =  "^[a-z\'0-9]+([._-][a-z\'0-9]+)*@([a-z0-9]+([._-][a-z0-9]+))+$" ;    if( eregi ( $exp , $email )){       if( checkdnsrr ( array_pop ( explode ( "@" , $email )), "MX" )){         return  true ;       }else{         return  false ;       }    }else{       return  false ;    }    } ?>

Dates in PHP (Tomorrow, Yesterday, Today of a Given Date)

Dates in PHP (Tomorrow, Yesterday, Today of a Given Date) echo “ Date Yesterday ”; $yesterday = date(“Y-m-d”, time()-86400); echo $yesterday; echo “ Date Today ”; echo date(“Y-m-d”); echo “ Date Tomorrow ”; $tomorrow = date(“Y-m-d”, time()+86400); echo $tomorrow; echo “ Previous Date from User-defined Date ”; $gdate = “2008-07-11″; echo “(” . $gdate . ” supplied.) ”; $dt = strtotime($gdate); echo date(“Y-m-d”, $dt-86400); echo “ Next Date from User-defined Date ”; echo “(” . $gdate . ” supplied.) ”; $dt = strtotime($gdate); echo date(“Y-m-d”, $dt+86400); // DAYS IN BETWEEN TWO DATES function days_in_between($s, $e){ $d = array(); $s = strtotime($s); $e = strtotime($e); for($n=$s; $n<=$e; $n=$n+86400){ array_push($d, strftime(“%Y-%m-%d”, $n)); } return $d; } ?>

Tips to find out fake Facebook Profiles

Image
Facebook contains tons of fake profiles unfortunately. Those fake profile holders use Social Engineering tactics to attack innocent people. Facebook has almost 500 Million Users (Check Infographic) and it is not surprising to have few thousands fake profiles. Below I mentioned some funny but true tips to check whether a profile is fake or not. 1. Profile Picture. Always be suspicious of profiles featuring photos of professional models. Most of the fake profiles, especially that of females, have only one profile picture and that too a beautiful or sexy (ahem) picture! 2. Many Males. Their friends list will contain males mostly (Well, that’s not their fault, gender issue  ). It could be around 1000s or even more than that. 3. When Did They Joined? Check when she/he joined. If they have lots of friends and have only been on the Facebook a short amount of time, it’s likely to be a fake one. 4. Tag Me! He/she would be tagged in tons of cartoon pictures than his/her own picture....

Types of drinks as we age......

Image

Have Fun using Notepad

1.Copy the below content and Paste it to notepad. 2 Use replace all (Ctrl + H) 3.And click on 'replace all' 6 with _ (Under score), (Try font size as 6) 66666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666699666669966996699999999669966666996666666996666669966999999996699666699666666666666669666666666666666666666666699666669966996699999999669966666996666666699666699666999999996699666699666666666666699966666666666666666666666699666669966996699666666669966666996666666669966996666996666996699666699666666666666996996666666666666666666666699669669966996699999999669999999996666666666999966666996666996699666699666666666669966699666666666666666666666699699969966996699999999669999999996666666666699666666996666996699666699666666666699999999966666666666666666666699996999966996666666699669966666996666666666699666666996666996699666699666666666999999999996666666666666666666699966699966996699999999669966666996666666666699666666999999...

Some things cannot be forgotten.

Image
Here is a small recap

Very good software for Communicate inside single office or multiple branch offices, and from anywhere.

Image
Outlook Messenger 6.0.39 [ Download ]