| User | Post |
|
5:32 pm 26 Sep 2007
| Walter
Guest
| | | |
|
| |
|
|
I’d like to show the latest post (or an excerpt of it) on my homepage. Is there any way to do this?
Thanks
|
|
|
|
|
Interesting question. I certainly have not provided any template tag that would provide for this. And if you used your own RSS feed and cut it down to one post it would spoil the feed for anyone else.
The answer really is that without getting your hands dirty in the code then no - there is no current way to do this.
Can you write php? If so I can create a sql query that you could use?
|
|
|
6:33 am 17 Jan 2008
| Ricotrutt
Guest
| | | |
|
| |
|
|
I can write php and have the same problem, can you write the sql query so that i can display the new posts in my homepage please ? That would be very nice of you
regards
|
|
|
|
|
yes I can but you need to tell me exactly what it is you want. One post? 5 posts? 10 posts? The post content itself? The posters name? The topic? Forum? Let me know and I can send you the sql.
|
|
|
3:17 pm 26 Jan 2008
| İSM@İL
Guest
| | | |
|
| |
|
|
I want it too. Show last 5 topics and list they.. Thank Yellow Swordfish..
|
|
|
|
|
Well this didn’t get done because nobody came back to me with details of that was wanted. So are you just after the SQL query
|
|
|
4:27 pm 26 Jan 2008
| Josh-B
New Member
| | | |
|
| posts 2 |
|
|
I’d like to be able to post that on my Blog Homepage. Any way of doing it?
|
|
|
|
|
The same question. Show what on your home page…?
|
|
|
4:50 pm 26 Jan 2008
| Josh-B
New Member
| | | |
|
| posts 2 |
|
|
Yellow Swordfish said:
The same question. Show what on your home page…?
Show the last 5 posts from the Forum on the homepage. Title & Some of the Post.
|
|
|
9:20 pm 26 Jan 2008
| İSM@İL
Guest
| | | |
|
| |
|
|
Add this code sidebar.php
<?php if (function_exists(’sf_recent_posts_tag’)) {
sf_recent_posts_tag(5, 1, 1, 1, 1);
} ?>
|
|
|
|
|
That doesn’t show the post content though… just the title.
|
|
|
10:45 pm 26 Jan 2008
| Mr Papa
Moderator
| | Arizona, USA | |
|
| posts 1256 |
|
|
We will add this feature to the upcoming 3.0 version… I should be able to make it work for the current version too and will post the resulting template tag so you wont have to change it when you upgrade… I hope to get it done this weekend…
or maybe not… backwards compatibility is gonna be difficult…
|
|
|
12:26 am 27 Jan 2008
| Mr Papa
Moderator
| | Arizona, USA | |
|
| posts 1256 |
|
|
For those of you who just want to display the last X number of topics on your front page, there is already a template tag to do this… it will not show any post content though… the tag is:
sf_recent_posts_expanded();
put the number of posts you desire within the ()… the default is 5…
however, since this is displayed outside of the simple forum pages, it doesnt get the proper forum appearance styling… you can fix this by forcing WP to load the SF styling on the front page… add this code to your header.php (or whatever file your theme uses to load the theme styles):
<?php if (is_home()) echo '<link rel="stylesheet" type="text/css" href="/wp-content/plugins/simple-forum/skins/default/default.css" />'; ?>
If you are not using the default skin, simply change that path to the SF skin you are using…
This will give you a very SF looking list of the last X number of topics…
|
|
|
12:01 pm 5 Jul 2008
| sebby
New Member
| | | |
|
| posts 2 |
|
|
|
3:25 pm 5 Jul 2008
| Mr Papa
Moderator
| | Arizona, USA | |
|
| posts 1256 |
|
|
absolutely you can… use one of the supplied template tags… this assume that the forum and page you reference are running on the same wp installation… if not, you can still do it, but you will need to write the code…
see the online help for information on the template tags, which one you want to use and how to use it…
|
|