Revision: 1079
Updated Code
at September 7, 2006 11:11 by dandyna
Updated Code
onClipEvent (load) {
//associa replace, che abbiamo creato noi con una funzione a tutte le stringhe.
String.prototype.replace = function(stringa, rep) {
var temp_array = this.split(stringa);
return temp_array.join(rep);
};
}
//now, an example of use:
onClipEvent (enterFrame) {
if (fine == 1) {
vel = 8;
testo_app = new String(testo0);
stringhe = new Array(new Array('*ec*', '&'), new Array("&", "&"), new Array("à", "à "), new Array("è", "è"), new Array("ì", "ì"), new Array("ò", "ò"), new Array("ù", "ù"), new Array("é", "é"));
num_stringhe = stringhe.length;
for (i=0; i<num_stringhe; i++) {
testo_app = testo_app.replace(stringhe[i][0], stringhe[i][1]);
}
fine = 2;
i = 0;
l = testo_app.length;
testo = " ";}
if (fine == 2) {
i=i+vel;
if (i>l){i=l;
fine=3;}
testo = testo_app.substr(0, i);
if (i == l) {
fine = 4;
}
}
}
Revision: 1078
Updated Code
at September 7, 2006 11:10 by dandyna
Updated Code
onClipEvent (load) {
//associa replace, che abbiamo creato noi con una funzione a tutte le stringhe.
String.prototype.replace = function(stringa, rep) {
var temp_array = this.split(stringa);
return temp_array.join(rep);
};
}
//now, an example of use:
onClipEvent (enterFrame) {
if (fine == 1) {
vel = 8;
testo_app = new String(testo0);
stringhe = new Array(new Array('*ec*', '&'), new Array("&", "&"), new Array("à", "à "), new Array("è", "è"), new Array("ì", "ì"), new Array("ò", "ò"), new Array("ù", "ù"), new Array("é", "é"));
num_stringhe = stringhe.length;
for (i=0; i<num_stringhe; i++) {
testo_app = testo_app.replace(stringhe[i][0], stringhe[i][1]);
}
testo = testo_app;
fine = 2;
}
}
Revision: 1077
Initial Code
Initial URL
Initial Description
Initial Title
Initial Tags
Initial Language
at September 7, 2006 10:05 by dandyna
Initial Code
onClipEvent (load) {
//associa replace, che abbiamo creato noi con una funzione a tutte le stringhe.
String.prototype.replace = function(stringa, rep) {
var temp_array = this.split(stringa);
return temp_array.join(rep);
};
}
Initial URL
Initial Description
Builds a function which replace some caracters
Initial Title
Replace function on text strings
Initial Tags
actionscript, replace, text
Initial Language
ActionScript