472,960 Members | 1,838 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

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

Math operation in html

Hello
I have a html page that I am trying to get data from an user input and
then I want to be ble to sum the data. I would sum mon-in and mon-out
to get mon-time. Then I would like to sum mon-time...fri-time to get
total time for the week.

<TD height="33" valign="top">
<input type="text" name="mon-in" size="7" maxlength="5"
value="00:00">
</TD>
<td valign="top">
<input type="text" name="mon-out" size="7" maxlength="5"
value="00:00">
</td>
<TD valign="top">
<input type="text" name="mon-time" size="7" maxlength="5"
value="00:00">
</TD>

I appreciate any help and feedback.

Thanks
Mike
Jul 23 '05 #1
3 3971

"mikecantrell" <hu***********@bcbsla.com> wrote in message
news:2a*************************@posting.google.co m...
Hello
I have a html page that I am trying to get data from an user input and
then I want to be ble to sum the data. I would sum mon-in and mon-out
to get mon-time. Then I would like to sum mon-time...fri-time to get
total time for the week.


HTML doesn't do this--it's not a programming language. If you want the sum
to appear immediately after the user has entered the addends, you need to
learn client-side programming. Get yourself trained on Javascript. But first
make sure you can count on all your users *having* Javascript available in
their browsers. If they don't, you're out of luck.

Jul 23 '05 #2
On 4 Oct 2004 07:26:20 -0700, mikecantrell <hu***********@bcbsla.com>
wrote:
Hello
I have a html page that I am trying to get data from an user input and
then I want to be ble to sum the data. I would sum mon-in and mon-out
to get mon-time. Then I would like to sum mon-time...fri-time to get
total time for the week.


Impossible without scripting. I recommend using a form and a server-side
script to return the result.
Jul 23 '05 #3
In our last episode,
<2a*************************@posting.google.com> ,
the lovely and talented mikecantrell
broadcast on comp.infosystems.www.authoring.html:
Hello
I have a html page that I am trying to get data from an user input and
then I want to be ble to sum the data. I would sum mon-in and mon-out
to get mon-time. Then I would like to sum mon-time...fri-time to get
total time for the week.
You cannot do this with html. The "ml" means markup language. Html
has no math functions. Indeed, since it is just markup, html has no
functions of any kind.

You have essentially two options: a server-side solution (e.g. cgi)
or a client-side solution such as javascript. In either case, you
will generate or rewrite an html document with the answers you want,
but html won't do the work.

<TD height="33" valign="top">
<input type="text" name="mon-in" size="7" maxlength="5"
value="00:00">
</TD>
<td valign="top">
<input type="text" name="mon-out" size="7" maxlength="5"
value="00:00">
</td>
<TD valign="top">
<input type="text" name="mon-time" size="7" maxlength="5"
value="00:00">
</TD> I appreciate any help and feedback. Thanks
Mike

--
Lars Eighner -finger for geek code- ei*****@io.com http://www.io.com/~eighner/
If it wasn't for muscle spasms, I wouldn't get any exercise at all.
Jul 23 '05 #4

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

Similar topics

7
by: Wernfried Schwenkner | last post by:
I've found the discussion about Math.Log and the error with Math.Log(8,2) on Google. Unfortunatly the full thread isn't on my news server, so I can't reply. The problem doesn't only depend...
12
by: Janiek Buysrogge | last post by:
Hello, Does anyone know if there is a library or a sample project that can parse strings with mathematical expressions inside ? eg. string math = "(23 + 48) ^ 2 - (7.76 * 3.14)"; parser...
13
by: david ullua | last post by:
Hi, In Expand.c of BSD system, I met the following codes, the expression (column & 07) if used to compare variable column and 7, if column<=7, it returns true, else false. It use (column & 07)...
1
by: Andy | last post by:
Hi, I noticed when migrating a 2002 application to 2003 that the system changed to a different usage for pow(2,-15). In 2002, it used double pow(double,double). In 2003, it is using double...
15
by: Morgan Cheng | last post by:
Hi, I am writing a program that will take a lot of Math.Cos & Math.Sin operation. I am afraid this will be source of performance impact. Anybody knows how Math.cos & Math.Sin is implemented?...
1
by: TC | last post by:
I am getting small math errors when I use a query to convert a column's data type from Text to Single. I am using a calculated column with the following expression. HighSchoolGPA:...
0
by: kirby.urner | last post by:
Cyber-curricula have a leveling aspect, as kids nearer Katrina's epicenter tune in and bliss out on 'Warriors of the Net' (why wait for stupid big dummy textbooks to catch up?). They feel more...
5
by: Yansky | last post by:
Anyone any idea why the Math.abs() isn't working in this code? I thought it was supposed to convert negative numbers to whole numbers? var se = ; var time = 100 if(se < 0){ Math.abs(se);...
13
by: =?Utf-8?B?RXRoYW4gU3RyYXVzcw==?= | last post by:
Hi, Why does Math.Sqrt() only accept a double as a parameter? I would think it would be just as happy with a decimal (or int, or float, or ....). I can easily convert back and forth, but I am...
2
by: DJRhino | last post by:
Was curious if anyone else was having this same issue or not.... I was just Up/Down graded to windows 11 and now my access combo boxes are not acting right. With win 10 I could start typing...
0
tracyyun
by: tracyyun | last post by:
Hello everyone, I have a question and would like some advice on network connectivity. I have one computer connected to my router via WiFi, but I have two other computers that I want to be able to...
2
by: giovanniandrean | last post by:
The energy model is structured as follows and uses excel sheets to give input data: 1-Utility.py contains all the functions needed to calculate the variables and other minor things (mentions...
4
NeoPa
by: NeoPa | last post by:
Hello everyone. I find myself stuck trying to find the VBA way to get Access to create a PDF of the currently-selected (and open) object (Form or Report). I know it can be done by selecting :...
3
NeoPa
by: NeoPa | last post by:
Introduction For this article I'll be using a very simple database which has Form (clsForm) & Report (clsReport) classes that simply handle making the calling Form invisible until the Form, or all...
1
by: Teri B | last post by:
Hi, I have created a sub-form Roles. In my course form the user selects the roles assigned to the course. 0ne-to-many. One course many roles. Then I created a report based on the Course form and...
3
by: nia12 | last post by:
Hi there, I am very new to Access so apologies if any of this is obvious/not clear. I am creating a data collection tool for health care employees to complete. It consists of a number of...
0
NeoPa
by: NeoPa | last post by:
Introduction For this article I'll be focusing on the Report (clsReport) class. This simply handles making the calling Form invisible until all of the Reports opened by it have been closed, when it...
0
isladogs
by: isladogs | last post by:
The next online meeting of the Access Europe User Group will be on Wednesday 6 Dec 2023 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, Mike...

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.