Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 14 of 14
  1. #1
    New Coder
    Join Date
    Dec 2006
    Posts
    33
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Need help on making a forum

    Hey everyone! I need help on making a form in html. I have dreamweaver btw. It is easy to set up the FORM and input the options I want the user to see and select but I need help on the hard part. Is it possible, when the user press "SUMBIT" instead of opening Outlook or any other e-mail program, can it just e-mail to the "ADMIN" The admin's email will be specifed. If so, in the email it would have like .. EX:

    Name: Test
    Last Name: Ties
    Link: COolio

    ect ect..

    Thanks in advanced! It would be nice if someone can help me add an option that would make sure the user has entered valid information instead of just pressing submit.
    Last edited by PardonMe; 12-20-2006 at 06:07 PM.

  • #2
    Senior Coder
    Join Date
    Jun 2002
    Location
    The Netherlands, Baarn, Ut.
    Posts
    4,252
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Spelling

    Although they differ just one character, a "forum" and a "form" are two very different animals. Can you please clarify which one you mean?

    In advance, because it seems you're talking about a form: there are basically two ways to act upon form submission: sending it directly to an email address, and sending it to a piece of server side script that processes the form's contents.

    For the second option you'll need such a script (commonly known as a form handler); if you just want the form's contents to be mailed to a fixed email address using a specific message layout, a fairly simple form handler script could do the trick.
    Where validation is concerned, usually this is performed both client side (to save an unnecessary server trip) and server side (in case client side validation fails, and to prevent abuse), which can be part of the forementioned form handler script.
    Regards,
    Ronald.
    ronaldvanderwijden.com

  • #3
    The fat guy next door VIPStephan's Avatar
    Join Date
    Jan 2006
    Location
    Halle (Saale), Germany
    Posts
    8,728
    Thanks
    6
    Thanked 1,015 Times in 988 Posts
    To me it seems like you're not ready to create a forum by youself yet. This is a pretty advanced task and requires a lot of considerations before one can start. Plus a forum can never just consist of pure HTML (made by Dreamweaver... I hope at least you aren't just relying on the design mode? *shudder*). If you want real users to input data then you need some kind of server side script (PHP, ASP,ColdFusion...) and a database (e.g. MySQL), and THIS is the real hard part as there is a lot of stuff to think about: how to structure your website, what about security, how should people be able to interact, etc. etc.

    As to your email form: This is one of the simple parts of that but for what you want you also need some server side script. Search this forum or the internet for "PHP form mail script" or something like that and you should get some answers.

    As to the forum: There are hundreds of free forums out there. You can download an open source forum software and look into the source to get an idea on how to proceed.

    Good luck.

    Edit: Ah dammit, I was too slow again!

  • #4
    Senior Coder
    Join Date
    Jun 2002
    Location
    The Netherlands, Baarn, Ut.
    Posts
    4,252
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Too slow

    Yeah, I have that all the time... This time, I won!
    Regards,
    Ronald.
    ronaldvanderwijden.com

  • #5
    New Coder
    Join Date
    Dec 2006
    Posts
    33
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Err. I meant FORM. Like a form to select things to buy on certain sites.

  • #6
    Senior Coder whizard's Avatar
    Join Date
    Jan 2005
    Location
    Philadelphia, PA, USA
    Posts
    1,662
    Thanks
    14
    Thanked 76 Times in 76 Posts
    Quote Originally Posted by PardonMe
    Is it possible, when the user press "SUMBIT" instead of opening Outlook or any other e-mail program
    [...]
    Thanks in advanced! It would be nice if someone can help me add an option that would make sure the user has entered valid information instead of just pressing submit.
    You need to use a Server Side script language, such as PHP or ASP to do that.

    This: http://www.webligo.com/products_dynaform.php is a good, free-for-personal-use script that will send you an email without opening Outlook.

    Dan
    PHP Tip: If you want to use short tags (<? or <?=$var) then make sure short_open_tag is set to "1". It really helps.

    Don't forget to save everyone time and mark your thread as Resolved :)

    "Also note that it is your responsibility to die() if necessary."

    DON'T USE THE MYSQL_ EXTENSION

  • #7
    New Coder
    Join Date
    Dec 2006
    Posts
    33
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Thanks, I have tried but it doesn't seem to work for me. I installed it correctly but when I try to send the form, my email doesn't receieve the form submitted. Is there another way?

  • #8
    Senior Coder whizard's Avatar
    Join Date
    Jan 2005
    Location
    Philadelphia, PA, USA
    Posts
    1,662
    Thanks
    14
    Thanked 76 Times in 76 Posts
    Does your server support PHP?

    Are you sure you set all the variables correctly?

    I've used this before. It should work.

    Dan
    PHP Tip: If you want to use short tags (<? or <?=$var) then make sure short_open_tag is set to "1". It really helps.

    Don't forget to save everyone time and mark your thread as Resolved :)

    "Also note that it is your responsibility to die() if necessary."

    DON'T USE THE MYSQL_ EXTENSION

  • #9
    New Coder
    Join Date
    Dec 2006
    Posts
    33
    Thanks
    0
    Thanked 0 Times in 0 Posts
    yes my server supports php. whenever i try to send it gives me this. (I am just going to copy the code directly from the .php file since I deleted already from my server.

    // MAKE SURE DYNAFORM IS BEING RUN FROM THE RIGHT DOMAIN
    if($secure_domain_on == "yes") {
    $form_url_array = parse_url($form_url);
    $form_domain = $form_url_array[host];
    if($form_domain != $_SERVER[HTTP_HOST]) {
    echo "<h2>DynaForm Error - Invalid Domain</h2>
    You have accessed DynaForm from an external domain - this is not allowed.<br>
    You may only submit forms to a DynaForm file that exists on the same domain name.<br>
    If you believe to be receiving this message in error, please refer to your readme.txt file.
    <br><br>";
    $error = "yes";
    }
    }

    The error message inputed in the code is what I get. When I deleted it from the .php file, I could submit the form but don't actually receieve it.

  • #10
    Senior Coder whizard's Avatar
    Join Date
    Jan 2005
    Location
    Philadelphia, PA, USA
    Posts
    1,662
    Thanks
    14
    Thanked 76 Times in 76 Posts
    If you still want to use that code, try changing $secure_domain_on to 'no'

    Dan
    Last edited by whizard; 12-20-2006 at 07:27 PM. Reason: Bolded text for clarity
    PHP Tip: If you want to use short tags (<? or <?=$var) then make sure short_open_tag is set to "1". It really helps.

    Don't forget to save everyone time and mark your thread as Resolved :)

    "Also note that it is your responsibility to die() if necessary."

    DON'T USE THE MYSQL_ EXTENSION

  • #11
    New Coder
    Join Date
    Dec 2006
    Posts
    33
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Yea I did that and without that it seems to be ok without the error message. But still no e-mail being sent. DOes the e-mail have to be the server email address or can I use one like @yahoo.com? Currently use a @yahoo.com address in the script.

  • #12
    Senior Coder whizard's Avatar
    Join Date
    Jan 2005
    Location
    Philadelphia, PA, USA
    Posts
    1,662
    Thanks
    14
    Thanked 76 Times in 76 Posts
    @yahoo should be fine

    Do you have the email address/ email subject and thank you location in hidden inputs in the form, or do you have them set in the script?

    If you use the hidden inputs, $override should be set to 'no'.

    If you use the variables $incoming_mailto, $incoming_subject, and $incoming_thanks, then you need to set $override to 'yes'

    Dan
    Last edited by whizard; 12-20-2006 at 07:55 PM.
    PHP Tip: If you want to use short tags (<? or <?=$var) then make sure short_open_tag is set to "1". It really helps.

    Don't forget to save everyone time and mark your thread as Resolved :)

    "Also note that it is your responsibility to die() if necessary."

    DON'T USE THE MYSQL_ EXTENSION

  • #13
    New Coder
    Join Date
    Dec 2006
    Posts
    33
    Thanks
    0
    Thanked 0 Times in 0 Posts
    It still doesn't work.. Ill attach the example.html and the dynaform.php in a .txt format. Can you look at it and see if I set everythign correct or possibly optimize it? If so thanks!
    Attached Files Attached Files

  • #14
    Senior Coder whizard's Avatar
    Join Date
    Jan 2005
    Location
    Philadelphia, PA, USA
    Posts
    1,662
    Thanks
    14
    Thanked 76 Times in 76 Posts
    Hmm looks good really. I can't seem to figure out what is wrong.

    I'm pretty sure this is as much help as you can get for this in the HTML forum... Post this in the PHP forum and someone can probably help you out.

    Alternatively, you could find a different script, although this one is really good.

    I'm sorry that I wasn't able to help you more with this, and I hope you solve your problem!

    Dan
    PHP Tip: If you want to use short tags (<? or <?=$var) then make sure short_open_tag is set to "1". It really helps.

    Don't forget to save everyone time and mark your thread as Resolved :)

    "Also note that it is your responsibility to die() if necessary."

    DON'T USE THE MYSQL_ EXTENSION


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •