Send copy of contact us form with checkboxAdmin order create: Shipping same as Billing always checked: can I clear that?Custom contact form not working with magento installationContact form: Getting error even though email is sentContact Form return me “Unable to submit your request. Please, try again later”Regions dropdown in account creation formHow to create a form on the frontend of a magento storeCan't send sku on contact formMagento checkout and autofill field unwanted resultsSend email depending on selected option in Contact formMagento 2: How to submit form on checkbox click?

Natural Armour and Weapons

What could a self-sustaining lunar colony slowly lose that would ultimately prove fatal?

Why did other houses not demand this?

Is there a context where the expression `a.b::c` makes sense?

Why would a rational buyer offer to buy with no conditions precedent?

Why was this character made Grand Maester?

What does kpsewhich stand for?

Why A=2 and B=1 in the call signs for Spirit and Opportunity?

Can a person survive on blood in place of water?

Why haven't we yet tried accelerating a space station with people inside to a near light speed?

Python program to take in two strings and print the larger string

What are Antecedent & Consequent Phrases in Music?

Can you output map values in visualforce inline using a string key?

Should there be an "a" before "ten years imprisonment"?

Making a electromagnet

Why is the Eisenstein ideal paper so great?

How can I make an argument that my time is valuable?

Do photons bend spacetime or not?

Can I tell a prospective employee that everyone in the team is leaving?

Is it legal to have an abortion in another state or abroad?

Need to read my home electrical Meter

Are there any German nonsense poems (Jabberwocky)?

What weight should be given to writers groups critiques?

Dealing with spaghetti codebase, manager asks for things I can't deliver



Send copy of contact us form with checkbox


Admin order create: Shipping same as Billing always checked: can I clear that?Custom contact form not working with magento installationContact form: Getting error even though email is sentContact Form return me “Unable to submit your request. Please, try again later”Regions dropdown in account creation formHow to create a form on the frontend of a magento storeCan't send sku on contact formMagento checkout and autofill field unwanted resultsSend email depending on selected option in Contact formMagento 2: How to submit form on checkbox click?






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;








0















I am using Magento's contact us form, which, at the moment, doesn't send a copy of the contact us form to the customer who is filling the form in.



I want to control this with a checkbox, therefore i have added a checkbox to the form.phtml page:



<input type="checkbox" name="sendcopy" value="Yes" checked/>


How can i configure the send e-mail function so that it sends out a copy (to the e-mail address which is filled in, in the e-mail field of the contact form) of the e-mail when the checkbox is checked, and doesn't send a copy when it is not checked?










share|improve this question






























    0















    I am using Magento's contact us form, which, at the moment, doesn't send a copy of the contact us form to the customer who is filling the form in.



    I want to control this with a checkbox, therefore i have added a checkbox to the form.phtml page:



    <input type="checkbox" name="sendcopy" value="Yes" checked/>


    How can i configure the send e-mail function so that it sends out a copy (to the e-mail address which is filled in, in the e-mail field of the contact form) of the e-mail when the checkbox is checked, and doesn't send a copy when it is not checked?










    share|improve this question


























      0












      0








      0








      I am using Magento's contact us form, which, at the moment, doesn't send a copy of the contact us form to the customer who is filling the form in.



      I want to control this with a checkbox, therefore i have added a checkbox to the form.phtml page:



      <input type="checkbox" name="sendcopy" value="Yes" checked/>


      How can i configure the send e-mail function so that it sends out a copy (to the e-mail address which is filled in, in the e-mail field of the contact form) of the e-mail when the checkbox is checked, and doesn't send a copy when it is not checked?










      share|improve this question
















      I am using Magento's contact us form, which, at the moment, doesn't send a copy of the contact us form to the customer who is filling the form in.



      I want to control this with a checkbox, therefore i have added a checkbox to the form.phtml page:



      <input type="checkbox" name="sendcopy" value="Yes" checked/>


      How can i configure the send e-mail function so that it sends out a copy (to the e-mail address which is filled in, in the e-mail field of the contact form) of the e-mail when the checkbox is checked, and doesn't send a copy when it is not checked?







      magento-1.7 forms send-mail






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Mar 29 '15 at 14:12









      Amit Bera

      60.7k1682181




      60.7k1682181










      asked Mar 29 '15 at 13:14









      JohnJohn

      52111




      52111




















          2 Answers
          2






          active

          oldest

          votes


















          0














          You can do this by using bcc function addBcc($post['email]) after -setReplyTo($post['email']) at class Mage_Contacts_IndexController of function postAction().



          $mailTemplate = Mage::getModel('core/email_template');
          /* @var $mailTemplate Mage_Core_Model_Email_Template */
          $mailTemplate->setDesignConfig(array('area' => 'frontend'))
          ->setReplyTo($post['email'])
          <!-- add this -->
          ->addBcc($post['email'])
          ->sendTransactional(
          Mage::getStoreConfig(self::XML_PATH_EMAIL_TEMPLATE),
          Mage::getStoreConfig(self::XML_PATH_EMAIL_SENDER),
          Mage::getStoreConfig(self::XML_PATH_EMAIL_RECIPIENT),
          null,
          array('data' => $postObject)
          );





          share|improve this answer

























          • Thanks, i understand this part will send the e-mail as BCC to the sender. How can i build in the check, that this function will only be active when the checkbox is checked?

            – John
            Mar 29 '15 at 14:59












          • yes. this can do this bcc

            – Amit Bera
            Mar 29 '15 at 15:00












          • I have added the line, but no e-mail is being sent unfortunately.

            – John
            Mar 29 '15 at 18:42


















          0














          I would not recommend this. What's to stop a bot filling out spam content, someone else's email, ticking the box and turning your magento store into a spam server.



          If you do decide to do this make sure you have captcha on the form.






          share|improve this answer























            Your Answer








            StackExchange.ready(function()
            var channelOptions =
            tags: "".split(" "),
            id: "479"
            ;
            initTagRenderer("".split(" "), "".split(" "), channelOptions);

            StackExchange.using("externalEditor", function()
            // Have to fire editor after snippets, if snippets enabled
            if (StackExchange.settings.snippets.snippetsEnabled)
            StackExchange.using("snippets", function()
            createEditor();
            );

            else
            createEditor();

            );

            function createEditor()
            StackExchange.prepareEditor(
            heartbeatType: 'answer',
            autoActivateHeartbeat: false,
            convertImagesToLinks: false,
            noModals: true,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: null,
            bindNavPrevention: true,
            postfix: "",
            imageUploader:
            brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
            contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
            allowUrls: true
            ,
            onDemand: true,
            discardSelector: ".discard-answer"
            ,immediatelyShowMarkdownHelp:true
            );



            );













            draft saved

            draft discarded


















            StackExchange.ready(
            function ()
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmagento.stackexchange.com%2fquestions%2f62282%2fsend-copy-of-contact-us-form-with-checkbox%23new-answer', 'question_page');

            );

            Post as a guest















            Required, but never shown

























            2 Answers
            2






            active

            oldest

            votes








            2 Answers
            2






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes









            0














            You can do this by using bcc function addBcc($post['email]) after -setReplyTo($post['email']) at class Mage_Contacts_IndexController of function postAction().



            $mailTemplate = Mage::getModel('core/email_template');
            /* @var $mailTemplate Mage_Core_Model_Email_Template */
            $mailTemplate->setDesignConfig(array('area' => 'frontend'))
            ->setReplyTo($post['email'])
            <!-- add this -->
            ->addBcc($post['email'])
            ->sendTransactional(
            Mage::getStoreConfig(self::XML_PATH_EMAIL_TEMPLATE),
            Mage::getStoreConfig(self::XML_PATH_EMAIL_SENDER),
            Mage::getStoreConfig(self::XML_PATH_EMAIL_RECIPIENT),
            null,
            array('data' => $postObject)
            );





            share|improve this answer

























            • Thanks, i understand this part will send the e-mail as BCC to the sender. How can i build in the check, that this function will only be active when the checkbox is checked?

              – John
              Mar 29 '15 at 14:59












            • yes. this can do this bcc

              – Amit Bera
              Mar 29 '15 at 15:00












            • I have added the line, but no e-mail is being sent unfortunately.

              – John
              Mar 29 '15 at 18:42















            0














            You can do this by using bcc function addBcc($post['email]) after -setReplyTo($post['email']) at class Mage_Contacts_IndexController of function postAction().



            $mailTemplate = Mage::getModel('core/email_template');
            /* @var $mailTemplate Mage_Core_Model_Email_Template */
            $mailTemplate->setDesignConfig(array('area' => 'frontend'))
            ->setReplyTo($post['email'])
            <!-- add this -->
            ->addBcc($post['email'])
            ->sendTransactional(
            Mage::getStoreConfig(self::XML_PATH_EMAIL_TEMPLATE),
            Mage::getStoreConfig(self::XML_PATH_EMAIL_SENDER),
            Mage::getStoreConfig(self::XML_PATH_EMAIL_RECIPIENT),
            null,
            array('data' => $postObject)
            );





            share|improve this answer

























            • Thanks, i understand this part will send the e-mail as BCC to the sender. How can i build in the check, that this function will only be active when the checkbox is checked?

              – John
              Mar 29 '15 at 14:59












            • yes. this can do this bcc

              – Amit Bera
              Mar 29 '15 at 15:00












            • I have added the line, but no e-mail is being sent unfortunately.

              – John
              Mar 29 '15 at 18:42













            0












            0








            0







            You can do this by using bcc function addBcc($post['email]) after -setReplyTo($post['email']) at class Mage_Contacts_IndexController of function postAction().



            $mailTemplate = Mage::getModel('core/email_template');
            /* @var $mailTemplate Mage_Core_Model_Email_Template */
            $mailTemplate->setDesignConfig(array('area' => 'frontend'))
            ->setReplyTo($post['email'])
            <!-- add this -->
            ->addBcc($post['email'])
            ->sendTransactional(
            Mage::getStoreConfig(self::XML_PATH_EMAIL_TEMPLATE),
            Mage::getStoreConfig(self::XML_PATH_EMAIL_SENDER),
            Mage::getStoreConfig(self::XML_PATH_EMAIL_RECIPIENT),
            null,
            array('data' => $postObject)
            );





            share|improve this answer















            You can do this by using bcc function addBcc($post['email]) after -setReplyTo($post['email']) at class Mage_Contacts_IndexController of function postAction().



            $mailTemplate = Mage::getModel('core/email_template');
            /* @var $mailTemplate Mage_Core_Model_Email_Template */
            $mailTemplate->setDesignConfig(array('area' => 'frontend'))
            ->setReplyTo($post['email'])
            <!-- add this -->
            ->addBcc($post['email'])
            ->sendTransactional(
            Mage::getStoreConfig(self::XML_PATH_EMAIL_TEMPLATE),
            Mage::getStoreConfig(self::XML_PATH_EMAIL_SENDER),
            Mage::getStoreConfig(self::XML_PATH_EMAIL_RECIPIENT),
            null,
            array('data' => $postObject)
            );






            share|improve this answer














            share|improve this answer



            share|improve this answer








            edited Mar 29 '15 at 14:59

























            answered Mar 29 '15 at 14:46









            Amit BeraAmit Bera

            60.7k1682181




            60.7k1682181












            • Thanks, i understand this part will send the e-mail as BCC to the sender. How can i build in the check, that this function will only be active when the checkbox is checked?

              – John
              Mar 29 '15 at 14:59












            • yes. this can do this bcc

              – Amit Bera
              Mar 29 '15 at 15:00












            • I have added the line, but no e-mail is being sent unfortunately.

              – John
              Mar 29 '15 at 18:42

















            • Thanks, i understand this part will send the e-mail as BCC to the sender. How can i build in the check, that this function will only be active when the checkbox is checked?

              – John
              Mar 29 '15 at 14:59












            • yes. this can do this bcc

              – Amit Bera
              Mar 29 '15 at 15:00












            • I have added the line, but no e-mail is being sent unfortunately.

              – John
              Mar 29 '15 at 18:42
















            Thanks, i understand this part will send the e-mail as BCC to the sender. How can i build in the check, that this function will only be active when the checkbox is checked?

            – John
            Mar 29 '15 at 14:59






            Thanks, i understand this part will send the e-mail as BCC to the sender. How can i build in the check, that this function will only be active when the checkbox is checked?

            – John
            Mar 29 '15 at 14:59














            yes. this can do this bcc

            – Amit Bera
            Mar 29 '15 at 15:00






            yes. this can do this bcc

            – Amit Bera
            Mar 29 '15 at 15:00














            I have added the line, but no e-mail is being sent unfortunately.

            – John
            Mar 29 '15 at 18:42





            I have added the line, but no e-mail is being sent unfortunately.

            – John
            Mar 29 '15 at 18:42













            0














            I would not recommend this. What's to stop a bot filling out spam content, someone else's email, ticking the box and turning your magento store into a spam server.



            If you do decide to do this make sure you have captcha on the form.






            share|improve this answer



























              0














              I would not recommend this. What's to stop a bot filling out spam content, someone else's email, ticking the box and turning your magento store into a spam server.



              If you do decide to do this make sure you have captcha on the form.






              share|improve this answer

























                0












                0








                0







                I would not recommend this. What's to stop a bot filling out spam content, someone else's email, ticking the box and turning your magento store into a spam server.



                If you do decide to do this make sure you have captcha on the form.






                share|improve this answer













                I would not recommend this. What's to stop a bot filling out spam content, someone else's email, ticking the box and turning your magento store into a spam server.



                If you do decide to do this make sure you have captcha on the form.







                share|improve this answer












                share|improve this answer



                share|improve this answer










                answered May 17 at 19:35









                Dominic XigenDominic Xigen

                48610




                48610



























                    draft saved

                    draft discarded
















































                    Thanks for contributing an answer to Magento Stack Exchange!


                    • Please be sure to answer the question. Provide details and share your research!

                    But avoid


                    • Asking for help, clarification, or responding to other answers.

                    • Making statements based on opinion; back them up with references or personal experience.

                    To learn more, see our tips on writing great answers.




                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function ()
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmagento.stackexchange.com%2fquestions%2f62282%2fsend-copy-of-contact-us-form-with-checkbox%23new-answer', 'question_page');

                    );

                    Post as a guest















                    Required, but never shown





















































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown

































                    Required, but never shown














                    Required, but never shown












                    Required, but never shown







                    Required, but never shown







                    Popular posts from this blog

                    Grendel Contents Story Scholarship Depictions Notes References Navigation menu10.1093/notesj/gjn112Berserkeree

                    Area configuration aggregation error after install Porto themeMagento 2.1 CE Installed but front/backend not loading/workingCSS not loading on page within Magento 2 pageCannot install module in Magento 2no commands defined in the “setup” namespace. in Magento2Magento 2: Static files are present but shows 404Why do i have to always run the commands to clean cache in Magento 2.1.8?Failure reason: 'Unable to unserialize value.'Error 500 after magento migrationIn production mode the site does not loadMagento 2 : Error 500 after installing

                    Middle Expansion Olielle Resaix Definition: Uttering songs of triumph shouting with joy triumphant exulting Sejunction Journal 붙다 달 고급 품목 외출 The stretch trades the screeching tin. Definition: The act of speaking with a drawl a drawl Cough Sand Definition: An uproar a quarrel a noisy outbreak Shake Iron Publicize Horse House Baby 사과 Resaix Flaggy Jelly Temporary Unequaled Puppet A drop in the bucket Shrew 성격 회원 성질 미팅 The burn frames the tacky quality. Materialistic The smoke reduces the way. Yammoe Nondescript Cheek 얼굴 배 약하다 날리다 타다 The illegal country shows the iron. Help Rule Drearien Smoke Teaching Meaty Wasp Abraham Lincoln Jaws 진심 수리하다 Size Cork Idea Convert Think Lark John Lennon 거울 청소 군 추천하다 아이스크림