WordPress.org

Ready to get started?Download WordPress

Forums

Contact Form 7
[resolved] is it possible to replace the form after submitting ? (19 posts)

  1. roycegracie
    Member
    Posted 2 years ago #

    hi, i want the form to disappear after submitting and a "thank you" message to appear...
    is it possible ?

    http://wordpress.org/extend/plugins/contact-form-7/

  2. CaroVonChaos
    Member
    Posted 2 years ago #

    Would love to know that too!

  3. roycegracie
    Member
    Posted 2 years ago #

    hi... i made this happen in my site...
    send me an email and i'll send you my code...

  4. AnteJ
    Member
    Posted 2 years ago #

    hi, is it possible to edit after submitting form for just one contact form on webpage trough css?

  5. mytorontocondos
    Member
    Posted 2 years ago #

    @zeevm.co.il

    I am new to this and i don't know how to email you directly. I clicked onto your name and it only gave me your thread posts and recent replies.

    i am interested in that code you have!

    Please and thank you!

  6. AnteJ
    Member
    Posted 2 years ago #

    Hi,

    you can download plugin from here http://wordpress.org/extend/plugins/contact-form-7/ and see code.

  7. roycegracie
    Member
    Posted 2 years ago #

    AnteJ. what they want is that form to disappear after submitting with a thank you massege.... i made this happen , you can see it here in this trial website i'm building this days:
    http://lighthost.zeevm.co.il/?page_id=49

    you can fill in the fields and a thank you massage will replace the form

    i uploaded the files in my plugin here:
    http://www.megaupload.com/?d=ZMNXZGYU

    and here is the code that goes inside the contact form admin pannel (sorry it's all in hebrew)

    [Code moderated as per the Forum Rules. Please use the pastebin]

  8. mytorontocondos
    Member
    Posted 2 years ago #

    @zeevm.co.il

    Thank you so much!

    How do i change it to English?

  9. roycegracie
    Member
    Posted 2 years ago #

    well... just install the plugin... if you want my form content you can take if from here:
    http://pastebin.com/DFQNs99D

    the name of the form is "BIG":
    [contact-form-7 id="195" title="BIG"]

    i guess this is all you need

  10. mytorontocondos
    Member
    Posted 2 years ago #

    So i ended up copying fromt http://pastebin.com/DFQN99D but you're right, its in hebrew.

    How can i change the autoreply to english? i somehow customized it the way i want it but its in hebrew.

    The code for the form that i got is:
    [contact-form-7 id="86" title="Untitled"]

    Many Thanks!

  11. AnteJ
    Member
    Posted 2 years ago #

    Hi, thank you for update. Please can you tell me what files are changed in plugin?

  12. roycegracie
    Member
    Posted 2 years ago #

    in the file "scripts.js" on line 45 i put:

    " $('div.wpcf7').parent().html("<div class=\"form_success\"><hr class=\"special_tag\" noshade=\"noshade\" /><div>thank you!</div>i will contact you soon.<hr class=\"special_tag\" noshade=\"noshade\" /></div>");"
  13. AnteJ
    Member
    Posted 2 years ago #

    Thank you, very helpfull.

  14. mytorontocondos
    Member
    Posted 2 years ago #

    I am still very confused.

    1. Where do i find the script in the contact form 7 folder?
    2. What do i put in order to make it to English?

    I have been trying very hard to change it around but for some reason, its not working properly.

    Please kindly help!

  15. roycegracie
    Member
    Posted 2 years ago #

    hi mate... there is a scripts.js file in the main folder of the plugin...
    on line 44 you can find this code:

    if (1 == data.mailSent) {
    						$(data.into).find('form').resetForm().clearForm();
    						ro.addClass('wpcf7-mail-sent-ok');

    replace it with:

    if (1 == data.mailSent) {
    						$(data.into).find('form').resetForm().clearForm();
    						$('div.wpcf7').parent().html("<div class=\"form_success\"><hr class=\"special_tag\" noshade=\"noshade\" /><div></div><hr class=\"special_tag\" noshade=\"noshade\" /></div>");
    						ro.addClass('wpcf7-mail-sent-ok');
  16. roycegracie
    Member
    Posted 2 years ago #

    and then in the you can see that this way the code is looking for a class called "form_success" and "special_tag"...
    so you need some CSS for this classes... go to your theme style.css and add this code:

    /* form success message */
    
    .form_success {
    	direction: rtl;
    	text-align: right;
    	padding: 8px 0;
    	font-weight: bold;
    	color: #fff;
    	position: relative;
    	top: 99px;
    	font-size: 14px;
    	line-height: 18px;
    }
    
    .form_success div {
    	color: #000;
    	background: url(img/more/thank_you.png) left top no-repeat transparent;
    	height: 34px;
    	margin: 10px 0 2px 0;
    }
    
    .form_success .special_tag {
    	background-image: url(img/more/dotting2.gif);
    }

    i added the "special_tag" but you don't need it..

    you can change this code if you wish....

    hope this help people, sorry for my bad english

  17. mytorontocondos
    Member
    Posted 2 years ago #

    Thank you so much for helping me!

    So i did what you told me to do and reloaded it into wordpress using ftp. Once i did it, it seems to be the same. I made a new contact form with the following pasted:

    <div class="form_wrap">
    <p>
    <div class="field">
    <span>name*:</span>[text* your-name]
    </div>
    <div class="field">
    <span>phone*:</span>[text* text-979]
    </div>
    </p>
    <p>
    <div class="field">
    <span>email*:</span>[email* your-email]
    </div>
    <div class="field">
    <span>comments:</span>[textarea your-message class:zeevff]
    </div>
    </p>
    </div>
    <div class="form_btn"><input type="submit" value=" " class="wpcf7-submit" onmouseover="this.className='wpcf7-submit hover'" onmouseout="this.className='wpcf7-submit'" /></div>
    <div class="ps">* required field</div>

    For some reason, the "send" button is gone and also, i don't get the comment after submitting the form anymore. I did used to get it in hebrew but even that is gone now.

    Please kindly advise.

    Thank you!

  18. roycegracie
    Member
    Posted 2 years ago #

    hi, well... you are using my button, wich is a picture... you don't need it. and in my form there is no notice messeges...

    you can just install a new contact form 7 and do the things i showd you before...

    see this code:

    <input type="submit" value=" " class="wpcf7-submit" onmouseover="this.className='wpcf7-submit hover'" onmouseout="this.className='wpcf7-submit'" />

    he is in charge of the submit button, you can just use the normal contact form submit button (you can create a new form and copy the code from there)

  19. mytorontocondos
    Member
    Posted 2 years ago #

    I manage to get the submit button to "send" button as the original contact form 7.

    I am still not getting the message after sending or submitting the form.

    This is so confusing. -_-"

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic