String Replace with the_content()
-
Hello,
I am rather new to WordPress. I am trying to figure out how to transform a custom tag into an anchor tag. I’ve created a special tag to markup my posts that I would like converted into a link to the proper page when viewed.
My tag takes the form of: <def Id=”itemid”>linkname</def>. I want it converted when the page is displayed to: linkname.
I tried doing a ‘str_replace()’ on the ‘the_content()’ function, but that didn’t seem to work. Is there an easier way to do this? Otherwise, in what file is ‘the_content()’ located? (I would prefer to do this in the template as opposed to editing that function.)
Thank you in advance for any tips.
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘String Replace with the_content()’ is closed to new replies.