Hello,
1) You can use the same contact form for that, just changing a few things, here’s an example:
<form class="contact-form form-style-5 opacity-10" action="php/contact-form.php" method="POST"> <div class="contact-form-success alert alert-success d-none mt-4"> <strong>Success!</strong> Your message has been sent to us. </div> <div class="contact-form-error alert alert-danger d-none mt-4"> <strong>Error!</strong> There was an error sending your message. <span class="mail-error-message text-1 d-block"></span> </div> <input type="hidden" value="Newsletter" name="subject"> <input type="hidden" value="New User" name="message"> <div class="row"> <div class="form-group col"> <input class="form-control" placeholder="Email Address" name="email" id="email" type="text" /> </div> </div> <div class="row"> <div class="form-group col"> <button class="btn btn-primary btn-rounded btn-px-4 btn-py-2 font-weight-bold" type="submit">SUBSCRIBE</button> </div> </div> </form>
It will work the same way as the contact form.
2) The problem with Gmail is that Google recently changed the security mode (they do that a lot of times and the form will just stop working). To send e-mails with PHP code (PHPMAILER) and Gmail you now need to use OAuth2, which is very very complex to setup, so we do not recommend it anymore, as using an email in the same server as the site will guarantee that it will work without any problems.
Related sites and videos:
https://mailtrap.io/blog/phpmailer-gmail/
Generating an OAuth2 secret code:
youtube.com/watch?v=-rcRf7yswfM
Note this problem is not actually related to Porto, it will be the same way with any template.