Is there any way to have Javascript in the post title in order to use if/else statements to output strings?
I want to output £ for UK and $ for US in the post title on the same post (using Maxmind Javascript Geo).
Thanks!
Is there any way to have Javascript in the post title in order to use if/else statements to output strings?
I want to output £ for UK and $ for US in the post title on the same post (using Maxmind Javascript Geo).
Thanks!
Is there any way to have Javascript in the post title
No.
Having given this some more thought, you might be able to write a function that grabbed wp_title() or similar, ran your javascript, then concatenated the appropriate symbol to the title and echoed the final value instead of wp_title() itself.
You must log in to post.