Monday, August 24, 2015
How to remove function from a jQuery object
The function can be removed from a previously-attached event handler.
eg. Remove submit function from a form element.
$('form[name="formname"]').unbind('submit');
Tuesday, July 28, 2015
git problem : You are in the middle of a conflicted merge
Fix merge conflicts
git reset --hard HEAD
git fetch origin
git reset --hard origin
git reset --hard HEAD
git fetch origin
git reset --hard origin
Thursday, July 23, 2015
How to Stop Your Mac Book Pro From Freezing with Keyboard & Trackpad Unresponsive
If you can still toggle caps lock and it dones't freeze in safe mode, you can backup and remove the directory below.
/System/Library/Extenstions/AppleIntelHD5000Graphics.kext
Tuesday, March 24, 2015
How to use Replace & ReplaceAll in Java
Replace character
String newstring = str1.replace("-",",");
Replace string
String newstring = str1.replaceAll("[a-z]","0");
Replace string only for first match
String newstring = str1.replaceFirst("[a-z]","0");
String newstring = str1.replace("-",",");
Replace string
Replace string only for first match
String newstring = str1.replaceFirst("[a-z]","0");
Tuesday, May 13, 2014
Validate Email Addresses With PHP preg_match
$email = "[email protected]"
preg_match("/^[[:alnum:]][a-z0-9_.-]*@[a-z0-9.-]+\.[a-z]{2,4}$/i", $email)
or
filter_var($email, FILTER_VALIDATE_EMAIL)
[Blog] Php is everything
Category
Information
URL
http://baiyuxiong.iteye.com/
Description
Php is everything...
[Blog] Shane Rutter's Blog
Category
Information
URL
http://shanerutter.co.uk/
Description
PHP PROGRAMMER AND WEBSITE DEVELOPER
Subscribe to:
Posts (Atom)