Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Web Programming > JavaScript > Javascript How-To
|
Javascript How-To Ask your "How do I do this with Javascript?" questions here.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Javascript How-To section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old April 2nd, 2004, 02:21 PM
Authorized User
 
Join Date: Oct 2003
Posts: 96
Thanks: 0
Thanked 0 Times in 0 Posts
Default change text colors in an javascript Alert?

Is it possible to change the color of the text in an Alet box? If so, the syntax would be appreciated...

Here is the Alert I am using.
<script language="javascript">
if (confirm("Sorry, reserved for registered users only.\n\nAll pages will be Unlocked upon Ordering your Full Version of the exams. In addition, you will have access to five separate study tests and the Final Exam. Over 300 test questions, reference pages, links, exhibits, and much more.\nOnly $14.95.\n\nClick ''OK'' to begin ordering . . ."))
{
window.location.href="http://www.whatever.com.htm";
}
else
{
window.close();
}
</script>

Thanks,

__________________
Rudy
 
Old April 2nd, 2004, 07:15 PM
Friend of Wrox
 
Join Date: Nov 2003
Posts: 1,285
Thanks: 0
Thanked 2 Times in 2 Posts
Default

I do not believe it is possible.

----------
---Snib---
----------

<><
 
Old November 24th, 2004, 08:57 PM
aus aus is offline
Registered User
 
Join Date: Nov 2004
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

did you get any way of doing this... changing the color of the text displayed in the alert message

 
Old November 25th, 2004, 05:08 AM
joefawcett's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 3,074
Thanks: 1
Thanked 38 Times in 37 Posts
Default

Can't be done with built in alert box. The easiest way is to have a hidden div that you show when needed.



--

Joe (Microsoft MVP - XML)
 
Old November 25th, 2004, 12:27 PM
Friend of Wrox
 
Join Date: Nov 2003
Posts: 1,285
Thanks: 0
Thanked 2 Times in 2 Posts
Default

Or you could use a modeless dialog window, now that I think about it. It looks more like an alert() box if you set the background color of the page in it to threedface.

hth,

-Snib
Where will you be in 100 years?
Try new FreshView 0.2!
 
Old February 12th, 2007, 08:03 AM
Registered User
 
Join Date: Jan 2007
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

check the following site:

http://slayeroffice.com/code/custom_alert/

u can change the alert box color also.






Similar Threads
Thread Thread Starter Forum Replies Last Post
Change Series colors in Stacked Line Marker chart Jell VB.NET 2002/2003 Basics 0 July 13th, 2005 04:01 AM
change this alert/confirm box crmpicco Javascript How-To 3 March 9th, 2005 01:11 PM
Javascript alert error Ed7777 Javascript How-To 5 June 25th, 2004 02:23 PM
Javascript alert box Adam H-W Javascript How-To 13 March 4th, 2004 05:11 AM
dynamically change the row colors in datagrid bvrao VS.NET 2002/2003 0 December 24th, 2003 06:19 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.