Zen Cart Logo
Forums / All Other Contributions/Addons / Autoresponder+ for ZC v1.3.x [support thread]

Autoresponder+ for ZC v1.3.x [support thread]

Views: 45,182

Results 141 to 160 of 232
13 Sep 2009, 4:18 PM
#141
steven300 avatar

steven300

Totally Zenned

Join Date:
Jan 2008
Posts:
1,564
Plugin Contributions:
1

Autoresponder+ for ZC v1.3.x [support thread]

Hi guys. It's been a while since I last did any work with this mod. In fact, I feel as if I've improved a lot with PHP since the last version, as I've been working on other projects. As such, I'm going to be rewriting some of the code and adding new features over the coming days. I have already made some improvements today:

  • Account emails can be restricted by location
  • Order status can be automatically updated

Next, I plan to:

  • Restrict emails by product
  • Add full source code comments
  • .. and possibly more

If you have a feature not already requested, now is a good time.

Expect a beta version (of v2.3) by next weekend :smile:

13 Sep 2009, 4:29 PM
#142
steven300 avatar

steven300

Totally Zenned

Join Date:
Jan 2008
Posts:
1,564
Plugin Contributions:
1

Re: Autoresponder+ for ZC v1.3.x [support thread]

1fghjkl:

My Store name is misspelled on my email header?

I checked it in ADMIN>CONFIGURATION>MY STORE>STORE NAME

and it's spelled correctly

It's auto pulling correctly on my sites footer- Copyright © 2009 Fintess Depot Super Store.

Is there some where else that I need to look to change the name for the e mail?

It Currently reads "Message from Fintess Depot Super Store"

Thanks-

Hi, I'm not sure how autoresponder+ would cause this as it doesn't actually do anything with the store name. It just displays whatever is configured in the setting you mentioned.

Can you attach a screenshot of this? Is the problem with html emails, text or both?

Also, the text you provided for your footer (which you said is correct) seems misspelled to me.

13 Sep 2009, 4:37 PM
#143
steven300 avatar

steven300

Totally Zenned

Join Date:
Jan 2008
Posts:
1,564
Plugin Contributions:
1

Re: Autoresponder+ for ZC v1.3.x [support thread]

aaelghat:

I have a feature request, which I would find very helpful, and I suspect others might as well....

Some excellent suggestions! I had planned to add a feature for product restriction for a while, but never thought of changing the order status after the emails. This allows users to run the mod as often as they want (providing it's an order related email).

14 Sep 2009, 3:35 PM
#144
aaelghat avatar

aaelghat

Zen Follower

Join Date:
Feb 2007
Posts:
100
Plugin Contributions:
0

Re: Autoresponder+ for ZC v1.3.x [support thread]

Hi - thanks for continually improving AutoResponder+!!

I love the addition of modifying the order status, since that will allow me to send out very timely instructions instead of just once a day.

I also like the fact you'll provide more source code comments for autoresponder.php. I'll need to hardcode some things that I mentioned in post 128, and that will make it easier.

In terms of feature requests, there was one thing I was going to hard-code manually (that others may benefit from). You can decide if you want to this in the base code....

Basically, I wanted to be able to put the order attributes in the text of the email. Maybe the user can specify an attribute keyword with the attribute number in brackets (e.g. [ATTRIB-13]) and that would retrieve attribute ID #13 from the zen_orders_products_attributes table. On the other hand, I could see where that might be complex to code.

I need to manipulate some of the attributes anyway (apply LCASE for example), so I need to bring them into variables so it's not a big deal for me to just bring all the attributes into variables if you decide it's not worth doing in the mod.

Thanks again for all your work on this. I'll hold off on making any changes to the code on my end until the beta appears.

14 Sep 2009, 3:47 PM
#145
steven300 avatar

steven300

Totally Zenned

Join Date:
Jan 2008
Posts:
1,564
Plugin Contributions:
1

Re: Autoresponder+ for ZC v1.3.x [support thread]

Hi, yes I would definitely hold off from making any changes at the moment. I think (hope) you'll find the source code a lot easier to work with once I'm done. A lot of comments are being added, and I have managed to remove some redundant code. I have also fixed an unreported bug whereby auto-generated coupons could be created even though the final email doesn't send because of newsletter subscription checks. I'm not sure any attribute related code will make it into the next version, but the mod will be easier to add such things.

14 Sep 2009, 5:49 PM
#146
steven300 avatar

steven300

Totally Zenned

Join Date:
Jan 2008
Posts:
1,564
Plugin Contributions:
1

Re: Autoresponder+ for ZC v1.3.x [support thread]

Just a quick update: Autoresponder+ can now restrict emails by product.

Tons of testing to do now :yuck:

16 Sep 2009, 12:37 PM
#147
steven300 avatar

steven300

Totally Zenned

Join Date:
Jan 2008
Posts:
1,564
Plugin Contributions:
1

Re: Autoresponder+ for ZC v1.3.x [support thread]

Autoresponder+ v2.3 Beta is now available:

http://wikisend.com/download/447690/

Any feedback is appreciated.

16 Sep 2009, 11:28 PM
#148
aaelghat avatar

aaelghat

Zen Follower

Join Date:
Feb 2007
Posts:
100
Plugin Contributions:
0

Re: Autoresponder+ for ZC v1.3.x [support thread]

I downloaded and tested the beta (only in test mode) and it seems to work great!! It only selects the specified product IDs and the status update works great!

I especially like the fact that it updates the status on the admin orders detail screen with a date/time stamp, and it doesn't notify the customer. That's perfect! You may want to warn people that the status does get updated even in test mode, but that works for me since it allows me to test better, and it's easy enough to change the statuses back.

I have some tailoring to do for my specific purposes, but these are great functionality improvements. Nice job!!

17 Sep 2009, 8:21 AM
#149
steven300 avatar

steven300

Totally Zenned

Join Date:
Jan 2008
Posts:
1,564
Plugin Contributions:
1

Re: Autoresponder+ for ZC v1.3.x [support thread]

Thanks for the positive feedback.

That's a good point about how it changes the order status while in test mode. I will add a note in the testing section to explain this.

17 Sep 2009, 2:20 PM
#150
aaelghat avatar

aaelghat

Zen Follower

Join Date:
Feb 2007
Posts:
100
Plugin Contributions:
0

Re: Autoresponder+ for ZC v1.3.x [support thread]

Hi, I'm wondering if you can provide some guidance. I'm trying to modify the code so that I can retrieve various order attributes, and reference them in the HTML and text files. I've been using the [coupon] as a reference, but I'm a low-level hack at PHP.

I'd like to get one attribute working, and then duplicate it. I'm starting with an attribute called RecipientName, and I wrote some SQL to retrieve it. I know the SQL code works, and tried to follow your example for the PHP syntax. I put the code right after the retrieval of the customer name.

        /* First, let's get the customer's name */
    
        //If in order mode
        if ($this_auto_state == 'order') {
        
        $sql3="select customers_name from " . AUTO_TABLE_ORDERS . " where orders_id='".$result->fields['orders_id']."'";
        $result3=$db->Execute($sql3);
        
        $name=$result3->fields['customers_name'];

              //AAE - Retrieve RecipientName
              $SQL-AAE-Recipient = "select products_options_values from " . AUTO_TABLE_ORDERS_PRODUCTS_ATTRIBUTES . " where orders_id='".$result->fields['orders_id']."'" AND products_options_id = 45";
              $ResultRecipientName=$db->Execute($SQL-AAE-Recipient);        
        $RecipientName=$ResultRecipientName->fields['RecipientName'];
```However, I'm unclear what I'd need to do to reference it by typing [RecipientName].  I duplicated what you had for the coupon by typing 

//This can be changed here if desired.
$coupon_key = "[coupon]";

// AAE - Set Recipient Name keyword.
$RecipientNameKey = "[RecipientName]";

17 Sep 2009, 2:40 PM
#151
steven300 avatar

steven300

Totally Zenned

Join Date:
Jan 2008
Posts:
1,564
Plugin Contributions:
1

Re: Autoresponder+ for ZC v1.3.x [support thread]

All you need to do now is to search the email's content and replace any occurance of [RecipientName] with $RecipientName.

So if I take the coupon feature as an example:

//Replace coupon keyword in text message with new coupon code
$text_message = str_replace($coupon_key, $new_coupon_code, $text_message);
		
//Repeat for html message
$html_message = str_replace($coupon_key, $new_coupon_code, $html_message);

It would be:

//Replace [RecipientName] keyword in text message with recipient's name
$text_message = str_replace($RecipientNameKey, $RecipientName, $text_message);
		
//Repeat for html message
$html_message = str_replace($RecipientNameKey, $RecipientName, $html_message);

Just make sure the above code goes after the text and html messages are formed.

17 Sep 2009, 2:48 PM
#152
steven300 avatar

steven300

Totally Zenned

Join Date:
Jan 2008
Posts:
1,564
Plugin Contributions:
1

Re: Autoresponder+ for ZC v1.3.x [support thread]

I haven't tested your SQL statement, but it looks as if you have an extra " in there.

$SQL-AAE-Recipient = "select products_options_values from " . AUTO_TABLE_ORDERS_PRODUCTS_ATTRIBUTES . " where orders_id='".$result->fields['orders_id']."'" AND products_options_id = 45";

Should be:

$SQL-AAE-Recipient = "select products_options_values from " . AUTO_TABLE_ORDERS_PRODUCTS_ATTRIBUTES . " where orders_id='".$result->fields['orders_id']."' AND products_options_id = 45";
11 Oct 2009, 6:44 PM
#153
allerup avatar

allerup

New Zenner

Join Date:
Dec 2007
Posts:
5
Plugin Contributions:
0

Re: Autoresponder+ for ZC v1.3.x [support thread]

I have had some trouble getting the autoresponder to send html messages on my 1.3.7 installation. When I added the functions_email.php from 1.3.8, emails from autoresponder was sent correctly, but all other emails wasnt send in html.

I discovered that adding the following code from 1.3.8 functions_email.php to 1.3.7 functions_email.php solved my problems.

1.3.7 before:

function zen_build_html_email_from_template($module='default',$block) {
    global $messageStack;
    // Identify and Read the template file for the type of message being sent

1.3.7 after:

function zen_build_html_email_from_template($module='default', $content='') {
    global $messageStack, $current_page_base;
    $block = array();
    if (is_array($content)) {
      $block = $content;
    } else {
      $block['EMAIL_MESSAGE_HTML'] = $content;
    }
    // Identify and Read the template file for the type of message being sent
11 Oct 2009, 7:36 PM
#154
steven300 avatar

steven300

Totally Zenned

Join Date:
Jan 2008
Posts:
1,564
Plugin Contributions:
1

Re: Autoresponder+ for ZC v1.3.x [support thread]

Thanks allerup, I'll add a link to your post next time I update the mod.

13 Oct 2009, 2:00 PM
#155
swguy avatar

swguy

Administrator

Join Date:
Feb 2006
Location:
Tampa Bay, Florida
Posts:
10,717
Plugin Contributions:
56

Re: Autoresponder+ for ZC v1.3.x [support thread]

Steven, please PM me. Thanks.

2 Nov 2009, 6:54 PM
#156
drc2100 avatar

drc2100

New Zenner

Join Date:
Oct 2006
Posts:
23
Plugin Contributions:
0

Re: Autoresponder+ for ZC v1.3.x [support thread]

Awesome product! We have been using it for awhile but noticed the response was fairly low and reallized the product links take poeple to our homepage instead of the product page to review.

Any idea why the program is leaving out the /Shop/index.php... this is what the program is grabbing for the link and the second one is what it should be?

Many thanks!

http://www.findbliss.com/?main_page=product_info&cPath=162&products_id=229

http://www.findbliss.com/Shop/index.php?main_page=product_info&cPath=162&products_id=229

2 Nov 2009, 8:48 PM
#157
steven300 avatar

steven300

Totally Zenned

Join Date:
Jan 2008
Posts:
1,564
Plugin Contributions:
1

Re: Autoresponder+ for ZC v1.3.x [support thread]

Hi,

I've had a look at the code that generates the product links and I can't see anything which would cause the issues that you're reporting. What I find really strange is that the code is meant to add the following string to the URL:

"/index.php?main_page=product_info&cPath="

Yet in your link, the "index.php" part is completely missing. I can't understand that.

Where do you have the autoresponder file located?

Are you on a Windows server?

Here is the full code:

/* Build first part of URL */
//If hyperlink is to main product page
if ($products_as_url == 'yes, to product page') {
		
//If store is not in a directory
if ( dirname($_SERVER['PHP_SELF']) == "/" ) {
$initial_url = HTTP_SERVER . "/index.php?main_page=product_info&cPath=";
} else {
$initial_url = HTTP_SERVER . dirname($_SERVER['PHP_SELF']) . "/index.php?main_page=product_info&cPath=";
}
		
} else { //Hyperlink is to product review page

//If store is not in a directory
if ( dirname($_SERVER['PHP_SELF']) == "/" ) {
$initial_url = HTTP_SERVER . "/index.php?main_page=product_reviews_write&cPath=";
} else {
$initial_url = HTTP_SERVER . dirname($_SERVER['PHP_SELF']) . "/index.php?main_page=product_reviews_write&cPath=";
}

}
2 Nov 2009, 9:03 PM
#158
drc2100 avatar

drc2100

New Zenner

Join Date:
Oct 2006
Posts:
23
Plugin Contributions:
0

Re: Autoresponder+ for ZC v1.3.x [support thread]

Thx for quick response. We are on a dedicated linux server. I had someone else install the mod and now waiting for location as I can't locate it on our server.

Be back shortly with location.

2 Nov 2009, 9:05 PM
#159
drc2100 avatar

drc2100

New Zenner

Join Date:
Oct 2006
Posts:
23
Plugin Contributions:
0

Re: Autoresponder+ for ZC v1.3.x [support thread]

We installed at the end of May 2009. Maybe we need to download and install the latest version?

2 Nov 2009, 9:07 PM
#160
drc2100 avatar

drc2100

New Zenner

Join Date:
Oct 2006
Posts:
23
Plugin Contributions:
0

Re: Autoresponder+ for ZC v1.3.x [support thread]

It looks like there is a php file in the Shop folder..only 70.1kb is this the file?