Skip navigation
Currently Being Moderated

Tip - delete any email address code in the Insert email link prior to use!

Feb 27, 2012 1:57 PM

Tags: #bug #insert_email

I have been using the email link for a while now. I know its not secure, but in certain cases it can be used - I think.

Today I found a strange problem.

 

I have a recordset with lots of email addresses in it which are shown on an encrypted password and userlevel  protected page.

The idea is to allow users with fully authorised access to the page to be able to email the other users by clicking on a link and opening their email client.

 

The email addresses are displayed as follows on the page:

<td>Email address:</td>

           <td><?php echo htmlentities($row_clubedit['club_chair_email'], ENT_COMPAT, 'utf-8'); ?></td>

 

So after highlighting and copying  the php code, I click on the insert email link in the insert menu.

The insert panel comes up with some code  in the email link field without me paying any attention to it.

I paste my code into the text part of the link panel.

 

It comes up with the following code:

 

<td><a href="mailto:<?php echo $row_joinupset['mail']; ?>"><?php echo htmlentities($row_clubedit['club_chair_email'], ENT_COMPAT, 'utf-8'); ?></a></td>

 

Note that thre are now two different recordsets in the email address.These recordsets do exist on the page, but I did not insert the  $row_joinupset['mail'] into the code - Dreamweaver did it.

 

Checking further, I find that earlier on the page I had created an email link by the same method using the joinupset recordset. The insert Email Link panel had not cleared the old email address from it's cache, so all the email adresses after the first one pointed to the same email address.

Because the page showed the correct email address, I did not notice until I tested my code, and found that every one called up the first email address.

 

I do not know if this is a bug in Dreamweaver, or why it happens, but it does.

 

Tip - delete any code in the email adress field of the insert panel prior to inserting the correct email address code.

 

CS5.5 on a 64 bit win 7 machine.

 

More Like This

  • Retrieving data ...

Bookmarked By (0)