News:

SMF 2.1.4 has been released! Take it for a spin! Read more.

Main Menu

Simple front page?

Started by Xipe, November 11, 2005, 03:33:25 PM

Previous topic - Next topic

Xipe

I've looked through the portals available and they're simply a bit overkill for what I am looking for. Since I am thinking that what I want could easily be made by using SSI.php I wanted to ask you some questions:

1. I use the default SMF theme
2. On my "front page" which will reside on a /portal.php url I want:
- The default theme
- The header portion (with login, news boxes and stuff)
- Under the header I want to mix and match various SSI.php functions, like latest posts, a poll or two, the news and user who are online.

I.e. basically I want the index.php but with the forum listing substituted with news and latest posts.

My hope is that I should be able to just load the theme somehow, ask for the header portion to be displayed and then add SSI.php functions and that the default theme would be applied to the output automatically?

Is this viable without having to rewrite other SMF files? I was kind of hoping, for upgrade purposes if nothing else, that I would be able to do all the coding in portal.php, and that most of it would consist of calling SMF functions?

Any help appreciated!

(PS - Hope this is the right forum to post in)

Questin

I quote this, there should be a simple php page with a css style named index.php on the root folder who calls the ssi functions. This would be the front page of the forum.

Varment

Why try and recreate the wheel.
Sounds like you are looking for this TinyPortal [nofollow];)

1MileCrash

umm..
QuoteI've looked through the portals available and they're simply a bit overkill for what I am looking for.

so i guess he's/she's seen tinyportal?

QuoteMy hope is that I should be able to just load the theme somehow, ask for the header portion to be displayed and then add SSI.php functions and that the default theme would be applied to the output automatically?

YEP! you can do that. that's exactly what i do for model98.org. Very easy too.


<?php

$ssi_theme 
1;
$ssi_layers = array('main');
require_once(
'SSI.php');
?>

put whatever you want here! ssi functions as well. since ssi is already included to load the theme, you dont need to do that again.
<?

ssi_shutdown();

?>


see the $ssi_theme = 1;? replace the 1 with the id of the theme you want to use.

see this topic for more info
http://www.simplemachines.org/community/index.php?topic=42460.0
The only thing php can't do is tell you how much milk is left in the fridge.



mattduke

For "Non coder" it would be AMAZING if I could get some sort of template PHP file, that called SSI scripts and put them into "Tables" etc.

I just want a nice front page that calls the SSI, and allows be to chop & change a bit.

But SMF is so amazing, and SSI is truly excellent, I can't really expect people to put it on a silver plate for free.

I guess I just have to learn how to code!

If anyone has exmple code they would share, I would bew very greatful.

wing

Not sure exactly what you want to do, but is something like my front page?

http://www.cartalkcanada.com

The first story is sucked in from my blog software, the second story is from the forum.  The news scroller on the left is from the news from the smf database and the scroller on the right is the most recent posts.

mattduke

Quote from: wing on January 20, 2006, 02:05:33 PM
Not sure exactly what you want to do, but is something like my front page?

http://www.cartalkcanada.com [nofollow]

The first story is sucked in from my blog software, the second story is from the forum.  The news scroller on the left is from the news from the smf database and the scroller on the right is the most recent posts.

Excellent!

psychophat

Even still its amazing and I really liked it. Are you going to add stuff on the lower left and right sides? By the way what blog software you using, is it easy to use and can it be connected to SMF's member database?
I adore this forum, from zero PHP knowledge to +.1% per post
I'm going to get the charter member thinggy when I get to save some cash
SMF v.1.1RC2
PHP v.4.3.11

HoTmetal

What about using the SSI.php & building an HTML templete based off your favorite theme.?

psychophat

Also maybe a static content frontpage/page with SSI includes.
I adore this forum, from zero PHP knowledge to +.1% per post
I'm going to get the charter member thinggy when I get to save some cash
SMF v.1.1RC2
PHP v.4.3.11

1MileCrash


<?php

$ssi_theme 
1;
$ssi_layers = array('main');
require_once(
'SSI.php');
?>

put whatever you want here! ssi functions as well. since ssi is already included to load the theme, you dont need to do that again.
<?

ssi_shutdown();

?>
The only thing php can't do is tell you how much milk is left in the fridge.



gerrymore

I agree wiht Tipmaster. That code works prefectly. You can use a table(s) to dictate where you want the different ssi functions to display. Its easy enough to make and use.
SMF RC1, Tiny Portal 0.75, Coppermine 1.3.3, Flashchat.

wing

Quote from: psychophat on February 12, 2006, 06:38:15 PM
Even still its amazing and I really liked it. Are you going to add stuff on the lower left and right sides? By the way what blog software you using, is it easy to use and can it be connected to SMF's member database?

You asking me?

Lower left and right sides?  Not sure what you mean there the page is full....

I am using WordPress for my blog software, it can be connected to the SMF's member database for posting comments that is how I did it using the SSI.php script.   But in order to allow users to post blogs you would have to add some fields to the SMF database as wordpress uses a system of 1-10 for user priveledges.

Advertisement: