CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
INDEX
Search Posts SEARCH
POSTS
Who's Online WHO'S
ONLINE
Log in LOG
IN

Home: Other Programming Languages: Javascript:
Arrays

 



sirus4u2c
Novice

Aug 13, 2003, 11:25 PM

Post #1 of 2 (27384 views)
Arrays Can't Post

could someone tell me how to remove a element from a array

@Ele = ("this","That","why","When");

How could I remove "That".

I was also wondering how to remove all the elements from the array in JavaScript


fashimpaur
User

Dec 31, 2003, 4:38 AM

Post #2 of 2 (27369 views)
Re: [sirus4u2c] Arrays [In reply to] Can't Post

I don't think this is going to do what you need but...

@Ele is Perl...

in JavaScript...

var Ele = new Array ("this","That","why","When");

Ele = [Ele[0],Ele.slice(2)];



Also, to empty an array try this ...

var Ele = new Array ("this","That","why","When");

Ele = new Array();

document.write Ele.length();



HTH,

Dennis




In Reply To
could someone tell me how to remove a element from a array

@Ele = ("this","That","why","When");

How could I remove "That".

I was also wondering how to remove all the elements from the array in JavaScript

Dennis

$a="c323745335d3221214b364d545".
"a362532582521254c3640504c3729".
"2f493759214b3635554c3040606a0",
print unpack"u*",pack "h*",$a,"\n\n";

 
 


Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives