|
|
|||||||||
|
|||||||||
|
|||||||||
| |
|||
| ||||||||||||||||||||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Display Modes |
|
#1
|
|||
|
|||
|
alert() function
can ne 1 plz tell me -
|
|
#2
|
||||
|
||||
|
To my knowledge, you can't change the title bar. If you discover that you can, please post the method here! I'm also not sure what the character limit is. Presumably, if you put too much text in, the box'll become too wide for some screens. I think you can add line breaks by adding either <br> or \n to the output. If none of this works out, consider making your own alert box by popping up a window with the alert message in it and adding an OK button that does self.close() onclick.
|
|
#3
|
||||
|
||||
|
you can't change the window title of an alert...
and it's \n to bring a new line |
|
#4
|
|||
|
|||
|
thanx for the tip about the newline. actually i found it out myself a few minutes after posting it here.
i had an idea that it was '\n' but i was trying something like Code:
alert('firstline'+\n+'next line')
instead of Code:
alert('first line\nnext line')
and regarding the max content allowable of alert() box, i am still not able to find it. but i do know that if the string is over the limit it gets trimmed |
|
#5
|
||||
|
||||
|
I'm guessing the max num of chars you could fit would depend on the screen res too. Though I can't imagine why you would want so much info in an alert box.
|
|
#6
|
|||
|
|||
|
you cannot change the title of the alert() popup...netscape has not provided this feature...dont kno y..
you can also use \r for the newline character..it works the same way.... |
![]() |
| Viewing: Dev Articles Community Forums > Programming > JavaScript Development > alert() function |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|