• I would like to have certain words in my blog to be linked to glossary pages I will be adding, and in some cases I want some text to be replaced by images I will be using a lot. Rather than go through and manually add all these links, is there a plugin that will do it for me? Something that will spider my content, and find the words I add, with links defined manually?

Viewing 4 replies - 1 through 4 (of 4 total)
  • This plugin replaces words with anythigs (as the author say)

    http://www.biggnuts.com/link-a-dink/

    So maybe you can use it to display images as well..
    Never tried it , and do not know how the HTML will be parsed.
    But at any rate, it is a simple function to write , to be added to your functions.php (only less flexible than the plug)

    <?php
    
    /*
    Plugin Name: Replace word with image
    */
    
    function replace ($text) {
    $text = str_replace('word', '
    <img src="next.jpg" /> ETC.ETC....
    ', $text);
    return $text;
    }
    
    add_filter('the_content', 'replace'); ?>

    this is the basic plugin/function,
    Now if you want it to be flexible with an interface, some DB integration is needed, but if you only have 2-3 words, you can use simple functions.
    Nice idea for someone to develop though.

    Thread Starter lowlight

    (@lowlight)

    I would definitely be adding a lot of words… For instance a deck of cards would have 52 entries in itself.. I just want to be able to say, write :Qh: and it will replace it with an image tag for the queen of hearts.

    If someone knows of a plugin, let me know!

    Thread Starter lowlight

    (@lowlight)

    Well I just figured it out – just use smilies! There is a plugin that allows custom smiley management, so I am just using that.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Automatic Text Replacement’ is closed to new replies.