deleting from array: delete argument is not a HASH element or slice at ./chess.cgi line 179. 
Author Message
 deleting from array: delete argument is not a HASH element or slice at ./chess.cgi line 179.

Hello, I am building a little chess game. So far, it's going quite
well. Now I've got a little problem. When I execute a local syntax
check, it says the script is ok. After uploading, I get an internal
server error.

Telnetting to my ISP and then executing the script from command line
gave this result:

[peanwebdev chess]$ ./chess.cgi
delete argument is not a HASH element or slice at ./chess.cgi line
179.

chess.cgi, line 179:

The error is a compile-time error (pre runtime error).
Well, delete argument is not a HASH element, indeed, but is IS a
slice! ([$gameID])...
What is wrong?

There's just one thing I can think of... On my local computer, I'm
running v5.6.1 for windows. My book says this:
"As of Perl v5.6.0, you can use the exists and delete functions on
array elements."

[peanwebdev chess]$ perl -v

This is perl, version 5.005_03 built for i386-linux
...

Is the error caused by an out-dated Perl-version?
Or what else causes the error?

Thanks in avance,
--Peter-Anders Ramakers



Fri, 03 Sep 2004 00:59:47 GMT  
 
 [ 1 post ] 

 Relevant Pages 

1. Deleting an element from hash of hashes?

2. Anonymous array, delete element from array if found:

3. Delete array slices?

4. PERLFUNC: delete - deletes a value from a hash

5. PERLFUNC: delete - deletes a value from a hash

6. deleting element from tie'd GDBM hash??

7. How do I delete a hash element ??

8. Compare files and arrays and delete elements:

9. How can i delete an array element i don't know the position

10. Help: Delete Element From Array?

11. delete an element from an array?

12. How to delete the current array element?

 

 
Powered by phpBB® Forum Software