PDA

View Full Version : Replace certain text with link


MikesSite
10-11-2009, 03:32 PM
I'm looking for a mod or somebody to make me a mod that will make specific text a specific link.

For example is anybody types espn the text would still say espn but be a link to ESPN.com.

Thanks.

Lynne
10-11-2009, 03:37 PM
Just use str_replace. I've posted a plugin to do this several times and I think someone even posted it in the mods forums.

MikesSite
10-11-2009, 07:53 PM
Could you show me how to replace the word espn with

<a href="http://www.espn.com">espn</a>please?

Lynne
10-11-2009, 08:10 PM
I would replace " espn " with the link (notice the spaces around the word) otherwise you could cause conflicts with links that have espn in them (like espn.com).

Did you find the modification or thread that shows you the plugin to use for this?

MikesSite
10-11-2009, 08:22 PM
Thanks. No I did not. Can you please send me a link to it?

Lynne
10-11-2009, 09:49 PM
I just did a search for "replace*" in "all mods" "titles only" and found these - Replacement Words In Posts (https://vborg.vbsupport.ru/showthread.php?t=149118&highlight=replace%2A) and Word Replacement (https://vborg.vbsupport.ru/showthread.php?t=93758&highlight=replace%2A) . I know there are others, including threads not in the mods forums. If those threads aren't what you want, try a search on the word "replace*" to find other similar threads.

MikesSite
10-11-2009, 11:20 PM
Thank you, the first one is what I was looking for.