News:

Bored?  Looking to kill some time?  Want to chat with other SMF users?  Join us in IRC chat or Discord

Main Menu

use ssi function to add forum theme to webpage

Started by bullbreedluverz, May 18, 2009, 06:23:54 PM

Previous topic - Next topic

bullbreedluverz

as the title says i want to create a webpage using the theme from my forum with the header, logo, background and other images creating the webpage but without any ssi functions

ive created a page, that shows the theme but it also shows my menu & shoutbox and i dont want them on my webpage

this is the code im using


<?php

$ssi_layers 
= array('main');
$context['page_title'] = 'Welcome To Bull Breed Luverz!';

require(
"/path/to/my/root/smf/SSI.php"); 

?>


and the result is

http://www.bullbreedluverz.com/

but i want dont want that i just want the themes look rather than functions/features too

niko

You need to edit your theme to skip these sections when using SSI.

easiest way is check if constant SMF is (not) SSI.

For example (assuming template_menu does show the menu)

if (SMF != 'SSI')
    
template_menu();
Websites: Madjoki || (2 links retracted by team, links out of date and taken over.)
Mods: SMF Arcade, Related topics, SMF Project Tools, Post History

WIP Mods: Bittorrent Tracker || SMF Wiki

bullbreedluverz

#2
sorry (and im going to make myself look thick here) but i dont understand what you mean

ive never done anything with SSI before so really complete novice with it - i get i need to exclude some of the template showing - i.e. menu and shoutbox but what you said doesnt mean anything to me lol

the attatched image shows what i would like to achieve on my webpage (although ive edit my forum bit more today so the appearance is bit different http://www.bullbreedluverz.com/smf/index.php )

[SiNaN]

SMF 2.0 has the layers changed. Use this $ssi_layers instead:

$ssi_layers = array('html', 'body');
Former SMF Core Developer | My Mods | SimplePortal

bullbreedluverz

changing

<?php

$ssi_layers 
= array('main');
$context['page_title'] = 'Welcome To Bull Breed Luverz!';

require(
"/path/to/my/root/smf/SSI.php"); 

?>


to

<?php

$ssi_layers 
= array('html''body');
$context['page_title'] = 'Welcome To Bull Breed Luverz!';

require(
"/home/bullbree/public_html/smf/SSI.php"); 

?>


gave me...

Unable to load the 'html_above' template.

SA™

move

$ssi_layers = array('html', 'body');


underneath

require("/path/to/my/root/smf/SSI.php");

maybe?
http://samods.github.io/SAChatBar/

Xbox Live: smokerthecheese 360 or xbone
My Work
Piano Movers / Delivery service
QuoteMy allies are dead.
I'm 'bout to be too.
Zombies are chasing me.
F*** it, I'm screwed -___-

bullbreedluverz

that gave me a blank white screen

any more offers???? lol

[SiNaN]

Reading your post again, with a fresh mind, I see I misunderstood your issue. Indeed, you have to hide the things that you don't want to be shown on SSI, as Niko pointed out.
Former SMF Core Developer | My Mods | SimplePortal


bullbreedluverz

its ok im marking this as solved now as ive made a webpage from my forums source code - thanks

Advertisement: