Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie
Hi all,
Vanilla are planning an update to the site on April 24th (next Wednesday). It is a major PHP8 update which is expected to boost performance across the site. The site will be down from 7pm and it is expected to take about an hour to complete. We appreciate your patience during the update.
Thanks all.

website form "submit"

Options
  • 10-08-2020 8:28pm
    #1
    Registered Users Posts: 861 ✭✭✭


    I downloaded a Dreamweaver template website and altered it for my needs. I know a little html so I just went into code and changed colours and a little copy and paste etc. Nothing fancy. Changed the pics and wording. I didnt really use the functions in dreamweaver.

    I made a basic website before using just html and I remember I used basic code for a contact form. This was all way before html5. The template I got came with a contact form. How do I get this form to send me an email with the details. I don't need it to be secure, its just name, email and message, no passwords etc.

    I don't understand what a php page is but I can copy and paste and follow instructions.

    I'll upload a pic of the code that I have. Let me know if you need more details.

    Any help on this matter would be great.

    Thanks in advance


Comments

  • Closed Accounts Posts: 9,700 ✭✭✭tricky D


    You could use a form plugin. Search for 'contact form plugin widget html' and check out the non-Wordpress ones.


  • Registered Users Posts: 861 ✭✭✭Zenify


    It looks like a plug in would give me a whole new form. I already have all the code for the form. I've also spent a lot of time customising it and really like how it looks. I was hoping it wouldn't be too difficult to alter it for sending an email


  • Registered Users Posts: 90 ✭✭iioklo


    PHP is a server side language that will receive the data posted in your form and process it e.g save it to a database or send it on in an email as you desire.

    You need to change the form action from # to point to the PHP page that will process your form data e.g form.php

    form.php
    $name = $_POST["name"];
    $email = $_POST["email"];
    $message = $_POST["message"]; 
    
    echo $name .'<br>';
    
    echo $email .'<br>';
    
    echo $message .'<br>';
    
    
    
    
    This is a small script that will capture the form data and echo it back to your screen just for testing purposes.

    TUTORIAL:
    https://htmldog.com/techniques/formtoemail/


  • Closed Accounts Posts: 9,700 ✭✭✭tricky D


    Zenify wrote: »
    It looks like a plug in would give me a whole new form. I already have all the code for the form. I've also spent a lot of time customising it and really like how it looks. I was hoping it wouldn't be too difficult to alter it for sending an email
    Whole new form in its own section.
    iioklo wrote: »
    PHP is a server side language that will receive the data posted in your form and process it e.g save it to a database or send it on in an email as you desire.

    You need to change the form action from # to point to the PHP page that will process your form data e.g form.php

    form.php
    $name = $_POST["name"];
    $email = $_POST["email"];
    $message = $_POST["message"]; 
    
    echo $name .'<br>';
    
    echo $email .'<br>';
    
    echo $message .'<br>';
    
    
    
    
    This is a small script that will capture the form data and echo it back to your screen just for testing purposes.

    TUTORIAL:
    https://htmldog.com/techniques/formtoemail/
    There are no sent or error pages options and could be open for spam. Also any dive into php might be a step too far for the op.


    A separate thing you might not have covered by using Dreamweaver is if it works on mobile which is very important these days.


  • Registered Users Posts: 861 ✭✭✭Zenify


    Am I allowed to add a link to the website folder on onedrive to ask for help with it here?

    Would there be any security concerns?

    In relation to how it looks on a mobile - yes it is completely responsive. It was a very nice template.

    As I mentioned before PHP is way above my head, I know a method is to be place that # with a PHP file address but i have no idea how to create that PHP file. If I had a template or instructions I could probably follow. I'll have a look at the link above.


  • Advertisement
  • Registered Users Posts: 861 ✭✭✭Zenify


    This was the template I started with

    https://templated.co/retrospect

    and this is where I am now

    https://1drv.ms/u/s!AkoCh_r6-uTwiDue4EUrVZ0UGc2I?e=AmVZVO


    Obviously its not finished. I just have the Layout pretty much done. Its my partners business so she now has to do the text.

    So if anyone could give me instructions on how to get the contact form to work it would be great. Any other advice would really be welcomed too as I have no experience in this stuff. I bought the domain with Blacknight but I havent put it up yet.


Advertisement