Here's the code: ------------------------------------------
Getting Syntax Error In this Code of 18 Lines (php)
8
Here's the code:
------------------------------------------
<?php if (is_category()) {
$this_category = get_category($cat);
if (get_category_children($this_category->cat_ID) != "") {
echo "<ul>";
wp_list_categories('orderby=id&depth=1&show_count= 0&title_li=
&use_desc_for_title=1&child_of='.$this_category->cat_ID);
echo "</ul>";
}
}
else { ?>
<ul>
<?php $recent = new WP_Query("cat=1&showposts=3"); while($recent->have_posts()) : $recent->the_post();?>
<li><a href="<?php the_permalink();?>"><?php the_title(); ?></a></li>
</ul>
<?php
} ?>
------------------------------------------
I'm unable to find as to where exactly is the error?:rolleyes:
Can anybody help?
Thanks in advance
Bhupinder
------------------------------------------
<?php if (is_category()) {
$this_category = get_category($cat);
if (get_category_children($this_category->cat_ID) != "") {
echo "<ul>";
wp_list_categories('orderby=id&depth=1&show_count= 0&title_li=
&use_desc_for_title=1&child_of='.$this_category->cat_ID);
echo "</ul>";
}
}
else { ?>
<ul>
<?php $recent = new WP_Query("cat=1&showposts=3"); while($recent->have_posts()) : $recent->the_post();?>
<li><a href="<?php the_permalink();?>"><?php the_title(); ?></a></li>
</ul>
<?php
} ?>
------------------------------------------
I'm unable to find as to where exactly is the error?:rolleyes:
Can anybody help?
Thanks in advance
Bhupinder
- Shounak Gupte
- imarketstuff
- [1] reply
- howudoin
- howudoin
- [1] reply
- Luke Graham
- [1] reply
- imarketstuff
Next Topics on Trending Feed
-
8