Current location: Hot Scripts Forums » General Community » The Lounge » Help with script to total form


Help with script to total form

Reply
  #1 (permalink)  
Old 04-05-04, 04:14 PM
janeinpa janeinpa is offline
Newbie Coder
 
Join Date: Mar 2004
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
Help with script to total form

I am a web designer, trying to learn new tricks! I want this form to be something users can play around with, to try various choices and see how the total changes. I'm pretty sure I need some javascript in the <head> and an onclick somethingorother in the form, but that's as far as my current knowledge takes me! I tried copying some script from a similar application, but it didn't seem to work. Can someone take pity on a non-programmer and show me the proper technique? Thank you so much! Here what I have now (an abbreviated version)

<html>
<head>
<title>Estimate Costs</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css">
<!--
.style1 { font-family: Arial, Helvetica, sans-serif;
font-weight: bold;
}
.style2 {font-family: Arial, Helvetica, sans-serif}
-->
</style>
</head>

<body>
<h2 class="style2">Estimate Costs -- How do I get this to total? </h2>
<table width="90%" align="center" cellspacing="10">
<tr class="row2">
<td align="left" valign="top"><div align="left"><span class="style1">Add</span>
<select name="addphoto" id="select">
<option value="0">0</option>
<option value="10">1</option>
<option value="20">2</option>
<option value="30">3</option>
<option value="40">4</option>
<option value="50">5</option>
<option value="60">6</option>
<option value="70">7</option>
<option value="80">8</option>
<option value="90">9</option>
<option value="100">10</option>
</select>
<span class="style1">Photos @ $10 Each </span></div></td>
</tr>
<tr class="row1">
<td align="left" valign="top">
<div align="left"><span class="style2"><strong>Add @ $200 per Session</strong></span>
<input name="photoshoot" type="checkbox" id="photoshoot" value="200">
</div></td>
</tr>
<tr class="row2">
<td align="left" valign="top">&nbsp;</td>
</tr>
<tr class="row2">
<td align="left" valign="top"><span class="style1">Add</span>
<select name="flashbut" id="flashbut">
<option value="0">0</option>
<option value="25">1</option>
<option value="50">2</option>
<option value="75">3</option>
<option value="100">4</option>
<option value="125">5</option>
<option value="150">6</option>
<option value="175">7</option>
<option value="200">8</option>
<option value="225">9</option>
<option value="250">10</option>
</select>
<span class="style1"> Decorations @ $25 Each</span></td>
</tr>
<tr class="row2">
<td align="left" valign="top"><span class="row2 style2"><strong>Total:</strong> $
<input type="text" name="showtotal" value="0"
size="8" />
<input name="totalcost" type="button" id="totalcost" onclick="Total" value="Total Estimated Cost"/>
<input type="reset" name="Reset" value="Reset">
</span></td>
</tr>
</table>
</body>
</html>
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
formmail problem gscraper Perl 12 08-27-04 03:06 AM
Is there any integrity of script rankings? webmaster@atmanager.com Hot Scripts Forum Questions, Suggestions and Feedback 17 08-06-04 12:12 AM
MySql update form script? dihan PHP 8 01-10-04 03:35 AM
live chat script, form script, autoresponder, babalu Script Requests 0 12-04-03 01:55 PM
PHP script that uploads and emails the form. ./n00b3 PHP 5 11-24-03 03:16 PM


All times are GMT -5. The time now is 03:31 AM.
vBulletin® Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.