News:

Support the VirtueMart project and become a member

Main Menu

Editing Customer registration email

Started by MaHe29, January 27, 2012, 15:17:17 PM

Previous topic - Next topic

MaHe29

When a user creates an account he/she receive an confirmation mail.
I have a few issues with the layout and output in the confirmation email.
The email doesnt use a header and a footer like the order confirmation mail. This way the email doesnt realy match the layout or housestyle of the webshop. Making the mail look less proffesional and correlating with the website.

Also it displays the user details 2 times.
Like this:
Land: Nederland
Nederland

Translation
Country: The Netherlands
The Neherlands


So i gues there is something wrong with the HTML code of mail_html_reguser.php
This is the part of the code i think is responsible for the wrong output, but my html knowledge isnt enough to make the correction.

                foreach ($this->userFields['fields'] as $userField) {
               if (!empty($userField['value']) && $userField['type'] != 'delimiter' && $userField['type'] != 'BT' && $userField['type'] != 'hidden') {
                   echo $userField['title'] . ': ' . $userField['value'] . $li;
                   ?>
                   <span class="values vm2<?php echo '-' . $userField['name'] ?>" ><?php echo $this->escape($userField['value']) ?></span>
                   <?php if ($userField['name'] != 'title' and $userField['name'] != 'first_name' and $userField['name'] != 'middle_name' and $userField['name'] != 'zip') { ?>
                       <br class="clear" />
                  <?php
                   }
               }
                }
                ?>


I'm hoping some wizkid can help me out. ;-)

MaHe29

I've edited the code like this. I'm not sure if 100% correct, but it seems to work

                foreach ($this->userFields['fields'] as $userField) {
               if (!empty($userField['value']) && $userField['type'] != 'delimiter' && $userField['type'] != 'BT' && $userField['type'] != 'hidden') {echo $userField['title'] . ': ' . $userField['value'] . $li;?><span class="values vm2<?php echo '-' . $userField['name'] ?>" >          <?php if ($userField['name'] != 'title' and $userField['name'] != 'first_name' and $userField['name'] != 'middle_name' and $userField['name'] != 'zip') { ?>                   <?php
                   }
               }
                }
                ?>

mojino

Hello Mahe29,
I had the same problem and your code seems to fix it.
Thanks.