jQuery Ajax – send all fields data by “POST”
jQuery Ajax – send all fields data by “POST” jQuery.ajax({ data: jQuery(‘#formId’).serialize(), // etc.. }
jQuery Ajax – send all fields data by “POST” jQuery.ajax({ data: jQuery(‘#formId’).serialize(), // etc.. }
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Praesent vel enim erat, nec luctus mi. Integer id dolor a erat commodo imperdiet. Vivamus nec odio…
PHP simple SOAP sample SOAP server file (soapserver.php): <?php // Set a function in SOAP server file function hello($someone) { return “Hello ” . $someone…
Redirect from www. to non www RewriteCond %{HTTP_HOST} ^www\.(.*)$ [NC] RewriteRule ^(.*)$ http://%1/$1 [R=301,L]
Edit Apache Config The file is located “c:xamppapacheconfextrahttpd-vhosts.conf”: Add this lines if not already exists: <VirtualHost 127.0.0.1:8080> DocumentRoot C:/xampp/htdocs/ ServerName localhost ServerAdmin admin@localhost </VirtualHost> Then…
Print array elements with javascript: var output = ”; for(var i=0; i < arr.length; i++){ output += "arr[" + i + "] = " +…
The syntax of the window.open: open (URL, windowName[, windowFeatures]) example: window.open (“http://www.g31zone.com”,”G31zone”); window.open (“http://www.g31zone.com”, “G31zone”,”status=1,toolbar=1″); Parameters: status The status bar at the bottom of the…
Verify if a checkbox is selected (checked) with jQuery <form name=”my_form_name” id=”my_check_box”> <input type=”checkbox” name=”my_check_box” id=”my_check_box”> </form> <script type=”text/javascript”> jQuery(document).ready(function() { jQuery(‘#my_check_box’).click(function () { if…
Method to prevent form submitting using jQuery: <form method=”post” name=”my_form_name” id=”my_form_id”> <input type=”submit” value=”Go”> </form> <script type=”text/javascript”> jQuery(‘#my_form_id’).submit(function() { alert(‘Prevent form submitting.’); return false; });…
Javascript – limit the number of characters in a textarea: <script language=”javascript” type=”text/javascript”> function limitText(fieldLimit, countLimit, limitNum) { if (fieldLimit.value.length > limitNum) { fieldLimit.value =…