hilj
Forum Replies Created
-
Forum: Fixing WordPress
In reply to: Permalinks “on” but images “gone”Always posting too hastily.
I found the following to work in my case:
$curl = str_replace('src="https://localhost:8888/wordpress','src="/wptest', $curl);
Just checking that is it done correctly? It works though.
Cheers.
Forum: Fixing WordPress
In reply to: Permalinks “on” but images “gone”I have a similar problem. I built my wp site locally. When I (idiot) added the photos to the site like shown below:
https://localhost:8888/wordpress/wp-content/uploads/2007/12/image.jpg
Theres lot of photos, it’ll be a tedious task for me to chance all of them. Can I use the code mentioned upper to get it done somehow? To replace the
https://localhost:8888
?Thank you.
Forum: Installing WordPress
In reply to: Nothing shows, theme disappears when istalled?Anybody?
Forum: Fixing WordPress
In reply to: posts_nav_link should include only one category?Ouch! I made a mistake. I was talking about the
next_post_link
andprevious_post_link
. I got mixed up when I searched with a previou_post_link and the result was the “next and previous links” article and not the “previous post link” article.next
andprevious_post_link
lets me exclude categories just as I wanted.There’s one litle really basic thing I couldn’t figure:
<?php previous_post_link('← %link','past', FALSE, '18 and 17'); ?>
The link is named “past”, I would like to see a post title there. I know the
%link
is just that, but if I leave “past” empty, like this:<?php previous_post_link('← %link','', FALSE, '18 and 17'); ?>
Nothing happens (obviously cause it’s empty) what should I put there to ignore it?
Thanks a lot for these. And sorry for mixing up the mix up.
Forum: Fixing WordPress
In reply to: posts_nav_link should include only one category?Okay, that makes sense.
I simply tried to ad a number in the end, like this:
single2.php
,sidebar2.php
no effect, it still browses trough all Posts.What should I call them then? Or should I build it somehow differently?
Thank you for this.
Forum: Fixing WordPress
In reply to: Understading conditional tags?Okay I got it! It works just fine. Thank you for your help! ??
Forum: Fixing WordPress
In reply to: Understading conditional tags?I first did that, in the second example:
Here, (lines, 5-9 and 37-39) when I use the else nothing shows.
I was just trying to wonder and ponder that what’s wrong with it, cause it’s not working, just plank page appears.
Then I tried to mess with it a to pin point the flaw. Obviously the flaw is not in the
if
statement but in theelse
statement.I’m reading about php all the time. For example here w3schools.com But just reading is not helping much (at least for me), by doing is better and that’s just what I’m doing here, with your generour help ??
Forum: Fixing WordPress
In reply to: Understading conditional tags?Thank for this. It partly works.
If I just put the whole upper mentioned code to the beginning of my single.php, it uses the single_blog.php like it should, but it shows, of course, in double.
If I try to use the
else
, to get rid of the double, it’s not working, nothing shows.This code (lines, 5-13) shows the single_blog.php like it should, but in double.
Here, (lines, 5-9 and 37-39) when I use the
else
nothing shows.This is kind of a complicated to such beginner as me, i’m getting there ?? Thanks.
Forum: Fixing WordPress
In reply to: Understading conditional tags?I just came up with another problem. The single post pages for my blog posts. Of course I took all the comment related stuff away from the single.php cause I was using Posts to display normal website stuff.
What conditions should I use here to guide the single posts to be viewed according to say, single_blog.php template file?
Forum: Fixing WordPress
In reply to: Understading conditional tags?New one is here, is that what you meant?
Anyway it works! Thank you!You’re using the show:
<?php if (is_category(18)) { show blog.php; }
I’m using:
<?php if (is_category('18')) { include(TEMPLATEPATH . '/blog.php'); }
I tried to use that
show
, but it didn’t work?Thak you for this.
Forum: Fixing WordPress
In reply to: Understading conditional tags?Wow, pastebin. I didn’t know such existed.
Here’s my archive.php
In line 5 you can see
if include
thing.Thank you.
Its the archive.php (might be also somewhere else, depending in the theme) sort of this looking thing:
Posted in <?php the_category(', ') ?>
. Mine says “Posted in” instead of the “Filed Under”. Just remove it, or chance the text, or move it to another place.I’m rather a rookie myself, correct me if I’m wrong.
Forum: Fixing WordPress
In reply to: Displaying news (or what ever) in a second sidebar?I read the https://codex.www.ads-software.com/The_Loop file. It says that “If the post is in the category we want to exclude, we simply pass to the next post.”
<?php if (in_category('3')) continue; ?>
So I’m trying to exclude the Posts in the “NEWS” gategory from displaying in the main “entry” div, and to display in the second sidebar.
The_Loop file also says that “Get the last 10 posts in the special_cat category.” Like this:
<?php query_posts('category_name=special_cat&showposts=10'); ?>
I try to put that in my second sidebar, but I cant do any of this.
My index.php looks like this.
<div id="content" class="narrowcolumn"> <?php if (have_posts()) : ?> <?php while (have_posts()) : the_post(); ?> <?php if (in_category('NEWS')) continue; ?> <div class="post"> <h3 id="post-<?php the_ID(); ?>"><?php the_title(); ?> <cat><?php the_category(', ') ?></cat></h3> <div style='border-bottom:1px #aaa solid;width:100%;'> <div class="entry"> <?php the_content('More ↓'); ?> </div> </div> <?php endwhile; ?>
So how to include and exclude categories?
Thanks
Forum: Fixing WordPress
In reply to: WordPress as cms, menusHmm…
This is the whole list as the browser puts it out. As you see the first<li>
, doesn’t end until in the very end of the whole list, like it should be, as far as I know. But that makes also the SubItems to be exposed to thecurrent_page_item
styling. I dont know… how should this be built?<li class="page_item current_page_item page_folder">Item1 <ul> <li class="page_item">SubItem1 </li> <li class="page_item">SubItem2 </li> <li class="page_item">SubItem3 </li> <li class="page_item">SubItem4 </li> <li class="page_item">SubItem5 </li> <li class="page_item">SubItem6 </li> </ul> </li>
The list in my sidebar.php file, looks like this (theres also a list of categories and the abmin link):
<li><h2><?php _e(); ?></h2> <ul> <?php wswwpx_fold_page_list ('depth=2&sort_column=menu_order&title_li='); ?> <?php wp_list_cats('depth=2&sort_column=menu_order&title_li='); ?> </ul> </li> <li><h2><?php _e(); ?></h2> <ul> <small><?php wp_register(); ?></small> <?php wp_meta(); ?> </ul> </li>
But anyway, thanks a lot for your support so far.
Forum: Fixing WordPress
In reply to: WordPress as cms, menusIt all looks good to me. The sub page items are
class="page_item"
and I can’t figure why thepage_item
doesn’t effect it.The css looks like this:
.page_item a { color: #c7baa3; } .current_page_item a { color: #333; } .current_page_parent { color: #333; }
And the browser shows the html like this:
<li class="page_item current_page_item page_folder"> <ul> <li class="page_item"> </li> <li class="page_item"> </li> <li class="page_item"> </li> <li class="page_item"> </li> <li class="page_item"> </li> <li class="page_item"> </li>
thank you