you want the code to execute or just be displayed? your question isnt clear?
You cannot simply paste php, (or any language for that matter) into a post, especially if you want it to be executed.
Thread Starter
teccus
(@teccus)
Well I want that image from that post to be displayed only if it is on the single.php…
So eg..
Text text text
<display pic if is single.php
Text text text
Why can’t I use php in my post?
Why can’t I use php in my post?
Because its not “safe” for starters. Because the wp devs care. Doesnt really matter.
The solution is easily found though via that magical search function:
http://ww.wp.xz.cn/search/php+inside+a+post?forums=1
Thread Starter
teccus
(@teccus)
Yes the search function is magical. But none of those posts solve my problem. The plugins only allow ‘Echo’..
They don’t allow me to do if(is_single()), do they..
I reckon if you cannot find a plugin that works than youre left to code your own plugin, ask someone else to write you a plugin, or find another way to accomplish whatever it is you’re trying to do.