?
Solved

sending form variables with POST without form

Posted on 2008-11-05
5
Medium Priority
?
348 Views
Last Modified: 2011-09-20
hi all,

i'm using ASP and Javascript.
A client has a shopping cart which, at the end of the order process, is submitted to a database... the details of this order are then submitted to paypal for payment.

so my problem is this :

the form with all the details of the order is submitted and the database insert scripts are run... how can i now pass all these variables on to paypal using POST ?
0
Comment
Question by:dog_star
  • 3
5 Comments
 
LVL 36

Expert Comment

by:Loganathan Natarajan
ID: 22883865
You can very well create a FORM on a ASP page, where you can get all the values on the hidden fields / paypal parameter ... then have redirection on the page to the paypal process page...

i have experienced this, it worked me well,
0
 
LVL 36

Accepted Solution

by:
Loganathan Natarajan earned 2000 total points
ID: 22883877
something like this,


<%
after db insert get values or retriev them and put it from methods
asp process code, 
 %>
 
	<html>
		<head><title>Tets Page</title></head>
	<body>
	<form name="frmpremium" method="post" action="<%URL%>">
		
		<input type=hidden name="Amount" value="">
		<input type=hidden name="Order_Id" value="<%   %>">	
			
		<input type=hidden name="Merchant_Id" value="">		
		<input type=hidden name="WorkingKey" value="<%   %>">	
		
		<input type=hidden name="Redirect_Url" value="">
		<input type=hidden name="Checksum" value="<% %>">
		
	
		
	</form>
	
	<script language="javascript" type="text/javascript">
		document.frm.submit();		
	</script>	
	
</body>
</html>

Open in new window

0
 
LVL 3

Expert Comment

by:SreejithG
ID: 22884036
Use XMLHTTP Object
See the link below for more details
http://www.4guysfromrolla.com/webtech/110100-1.shtml
0
 

Author Closing Comment

by:dog_star
ID: 31513433
a simple solution that works well.... thanks...
0
 
LVL 36

Expert Comment

by:Loganathan Natarajan
ID: 22886630
Glad to help!... Thanks for your grade!
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article discusses how to create an extensible mechanism for linked drop downs.
This article discusses how to implement server side field validation and display customized error messages to the client.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…
Suggested Courses

839 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question