DCSIMG
JavaScript - Client-Side with Basil Goldman

Browse by Tags

20 July 2011
Javascript "object or function?"
Hi all, See below example, how to make your javascript code sexy. If you call --> getTimeStamp as variable, return object of the Date.now, but if you call --> getTimeStamp() as function, return a timestamp value. var getTimeStamp = Date.now || function () { return +( new Date).getTime(); }; Best... Read More...
23 January 2010
JavaScript Breadcrumbs navigation
In this code listing I want to demonstrate how to implement "Breadcrumbs" in JavaScript for the pages collection, where page object have a two main key's pageId and parentPageId, and create a new collection sorted by current parents. Listing 1: function page(pageId, parentPageId, title... Read More...
22 September 2008
Defining your own functions in jQuery
Defining your own functions in jQuery. In this post i want to present how easy define your own functions in jQuery and using them. As you know, jQuery it's a very rich JavaScript library and it's a pity not to use all it resources. Ok. Do you want to create your own jQuery function to work with... Read More...
21 August 2008
jQuery.create() - jQuery plugin to create HTML elements
jQuery.create() - it's a featured plugin for jQuery JavaScript Library. You can create any types of HTML elements, set attributes and context or HTML using jQuery.create(). See below the HTML example declaration. I think it make easy and fast your programming in JavaScript. jQuery.create = function... Read More...
20 August 2008
JavaScript Repeater Control (dataRepeater) - from jQuery.Presenter.1.0.8 - UIControls Library
In this post, I want to present a new JavaScript Repeater Control from my latest UIControls Library jQuery.Presenter 1.0.8. This control like (ASP.NET Repeater Control) created using jQuery Library 1.2.3 and support for later versions. It's a free open source script... Enjoy... /* * jQuery.Presenter... Read More...
26 February 2008
Understand prototype in JavaScript (JavaScript prototype)
Understand prototype in JavaScript Hi Guy’s Sorry on this syntaxed post, but I think for understand syntax you will read. Follow my comments Hope!!! // Namespace core function core() { return this .constructor( '1.0.0.0' ); } core.prototype = { // String type version: '' , constructor... Read More...
25 February 2008
How to set absolutePath using CSS expression for AlphaImageLoader (IE) *.png files
TIP : "Set absolutePath using CSS expression for AlphaImageLoader (IE) *.png files". So what you can do to write absolute path in CSS files not like "HARD CODE" Here attached below examples CSS syntax. Before: _filter : progid:DXImageTransform.Microsoft.AlphaImageLoader(src='... Read More...
19 February 2008
How to write JavaScript right?
Ok guy's. We are having 3 ways (Prototype, Object and Closure) to write JavaScript but I like at once strong and beautiful "Prototype". Here attached example for Prototype way (with Namespaces, Classes and Methods as in C#). // Namespace Core function core() { return this .constructor(... Read More...
18 February 2008
JavaScript String.format & StringBuilder
// String.Format String.format = function() { var s = arguments[0]; for (var i = 0;i<arguments.length-1;i++){ var reg = new RegExp( "\\{" +i+ "\\}" , "gm" ); s = s.replace(reg,arguments[i+1]); } return s; } String.prototype.format = function() { var s = this ; for (var... Read More...