• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Need to make 2 actions in 1 form w/1 button

 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I know extremly little about java script but I think this may be the way to go. Forgive me if this is too lame a question or too hard a question because like I said I have no clue.

I have a form that sends data to a filemaker database. I have another form that send the info to an ASP script that sends out an email. I would like to combine the actions into one form so it will send the info both to the filemaker database and also send an email. I've seen a couple of java examples that kind of do this but they have two buttons and that won't work for what I need. I assumed that you could just combine the actions but when I try only one or the other will work. Below is the example of the two I want to combine.

THIS:
<FORM ACTION="FMPro" METHOD="post">
<INPUT TYPE="hidden" NAME="-db" VALUE="infomail.fp3">
<input type="hidden" name="-mailformat" value="Formatmusic.txt">
<input type="hidden" name="-Format" value="redirectmusic.htm">
<INPUT TYPE="hidden" NAME="area" VALUE="music">


and THAT:
<form name="form1" method="post" action="dNBmail-noformat.asp">
<input name="_recipient" type="hidden"value="lmcquestions@losmedanos.edu; echapman@losmedanos.edu">
<input name="_subject" type="hidden" value="Questions from the LMC website">
<input name="_redirect" type="hidden" value="http://www.losmedanos.edu">
 
Ranch Hand
Posts: 618
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The moderator might move your forum to the JavaScript forum since your post doesn't really relate to Java (it would if you were using Java/JSP instead of ASP). It sounds like you'll need to just have one form on the page (combine the two), and when that gets submitted it gets handled by some ASP code that both sends out the email and sends the data to FileMaker.
 
Ranch Hand
Posts: 582
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
According to my experiences in my projects, that should be 2 buttons to handle that separately.
But if you want users to just click one button to do both actions, I think you should handle that in server side.

I ussually using a servlet to handle that. After that servlet receives a request, that servlet will execute both actions before that servlet returns HTTP Response.

Correct me if I am wrong to understand your question

thanks
daniel
 
Eloine Chapman
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks very much for your responses I was hoping to combine the two forms somehow with java script but I'm not really familiar with hodw to do it. I think you're right it needs to be a server side thing that handles the flow of being sent to an email and into a database. Our Filemaker used to do that and then SMTP on that box was turned off so I was using an ASP script on another box and hoping to combine the actions of the two since one I have SMTP access on one and the other I have a database. Getting a bit complicated!
 
Ranch Hand
Posts: 3061
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Please direct further questions to the HTML and JavaScript forum. This forum is about Java (which is NOT the same as JavaScript, nor even related).

Thanks,

Layne
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic