Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Dreamweaver MX 2004 Submit form, any way to use remote script to do mailform function?

Posted on 2009-06-28
7
Medium Priority
?
200 Views
Last Modified: 2012-05-07
Hi
Trying to get some students to add a form to a basic web site (only a couple of simple questions) , i understand that we cant send the form without some server side help but wondered if its possible to use a mailform function from some other website/server not ours.
anyone any ideas how we could get a submit form button working with out our server having to do anything?
or is it possible to have the contents of the form passed into a email that is sent from the clients own email account (outlook etc) ??
Hope you can help
Paul
0
Comment
Question by:2E0AQU
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
  • 2
7 Comments
 
LVL 70

Expert Comment

by:Jason C. Levine
ID: 24733049
Hi Paul,

>> if its possible to use a mailform function from some other website/server not ours.

Yes.  All you would need to do is find a remotely hosted form to email script and point the form action to that URL.

>> or is it possible to have the contents of the form passed into a email that is sent from the clients own email account (outlook etc) ??

You could attempt to set the form action to "mailto:account@domain.com" but a lot of the more modern browsers will not process it.  You are better off going with the remotely hosted solution above.
0
 
LVL 30

Expert Comment

by:IanTh
ID: 24734676
setup a new server as a test web server either, virtualy or an old pc, and setup xampp or install linux and apache etc then your students can use that with the mail script

if you go down the apache route you can install pear mail which will act as a mail server and use that as a test web server
see
http://pear.php.net/package/Mail/

0
 

Author Comment

by:2E0AQU
ID: 24735180
Hi Jason

Thanks for the reply, it sounds nice and easy that way but having just spent the last hour searching the web for a free to user link and having no luck im not so sure, i dont suppose you know of any links for such a script.?
regards
Paul
0
[Webinar] Lessons on Recovering from Petya

Skyport is working hard to help customers recover from recent attacks, like the Petya worm. This work has brought to light some important lessons. New malware attacks like this can take down your entire environment. Learn from others mistakes on how to prevent Petya like worms.

 
LVL 30

Expert Comment

by:IanTh
ID: 24735276
see my comments as well

use pear mail
and heres a script to read all the elements on the form
it works I am using it on a current web project
it will work if the server has a mail component installed and as I said if you install apache on a old pc or a virtual pc you can install pear mail to act as a mail server to parse the php script
<?php
//--------------------------Set these paramaters--------------------------
 
// Subject of email sent to you.
$subject = 'form from Oswald Inns'; 
 
// Your email address. This is where the form information will be sent. 
$emailadd = 'ian@gbpost.com'; 
$emailaddto = 'ian@gbpost.com';  
$fromadd = 'ian@ian.no1net.co.uk'; 
// Where to redirect after form is processed. 
// $url = '../thankyou.html'; 
$url = 'thankyou.html';
// Makes all fields required. If set to '1' no field can not be empty. If set to '0' any or all fields can be empty.
$req = '0'; 
 
// --------------------------Do not edit below this line--------------------------
$text = "Results from form:\n\n"; 
$space = ' ';
$line = '
';
foreach ($_POST as $key => $value)
{
if ($req == '1')
{
if ($value == '')
{echo "$key is empty. Click the back button to return to the form";die;}
}
$j = strlen($key);
if ($j >= 20)
{echo "Name of form element $key cannot be longer than 20 characters";die;}
$j = 20 - $j; 
 
for ($i = 1; $i <= $j; $i++)
{$space .= ' ';}
$value = str_replace('\n', "$line", $value);
$conc = "{$key}:$space{$value}$line";
$text .= $conc;
$space = ' ';
}
 
 
 
 
mail($emailadd, $subject, $text, "From: $fromadd", "-f".$fromadd );
mail($emailaddto, $subject, $text, "From: $fromadd", "-f".$fromadd);
echo '<META HTTP-EQUIV=Refresh CONTENT="0; URL='.$url.'">';
?>

Open in new window

0
 
LVL 30

Expert Comment

by:IanTh
ID: 24735281
see my comments as well

use pear mail
and heres a script to read all the elements on the form
it works I am using it on a current web project
it will work if the server has a mail component installed and as I said if you install apache on a old pc or a virtual pc you can install pear mail to act as a mail server to parse the php script
<?php
//--------------------------Set these paramaters--------------------------
 
// Subject of email sent to you.
$subject = 'form from Oswald Inns'; 
 
// Your email address. This is where the form information will be sent. 
$emailadd = 'ian@gbpost.com'; 
$emailaddto = 'ian@gbpost.com';  
$fromadd = 'ian@ian.no1net.co.uk'; 
// Where to redirect after form is processed. 
// $url = '../thankyou.html'; 
$url = 'thankyou.html';
// Makes all fields required. If set to '1' no field can not be empty. If set to '0' any or all fields can be empty.
$req = '0'; 
 
// --------------------------Do not edit below this line--------------------------
$text = "Results from form:\n\n"; 
$space = ' ';
$line = '
';
foreach ($_POST as $key => $value)
{
if ($req == '1')
{
if ($value == '')
{echo "$key is empty. Click the back button to return to the form";die;}
}
$j = strlen($key);
if ($j >= 20)
{echo "Name of form element $key cannot be longer than 20 characters";die;}
$j = 20 - $j; 
 
for ($i = 1; $i <= $j; $i++)
{$space .= ' ';}
$value = str_replace('\n', "$line", $value);
$conc = "{$key}:$space{$value}$line";
$text .= $conc;
$space = ' ';
}
 
 
 
 
mail($emailadd, $subject, $text, "From: $fromadd", "-f".$fromadd );
mail($emailaddto, $subject, $text, "From: $fromadd", "-f".$fromadd);
echo '<META HTTP-EQUIV=Refresh CONTENT="0; URL='.$url.'">';
?>

Open in new window

0
 
LVL 70

Accepted Solution

by:
Jason C. Levine earned 2000 total points
ID: 24737962
Hi Paul,

A simple Google search produces the following.  I would trust the first link above the others.

http://cgi.resourceindex.com/Remotely_Hosted/Form_Processing/

http://www.scripts.com/remotely-hosted-scripts/form-processor-scripts/

http://www.scriptgateway.com/scripts/remotely_hosted_scripts/c666-form_processors-download.html

http://www.developertutorials.com/scripts/637/666/

--------------

As far as a specific recommendation, I have seen people use http://www3.formassembly.com/ to good effect but I think that is more of a form generator than a remotely hosted solution.  It does remotely process the forms but I am not sure you can hook a user-generated form to it.

The other product you should look into is http://www.formbuddy.com/

0
 

Author Closing Comment

by:2E0AQU
ID: 31598297
Thanks Jason and thanks Ian too,
Jasons links , the first one on the list , works like a charm. I have just tryed it with a simple form made in dreamweaver and it went straight to the emal address i wanted so many thanks for the help.
0

Featured Post

New benefit for Premium Members - Upgrade now!

Ready to get started with anonymous questions today? It's easy! Learn more.

Question has a verified solution.

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

For those who don't know, Adobe Dreamweaver is a popular commercial web editor that enables you to design, build and manage complex websites. The editor is a WYSIWYG (What You See Is What You Get) web editor, which means that you can create your web…
This article is very specific and is only intended to help if you are installing Dreamweaver 8 in a Windows 7 environment with Office 2007 installed.   I'm not sure why Microsoft tends to release OS' that should not be released but they do.  Windows…
Monitoring a network: how to monitor network services and why? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the philosophy behind service monitoring and why a handshake validation is critical in network monitoring. Software utilized …
Have you created a query with information for a calendar? ... and then, abra-cadabra, the calendar is done?! I am going to show you how to make that happen. Visualize your data!  ... really see it To use the code to create a calendar from a q…

715 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