Jump to content


Corporate Sponsors


Latest News: (loading..)

* * * * * 3 votes

Email issues


162 replies to this topic

#21 maccuda

  • Community Member
  • 75 posts
  • Real Name:Benjamin Dover

Posted 21 July 2009, 14:50

View Postaltoid, on Jul 21 2009, 01:42 PM, said:

Hello, I am having the Contact Us problems and inserted the code in post number 2. Still doesn't work. Before doing that I contacted my host and they looked into the matter and here's there response to me:



My settings are:

E-Mail Transport Method sendmail
E-Mail Linefeeds LF
Use MIME HTML When Sending Emails false
Verify E-Mail Addresses Through DNS false
Send E-Mails true

Thanks in advance for any ideas on this.

have you tried altering the contact_us.php files as suggested?
that in combination to my Host allowing scripts for email through my site did the trick for me..

#22 altoid

  • Community Member
  • 435 posts
  • Real Name:Steve
  • Gender:Male
  • Location:Pennsylvania

Posted 21 July 2009, 14:55

View Postmaccuda, on Jul 21 2009, 10:50 AM, said:

have you tried altering the contact_us.php files as suggested?
that in combination to my Host allowing scripts for email through my site did the trick for me..

Hello and yes I did alter the contact_us.php file. I put in a ticket to my host yesterday and they worked on it quite a bit, even trying out a test_email.php they wrote to see if it would go out. That worked but the Contact Us still didn't. What did your host do from their side. Perhaps there's something there that I could suggest to them.

Thanks

SK
I am not a professional webmaster or PHP coder by background or training but I will try to help as best I can.
I remember what it was like when I first started with osC. It can be overwhelming.
However, I strongly recommend considering hiring a professional for extensive site modifications, site cleaning, etc.
There are several good pros here on osCommerce. Look around, you'll figure out who they are.

#23 Indrador

  • Community Member
  • 1 posts
  • Real Name:Daniel

Posted 22 July 2009, 21:03

Hi all,

im very new with osCommerce and thought I have handled any kind of problems but i have a problem with the emails,
i haven't any idea of sending mails via php. I want a "freetext" in my confirmation mails but i have no idea how I can add a
text or where to add a txt.

I have already searched and read this topic.
I just fount in the email.php this part:

LINE
143 /**
144 * Adds plain text. Use this function
145 * when NOT sending html email
146 */
147
148 function add_text($text = '') {
149 $this->text = tep_convert_linefeeds(array("\r\n", "\n", "\r"), $this->lf, $text);
150 }

But I dont know what it means I guess I have to write this in the checkout_process.php....


Can anybody help a newbie?

Edited by Indrador, 22 July 2009, 21:04.


#24 multimixer

  • Community Sponsor
  • 3,437 posts
  • Real Name:George Zarkadas
  • Gender:Male
  • Location:Greece

Posted 23 July 2009, 04:25

View PostIndrador, on Jul 23 2009, 12:03 AM, said:

I want a "freetext" in my confirmation mails but i have no idea how I can add a
text or where to add a txt.

In post Number 3 you can read how to add text to the order confirmation email at the top and bottom. You can pick what you want and insert it to the files mentioned there. If you take the "complete" suggestion, you will have also the customers mail and phone in this email, and I think thats not bad to know.

#25 altoid

  • Community Member
  • 435 posts
  • Real Name:Steve
  • Gender:Male
  • Location:Pennsylvania

Posted 28 July 2009, 12:00

View Postmaccuda, on Jul 21 2009, 10:50 AM, said:

have you tried altering the contact_us.php files as suggested?
that in combination to my Host allowing scripts for email through my site did the trick for me..

Still working with the Contact Us page not working here. The host did some checking, ran some tests and advised the problem is probably somewhere in the php. They are probably correct. I installed a test oscommerce store yesterday and from that test store, the Contact Us page does work. So I am going to have to look through things to see what might have been changed by me in my store, via add ons, etc along the way. Thanks...
I am not a professional webmaster or PHP coder by background or training but I will try to help as best I can.
I remember what it was like when I first started with osC. It can be overwhelming.
However, I strongly recommend considering hiring a professional for extensive site modifications, site cleaning, etc.
There are several good pros here on osCommerce. Look around, you'll figure out who they are.

#26 soodanim

  • Community Member
  • 88 posts
  • Real Name:Cindy

Posted 28 July 2009, 12:22

Just wanted to say THANK YOU

I needed to include a heading into the order email and reading through I figured it out (and I am no PHP guru!)

Great to have so much help

Thanks again :)

#27 Ironhalo

  • Community Member
  • 20 posts
  • Real Name:Alan Borthwick

Posted 05 August 2009, 09:01

Hi there,

thanks for this cool list of things, i've been installing some of them and they are working great.

i just have one question;

on the thing for adding a greeting to the customer order update email, i have it set up now and its working cool.

but it puts their whole name, so it says Dear Bob Smith, what i would like to do is just have it say Dear Bob.

i had a look in the database and the orders table has the full name, so i have passed my level of knowledge.

any ideas how to do this?

cheers,

AL

#28 multimixer

  • Community Sponsor
  • 3,437 posts
  • Real Name:George Zarkadas
  • Gender:Male
  • Location:Greece

Posted 05 August 2009, 09:35

This query takes the customer name from "table_orders" of your DB
		$check_status_query = tep_db_query("select customers_name, customers_email_address, orders_status, date_purchased from " . TABLE_ORDERS . " where orders_id = '" . (int)$oID . "'");
		$check_status = tep_db_fetch_array($check_status_query);

To get just the first name, you need to change this, to get the first name from "table_customers" ie
c.customers_firstname (look at other queries about how they separate what data from what table, and how they connect different id's (ie the order_id and customers_id)

and then just do a
$customers_firstname = $check_status ['customers_firstname'];
, place it before the tep mail function and then replace there the $customers_name with $customers_firstname

I'm sorry that I do not post the complete lines of code, it's because of lack of time, maybe later I will do and post. If you succeed to do, then it would be great to post it here

#29 Ironhalo

  • Community Member
  • 20 posts
  • Real Name:Alan Borthwick

Posted 08 August 2009, 09:34

hi there,

thanks for that, i gave it a go, and could not make it work. if you have time, would you be able to post the full code?

Cheers,

AL

#30 blr044

  • Community Member
  • 1,009 posts
  • Real Name:Bennett
  • Gender:Male
  • Location:USA

Posted 22 August 2009, 18:19

I appreciated these suggestions and did incorparate in web site.

Bennett

#31 col_b

  • Community Member
  • 25 posts
  • Real Name:col_b

Posted 23 August 2009, 09:35

Hi multimixer,

I want to put a greeting into the order confirmation email, and a few extra lines of text to make it a bit more personal. However, I find that the changes I make don't seem to take effect. Even when I comment out EMAIL_SEPARATOR . "\n", the separator lines still appear. This is all I really want to add:

$email_order = EMAIL_TEXT_GREETING . ' ' . $order->customer['firstname'] . "\n\n" .
//STORE_NAME . "\n" .
//EMAIL_SEPARATOR . "\n" .
EMAIL_TEXT_ORDER_NUMBER . ' ' . $insert_id . "\n" .
EMAIL_TEXT_INVOICE_URL . ' ' . tep_href_link(FILENAME_ACCOUNT_HISTORY_INFO, 'order_id=' . $insert_id, 'SSL', false) . "\n" .
EMAIL_TEXT_DATE_ORDERED . ' ' . strftime(DATE_FORMAT_LONG) . "\n\n";

But like I say, the text_greeting doesn't appear and the separator lines still appear even thought they're commented out.

Given that you've dont such a great job here with the email mods, I wondered if this was a problem you've come accross or know why it's happening.

Cheers,
Col

#32 multimixer

  • Community Sponsor
  • 3,437 posts
  • Real Name:George Zarkadas
  • Gender:Male
  • Location:Greece

Posted 23 August 2009, 13:54

View Postcol_b, on Aug 23 2009, 12:35 PM, said:

I want to put a greeting into the order confirmation email, and a few extra lines of text to make it a bit more personal.

I don't know why this happens. Maybe you try this
$email_order .= EMAIL_TEXT_GREETING  .  '  '  .  $order->customer['firstname'] . "\n\n" .
				   //STORE_NAME . "\n" . 
								 //EMAIL_SEPARATOR . "\n" . 
								EMAIL_TEXT_ORDER_NUMBER . ' ' . $insert_id . "\n" .
								EMAIL_TEXT_INVOICE_URL .  '  '  . tep_href_link(FILENAME_ACCOUNT_HISTORY_INFO, 'order_id=' . $insert_id, 'SSL', false) . "\n" .
				 EMAIL_TEXT_DATE_ORDERED .  '  '  . strftime(DATE_FORMAT_LONG) . "\n\n";

and also don't forget to upload the file and make the text definition in your language file.

What is if you delete the email separator and the store name? Are you sure that the separator that you see appear at this part of the mail and not lower?

#33 col_b

  • Community Member
  • 25 posts
  • Real Name:col_b

Posted 23 August 2009, 18:10

View Postmultimixer, on Aug 23 2009, 02:54 PM, said:

I don't know why this happens. Maybe you try this
$email_order .= EMAIL_TEXT_GREETING  .  '  '  .  $order->customer['firstname'] . "\n\n" .
				   //STORE_NAME . "\n" . 
								 //EMAIL_SEPARATOR . "\n" . 
								EMAIL_TEXT_ORDER_NUMBER . ' ' . $insert_id . "\n" .
								EMAIL_TEXT_INVOICE_URL .  '  '  . tep_href_link(FILENAME_ACCOUNT_HISTORY_INFO, 'order_id=' . $insert_id, 'SSL', false) . "\n" .
				 EMAIL_TEXT_DATE_ORDERED .  '  '  . strftime(DATE_FORMAT_LONG) . "\n\n";

and also don't forget to upload the file and make the text definition in your language file.

What is if you delete the email separator and the store name? Are you sure that the separator that you see appear at this part of the mail and not lower?

multimixer,

If I comment out the separator and the store name, they still appear in the email. I haven't tried deleting them outright. I wondered is it possible to send this email without purchasing anything, i.e. to test it to see how things look, without going thru the procedure og actually placing an order.

Cheers,
Col

#34 mower

  • Community Member
  • 6 posts
  • Real Name:Tom Turner

Posted 26 August 2009, 20:38

Hello,

I have been using and learning osc commerce version 2.2 RC2 for some months now.

I have just found that when a new customer joins the welcome email does not send?

I can send emails from the send email page in tools fine, I have checked several different addresses but I cannot find a reason why they won't send from the registration page.

I have had a good hunt round the forum and there is some great stuf that I will come back to and use but I can't find an answer to this problem.

Any ideas would be most welcome.

Tom

#35 multimixer

  • Community Sponsor
  • 3,437 posts
  • Real Name:George Zarkadas
  • Gender:Male
  • Location:Greece

Posted 27 August 2009, 07:17

View Postmower, on Aug 26 2009, 11:38 PM, said:

I have just found that when a new customer joins the welcome email does not send?

Osc does not send new registration emails to the store owner by default.

I described in post #1 of this topic what to do if you want to have this

#36 mower

  • Community Member
  • 6 posts
  • Real Name:Tom Turner

Posted 27 August 2009, 16:40

Sorry I should have been more specific.

The new customer does not recieve the welcome email.

I have registered various test accounts and I cannot make the welcome email send from my store to the new accounts.

Hope that explains the problem a bit better.

Tom

#37 multimixer

  • Community Sponsor
  • 3,437 posts
  • Real Name:George Zarkadas
  • Gender:Male
  • Location:Greece

Posted 27 August 2009, 17:12

View Postmower, on Aug 27 2009, 07:40 PM, said:

The new customer does not recieve the welcome email.

Ok, it's clear now what the problem is.

Does the customer receive the order confirmation mail? If YES then can you post the relevant content of your create_account.php?

The relavant lines are
// build the message content
.
.
.
.
.
.
 $breadcrumb->add(NAVBAR_TITLE, tep_href_link(FILENAME_CREATE_ACCOUNT, '', 'SSL'));


#38 mower

  • Community Member
  • 6 posts
  • Real Name:Tom Turner

Posted 27 August 2009, 18:01

No I have just done some tests and an order confirmation is not recieved by the customer iether.

I was sent one to my admin account.

What other tests should I run to give you a clue what the problem might be?

Thanks

Tom

#39 multimixer

  • Community Sponsor
  • 3,437 posts
  • Real Name:George Zarkadas
  • Gender:Male
  • Location:Greece

Posted 27 August 2009, 19:25

View Postmower, on Aug 27 2009, 09:01 PM, said:

No I have just done some tests and an order confirmation is not recieved by the customer iether.

I was sent one to my admin account.

What do you mean? Does the store owner received an email? And the customer not? You need to be specific please

#40 mower

  • Community Member
  • 6 posts
  • Real Name:Tom Turner

Posted 27 August 2009, 22:12

Sorry for the confusion.

I have set up a test customer with a yahoo email adress.

When I registered the test customer no email was sent to the yahoo adress.

I made a test purchase and no confirmation email was sent to yahoo.

My admin email adress recieved a copy of the confirmation.

I have set up other test customers with hotmail and google mail accounts and both of these recieved emails.

I am now very confused.

I will try again tomorrow.

If anyone would care to try the registration for me the site is

http://studulike.turnerclan.co.uk

Thanks again

Tom