473,378 Members | 1,319 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,378 software developers and data experts.

Setting font in confirm() dialog

I have become owner of some Javascript code that displays a message
through the confirm() function. I have a uwser reuqest to make the
font size of this message larger. Can this be done? I don't see
readily a way to modify the font or other properties of the popup
created by confirm(). Thanks.

Ken

Apr 16 '07 #1
3 8723
Daz
On Apr 16, 4:36 pm, "OccasionalFlyer" <klit...@apu.eduwrote:
I have become owner of some Javascript code that displays a message
through the confirm() function. I have a uwser reuqest to make the
font size of this message larger. Can this be done? I don't see
readily a way to modify the font or other properties of the popup
created by confirm(). Thanks.

Ken
Hi Ken.

To my knowledge, this can't be done. The only thing you can do is make
a custom dialog yourself, out of divs, tables or whatever other
elements you have lying around. I think that IE does have some level
of support for it, using .NET, but I am uncertain.

I recommend you google the term "javascript lightbox", both with and
without quotes. You should find the results useful.

All the best.

Daz.

Apr 16 '07 #2
On Apr 16, 8:49 am, "Daz" <cutenfu...@gmail.comwrote:
On Apr 16, 4:36 pm, "OccasionalFlyer" <klit...@apu.eduwrote:
I have become owner of some Javascript code that displays a message
through the confirm() function. I have a uwser reuqest to make the
font size of this message larger. Can this be done? I don't see
readily a way to modify the font or other properties of the popup
created by confirm(). Thanks.
Ken

Hi Ken.

To my knowledge, this can't be done. The only thing you can do is make
a custom dialog yourself, out of divs, tables or whatever other
elements you have lying around. I think that IE does have some level
of support for it, using .NET, but I am uncertain.

I recommend you google the term "javascript lightbox", both with and
without quotes. You should find the results useful.

All the best.

Daz.
Thanks. I want to try a simpler idea but I'm wondering if I'm doing
something wrong here:
var msg = new String(
'WARNING: Quiting now will cancel all changes up to this point, ' +
'leaving your schedule as it was when you began this session. ' +
'Are you sure you want to quit?'
);
"msg".blink();
"msg".fontsize(7);

if (confirm(msg))
{
document.location.href = '<jsp:getProperty name="req"
property="contextPath"/>/regcontrol?command=SessionDone';
}
else
{
return false;
}
setting the properties of the string object seems to have no effect on
the confirm box. Am I doing this wrong to set the string object's
attributes? THank.s

Ken

Apr 16 '07 #3
OccasionalFlyer said the following on 4/16/2007 1:43 PM:

<snip>
setting the properties of the string object seems to have no effect on
the confirm box. Am I doing this wrong to set the string object's
attributes? THank.s
Yes, as you can't specify anything but the text in a confirm. No fonts,
no colors, nothing but text.

--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq/index.html
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
Apr 16 '07 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Hans | last post by:
Basically what I would like to do is my own confirm dialog so I can choose the text on the buttons etc. My code looks something like this today if (confirm("Do you want to save?")) //do some...
0
by: Tony Baker | last post by:
Wow. I finally found out the easiest way to display a yes/no (well, yes/cancel) dialog pop up from ASP.Net. Turnes out to be really easy. Just add the following in you Page_Load method (C# code...
3
by: ad | last post by:
I want user can confirm before delete records ? How can I show a confirm dialog when users press a button?
1
by: zhuang | last post by:
With Javascript, i know I could create confirm dialog in ASP.NET app.But the button is yes and cancel, is there anyway to change it to yes and no Thanks zhuang
0
by: Victor | last post by:
Hi everybody, could anybody kindly point me out to a possible reason for my problem : I create a modeless dialog using CreateDialogIndirect() from a memory template that contains DS_SETFONT...
4
by: mamun | last post by:
Hi All, I have the following situation and am looking for answer in C#. I have a datagrid and putting checkbox next to each record. In the header I have a Delete button. I want users to...
1
by: =?Utf-8?B?UmFq?= | last post by:
In my user control, I have included javascript code using ScriptManager.RegisterClientScriptBlock(). JavaScript code has a confirm message dialog box and we store the message value in a hidden...
0
by: marksommerville | last post by:
Can anyone help? I have a Delete button that processes a request to delete 1 or more records. I want to be able to issue a custom javascript confirm dialog message before I go through my save...
2
by: 00steve | last post by:
Hi, I am using a confirm dialog to display a list of altered records when the user submits changes. I would like it displayed in the following format: Student ...
21
raveendrabikkina
by: raveendrabikkina | last post by:
I want the confirm dialog box with "yes/no" buttons rather than the default "ok/cancel" buttons of confirm dialog box. what is the syntax for getting that . P.S: one thing don't tell me the...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 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 former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
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
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
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 using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.