Wrox Programmer Forums
|
ASP Forms As of Oct 5, 2005, this forum is now locked. Please use "Classic ASP beginner" at http://p2p.wrox.com/forum.asp?FORUM_ID=54 or "Classic ASP Professional" http://p2p.wrox.com/forum.asp?FORUM_ID=56 instead.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP Forms 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 September 9th, 2004, 10:44 PM
Authorized User
 
Join Date: Aug 2004
Posts: 11
Thanks: 0
Thanked 0 Times in 0 Posts
Default Dun know how to do the coding for pulldown

I'm learning how to write a forum but i'm stuck w/ posting new topic. Can anyone out there advise me how could i go abt writing the script on change the fontface, size and color using the pulldown?? i using asp. my code juz could not work any tips. i new in this n not sure at all how to go abt

 
Old September 9th, 2004, 11:28 PM
Friend of Wrox
 
Join Date: Jun 2004
Posts: 331
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to qazi_nomi
Default

Do you want any editor for writing the new topic or some thing else I cant understand what r u required ?

(*_*)



Numan
--------------------------------------------------
Love is the most precious thing of this world. So find and grab it!
 
Old September 9th, 2004, 11:35 PM
Authorized User
 
Join Date: Aug 2004
Posts: 11
Thanks: 0
Thanked 0 Times in 0 Posts
Default

like most forum when they do posting if they wan to change their text type, size or color the could do so from the pull down but i do not know how tat could works u c
how could user change there text color by juz selecting from the pulldown???
e.g if the user type "testing" and he could change this text to arial by selecting the text type pulldown, change the font size to "size 4" by selecting the pulldown from font size and text to be red in color by selecting "red" from the pulldown...etc

 
Old September 9th, 2004, 11:55 PM
Friend of Wrox
 
Join Date: Jun 2004
Posts: 331
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to qazi_nomi
Default

Its mean you want a rich text editor for changing the text to bold italic underline or change font or color e.t.c. If so then find on google by writing rich text editor or contact me I am online on my MSN at [email protected] I will provide u the rich text editor


Numan
--------------------------------------------------
Love is the most precious thing of this world. So find and grab it!
 
Old September 10th, 2004, 04:47 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 2,480
Thanks: 0
Thanked 1 Time in 1 Post
Default

Hi aprnip,

You got to use a variable for each of such things, that is set to default value as font size, color and other required stuff. Then use that variable within your asp code. In case something is selected from the pulldown, set that as the value for that variable and your code should look like this.
Code:
' size='<%=varSize%>'>Some text
Hope this is what you were looking for.

Cheers!

_________________________
- Vijay G
Strive for Perfection
 
Old September 11th, 2004, 03:35 AM
Authorized User
 
Join Date: Aug 2004
Posts: 11
Thanks: 0
Thanked 0 Times in 0 Posts
Default

happygv, i dun really undstand how this could be done???? How abt the pull down how should it be done??
<select name="selectSize" class="button">
    <option value="Size" selected>Size</option>
    option value="size=1">1</option>
    <option value="size=2">2</option>
    <option value="size=3">3</option>
</select>

where in the pulldown i name the varColor or varSize??

i saw some ppl do a onchange coding "<select name="selectSize" class="button" onchange="..."> but i do not know how to write to code when my user select size 3 n tell the computer to change the the size to 3


 
Old September 11th, 2004, 04:05 AM
Friend of Wrox
 
Join Date: Jun 2004
Posts: 331
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to qazi_nomi
Default

Dear simply you want a rich text editor ?

Numan
--------------------------------------------------
Love is the most precious thing of this world. So find it and grab it!
 
Old September 11th, 2004, 05:17 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 2,480
Thanks: 0
Thanked 1 Time in 1 Post
Default

Code:
<%
    Dim varSize
    varSize= Request.Form("selectSize")
    If len(trim(varSize))=0 then varSize=1 'Setting to a default as 1

    'Dim varColor
    'varColor= Request.Form("selectColor")
    'If len(trim(varColor))=0 then varColor="Red" 'Setting to a default as Red Color

%>
<html>
<body>
<form name="frm" method="post" action="">

<select name="selectSize" class="button">
    <option value="" selected>Select Size</option>
    option value="1">1</option>
    <option value="2">2</option>
    <option value="3">3</option>
    <option value="4">4</option>
    <option value="5">5</option>
    <option value="6">6</option>
    <option value="7">7</option>
</select>
</form>

" color="<%=varColor%>">This is MyText of MySize

</Body>
</html>
Similarly add another pull down and do it for Color.

Hope that helps.
Cheers!

_________________________
- Vijay G
Strive for Perfection





Similar Threads
Thread Thread Starter Forum Replies Last Post
Coding Help sugunakar Classic ASP Professional 2 March 30th, 2008 04:42 PM
help with coding mastrgamr C++ Programming 15 November 10th, 2006 07:55 AM
How to refresh a pulldown menu? flickerfree Javascript 4 November 26th, 2005 11:12 AM
coding mdlan PHP Databases 1 May 28th, 2005 07:40 PM
can someone help me in coding this? somanchivasu Access 1 April 5th, 2004 02:41 PM





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