close ad
WARNING PC USERS: Do Not Install the DREAMWEAVER CC 2017 Update »
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

correct syntax for 'To' settings

Thread began 2/03/2011 11:14 am by CraigR | Last modified 2/07/2011 4:24 pm by Jason Byrnes | 1399 views | 11 replies |

CraigRBeta Tester

correct syntax for 'To' settings

After starting afresh, (again), i can create an email message which sends successfully to one recipient.

when i attempt to select recipients from a recordset to use in the 'recordset loop' , whenever i save the changes and then re-open the server behavior, the 'from file' option is selected.

on my mail page, the $recipArray line reads as follows..

$RecipArray[$CurIndex] = EmailArrayFromFile("rsmembers.MemberEmail");

even if i selected recordset loop.

is this correct ?

Sign in to reply to this post

Jason ByrnesWebAssist

No, this is not correct, I started a ticket for this issue for you on your other thread, an engineer will need to contact you to look into the issue and find the cause.
Please update the ticket that was started with contact information so we can debug the issue with you.

Sign in to reply to this post

CraigRBeta Tester

Hi Jason.

I updated the ticket with my contact info yesterday.

I closed this ticket as I couldn't reproduce the original problem. but the contact info still stands

in the meantime, can you tell me the correct syntax so I can hand code for now ?

I can't seem to find the relevant function in mailformatting_php.php

thanks

Sign in to reply to this post

Jason ByrnesWebAssist

in your file, you have:

php:
$CurIndex = sizeof($RecipArray);

  $RecipArray[$CurIndex] = EmailArrayFromFile("rsmembers.MemberEmail");
  $TotalEmails += sizeof($RecipArray[$CurIndex]);




that should be changed to:

php:
$CurIndex = sizeof($RecipArray);

  $RecipArray[$CurIndex] = array();
  $RecipArray[$CurIndex][] = $row_rsmembers;
  $RecipArray[$CurIndex][] = $rsmembers;
  $RecipArray[$CurIndex][] = "MemberEmail";
  $TotalEmails += mysql_num_rows($rsmembers);
Sign in to reply to this post

CraigRBeta Tester

thanks Jason.

I typed that in to replace the original code, and now the mail is sent correctly.

to try and finish off. I want to use my recordset to include the first name of each member for their respective email.

I read in another thread about adding $RecipArray etc as globals and using this instead of the recordset , but again, the changes I make don't seem to stick if done via the wizard.

Is this the correct approach to take ?

Sign in to reply to this post

Jason ByrnesWebAssist

the changes should not be made through the wizard, make the changes after running the wizard.

Sign in to reply to this post

CraigRBeta Tester

sorry. i meant the server behavior interface, as opposed to editing the code directly.

The changes don't save to the page

Sign in to reply to this post

Jason ByrnesWebAssist

yes, i understand, you should not make the changes in the server behaviors interface, you need to make the code changes directly in the code.

if you edit the server behavior, they will be erased and you will need to make the changes again.

Sign in to reply to this post

CraigRBeta Tester

great, making progress

thanks Jason.

After creating the basic email, I am now hand coding so I don't overwrite anything inadvertently.

i have also included html editor 3 onto my page.

I have 2 questions relating to html editor..

1. the message created in the htmleditor has very wide line spacing after each cr/lf, how can i reduce this ?

2. apostrophies are not escaped, so "can't" is shown as "can\'t" in the message

Using 2 recordsets on the page.

in order to personalise the email, i am using the syntax $MailBody = $MailBody . ($RecipArray[$RecipIndex][0]['MemberFirstName']);

my mail page has 2 recordsets.

the user will choose an event a list, whose id I use as a url parameter in a link, but i also want to include the event description in the link

can you tell me how to achieve this ?

Attached Files
emailfiles.zip
Sign in to reply to this post

Jason ByrnesWebAssist

By default HTML Editor uses P tags for the enter key.

in the HTML editor instance, go to the Formatting tab and select the option to use BR for enter instead.


for the escaping issue, try adding this at line one of your page:
<?php
ini_set('magic_quotes_gpc','on');
?>

for the delected event title to show in the email, you will need to set the event recordset to filer the eventID column on the eventList select list.

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...