Indigo Rose Software
  #1  
Old 06-07-2005
ianhull ianhull is offline
Forum Member
 
Join Date: Jul 2004
Posts: 313
php question Not related to AMS

Hi all,

I am just beginning with php mysql and I am wondering if anyone knows a way to submit a form to 2 different formproccessors.php on different servers.

I have the same web based application running on diferent servers with a different purpose but if a customer registers for one site I would like them to also be registered for my other site without having to submit the information again.

anyone got any ideas on how to achieve this?
or any links to to a data feed script?

Thanks
Reply With Quote
  #2  
Old 06-07-2005
Corey's Avatar
Corey Corey is offline
Registered User
 
Join Date: Aug 2002
Posts: 9,746
Hi. Sure, just use two separate HTTP.Submit() actions...
Reply With Quote
  #3  
Old 06-07-2005
ianhull ianhull is offline
Forum Member
 
Join Date: Jul 2004
Posts: 313
Thanks Corey,

Would I place a new form method tag underneath the first one?

Do you have a litttle sample?

Thanks
Reply With Quote
  #4  
Old 06-07-2005
Corey's Avatar
Corey Corey is offline
Registered User
 
Join Date: Aug 2002
Posts: 9,746
I think I might be mistaking this task. OK if I'm re-reading right, you have a web form on the net, and you want to send the same set of values to two different processing scripts. It sounds like more of a planning issue but anyhow one easy way is to use PHP "location" to forward the results from script one to script two. I can't post a working example on our server but the gist is:

1. Web form submits data to "process.php" on server 1.
2. Script on server one processes the data, then concatenates the variables into a string like this:

$myVars = "?var1=123532&var2=John+Smith&var3=Microsoft+X P";

3. And forwards them to script two like this:

header("Location: http://www.yoursite.com/scripttwo.php".$myVars);

4. And then script two processed the data and returns to the form, i.e.

header("Location: http://www.firstsite.com/theform.php?msg=success");

5. Or you could even use Javascript, i.e. return to a page with:

<body onload="document.siteForm.submit()">

and for your form:

<form action="<? print $site_registered_to; ?>" name="siteForm" method="POST">
<input type="hidden" name="username" value="<? print $username; ?>">
<input type="hidden" name="password" value="<? print $password; ?>">
</form>

Etc... Neither is secure. Anyhow it's some ideas to get your started...
Reply With Quote
  #5  
Old 06-07-2005
ianhull ianhull is offline
Forum Member
 
Join Date: Jul 2004
Posts: 313
Excellent Corey,

Thanks, I'm sure I can customize this for my needs.

Thanks again
Reply With Quote
Reply

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 On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Mysql, PHP results display in AMS? yss AutoPlay Media Studio 5.0 8 05-23-2005 11:02 AM
Proper Syntax for Sending Multiple Email Body Items From AMS to PHP Script AXXESS AutoPlay Media Studio 5.0 6 12-01-2004 01:45 PM
Quick Question Showing Windows system time in AMS slafta AutoPlay Media Studio 5.0 3 11-26-2004 12:36 AM
Question related to HTTP Proxy and Caching servers imanta TrueUpdate 1.0 0 11-19-2003 01:10 PM
One question before buying AMS na9 AutoPlay Menu Studio 3.0 1 12-08-2001 04:39 PM


All times are GMT -6. The time now is 12:27 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Copyright © 2000 - 2009 Indigo Rose Corporation. All rights reserved.
Indigo Rose Software