Recent Topics

1 Sep 21, 2005 18:19    

I am using stub file to limit the posts to display only one. The posts are quite lengthy...

It has been asked before, but i cannot find an answer.

I would like to show all the posts when i choose the category.

I am not skilled enough in PHP to write this myself, but shouldnt it be possible to do something like this

If category is true
$posts = '50';
else
$posts = '1';

When a category is chosen then the url is filename.php?cat=18

So if cat is equal to something, then a category is chosen in the sidebar.

Or mayby you could do something in the /skin/_caetgories.php or the _main.php

Hope someone has an anwer :)

2 Sep 21, 2005 18:25

Just a guess here, but worth trying. In your skin's _main.php file up near the top, like right after the <body> tag, try this:

<?php if( $cat >= 1 ) {
$posts = '50';
} ?>

It only exists here though - never tested, and might be useless. Can't hurt to find out eh?

3 Sep 21, 2005 19:45

It doesn't do anything. Not even a tiny error.

Even tried in the stub file, but that just inflicts a parse error.
UPS, no error just removed the start tags. I really am new to php.

Hmmm there must be a way. Thanks for the try :)

4 Sep 22, 2005 19:34

You can trick the blog to do what you want....

Lets say my blog is called crime books, and it is displaying all the posts.

If i make a stub file that calls the crime books, that displays 1 post. If I do not change the original blog to call to the stub file, then I have my 1 post in my stub file, and if i click one of the categories in the stub file, then it links to the original crime blog which displays all the posts in that category!!!!

If i use the same skin, nobody will see the change as it is the same blog.

Hmmm I would like to have different settings for the posts, and the category listings. :)

Hope someone can use this


Form is loading...