close ad
Install the LAtest Updates to Work with CC 2017 and CC 2018
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

emils not looping through recordset

Thread began 10/01/2013 10:34 am by Sweens | Last modified 10/01/2013 1:16 pm by Jason Byrnes | 1850 views | 9 replies |

Sweens

emils not looping through recordset

Hi
I've created a recordset on a pag, applied the 'create email message' - used the 'recordset loop and selected the email field for the recordset.

However, the same email is being sent multiple times to one recipient, rather than individual emails to each individual.

(I've rebuilt the page twice from scratch and followed the instructions to the letter, with the same results)

Any help much apreciated.
Thanks
Chris

Sign in to reply to this post

Jason ByrnesWebAssist

In DW, edit the recordset and test it, send a screen shot of the recordset test.

Sign in to reply to this post

Sweens

Thanks Jason; screen shot attached.
Cheers
Chris

Sign in to reply to this post

Jason ByrnesWebAssist

In the universal email wizard, you have the to address using the MemEmail column, judging from the screen shot, you want to be using the BusEmail column instead.

Sign in to reply to this post

Sweens

I know - I've put the MemEmail column in as a temporary things whilst testing - which is a good job I did!

When it works, the MemEmail column will be removed and the BusEmail renamed MemEmail

Sign in to reply to this post

Jason ByrnesWebAssist

but it does work, the MemEmail column uses the same email multiple times, I only see about 4 addresses in that column....

Sign in to reply to this post

Sweens

Yes, the emails are sent to all the 4 different test addresses - but the content of the emails is identical; all relate to 'Tim Freeman', the first result in the recordset.

Sign in to reply to this post

Jason ByrnesWebAssist

I see, that was not clear in the initial message.


In the email body template file, add the following code at line 1:

php:
<?php

global $RecipArray;
global 
$RecipIndex;
?>



the n to refer to column from the recordset, use the following:

php:
<?php echo($RecipArray[$RecipIndex][0]["[yourColumnName]"]); ?>




where [yourColumnName] is the name of the column, for example:

php:
<?php echo($RecipArray[$RecipIndex][0]["FullName"]); ?>
Sign in to reply to this post

Sweens

No Joy!

Message page in private area.

Sign in to reply to this post

Jason ByrnesWebAssist

This is using the DW Edit option for creating the email message, instead, select the option to create a file for the email message and selct one of the templates, then edit the template to include the code from my previous reply.

Sign in to reply to this post
loading

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...