Jump to content


  • Posts

  • Joined

  • Last visited

Profile Information

  • Location
  • Activity

klubas's Achievements


Newbie (1/14)



  1. Hello Richard, If I do like you say "[email protected], [email protected]" l got popup with error at front-end: Your e-mail could not be sent. Please check the e-mail address and try again. I found that this error coming from sendtoafriend-extra.tpl. What is the next step to make it work? <script type="text/javascript"> {literal} $('document').ready(function(){ $('#send_friend_button').fancybox({ 'hideOnContentClick': false }); $('#sendEmail').click(function(){ var name = $('#friend_name').val(); var email = $('#friend_email').val(); var id_product = $('#id_product_comment_send').val(); if (name && email && !isNaN(id_product)) { $.ajax({ {/literal}url: "{$module_dir}sendtoafriend_ajax.php",{literal} type: "POST", headers: {"cache-control": "no-cache"}, data: {action: 'sendToMyFriend', secure_key: '{/literal}{$stf_secure_key}{literal}', name: name, email: email, id_product: id_product},{/literal}{literal} dataType: "json", success: function(result) { $.fancybox.close(); var msg = result ? "{/literal}{l s='Your e-mail has been sent successfully' mod='sendtoafriend'}{literal}" : "{/literal}{l s='Your e-mail could not be sent. Please check the e-mail address and try again.' mod='sendtoafriend'}{literal}"; var title = "{/literal}{l s='Send to a friend' mod='sendtoafriend'}{literal}"; fancyMsgBox(msg, title); } }); }else
  2. Hello, this solution works with one email address /* Admin email sending - modified */ if (!Mail::Send((int)$module->context->cookie->id_lang, 'send_to_a_friend', sprintf(Mail::l('%1$s sent you a link to %2$s', (int)$module->context->cookie->id_lang), $customer, $product->name), $templateVars, "[email protected]", null, ... if I want to send copy to another email, it doesnt work, something is missing in the code I think /* Admin email sending - modified */ if (!Mail::Send((int)$module->context->cookie->id_lang, 'send_to_a_friend', sprintf(Mail::l('%1$s sent you a link to %2$s', (int)$module->context->cookie->id_lang), $customer, $product->name), $templateVars, "[email protected]", "[email protected]", null, null, ($module->context->cookie->email ? $module->context->cookie->email : null), ($module->context->cookie->customer_firstname ? $module->context->cookie->customer_firstname.' '.$module->context->cookie->customer_lastname : null), null, null, dirname(__FILE__).'/mails/')) die('0'); die('1'); } die('0');
  3. Hello Richard, Thank you for replay but I need example I'm just at the begining of programing.
  4. Hello, What to change in the code of module "Send to a Friend 1.7.2" that it could also send a copy of same email to the shop administrator. in the file sendtoafriend_ajax.php I found part that propably responsible for email sending..but I dont what to change there... ... /* Email sending */ if (!Mail::Send((int)$module->context->cookie->id_lang, 'send_to_a_friend', sprintf(Mail::l('%1$s sent you a link to %2$s', (int)$module->context->cookie->id_lang), $customer, $product->name), $templateVars, $friendMail, null, ... Thank you.
  5. Hello, I replaced all content in: ..\controllers\front\CategoryController.php with: <?php class CategoryController extends CategoryControllerCore { public function setMedia() { $this->context->controller->addJs(_PS_JS_DIR_.'jquery/jquery-1.7.2.min.js'); $this->context->controller->addJqueryUi('ui.accordion'); } protected function assignSubcategories() { if ($subCategories = $this->category->getSubCategories($this->context->language->id)) { foreach ($subCategories as $key => $subcat) { $subcatObj = new Category($subcat['id_category']); $subCategories[$key]['subcategories'] = $subcatObj->getSubCategories($this->context->language->id); } $this->context->smarty->assign(array( 'subcategories' => $subCategories, 'subcategories_nb_total' => count($subCategories), 'subcategories_nb_half' => ceil(count($subCategories) / 2) )); } } } and in category.tpl replaced this: {foreach from=$subcategories item=subcategory} <li class="clearfix"> <a href="{$link->getCategoryLink($subcategory.id_category, $subcategory.link_rewrite)|escape:'htmlall':'UTF-8'}" title="{$subcategory.name|escape:'htmlall':'UTF-8'}" class="img"> {if $subcategory.id_image} <img src="{$link->getCatImageLink($subcategory.link_rewrite, $subcategory.id_image, 'medium_default')|escape:'html'}" alt="" width="{$mediumSize.width}" height="{$mediumSize.height}" /> {else} <img src="{$img_cat_dir}default-medium_default.jpg" alt="" width="{$mediumSize.width}" height="{$mediumSize.height}" /> {/if} </a> <a href="{$link->getCategoryLink($subcategory.id_category, $subcategory.link_rewrite)|escape:'htmlall':'UTF-8'}" class="cat_name">{$subcategory.name|escape:'htmlall':'UTF-8'}</a> {if $subcategory.description} <p class="cat_desc">{$subcategory.description}</p> {/if} </li> {/foreach} with this: {foreach from=$subcategories item=subcategory} <h3>{$subcategory.name|escape:'htmlall':'UTF-8'}</h3> <div> <ul class="sub-menu"> {foreach from=$subcategory['subcategories'] item=subcategories} <li> <a href="{$link->getCategoryLink($subcategories.id_category, $subcategories.link_rewrite)|escape:'htmlall':'UTF-8'}">{$subcategories.name|escape:'htmlall':'UTF-8'}</a> </li> {/foreach} </ul> </div> {/foreach} Please correct me if this is wrong. Thank you.
  6. Not working on v.1.5 or I'm not doing it correctly. Need more explanation
  7. Hello, I'm also interested in solution to show subcategories together with categories like in the first post. Added photo to show sample.
  8. No this did not worked. It it is still showing 28,69eur....
  9. Dear rocky, one problem in Total price at (order_conf): now if product price (without tx) is 14,35eur and quantity is 2pcs. then total price is shown 28,69eur (not 28,70eur as should) one cent is mising... I think problem is with this line: '.Tools::displayPrice((intval($product['cart_quantity']) - $customizationQuantity) * (Product::getTaxCalculationMethod() == PS_TAX_EXC ? $price : $price_wt), $currency, false, false).'
  10. Thank you, rocky Code editing solution helped realy much! Now I can show both unit price+tx, and price-tx in same mail.
  11. dear rocky, How to make Unit price to show without tax in products table (order_conf.html) ?
  12. My situation is a little bit different from "paranoiac" mentioned in first message. I have two groups and i need to send different Design emails (order_conf) after order complete. Maybe in PaymentModule.php we can change below "'// Send an e-mail to customer"" , then we can have two templates for different groups?
  13. no solution? can we make with {if $trade} in email templates? like in this post
  • Create New...

Important Information

Cookies ensure the smooth running of our services. Using these, you accept the use of cookies. Learn More