We are creating a table as a contact Directory and need to use the email guardian module to filter email address, but the table wont allow php coding... How can I get this to work.

Comments

pobster’s picture

I'm actually replying to this using my WAP enabled mobile phone as I've no other access to the internet - it's probably costing me a fortune! (...This is why development for tablemanager has ground to a halt)

Anyways, as far as I'm aware you ahhhhh, select php from the list of filters and just enter it? It worked for me when I tested it very early on? I take it you've tried selecting the php filter right...? Don't forget you need to tag it correctly like <?php print "hello"; ?> or whatever.

Pobster

llizards’s picture

That is correct... I used the code you gave and it still says "The specified field contains some illegal code."

the only thing I found on this was http://drupal.org/node/37530

the guardian filter has to have php to work I have tried allowing it on html but with no luck.
the info being entered is just text so someone@domain.com then it should filter that into an image that links to a form so harvester cant get your emails. The guardian filter works great on php pages or full html allowing php tags.

pobster’s picture

I hate to be the bearer of bad news but I've just added some php code to one of my own tables and it works fine for me... Please remember that I'm having to do this on a pocket pc phone using WAP so I'm not going to be your best bet for support on this matter. All I can tell you is that you're doing something wrong... I think your best course of action is to open up tablemanager.module and delete all the code in the function "tablemanager_validate" - DON'T delete the function call itself as the module will then throw up errors where it tries to call it in other places in the code - literally just leave it like this:

function tablemanager_validate(...whatever the variables are....) {
return;
}

If it works - let me know as its an error in my code. If it doesn't work, then try asking for support in the forum as it's not going to be an issue with this module.

Hope this helps

Pobster

pobster’s picture

Hang on a minute... You call it a 'filter'? Is it a Drupal filter? Is it being displayed on the list of available filters on tablemanager? This isn't as straightforward as I read it is it? You're actually trying to use a module within my module right? If so, that brings up a whole new range of problems...

Can you explain your problem a bit better for me to understand? Try and completely break down each step of what you're trying to do.

Thanks

Pobster

llizards’s picture

That is correct it's the guardian

http://www.tuna.org/guardian/

It is a filter that checks post for emails and converts them to an image link to a form.. This has worked in the page module, but only as part of the php input filter.

I think you have a great module here and I hope you dont quit the work on it. I am using it to create a contact directory but I need to hide the emails. Also the sort wasnt working... Is there a patch for that.

pobster’s picture

Hiya!

Yeah the sorting is a known issue - to fix it just display the table with a list length/ pagination amount (can be 1000 or whatever to show all results). I was working on it beforehand and I know how to fix it, I just don't have a PC to fix it with at present.

I'll look into your problem next time I have some PC access.

Pobster

llizards’s picture

I did try the tablemanager module on another server without any email protection filter and it still wouldn't allow me to use php.. I did remove the validation part between the tags and I get no error but it automatically switches the input filter to filtered html regardless of what filter you select.

pobster’s picture

Ah no I think you're wrong... All that is happening is that I couldn't work out the proper technique for the input filters (and no-one seemed willing to help me) so every time you look at an entry the input filter starts at the first one (which is usually the filtered html option) - to test, take a look at your entries in the database and see which filter they are numbered with.

Pobster

pobster’s picture

Status: Active » Closed (fixed)