Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- /* Tiki-Wiki plugin EMENCR */
- function wikiplugin_emencr($data, $params) {
- extract ($params,EXTR_SKIP);
- if (!isset($email)) { return ("<b>missing email address parameter for plugin</b><br />"); }
- $em = explode("@", $email);
- $ed = str_split($em[1], (strlen($em[1])/2)+1);
- $at = "'+\"&#\"+eval(60 + 4)"; # formula to create the number 64 for at sign
- $ret = "{JS()}document.write('<' + 'a h' + 'ref=\"m'+'grailto:z'.substr(2,6)+'";
- $ret .= $em[0].$at."+';'+'" . $ed[0] . "'+'" . $ed[1];
- if ("$data" == "") { # no data for link so make email address the link
- $ret .= "\">".$em[0].$at."+';'+'" . $ed[0] . "'+'" . $ed[1] . "</a>');{JS}";
- } else { # there is data so make it the link
- $ret .= "\">" . $data . "</a>');{JS}";
- }
- return $ret;
- }
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement