Justyna Ratajczak
Forum Replies Created
-
Forum: Fixing WordPress
In reply to: Displaying categories in two-level droplineStill looking for a solution.
Forum: Fixing WordPress
In reply to: Displaying categories in two-level droplineShameless bump. Anyone able to help?
I also noticed I didn’t close the ul tags. So the code should be:
<ul id="nav"> <?php wp_list_pages('title_li=&depth=1'); ?> <./ul> <?php if($post->post_parent) $children = wp_list_pages("title_li=&child_of=".$post->post_parent."&echo=0"); else $children = wp_list_pages("title_li=&child_of=".$post->ID."&echo=0"); if ($children) { ?> <ul id="subnav"> <?php echo $children; ?> <./ul> <?php } else { ?> <?php } ?>
Edit: Please ignore the dots in closing tags. Couldn’t make the preview here work without them.
Forum: Fixing WordPress
In reply to: Displaying name of current page in query_posts?Yes, I understand I can’t make two categories with the same slug. I was more worried about a Page, let’s call it “Latest News” and a category with the same name. Will both have a slug of “latest-news”?
I don’t really plan to make two pages or categories with the same name, so the case you described shouldn’t happen.
Forum: Fixing WordPress
In reply to: Displaying name of current page in query_posts?Oh, that makes sense! Sorry for a newbie questions but will the slugs of page and category with the same name will be exactly the same then? If so, I guess I have my solution. Will test it later.
I also found a plugin called WP Extra Template Tags which has a
_category_slug()
– guess I could use that instead.Forum: Fixing WordPress
In reply to: Displaying name of current page in query_posts?I haven’t tried that yet, but I’m not sure it will work.
First of all,
$post->post_name
returns the slug of the page/post, not the name itself, while thecategory_name
parameter ofquery_posts
requires the name. So the “Latest News” page will be be displayed as “latest-news” in my variable and the query will look for “latest-news” category, instead of “Latest News”.So the question is, is there anyway to pass a category slug into
query_posts
and/or get a page *name* instead of slug?Forum: Fixing WordPress
In reply to: Comment submit button doesn’t seem to work.Yes, the default theme looks just fine.
Is there any way I could do something wrong within my theme to cause that weird behaviour? Again, the problem doesn’t seem to be in the comments.php file itself :/
Forum: Fixing WordPress
In reply to: Comment submit button doesn’t seem to work.Any ideas? This doesn’t seem like a code mistake to me anymore :/
Forum: Fixing WordPress
In reply to: Comment submit button doesn’t seem to work.Yes, I have everything just like in the Codex, both in comments.php and header.php.
Now, the weirdest part is, I copy-pasted the code from this blog post – it gave me the exact same “effect” – the “submit” button doesn’t work at all. Nothing happens.
For a moment I thought it may be an issue that I have WP installed locally so I uploaded everything, activated my theme and it still doesn’t work. Form keeps displaying “Send” button under the textarea.
So I have now two pretty much different versions of comments.php file, BOTH with the same result – not working submit button…
Forum: Fixing WordPress
In reply to: Comment submit button doesn’t seem to work.Bump for making sure I had
<?php if(is_singular()) { wp_enqueue_script('comment-reply'); } ?> <?php wp_head(); ?>
in my header – and I do.
Still no idea what causes the problem.
Forum: Themes and Templates
In reply to: How to highlight current nav tab?Thank you, that was easier than I thought.
Guess I should have taken a sneak peek into the code before ??Thanks again!
JustineForum: Themes and Templates
In reply to: Paginated posts on a static page?Bump. Still looking for a solution.
Forum: Themes and Templates
In reply to: Paginated posts on a static page?Hi,
Nope, still doesn’t work – I put<?php previous_posts_link('Previous') ?> <?php next_posts_link('Next'); ?>
just after the endwhile this time, to make sure if it’s displayed, and it doesn’t show these links at all.