Jump to content

Recommended Posts

@burt what are you using for your line breaks?

content-type: text/plain
"\n" - move cursor to next line
"\r" - move curser to beginning of the line
"\n\r" - produces 2 new lines whereas "\n", "\r" and "\r\n" give single lines

content-type: text/html
<br> - single line break HTML
<br /> - single line break XHTML
HTML5 allows both but prefers <br>

nl2br($str, boolean) - replace \n with <br> or <br />
boolean - true/false default true
nl2br($str, true) same as nl2br($str)

 


No longer giving free advice. Please place deposit in meter slot provided.  Individual: [=] SME: [==] Corporation: [===]
If deposit does not fit one of the slots provided then you are asking too much! :P


Support The Project
Documentation/Knowledgebase/Discussions
 

Share this post


Link to post
Share on other sites
On 4/18/2019 at 2:52 PM, 241 said:

@burt what are you using for your line breaks?

nl2br - which is a pain in some circumstances.  So I removed it, in favour of user using HTML.


Help shape the future of Phoenix; join the Phoenix Club

Share this post


Link to post
Share on other sites

Right now I am working on setting up a Cron system for this system.

Having not really played in-depth with Cron before, it's proving to be a PITA.

But the system is close to starting the next phase of testing.


Help shape the future of Phoenix; join the Phoenix Club

Share this post


Link to post
Share on other sites
41 minutes ago, burt said:

Right now I am working on setting up a Cron system for this system.

Having not really played in-depth with Cron before, it's proving to be a PITA.

But the system is close to starting the next phase of testing.

Do I smell some scope creep here? Planning to build a shed, and coming out with a sky scraper? 🙂

 

Share this post


Link to post
Share on other sites
7 minutes ago, René H4 said:

Do I smell some scope creep here? Planning to build a shed, and coming out with a sky scraper? 🙂

 

Always.  Problem is that by thinking of doing one thing different/better...it means coding something else different/better.

But, I do now have it working.  It also now has an email pre-viewer;

Noname.thumb.jpg.92906f8597a48d6de00ef370a7050df6.jpg


Help shape the future of Phoenix; join the Phoenix Club

Share this post


Link to post
Share on other sites

I now have this working smooth with a Cron - which I have set for every 5 minutes.  On a busy shop, you could set it for every 1 minute, on a slow shop you could set it for once a day - you get the idea.  Anyway in the test shop as it is set for every 5 minutes, the lonest you'll need to wait (to get the order_success email) is 5 minutes...

So, if anyone now wants to test it, please go ahead:  

https://template.me.uk/outgoing/

All I ask is that you use a REAL EMAIL that you have access to so that you can receive/view the order_success email (which is HTML).  The "slug" (aka template) for the order_success email looks like this):

<p>Dear {{FNAME}}, thank you for your order #{{OID}}.</p>

<p align="center"><img src="https://template.me.uk/outgoing/images/apps/thanks.png"></p>

<table cellspacing="0" cellpadding="0" width="100%">
  <tr>
    <td valign="top"><b>Products:</b></td>
    <td valign="top">{{PRODUCTS}}</td>
  </tr>
  <tr>
    <td colspan="2"><hr></td>
  </tr>
  <tr>
    <td valign="top"><b>Invoice:</b><br>#{{OID}}</td>
    <td valign="top"><b>Full Invoice:</b><br>https://template.me.uk/outgoing/account_history_info.php?oid={{OID}}</td>
  </tr>
  <tr>
    <td valign="top"><b>Date Ordered:</b><br>{{ORDER_DATE}}</td>
    <td valign="top"><b>Status:</b><br>{{ORDER_STATUS}}</td>
  </tr>
  <tr>
    <td valign="top"><b>Payment Method:</b><br>{{PAYMENT_METHOD}}</td>
    <td valign="top"><b>Order Value:</b><br>{{ORDER_VALUE}}</td>
  </tr>
  <tr>
    <td valign="top"><b>Delivery Address</b><br>{{DELIVERY_ADDRESS}}</td>
    <td valign="top"><b>Billing Address:</b><br>{{BILLING_ADDRESS}}</td>
  </tr>
</table>

<p>A big BIG BIG Thank You from all of us here at Burtys Test Shop!</p>

As you can see, that is obviously a very basic HTML template - if you look back through this thread you will see @Dan Cole has come up with a much better HTML template for his emails.   But read between the lines and you'll see that it you are, pretty much, limited only by your imagination.

Feel Free To Test...any feedback is gratefully received.


Help shape the future of Phoenix; join the Phoenix Club

Share this post


Link to post
Share on other sites

Looks great Gary except for the flower pot that I see you're still wearing.  😂

Dan

QueuedEmail.thumb.jpg.570657483d085dcde4dc605ec1815433.jpg

Edited by Dan Cole

Share this post


Link to post
Share on other sites

@burt

Received both the "New Account" and "Order Acknowledgement" emails. Both emails are in both plain text and HTML.

One thing ... in the Order Acknowledgement email, in the plain text version, the URL to the invoice is clickable. In the HTML version, it is not.

HTH

Malcolm


Get the latest Responsive osCommerce CE (community edition) here .

Share this post


Link to post
Share on other sites
7 minutes ago, ArtcoInc said:

One thing ... in the Order Acknowledgement email, in the plain text version, the URL to the invoice is clickable. In the HTML version, it is not.

That probably just happens to people who were raised funny.  😂

That is odd though...as you can see in the image I posted above.  The html URL is clickable for me.

Dan

Share this post


Link to post
Share on other sites

@Dan Cole

Here is the raw HTML code that came in the email to me:

 

<p>Dear Malcolm, thank you for your order #44.</p><br /><br /><p align=3D"c=
enter"><img src=3D"https://template.me.uk/outgoing/images/apps/thanks.png">=
</p><table cellspacing=3D"0" cellpadding=3D"0" width=3D"100%"><br />  <tr><=
br />    <td valign=3D"top"><b>Products:</b></td><br />    <td valign=3D"to=
p">1 x Samsung Galaxy Tab<br /></td><br />  </tr><br />  <tr><br />    <td =
colspan=3D"2"><hr></td><br />  </tr><br />  <tr><br />    <td valign=3D"top=
"><b>Invoice:</b><br>#44</td><br />    <td valign=3D"top"><b>Full Invoice:<=
/b><br>https://template.me.uk/outgoing/account_history_info.php?oid=3D44</t=
d><br />  </tr><br />  <tr><br />    <td valign=3D"top"><b>Date Ordered:</b=
><br>Thursday 25 April, 2019</td><br />    <td valign=3D"top"><b>Status:</b=
><br>Pending</td><br />  </tr><br />  <tr><br />    <td valign=3D"top"><b>P=
ayment Method:</b><br>Cash on Delivery</td><br />    <td valign=3D"top"><b>=
Order Value:</b><br>$754.99</td><br />  </tr><br />  <tr><br />    <td vali=
gn=3D"top"><b>Delivery Address</b><br>Malcolm Spann <br /> 123 No Name Stre=
et<br /> Some City, 12345<br /> A failed State of Mind, Afghanistan</td><br=
 />    <td valign=3D"top"><b>Billing Address:</b><br>Malcolm Spann <br /> 1=
23 No Name Street<br /> Some City, 12345<br /> A failed State of Mind, Afgh=
anistan</td><br />  </tr><br /></table><p>A big BIG BIG Thank You from all =
of us here at Burtys Test Shop!</p>

And here's the result, displayed in Firefox:

106906045_ScreenCapture04-25-2019.jpg.2abdda86b092774eb23a57be32b51ad8.jpg

Don't know what else to say ...

M

 


Get the latest Responsive osCommerce CE (community edition) here .

Share this post


Link to post
Share on other sites

Instead of this ....

<td valign="top">
  <b>Full Invoice:</b>
  <br>
  https://template.me.uk/outgoing/account_history_info.php?oid={{OID}}
</td>

Should it not be

<td valign="top">
  <b>Full Invoice:</b>
  <br>
  <a href="url">https://template.me.uk/outgoing/account_history_info.php?oid={{OID}}</a>
</td>

 

Otherwise, you are just relying on the browser to identify the URL, and display it accordingly.

Malcolm

Edited by ArtcoInc

Get the latest Responsive osCommerce CE (community edition) here .

Share this post


Link to post
Share on other sites

It's just a template so individual shopowners can easily set it up as they like and tweak it etc. 
HTML Emails are actually quite difficult as email programs render the output markedly differently.

Well, it's certainly close enough to get the updated system out to the two testers to try.  Tomorrow chaps.


Help shape the future of Phoenix; join the Phoenix Club

Share this post


Link to post
Share on other sites
7 hours ago, ArtcoInc said:

Otherwise, you are just relying on the browser to identify the URL, and display it accordingly.

I guess the other thing that is in play here is your email client....I too was using FireFox but I use gmail for my email client. What are you using?

Dan

Share this post


Link to post
Share on other sites

Be aware that those of you who took the time to make a test order or two at my Test Shop [thank you for doing so, your time is appreciated] will be getting Emails, these emails are completely hands off for the shopowner...basically these emails are meant to;

  • remind the shopper that you exist
  • remind the shopper to perform an action (eg write a review)

As the system is very much hands off, it's something that the shopowner can leave alone and let the system do its thing.  If just one customer comes back and purchases something...that's a WIN.  Or if just one customer comes back and writes a review, that's also a win, but not a WIN.  Two customers..double WIN.  Etc and so on.

I think I'm ready to ask for 2 more testers - you must be willing to take;

  1. 2 minutes uploading files
  2. 10 minutes writing your HTML Template(s)
  3. 3 minutes able to set up a CRON via (eg) cPanel

And then, provide feedback to me (by email) on how you would like to see the system improved.  If you are able to give me that time/effort, PM me - thanks


Help shape the future of Phoenix; join the Phoenix Club

Share this post


Link to post
Share on other sites
8 hours ago, blaine109 said:

I'm willing to test this out.  I was about to have a similar addon coded but was referred to you by Jack_MCS. 

Thanks for the offer.  It's now fully tested and on limited release.


Help shape the future of Phoenix; join the Phoenix Club

Share this post


Link to post
Share on other sites
On 6/11/2019 at 2:04 AM, burt said:

Thanks for the offer.  It's now fully tested and on limited release.

I came across to this great module today. Sounds very exciting. I have already created a test account on https://template.me.uk/outgoing and placed couple of orders.

Meanwhile, how can I get access to the code to test it on my shop?

Thanks in advance.

- Ed

Share this post


Link to post
Share on other sites
On 6/11/2019 at 2:04 AM, burt said:

Thanks for the offer.  It's now fully tested and on limited release.

For a slightly cleaner look.

I have added the following line in my .htaccess file:

RewriteRule ^orders/([^/\.]+)/?$ account_history_info.php?order_id=$1 [L]

and in checkout_process.php I replaced:

EMAIL_TEXT_INVOICE_URL . ' ' . tep_href_link(FILENAME_ACCOUNT_HISTORY_INFO, 'order_id=' . $insert_id, 'SSL', false) . "\n" .

with:

EMAIL_TEXT_INVOICE_URL . ' ' . tep_href_link('orders/' . $insert_id, '', 'SSL', false) . "\n" .

 

to change the order details header from:

Order Number:    401
Detailed Invoice:    https://mywebsite.com/account_history_info.php?order_id=401
Date Ordered:    Wednesday 17 April, 2019
Status:    Pending

to:

Order Number:    401
Detailed Invoice:   https://mywebsite.com/orders/401
Date Ordered:    Wednesday 17 April, 2019
Status:    Pending

 

In case someone wants to use it.

Share this post


Link to post
Share on other sites
7 minutes ago, burt said:

It is still on very limited release due to a couple of bugs to iron out etc.  

Can't wait to see it. Let me know if you need additional testers/debuggers. I may be able to help.

Share this post


Link to post
Share on other sites

@burt Interested, was this ever released?


Getting the Phoenix off the ground

Share this post


Link to post
Share on other sites
2 hours ago, Peper said:

@burt Interested, was this ever released?

It did get finished but it turned out to be one of the projects where things didn't quite go according to plan, and the code ended up not being ready for public release.  I do plan to revisit it soon as part of the Phoenix Updating process as this system (or something similar) would supercharge outgoing (and incoming) customer contact.


Help shape the future of Phoenix; join the Phoenix Club

Share this post


Link to post
Share on other sites
6 minutes ago, burt said:

It did get finished but it turned out to be one of the projects where things didn't quite go according to plan, and the code ended up not being ready for public release.  I do plan to revisit it soon as part of the Phoenix Updating process as this system (or something similar) would supercharge outgoing (and incoming) customer contact.

This would be an awesome step forward but no point in releasing it until you're happy with it.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×