Platon Technologies
neprihlásený Prihlásiť Registrácia
SlovakEnglish
open source software development oslavujeme 10 rokov vývoja otvoreného softvéru! Streda, 25. november 2026
O nás
Magazín
Otvorený softvér
CVS
Služby
Index  »  Projekty  »  phpMyEdit  »  Fórum  »  Display email addresses as a link

phpMyEdit General     Display email addresses as a link
Odoslať novú tému   Odpovedať na tému    
 
jim2point0     Založený: 31.07.2008   Príspevky: 8  
Príspevok Zaslal: 2008-07-31 18:47
Návrat hore  Odpovedať s citátom     

Hi. I want to edit PHPMyEdit a little bit. We're using it on our site to configure address books. Every address book requires an email address field. Where we display the form, I would like to change it from being static text to a mailto: link.

Basically, the email address will look the same (displays "person@someplace.com") but can be clicked on. The URL would be "mailto:person@someplace.com"

This doesn't seem like it would be hard, but I looked at the code and got a little scared. Is this easy to do? Can anyone help?

Thanks,
~James

 
michal     Založený: 17.06.2003   Príspevky: 537   Bydlisko: Slovakia
Príspevok Zaslal: 2008-08-01 10:16
Návrat hore  Odpovedať s citátom     

http://opensource.platon.sk/projects/doc.php/phpMyEdit/html/configuration.url-linking.html

 
jim2point0     Založený: 31.07.2008   Príspevky: 8  
Príspevok Zaslal: 2008-08-01 14:42
Návrat hore  Odpovedať s citátom     

I don't understand where to do this though. In "phpMyEdit.class.php" or phpMyEditSetup.php" maybe?

The class file is so huge that I'm afraid to try and guess where I would do this at in there....

 
michal     Založený: 17.06.2003   Príspevky: 537   Bydlisko: Slovakia
Príspevok Zaslal: 2008-08-01 15:17
Návrat hore  Odpovedať s citátom     

in the generated call script, the configuration php file. where $opts is defined.

do not touch phpMyEdit.class.php (unless you know what you are doing)

 
jim2point0     Založený: 31.07.2008   Príspevky: 8  
Príspevok Zaslal: 2008-08-04 20:02
Návrat hore  Odpovedať s citátom     

Unfortunately I think I may need to edit that class file after all. I misunderstood what needed to be done.

If ANY text appears to be a link of some kind, be it email or http, I need to have it display as a link. I already have a python function that does this, and I've called a few python functions from PHP before. However, I think I need to do this in the class file.

ANY cell in the table needs to be processed through this function before being displayed. So I need to know where to make this change. Basically, where in the class file should I go to change the output? There has to be a place that I can go to that is something like....

echo $valueToBeDisplayed

And change it to...

echo PythodMethod($valueToBeDisplayed)

If this is also done in the configuration file, that would be fantastic. I've no experience with extending phpMyEdit though.... so I don't know how to do this there.

 
michal     Založený: 17.06.2003   Príspevky: 537   Bydlisko: Slovakia
Príspevok Zaslal: 2008-08-05 15:34
Návrat hore  Odpovedať s citátom     

have a look at 'php' field option

 
Odoslať novú tému   Odpovedať na tému    

Copyright © 2002-2006 Platon Group
Stránka používa redakčný systém Metafox
Na začiatok · Odkazový formulár · Prihláška
Upozorniť na chybu na PLATON.SK webstránke · Podmienky použitia · Ochrana osobných údajov