Jump to content

B.K

Members
  • Content count

    3
  • Joined

  • Last visited

Everything posted by B.K

  1. Hi and sorry for my late answer. - I had the same problems described above. indeed, a ligne is missing in the database file that define the newsletters_to_products file. - Also care of p.products_image2 (normally p.products_image) ! - rename newsletter_id by newsletters_id in the newsletters_to_products database. I still haven't manage to join the content of my newsletter with my template in the preview step, I've got only the product. I'm woking on it. Special prices are present, it's great. See you
  2. HI, first of all, sorry for my bad english :lol: Next the solution : 1. How I've proceed : at the end of the file while ($mail = tep_db_fetch_array($mail_query)) { $mimemessage = new email(array('X-Mailer: osCommerce bulk mailer')); $mimemessage->add_html($this->content.'<br><br><div align="center"> YOUR TEXT<br>'.'<a href="'.HTTP_SERVER.DIR_WS_CATALOG.THE NAME OF THE FILE YOU WANT THE RECEIVER TO GO.'?email='.$mail['email'].'">Stop receiving the news</a></div>'); $mimemessage->build_message(); $mimemessage->send('', $mail['email'], 'XXXX' . ' ', EMAIL_FROM, $this->title); } You are likely to replace email or $mail by the name you have in your database. 2. Just let your pictures on a folder in your web site, and in your template put a link like <img src ="http://www.mysite/images/mypicture.jpg"> Hope I've been useful :-"
  3. Hi ! As a french user, I'll try my best english :lol: This contribution is more than useful, and I manage to display the prices in the newsletter following the several advices in the topic. But there is one thing left : I haven't succeded in displaying specials prices. Here are the relevant code : $current_products_query = tep_db_query("select p.products_id, pd.products_name, p.products_image, p.products_price, p.products_tax_class_id, if(s.status, s.specials_new_products_price, NULL) as specials_price from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd left join " . TABLE_SPECIALS . " s on p.products_id = s.products_id where pd.products_id = p.products_id and p.products_id in(" . $p_string . ") and pd.language_id=" . $languages_id); $product_query = tep_db_query("select p.products_id, pd.products_name, p.products_image, p.products_price, p.products_tax_class_id, if(s.status, s.specials_new_products_price, NULL) as specials_price from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd left join " . TABLE_SPECIALS . " s on p.products_id = s.products_id where pd.products_id = p.products_id and p.products_id in(" . $p_string . ") and pd.language_id=" . $languages_id); if ($this->products != ''){ $images_query = tep_db_query("select p.products_id, pd.products_name, p.products_image, p.products_price, p.products_tax_class_id from " . TABLE_PRODUCTS . " p, " . TABLE_PRODUCTS_DESCRIPTION . " pd where pd.products_id = p.products_id and p.products_id in(" . $this->products . ")"); } while($images = tep_db_fetch_array($images_query)){ if($col > COLS-1){ $html_content .= '</tr><tr><td class="content" align="center" width="' . $width . '%"><a href="' . tep_catalog_href_link(FILENAME_PRODUCT_INFO, 'products_id=' . $images['products_id']) . '" class="content">' . tep_image(HTTP_CATALOG_SERVER . DIR_WS_NORMAL_IMAGES . $images['products_image'], $images['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT) . '<br>' . $images['products_name'] . '<br>' . $currencies->display_price($images['products_price'], tep_get_tax_rate($images['products_tax_class_id'])) . $specials_price->$product['specials_price'] .'</a></td>'; $html_content .= (!empty($images['specials_price'])) ? '<s>' . $images['specials_price'] . '</s>' : ''; $col = 0; }else{ $html_content .= '<td class="content" align="center" width="' . $width . '%"><a href="' . tep_catalog_href_link(FILENAME_PRODUCT_INFO, 'products_id=' . $images['products_id']) . '" class="content">' . tep_image(HTTP_CATALOG_SERVER . DIR_WS_NORMAL_IMAGES . $images['products_image'], $images['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT) . '<br>' . $images['products_name'] . '<br>' . $currencies->display_price($images['products_price'], tep_get_tax_rate($images['products_tax_class_id'])) . $specials_price->$product['specials_price'] .'</a></td>'; $html_content .= (!empty($images['specials_price'])) ? '<s>' . $images['specials_price'] . '</s>' : ''; } $col++; } Thanks to those who will take time to help me !
×