Contact Form

This forum is only for questions or discussions about working with the mojoPortal source code in Visual Studio, obtaining the source code from the repository, developing custom features, etc. If your question is not along these lines this is not the right forum. Please try to post your question in the appropriate forum.

Please do not post questions about design, CSS, or skinning here. Use the Help With Skins Forum for those questions.

This forum is for discussing mojoPortal development

This forum is only for questions or discussions about working with the mojoPortal source code in Visual Studio, obtaining the source code from the repository, developing custom features, etc. If your question is not along these lines this is not the right forum. Please try to post your question in the appropriate forum.

You can monitor commits to the repository from this page. We also recommend developers to subscribe to email notifications in the developer forum as occasionally important things are announced.

Before posting questions here you might want to review the developer documentation.

Do not post questions about design, CSS, or skinning here. Use the Help With Skins Forum for those questions.
This thread is closed to new posts. You must sign in to post in the forums.
10/3/2019 11:06:53 AM
Gravatar
Total Posts 1

Contact Form

Dear Admin,

I am currently trying to develop contact form on mojo portal and is facing issues with linking .PHP mailer file to the website.

I am having a problem receiving the submitted form.

When using Iframe with the exact code, I am able to recieve the submitted forms. So my feeling is I am not able to link to .PHP mailer file when i link it on the html coding.

Can you help me?

Below is the code I am using:

<center>Contact Us</center>

<p>&nbsp;</p>

<center>Please specify your preferred mode of contact and we will respond as quickly as possible!</center>
&nbsp;

<form action="/Data/Sites/1/media/formS2/contact-3.php" id="contactForm" method="post" role="form">
<div class="messages">&nbsp;</div>

<div class="controls">
<div class="row">
<div class="col-md-2">
<div class="form-group"><select aria-invalid="false" aria-required="true" id="form_titles" name="title" style="width:150px; border :0; outline:0; background: transparent; border-bottom: 0;"><option selected="selected" value="Mr">Mr</option><option selected="selected" value="Mrs">Mrs</option><option selected="selected" value="Ms">Ms</option><option selected="selected" value="Title">*Title</option> </select></div>
</div>

<div class="col-md-4">
<div class="form-group"><input data-error="Firstname is required." id="form_name" name="name" placeholder="Enter your firstname *" required="required" style="width:300px;" type="text" />
<div class="help-block with-errors">&nbsp;</div>
</div>
</div>

<div class="col-md-5">
<div class="form-group"><input data-error="Lastname is required." id="form_lastname" name="surname" placeholder="Enter your lastname *" required="required" style="width:300px;" type="text" />
<div class="help-block with-errors">&nbsp;</div>
</div>
</div>
</div>
&nbsp;

<div class="row">
<div class="col-md-6">
<div class="form-group"><input data-error="Valid email is required." id="form_email" name="email" placeholder="Please enter your email *" required="required" style="width:460px;" type="email" />
<div class="help-block with-errors">&nbsp;</div>
</div>
</div>

<div class="col-md-5">
<div class="form-group"><input id="form_phone" name="phone" placeholder="Please enter your phone" style="width:300px;" type="tel" />
<div class="help-block with-errors">&nbsp;</div>
</div>
</div>
</div>
&nbsp;

<div class="row">
<div class="col-md-12">
<div class="form-group"><textarea id="form_message" name="message" placeholder="Message for me *" style="width:85%; height:100px; border:1px solid #fff;"></textarea>

<div class="help-block with-errors">&nbsp;</div>
</div>
</div>

<div class="col-md-12"><input id="agree" name="Terms and Conditions" type="checkbox" value="terms" /> *I have read and accepted the <span><a href="https://www.sweecheong.com.my/terms-and-conditions">terms and conditions and privacy policy.</a></span><br />
<input name="Marketing Information" type="checkbox" value="marketing" /> I accept receiving marketing information about Rolex from Swee Cheong Watch Sdn Bhd.
<p class="text-muted"><strong>*</strong> These fields are required.</p>
</div>

<div class="col-md-12">
<center><input class="btn btn-success btn-send" onclick="if(document.getElementById('agree').checked) { return true; } else { alert('Please indicate that you have read and agree to the Terms and Conditions and Privacy Policy'); return false; }" type="submit" value="Send message" /></center>
</div>
</div>
</div>
</form>
</div>
<!-- /.8 --></div>
<!-- /.row--></div>
<!-- /.container--><script src="https://code.jquery.com/jquery-1.12.0.min.js"></script><script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js"></script><script src="https://cdnjs.cloudflare.com/ajax/libs/1000hz-bootstrap-validator/0.11.9/validator.min.js" integrity="sha256-dHf/YjH1A4tewEsKUSmNnV05DDbfGN3g7NMq86xgGh8=" crossorigin="anonymous"></script><script src="/Data/Sites/1/media/formS2/contact-3.js"></script>

 

10/4/2019 5:11:34 PM
Gravatar
Total Posts 2253

Re: Contact Form

mojoPortal is a .net webforms application so it cannot have more than one form element on a page and every page has a form element already. You could use the Contact Form module or the Form Wizard module to create a contact form. If you must use your PHP form, you should put it in an iframe. You can put the iframe inside of a jquery or bootstrap modal as well, though it's not required.

Thanks,
Joe

You must sign in to post in the forums. This thread is closed to new posts.