I’m looking to replace text that I put into my posts and pages.
For example, if I put in ##funnypic## somewhere in the page/post text, I’d like to replace it with an html image.
To avoid having the same code on several pages I imagine I’ll need a function somewhere.
Any recommendations on doing this? Each page outputs “the_content()” so I assume I need to alter that somehow with an str_replace()?
- The topic ‘How to replace text inside of posts and pages’ is closed to new replies.