I tried this in iexplorer, mozilla, opera.
var in = 1;
switch( in ){
case 1:
in = "-1-";
break;
case 2:
in = 2;
break;
default:
document.writeln(' <FONT COLOR="black">dddddddd </FONT>');
}
alert(in);
document.writeln('<FONT COLOR="black">ffffffffffffffffff</FONT> ');
Is it not supposed to work?
--
Jean Pierre Daviau
--
Easyphp1.8
Apache1.3.24
DEVC++, borland 5.5
windows Xp
asus p4 s533/333/133
Intel(R) Celeron (R) CPU 2.00 GHz http://www.jeanpierredaviau.com 7 4499
Jean Pierre Daviau wrote: I tried this in iexplorer, mozilla, opera.
var in = 1;
'in' is a reserved word in JavaScript, do not use it for variable names.
This line causes an error message in the Firefox Javascript console of
'missing variable name'.
Change the variable name to something else and maybe it will 'work'.
[...]
Is it not supposed to work?
'Work'? What result did you expect? What did you get? Error messages?
--
Rob
Nothing.
A blank page with ie debugger and Frontpage debugger.
So it was hard to find....
Well, I should have remember. But I did not play with JavaScript for 4
years at least...
Thank you
"RobG" <rg***@iinet.net.au> a écrit dans le message de news:
9m*****************@news.optus.net.au... Jean Pierre Daviau wrote: I tried this in iexplorer, mozilla, opera.
var in = 1;
'in' is a reserved word in JavaScript, do not use it for variable names. This line causes an error message in the Firefox Javascript console of 'missing variable name'.
Change the variable name to something else and maybe it will 'work'.
[...]
Is it not supposed to work?
'Work'? What result did you expect? What did you get? Error messages?
-- Rob
Nothing either. I think my javascript is corrupted.
<SCRIPT type="javascript" language="JavaScript">
var entrant = 1;
switch( entrant ){
case 1:
entrant = "-1-";
break;
case 2:
entrant = 2;
break;
default:
document.writeln(' <FONT COLOR="black">dddddddd </FONT>');
}
alert(entrant);
document.writeln('<FONT COLOR="black">ffffffffffffffffff</FONT> ');
</SCRIPT>
</head>
<body>
<SCRIPT type="javascript" language="JavaScript">
<!--
alert()
document.writeln('<FONT COLOR="black">ffffffffffffffffff</FONT> ');
//-->
</SCRIPT>
Jean Pierre Daviau wrote: Nothing either. I think my javascript is corrupted.
<SCRIPT type="javascript" language="JavaScript">
Unknown script type and language is deprecated, use:
<script type="text/javascript">
var entrant = 1;
switch( entrant ){ case 1: entrant = "-1-"; break;
case 2: entrant = 2; break;
default: document.writeln(' <FONT COLOR="black">dddddddd </FONT>');
You should update your HTML too, the font element has been deprecated
for quite a while. An HTML 4 compliant alternative is:
document.writeln(' <span style="color: black;">dddddddd </span>');
}
alert(entrant); document.writeln('<FONT COLOR="black">ffffffffffffffffff</FONT> '); </SCRIPT> </head>
<body>
<SCRIPT type="javascript" language="JavaScript">
As above, error with type & remove language attribute.
<!--
No need for this, just remove it.
alert() document.writeln('<FONT COLOR="black">ffffffffffffffffff</FONT> '); //-->
And remove this one too.
</SCRIPT>
--
Rob
Jean Pierre Daviau wrote: I tried this in iexplorer, mozilla, opera.
var in = 1; switch( in ){ case 1: in = "-1-"; break;
case 2: in = 2; break;
default: document.writeln(' <FONT COLOR="black">dddddddd </FONT>'); }
alert(in); document.writeln('<FONT COLOR="black">ffffffffffffffffff</FONT> ');
Is it not supposed to work?
No. I ran it through JSLint, and it reported:
Error:
Problem at line 1 character 5: Expected an identifier and instead saw 'in'.
var in = 1;
'in' is a reserved word. http://www.JSLint.com/
Try it here. This page does not work for me: http://www.jeanpierredaviau.com/delme.html
It does not work for me. But I do can go on websites with javascripted pages
? ?????????????
It seems only some core javascript dont work like functions or alert().
javascript:var entrant = 1;switch( entrant ){case 1:entrant =
"-1-";break;case 2:entrant = 2;break;default:}alert(entrant);
the previous works in the addres bar. This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: r.e.s. |
last post by:
No matter which site I download it from,
NumTut.tgz appears to be corrupted.
Anyone else having this problem?
Thanks.
--
r.e.s.
|
by: WKC |
last post by:
Recently, one of our database's mdf and ldf was corrupted. We were able to
bring back the database with the capability of importing and querying the
data. However, the data is not the full list. ...
|
by: bugman |
last post by:
The problem started with Firefox. Got to www.foxnews.com and click on
any of the scrolling headlines in the right hand box. Firefox would
crash. Now Opera and IE do also. If I disable...
|
by: Bob Hynes |
last post by:
Hi All,
Does anyone know of a place where a corrupted mdb(front-end) can be
sent and have that place be able to tell me what got corrupted within
the db?
Here's the issue;
All pc's are WindowsNT...
|
by: Lee Rouse |
last post by:
Hello all,
This is going to be a rather lengthy "question".
I have an Access 2k database, separated front end/back end. Front end
copies are on about 30 workstations and used frequently during...
|
by: hrishikesh |
last post by:
hi all can you tell me how to call javascript function
in .aspx page
i want to call it on onclick of button
this codebehind code giving me some other problem like
The viewstate is invalid for...
|
by: Vinod I |
last post by:
Hi Team,
When I tryed following code, I am getting the Runtime Error as
"The View State is invalid for this page and might be corrupted."
Exception Details: System.Web.HttpException: The View...
|
by: Noone Here |
last post by:
AIUI, it was not all that long ago when the threat to personal users,
was attachments that when executed compromised machines with keyloggers,
trojans, etc.
Now it seems that the big problem is...
|
by: advance scout |
last post by:
HELP! My database is suddenly corrupted. My computer was acting funny
(very sluggish) and was shut down. Access had been already been closed down
but computer was acting very slow , so perhaps it...
|
by: emmanuelkatto |
last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud.
Please let me know.
Thanks!
Emmanuel
|
by: Hystou |
last post by:
There are some requirements for setting up RAID:
1. The motherboard and BIOS support RAID configuration.
2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers,...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new...
| |