Create a List of Categories?
-
I am trying to put a list of categories into my index.php
I inserted the following tag
<?php the_category() ?>
into the spot where I want the list to show, uploaded and then got the following error where the tag was inserted.
SQL/DB Error:
[You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near ” at line 3]
SELECT category_id, cat_name, category_nicename, category_description FROM wp_categories, wp_post2cat WHERE wp_post2cat.category_id = cat_ID AND wp_post2cat.post_id =
Warning: Invalid argument supplied for foreach() in /home/fetal/public_html/wp-includes/template-functions.php on line 1368
Is that tag the correct one to make a list of category links happen?
In the template-functions.php is it supposed to be category_”nicename” or is that a typo? I replaced all “nicemame” occurrances with “nickname” but still got the error.
Any thoughts or solutions?
Thanks
- The topic ‘Create a List of Categories?’ is closed to new replies.