Wordpress comments not showing up on posts - php

I'm working on rebuilding a friends website however cannot get the wordpress comments to show up on posts, I have tried disabling all plugins, switching themes (even default themes) but the comments still do not show up.
This is the first time I've worked on a wordpress site and all the posts I can see from people with the same issue resolved it either by disabling plugins or switching themes (usually issues with single.php which the theme I'm using does not have that file).
Any ideas?
URL for the site

Looks like there are no comments on that site, the "Comments feed" is empty: http://happybody.co.nz/comments/feed/

Have you checked SETTINGS > DISCUSSIONS > Allow people to post comments on new articles - or any of the other Comments Settings there?

In the file sigle-post.php or like some Think similar in the theme folder, find the function get_post_commets($post->ID) and delete.
May be exist an foreach to show a result of the function one by one.
Get lucky.

Find get_post_comments() function ... In wordpress site support.

So I've just figured out why the comments section does not show up, when I recreated all the posts from a cached copy of the site from archive.org/web I never ticked the box on each post under "discussion" for "allow comments".

Related

Wordpress blog posts have no <a href="url_to_blogpost">

I have encountered a very weird issue after the last update to WP 4.4.1 and it's that the href attribute on all blog posts in the website.com/blog section are missing, so the link looks like this:
Most read articles in the previous year
The articles are normally accessible and have the href attribute from the front page of the blog, where they point to: website.com/texts/name_of_the_blogpost just not from website.com/blog
Did anyone else ever experience such an issue, and could the update of WP be the reason for it? Everything worked normally until the update.
Your theme may use a now deprecated (under 4.4.1) WordPress function. Switch to the default WordPress twentyfifteen or twentysixteen theme for a minute and see if the php function correctly outputs the URLs of the blog posts. If so, it's your theme. Talk to the theme developer or take a look at the functions in theme files, the query loop, etc. No one can help more until you post some code.

Post content only visible when only logged with admin

Check live- http://mylistoflists.com/9-football-season-snack-ideas/
Post content only visible when i logged with admin, due to my low knowledge on wordpress i am not sure how to fix that.
N: B: Post visibility set as PUBLIC!
Without Admin
With Admin
My guess is that your post is set to Private in the Post settings in the posts tab on your dashboard.
You have to click on edit and then choose public instead.
EDIT:
First Look at your trashcan. If there are posts with the same name it can conflict with the new post. Try to empty your trashcan.
Second: Are you using a cache plugin? Try to disable this and see if that fixes it.
Only Admin can see your code:
<?php if(current_user_can('administrator')): ?>
//put your code part only admin can see
<?php endif; ?>
your problem will solve with one these of solutions:
first check that post published in public mode.
if you have a cach plugin or any speed boost plugin, first deactive that plugin and see that problem resolved or not?
if above solution not work, then deactive all plugins of wordpress and check again,
and also if above solution not work, change your wordpress theme to default theme like twenty seveteen and check that problem solved or not
Deactivate "W3 Super Cache" Plugin or any cache Plugin. It works for me. Hopefully, it will work for you.
DELETE htaccess file, is the only 100% working solution.

Standard HTML & CSS to wordpress page

I created a webpage in Standard HTML and CSS and everything looks / works exactly how I want it too.
Now I need it to appear as it is on a wordpress site (http://www.texasenergyessentials.com/). I already created a template page and can see it in the template select in the wordpress "add new page" window. I was hoping I could just select the template and leave the text editor blank but that doesn't seem to be the case. All I get is a completely un-formatted page that says welcome guest.
What is the easiest way to get https://gist.github.com/anonymous/8545681 to work on the aforementioned wordpress site? ?
Thanks!
P.S. Please don't link any codex files I just spent 2 hours digging around in them :(
Try to read and understand how http://codex.wordpress.org/The_Loop works
Install this theme https://code.google.com/p/wordpress-naked/ and try to work your way to the desired theme by editing theme files. That will be much easier.
Maybe the problem can be understood by reading the template hierarchy:
http://codex.wordpress.org/Template_Hierarchy
(especially check the visual overview)
If you name your file page-[insert-page-id-here].php Wordpress will use it for the page you've created. Get your page id by editing the page and looking it up in the url.

Create second, fully customisable loop page in Wordpress

I'm looking to do something with a website I'm working on. This is my first time using Wordpress, and I've got most of the things I need to work running fine.
However, I'd like to create another page on my website that can display loop posts that is formatted completely different from the normal index.php file.
For example, index.php has it's own loop, and acts as the website homepage. The second page would be called roster.php, and has a loop that displays and formats posts from a specific category of posts. If this is possible, where would I create the roster.php file, and would it still work properly with my Wordpress installation?
I've dug around the Wordpress Codex, and done several Google searches on this subject, but I can't seem to find anything similar to this scenario. Or maybe I've just misunderstood them all.
I really appreciate your time reading this post, anything you can contribute would be extremely useful to me.
Thanks again, Callum Kerr
You can create a page roster in wordpress and a page-roster.php in your template directory. Wordpress will automatically route the page to the php file.
You can then do a custom search & loop in page-roster.php
page-roster.php should do the trick!
Check this for more info: http://codex.wordpress.org/Pages#What_Template_is_Used_to_Display_a_Particular_Page.3F
You can create custom Templates for your pages, posts and even categories, this Codex Page may help you with examples on how to do it.

How to override a disqus comment count with the comment count from my Wordpress theme

My first question here! I want to override the disqus "1 Comentario y 0 Reacciones" from the left part of the theme to just the comment count. It shoud look like the image attached.
I have searched the database for a similar problem but no luck.
Here is my blog in the test server if you want to check out.
I have tried to put this code in the functions.php of my theme so the Disqus doesn't override the comments from the theme.
// Disqus: Prevent from replacing comment count
remove_filter('comments_number', 'dsq_comments_text');
remove_filter('get_comments_number', 'dsq_comments_number');
remove_action('loop_end', 'dsq_loop_end');
Also the output Javascript option in the Advanced options of the Disqus plugin, But no luck with that. Hope someone help me (I will owe you a beer!)
Update: Apparently the problem happens in the home, category, search pages but not in the single post.
Ok after looking #dInGd0nG post link I found the simple solution to this problem. Just go to functions.php of your wordpress theme and insert this snippet:
// Disqus: Prevent from replacing comment count
remove_filter('comments_number', 'dsq_comments_text');
remove_filter('get_comments_number', 'dsq_comments_number');
remove_action('loop_end', 'dsq_loop_end');
That's all. And it's better than going to the Advanced tab from the Disqus plugin and outputting the Javascript in the footer, since that would make it slower.

Categories