HOME
TUTORIAL
∇
Applets
Comments
CSS
Document Tags
Embed
Fonts
Forms
Frames
Images
Lines & Paragraphs
Links
Lists
Logical Tags
Scripts
Sounds
Symbols
Tables
Weird Tags
FORUM
∇
HTML Help
Web Design
Programming Languages
Web Hosting
Domain Names
Marketing
Community
QUICK LIST
CSS
Forum Home
FAQ
Search
Memberlist
Register
Profile
Log in to check your private messages
Log in
Register
- Not registered yet? Got something to say?
Join HTML Code Tutorial
!
using javascript to submit form in asp
HTML Help Forum Index
->
ASP
View previous topic
::
View next topic
Author
Message
rollsroyce1400
Joined: 12 Sep 2006
Posts: 33
Posted: Thu Sep 18, 2008 10:37 am
using javascript to submit form in asp
So heres the problem:
i have a js function updaterecord which passes in an id. the js then has a hidden form value = ID then submits the form.
My problem is when its on the next page the value is still at default even though i know it was the correct value when on the original page..
User clicks this
Code:
<td align="center"><input type="submit" name="Update" value="Update" onClick="UpdateRecord(<%= rstMatrix.Fields("ID").Value %>)"></td>
JS function
Code:
function UpdateRecord(intPrimaryKey)
{
document.getElementById('intUpdatePrimaryKey').Value = intPrimaryKey;
document.frmUpdate.submit();
}
and heres the hidden form which has the new value (but value doesnt transfer to UpdatePlantMfg.asp, rather stays as -1)
Code:
<form name="frmUpdate" method="post" action="UpdatePlantMfg.asp">
<input type="hidden" name="intUpdatePrimaryKey" value="-1" />
</form>
Ive tried alot and have not been able to figure this out..any help is appreciated!!
rollsroyce1400
Joined: 12 Sep 2006
Posts: 33
Posted: Thu Sep 18, 2008 11:28 am
figured it out.....
.value (case sensitive) DUH
Display posts from previous:
All Posts
1 Day
7 Days
2 Weeks
1 Month
3 Months
6 Months
1 Year
Oldest First
Newest First
HTML Help Forum Index
->
ASP
All times are GMT - 8 Hours
Page
1
of
1
Jump to:
Select a forum
Announcements
----------------
Announcements
HTML Help
----------------
HTML FAQ
General HTML
HTML Form
HTML Table
HTML Frame
CSS
DHTML
SSI
MySpace
HTML Tools
Web Design
----------------
Images & Graphics
Templates
Multimedia
Programming Languages
----------------
Javascript
PHP
Perl
ASP
Others
Web Hosting
----------------
Free Hosting
Shared Hosting
Dedicated, Managed, and Co-located Hosting
Hosting Business and Reseller Hosting
Domain Names
----------------
Registrars
Tools
For Sale, Wanted, & Appraisals
Expired Domains
Monetization
Legal Issues
Marketing
----------------
SEO
PPC
Affiliate Marketing
Other Internet Marketing
Community
----------------
Miscellaneous
Website Review
Introduce Yourself
Feedback
Praise
Errors
You
cannot
post new topics in this forum
You
cannot
reply to topics in this forum
You
cannot
edit your posts in this forum
You
cannot
delete your posts in this forum
You
cannot
vote in polls in this forum
Your Ad Here
HTML Help Archive
Powered by phpBB © 2001, 2005 phpBB Group
HOSTING / DESIGN
$1.99 Domain Registration
Cheap Web Hosting
Website Templates
MAKE MONEY
Sell Domain Names
Sell Website Templates
Home
|
Tutorials
|
Forum
|
Quick List
|
Link Directory
|
About
Copyright ©1997-2002 Idocs and ©2002-2007 HTML Code Tutorial