Closed Bug 286787 Opened 20 years ago Closed 20 years ago

Javascrpt alert() with no arguments is not displayed

Categories

(Core :: JavaScript Engine, defect)

x86
Windows XP
defect
Not set
minor

Tracking

()

VERIFIED DUPLICATE of bug 98185

People

(Reporter: jpage, Unassigned)

Details

Attachments

(1 file)

User-Agent:       Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; (R1 1.5); .NET CLR 1.0.3705; Media Center PC 2.8)
Build Identifier: 

A call to alert(); in Javascript with no arguments does not display an alert at 
all.  If you use an empty string - alert(""); it works OK.  Its not a terribly 
serious problem.  I use it in debugging. To see if a certain piece of code is 
being run I will just put an alert() in there.  In IE it does display an empty 
alert dialog box, so the Firefox behaviour had me confused for a little while.

Reproducible: Always

Steps to Reproduce:
1.Run the attached sample file
2.
3.

Actual Results:  
Only one button produces an alert

Expected Results:  
Both buttons should produce an alert
Assignee: firefox → general
Component: General → JavaScript Engine
Product: Firefox → Core
QA Contact: general → general
Version: unspecified → Trunk

*** This bug has been marked as a duplicate of 98185 ***
Status: UNCONFIRMED → RESOLVED
Closed: 20 years ago
Resolution: --- → DUPLICATE
Error: uncaught exception: [Exception... "Not enough arguments
[nsIDOMWindowInternal.alert]"  nsresult: "0x80570001
(NS_ERROR_XPC_NOT_ENOUGH_ARGS)"  location: "JS frame ::
https://bugzilla.mozilla.org/attachment.cgi?id=177920 :: onclick :: line 1" 
data: no]
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: