Making Invisimail Work with existing mailto: links

jrust - December 15, 2007 - 18:18
Project:Invisimail
Version:6.x-1.x-dev
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:closed
Description

Currently Invisimail only picks up email addresses that are not already mailto: links. It does not pick up and encode addresses that have been made into a mailto: link via another filter or something like TinyMCE. This patch adds the functionality of also encoding the addresses in those existing links.

AttachmentSize
invisimail_links.patch2.72 KB

#1

jrust - December 17, 2007 - 22:56

I've attached an updated version of the patch which has a speed improvement and removes a couple lines of testing code.

AttachmentSize
invisimail_links2.patch 2.46 KB

#2

Digital Deployment - August 1, 2008 - 06:24

Has this been committed to the latest version? This is a terrific patch that provides essential functionality.

#3

jrust - August 13, 2008 - 19:22

I've attached a new version of the patch for the recently released 1.0 version of Invisimail. It also fixes a bug where if the text consists of solely an email address or the email address is in a table cell it wasn't getting encoded.

AttachmentSize
invisimail_links_1.0.patch 3.02 KB

#4

Crell - August 19, 2008 - 16:42

Is this for D5 or D6? The D5 version is in maintenance mode, so I'm only looking at D6 feature improvements. (Of course, it's not like this module has much difference between the two...)

#5

jmstacey - August 21, 2008 - 21:50

It patched against 5.x-1.0 just fine for me, thanks jrust!

It would be very nice if this patch was merged with both D5 and D6. It would reduce some of the complexity on our side when it comes time to merging our custom branches with the official module later on down the road.

#6

jrust - March 10, 2009 - 17:20
Version:HEAD» 6.x-1.x-dev
Status:needs review» reviewed & tested by the community

Attached is a patch for the 6.x branch.

AttachmentSize
invisimail_links_6.x.patch 2.9 KB

#7

jrust - March 31, 2009 - 18:50

An updated version of the patch is attached.

AttachmentSize
invisimail_links_6.x.patch 2.79 KB

#8

Crell - March 31, 2009 - 22:05
Status:reviewed & tested by the community» needs work

OK, trying to get back to module maintenance...

1) Don't name a function "invisimail_callback2". That says nothing about what it does or why it does it or how it's used. It should have a real name. (Arguably so should invisimail_callback, then, which can be done in the same patch.)

2) I'm going to hope you've tested the regexes, because I can't even begin to comprehend them. :-)

#9

jrust - April 14, 2009 - 16:50

Good ideas. I've updated the patch with clearer function calls. And, yup, I've tested the regexes. The first one looks for a mailto: link and encodes it. The second one is similar to what was there before, except that it now handles two new cases: when an email address is at the beginning of the line and when an email address is inside a table cell.

AttachmentSize
invisimail_links_6.x.patch 3.73 KB

#10

jrust - April 14, 2009 - 16:50
Status:needs work» patch (to be ported)

#11

Crell - April 14, 2009 - 19:05
Status:patch (to be ported)» needs review

#12

ebrand - May 27, 2009 - 21:26
Status:needs review» reviewed & tested by the community

Here's the patch to work with the current version of invisimail. It seems to work great.

AttachmentSize
invisimail_work.patch 5.42 KB

#13

Crell - May 29, 2009 - 16:01
Status:reviewed & tested by the community» needs review

What was wrong with the patch in #9? Please don't set your own patches RTBC. Someone else needs to review them first.

#14

Crell - June 29, 2009 - 22:29
Status:needs review» fixed

Another patch addressed this issue already.

#15

System Message - July 13, 2009 - 22:30
Status:fixed» closed

Automatically closed -- issue fixed for 2 weeks with no activity.

 
 

Drupal is a registered trademark of Dries Buytaert.