Log in

View Full Version : trying to mod bbcode


dethfire
04-06-2004, 04:01 PM
hey all, I though it might be cool if we could surround common acronyms with an html acronym tag. For example, lets say you run a computer hardware site. The extended bbcode will find ddr, raid, amd and will underline them and give them a tool tip so people can easily understand the meaning of the acronym. Think it would be hard?

dethfire
04-06-2004, 05:05 PM
I tried just adding this code to the bbcode functions file but it didn't do anything


// ACRONYM TEST
// LGQ
$bbcodes['custom']['find']['LGQ'] = '#\LGQ\#esiU';
$bbcodes['custom']['replace']['LGQ'] = "handle_bbcode_parameter('\\1','" . str_replace("'", "\'", '<acronym

title=Loop Quantum Gravity><u>\1</u></acronym>') . "')";
$bbcodes['custom']['recurse']['LGQ'][0] = array('replace' => 'LGQ');