Author:
erics , September 23rd, 2011
GET Resources http://code.jquery.com/jquery-1.6.4.min.js http://jqueryui.com/resources/download/jquery-ui-1.10.1.custom.zip LOAD Resources
< LINK rel = "stylesheet" HREF = "/css/smoothness/jquery-ui-1.8.14.custom.min.css" >
<script src = "/js/jquery-1.6.4.min.js" > </script>
<script src = "/js/jquery-ui-1.8.16.custom.min.js" > </script>
HTML Substitute your own loader graphic from http://www.ajaxload.info/
< img
src = "//www.ericmichaelstone.com/wp-content/uploads/2013/02/ajax-loader.gif"
alt = "Please wait..."
class = "Spinner hidden"
id = "Spinner-first"
/ >
CSS
. Spinner
{
margin : 0 ;
padding : 0 ;
border : 0 ;
}
. Spinner . hidden
{
display : none ;
}
JS Show the spinner called “first”: jQuery(‘#Spinner-first’).fadeIn(); Hide the spinner called “first”: jQuery(‘#Spinner-first’).fadeOut(); Hide all spinners that start with an ID of “Spinner”: jQuery(‘[id^=Spinner]’).fadeOut(); That’s All Folks…
Categories: How-To's , Technology Tags: ajax , ajax-loader.gif , CSS , gif , html , img , javascript , JQuery , jQuery UI , jQueryUI , JS , Loader , Spinner
| 1 comment
Author:
erics , August 16th, 2011
setTimeout ( function ( ) {
window . location . href = "/index.html" ;
} , 4000 ) ;
Categories: How-To's , Technology Tags: Delay , howto , href , html , javascript , JS , Location , redirect , setTimeout , Timeout , timer , tips , window.location
| No comments
Author:
erics , June 30th, 2011
/ usr / bin / find / my / dir - name "*.css" - a - not - name "*.min.*" - exec rm { } \ ;
Categories: How-To's , Technology Tags: CSS , Delete , Development , Find , howto , javascript , JS , minimized , tips
| No comments
Author:
erics , June 20th, 2011
var Obj = jQuery ( this ) . parent ( ) . nextAll ( '.myClass:first' ) ;
Categories: How-To's , Technology Tags: Class , Find , howto , javascript , JQuery , JS , Next , NextAll , tips
| No comments
Author:
erics , May 3rd, 2011
& lt ; select onchange = "this.form.submit();" & gt ;
Categories: How-To's , Technology Tags: form , javascript , JS , onchange , Submit
| No comments
Author:
erics , September 24th, 2010
Click here for the official jQuery Selectors documentation… jQuery(“input:radio[name^=foo]”) [code] <div id="test_1">Test One</div> <div id="test_2">Test Two</div> <div id="test_3">Test Three</div> [/code] Show all divs with an ID starting with “test”: [code]$("div[id^=test]").show();[/code] Hide any element that has an ID starting with “test”: [code]$("[id^=test]").hide();[/code] Another interesting approach I found was to use a filter. In the following example […]
Categories: How-To's , Technology Tags: javascript , JQuery , JS , Selector , wildcard , Wildcard Selector
| No comments
Author:
erics , October 21st, 2009
[code]if ( typeof(myVar) !== ‘undefined’) { // variable is defined } [/code] ~or~ [code]if (typeof variable === ‘undefined’ || variable === null) { // variable is undefined or null } [/code]
Categories: How-To's , Technology Tags: defined , Exists , isset , javascript , JS , typeof
| No comments