in my wordpress site, the_content() is not showing the content, but $post->post_content shows it, why this is happening? and how can I use the_content again?
|
closed as too localized by toscho♦ Nov 26 '12 at 10:55
This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, see the FAQ.
|
If it worked before, it's probably a plugin hooking into the_content filter. Disable your plugins one by one to see if this fixes the issue. Next, check the callback functions for You can see every callback for the_content by adding the following:
Find each of the functions listed by doing a 'find in files' code search on your code editor. A filter callback HAS TO return $content data back for the_content() to work properly. |
|||
|
|
|
you can check your functions.php in your theme folder,find if some function do something for the "the_content" function.my theme have the same problem,and I found a function has a mistake and cause "the_content" can't work find text like "the_content" in your functions.php, |
|||
|
|
|
Easy peasy lemon squeezy! In order to use "the_content()" it must be used within The Loop. See here: http://codex.wordpress.org/Function_Reference/the_content "Displays the contents of the current post. This tag must be within The_Loop." |
|||||||||||
|