Articles Tagged 'Internet'


DatePicker with Prototype and Scriptaculous

image An interesting and useful Javascript library based on the coupling Prototype and Scriptaculous allows you to add the function of DatePicker (component present in ActionScript / Flash) in the normal HTML TEXT INPUT.

Its characteristic Unobtrusive (not intrusive) makes it an ideal tool to expand the functionality of a site which has been previously established. To activate the DatePicker just add the class "dates" in our input tag. In Javascript you can set a number of parameters including the overwhelming support for the Italian language.

Here is a piece of code examples:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
"text/javascript" src = "/prototype.js" >< / script > < script type = "text / javascript" src = "/ prototype.js"> </ script >
"text/javascript" src = "/scriptaculous.js" >< / script > < script type = "text / javascript" src = "/ scriptaculous.js"> </ script >
"text/javascript" src = "/datepicker.js" >< / script > < script type = "text / javascript" src = "/ datepicker.js"> </ script >
"text/css" > < style type = "text / css">
@ Import ("/ css / datepicker.css");
</ style >
< form >
"text" id = "date-from" name = "date-from" / > < input type = "text" id = "date-from" name = "date-from" />
</ form >
"text/javascript" > < script type = "text / javascript">
dpck var = new DatePicker ({
on: 'date-from',
language: 'en'
});
</ script >

Continued ...

Windows tools: the best freeware

iColorFolder 1.4.2

The happy Mac owners have always had an operating system can handle the colors of the folders. Finally with iColorFolder , open source utilities, even on Windows XP you can set the colors and graphics of the folders.

image

Dexpot 1.4.0

It allows you to manage virtual desktops in a very efficient way. It provides a range of utilities for managing windows and many advanced features to track well hidden windows, adjust the transparency and more. This software allows full personalization and run a slide show of all Desktop created and allows you to create rules for the management of windows on the desktop. You can also visuallizzare all Desktop (maximum 20) in one go!.

image

Visual Task Tips

Lets get a thumbnail preview then iconified windows in the taskbar, just like in Windows Vista. The unique feature of this application lies in the size of the preview, very clearly visible in the ability to view real-time changes to the window, like Flash animations, progress bars, etc. ...

Vista Wallpaper Collection

On the Web site of Hamad Darwish , the photographer, there are some shots that Microsoft made ​​two of which are just part of those in support of Windows Vista. You can download 22 wallpapers really wonderful to use on any OS, including XP.

image

FileHamster

Dedicated mainly to developers, but not limited to this simple, lightweight software allows you to keep track of file versions. Its use is very simple: just select a folder or file by the application to be kept "under control". From that moment you can repristinare a previous version. You can decide which files or folders "preserve" through classic wildcard (such as *.* or _ *) and the number of revisions. It works in practice with any type of document: PSD, DOC, PDF, HTML, etc. So ... useful to anyone who writes documents, graphics using Photoshop and software developers.

image

Continued ...

Aptana IDE update: 9 Milestones

It is available to update the Aptana IDE , the Web development environment that supports Adobe AIR and Apple iPhone . Among the changes include the improvement of the section with the update of the PHP Code Assist functions on both parameters. Also improved the "color" of the code. Added support for latest Ajax frameworks including prototype.js and jQuery . Also improved handling of Javascript.

image

For the complete list of new features click here .

Continued ...

Reflex 1.1: add reflection effect to images

image New version 1.1 of Javascript library SLR with which you can add reflection effects to images. The advantage of using this technique "unobtrusive" is the speed with which you can add these effects without having to actually spend time in creating the image of reflection.
This version has been tested on Mozilla Firefox 1.5 +, Opera 9 +, Safari and IE6. The minimum supported size of an image is 32 × 32. Once libreiria including:

1
"text/javascript" src = "reflex.js" >< / script > < script type = "text / javascript" src = "reflex.js"> </ script >

Just enter class = "reflex" on the images where we want to apply this effect. By exploiting the properties of the class, you can manipulate the effects of reflection, which makes this very special library. You can, in fact, distort the image by adding 3D effects. For example, here is how to add various features to rilfessione:

1
"reflex idistance16 iborder2 iheight24" width = "200" alt = "" src = "images/example.jpg" / > < img class = "reflex idistance16 iborder2 iheight24" width = "200" alt = "" src = "images / example.jpg" />

For details see the official documentation .

On the same site you can download many other effects such as Edge, Corner, Glossy and many others, all dedicated to images.

Continued ...

Proto.Menu: Context menus in JavaScript with Prototype 1.6.0

Proto.Menu is a simple and lightweight (2Kb) solution of JavaScript to add functionality to the context menus HMTL pages. This library uses the recent release of Prototype 1.6.0_rc0 . Its main characteristics are:

  • Lightness: ~ 2 KB (~ 1.5 MB version)
  • Unobtrusive: not intrusive
  • Supports all browsers
  • Customizable in terms of style-sheet
  • Extremely fast

For its use is required:

  • prototype.js 1.6.0_rc0
  • tested on browsers: Firefox 1.5 +, Internet Explorer 6 +, Safari 3 +, Opera 9 +, Netscape Navigator 9 +

To use it simply include the library prototype and proto.menu:

Download Proto.Menu.js (or compressed version )

1
2
"text/javascript" src = "js/prototype.js" >< / script > < script type = "text / javascript" src = "js / prototype.js"> </ script >
"text/javascript" src = "js/Proto.Menu.js" >< / script > < script type = "text / javascript" src = "js / Proto.Menu.js"> </ script >

You can include a custom CSS file

1
"stylesheet" href = "Proto.Menu.css" type = "text/css" media = "screen" / > < link rel = "stylesheet" href = "Proto.Menu.css" type = "text / css" media = "screen" />

And its use is really simple, you create an array with links to show:

1
2
3
4
5
6
7
8
9
10
11
[ myLinks var = [
: 'Back' , callback : function ( ) { alert ( 'back function called' ) } } , {Name: 'Back', callback: function () {alert ('Called back function')}},
: 'Forward' , callback : function ( ) { alert ( 'Forward function called' ) } } , {Name: 'Forward', callback: function () {alert ('Forward function Called')}},
true } , {Separator: true},
: 'Reload' , callback : function ( ) { alert ( 'Reload function called' ) } } , {Name: 'Reload', callback: function () {alert ('Reload Called function')}},
: 'Disabled option' , disabled : true } , {Name: 'Disabled option', disabled: true},
: 'Toggle previous option' , callback : function ( ) { {Name: 'Toggle previous option', callback: function () {
= oLinks. find ( function ( l ) { return l. name == 'Disabled option' } ) ; var item = oLinks. find (function (l) l {return name == 'Disabled option'});
= item . disabled == false ? true : false ; items. disabled = item. disabled == false? true: false;
}}
]

Menus are activated by passing the reference to the array created:

1
2
3
4
5
6
7
"text/javascript" > < script type = "text / javascript">
Proto.Menu new ({
selector: '. contextmenu' / / context menu will be shown When element with class name of "contextmenu" is clicked
className: 'myContextMenu', / / ​​this is a class Which will be attached to menu container (used for css styling)
MenuItems: myLinks / / array of menu items
})
</ script >

Note the property selector indicates that the item related to the click context menu for this.

Continued ...

Right Click in AS3: Custom context menus

Remove context menus, or simply responding to "right click" the mouse is a possibility of the Flash Player directly from ActionScript code is not allowed even in CS3. This feature would be attractive for both games for RIA applications. Uza Paulius has proposed a solution for ActionScript 3 (AS3) that works in tandem with Javascript. This "patch" is still in testing it depends on the browser and the Flash Player installed. You can help by testing application demo here .
It was also an aperitif "project" on Google Code :

The idea is fairly simple:

1-Use Javascript in the HTML container page to disable right-click on the top of the SWF.

2 - Capture the event and pass it to a function That communicates with Flash via the External Interface

3-In Actionscript the function Called from Javascript does whatever you need to display your own custom context-menu.

Continued ...

Prototype 1.6.0 release candidate

You have just released the release candidate of Prototype 1.6.0 with the latest updates to the entire system API. è stato migliorato e ora fornisce il contesto dell'oggetto che ha rilasciato l'evento. In particular, the method observe the object Event has been improved and now provides the context object that issued the event. This "right" behavior can be overridden, however. This means that by default, this refers to the object that issued the event. It also introduced the ability to create custom events. Other improvements concern the Function.prototype, the functions of DOM, Ajax, functions, classes and more. For a complete list see the CHANGELOG.

Download

Continued ...

Event management: similarities between Flash and Javascript

One of the strengths of Adobe Flash lies in the choice of the ECMAScript (ECMA-products - E uropean C omputer A ssociation anufacturers M) as the standard scripting. ActionScript and JavaScript, in fact, both stem from a higher standard as they are extremely similar. This is one of the reasons for which many ActionScript programmers develop very easily in JavaScript and vice versa.

ActionScript has always had a management "double" of events that often has confused some developers. In MovieClip, for example, you can set an event by simply declaring a function to the properties of the event, for example:

Method 1

1
2
3
( ) { mio_mc. onRelease = function () {
"Click sul MovieClip" ) ; trace ("Click on the MovieClip");
}

Other objects, in contrast, require a different handling of the event that you want to monitor, requiring the classical listener, an object designed for this task. For example, the Mouse object can be controlled in this way:

Method 2

1
2
3
4
5
Object = new Obejct ( ) ; MouseListener var: Object = new Obejct ();
( ) { MouseListener. onMouseMove = function () {
"Mouse in moto" ) ; trace ("Mouse in motion");
}
addListener ( mouseListener ) ; Mouse . addListener (MouseListener);

The components have a further variant, as the Loader component:

Method 3

1
2
3
4
5
Object = new Object ( ) ; loaderListener var: Object = new Object ();
= function ( evt : Object ) { loaderListener. complete = function (evt: Object ) {
"Caricamento completato" ) ; trace ("Upload completed");
};
( "complete" , loaderListener ) ; myLoader_ldr. addEventListener ("complete", loaderListener);

Why these differences? The reason, indeed, is very simple. Method 1, the most immediate, is used when the event to "intercept" is unique, that is when it makes no sense to "take" several functions one after all ' other. Methods 2 and 3, however, create the "lists" of "listeners" and are extremely useful and powerful because they allow you to attach virtually infinite number of functions to a particular event.

The same thing happens in JavaScript and can be seen in libraries as a prototype . The convenient observe () method, available from the event, allows you to fit a function to an event object. For example:

1
window , 'load' , function ( ) { alert ( "Finestra caricata" ) ; } ) ; Event. Observe (window, 'load', function () {alert ("Window loaded");});

In this case we have attached our function that displays an alert to the load event of the window object. We could only repeat the statement and attach additional event:

1
2
window , 'load' , function ( ) { alert ( "Finestra caricata - 1" ) ; } ) ; Event. Observe (window, 'load', function () {alert ("Window loaded - 1");});
window , 'load' , function ( ) { alert ( "Finestra caricata - 2" ) ; } ) ; Event. Observe (window, 'load', function () {alert ("Window loaded - 2");});

This feature, also common in ActionScript, it is extremely versatile, especially in JavaScript, is the key to the creation of many "widgets" and extensions (see the classic snap ) now proliferating on the Web The ability to tag along, in fact , for events that are already controlled by other functions, can be non-intrusive (Unobtrusive) and then, in practice, to add functions to those already present.

Continued ...

BlogBabel API beta now

Update: BlogBabel closed - all the services, widgets and plugins are no longer active

With reports of P | xel and Dat I became aware of the new APIs provided by the site BlogBabel . So I released a new version of dell'antipixel BlogBabel Flash.

image

In this new version (who installed the previous version of Flash does not do anything, the update is automatic) are used the new APIs made ​​available by BlogBabel . The code is less invasive and faster than the previous year. From the context menu, also you can access more information and a calculation on the "up" or "down" (green or red background) is now correctly being provided by the same system API BlogBabel .

Remember to use enough to be recorded on the antipixel BlogBabel and insert the following lines of code in your site:

[Html

Latest Comments