News:

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

Main Menu

Basic SSI FAQ

Started by Tomer, June 23, 2004, 05:06:24 AM

Previous topic - Next topic

<--Atlas-->

I heard there is a new API that is not SSI is this true, and where can I find more info on it?
There are two main products that come out of UC Berkeley: BSD and LSD -- We don't see this as a coincidence. --

I swear by my life and my love of it that I will not live for the sake of another man, or ask someone to live for mine--John Galt

Anguz

Cristián Lávaque http://cristianlavaque.com

vizcares

Hi

if I want to insert the latest post in a html page can I use SSI or has it to be on a php page?

Maybe it's a supid question, but I have no clue about php

thanks in advance

Tomer

You can use .shtml, or .php

- TOmer

vizcares

Quote from: Tomer on July 17, 2005, 06:12:21 PM
You can use .shtml, or .php

- TOmer

Ok thanks

I normally use Frontpage and I have a index page called index.htm is there some way I can change this page to .shtml or do I have to make a whole nesw page?

JoeP

 :)This kind of tutorial is EXTREMELY helpful!
Looking forward to the advanced topics!

I hope there's something similar for the events calendar.
joe

Gary

#66
Nevermind, its sorted.  8)
Gary M. Gadsdon
Do NOT PM me unless I say so
War of the Simpsons
Bongo Comics Fan Forum
Youtube Let's Plays

^ YT is changing monetisation policy, help reach 1000 sub threshold.

Gwydion Frost

#67
Ok, maybe I'm just not following...and as smart as I like to think I am, it's a little frustrating to be sounding so stupid and not grasping what should be a simple concept.

Following the directions as I have read them:

Create a document with a php extension. Place code within it. Place UNNAMED php document SOMEWHERE RANDOM in your forum directory.

Errr...what do I name this document, and how the heck does the forum software know how to access it?

I have multiple forums.

I have a shared database for these forums, each install has it's own tables, with only a few tables shared, such as...
  shared_log_activity
  shared_log_floodcontrol
  shared_log_karma
  shared_log_online
  shared_log_subscribed
  shared_membergroups
  shared_members
  shared_personal_messages
  shared_pm_recipients
  shared_subscriptions

Now, the issue I have here, is that I am under the understanding that SSI will allow my folks to log in, and bop from board to board to board (I also have the cookies set the same for each board). How do I do so, with SSI, because right now, even with the shared tables and cookies, you still have to log in fresh for each board...and that just won't do!

PSPXavier

I'm quite confused...... I have a html homepage and that's where I want the code to go... So if I put the code in a php file it works, but how do I get it to work on my html page? Here's my current code.

<?php
require("/home/pspzone/public_html/smf/SSI.php"); 
 
ssi_welcome(); ?>

1MileCrash

change the .html extension to .php.
The only thing php can't do is tell you how much milk is left in the fridge.



PSPXavier

But everything else in that page(index.html) is html.........

1MileCrash

#71
it doesnt matter.


php doesnt even do anything if the code isnt surrounded by <?php ?> tags. it's a server side language. it just outputs html.

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



PSPXavier

Okay-- so you have to have it .php, gotcha.

Is there a shtml version of this FAQ?

psychophat

#73
Hi,

Got lost again in the vast forum, heheheh . . . I also wanted to know how to CSS this:

Output page                    CSS file
Board  Topics Posts  =    .ssi_table
test1    1        1        =     ? what .ssi are these?
test2    1        2

<th height="300" scope="row" class="ssi_tables"><?php ssi_topBoards(); ?></th>

What is the code for this one, err I mean the .ssi_??? for this part. But when you use .ssi_table it'll only change the table not the lower half where would I change this and how to I code this for these are two types, right?



Thank you


-Patrick Grey
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

Acf

Tomer shouldn't your welcome.txt be:

<?php
require("/your/path/to/SSI.php"); 

// Script writen by Tomer "Lamper" Dean.
// **NOTE** Always check that the require statement is correct!
// A script that puts the persons membergroup into a variable for later use.

// Puts every person into a group.

if ($context['allow_admin'])
   {
      
$MemberGroup "Admin";
   }
elseif (
$context['user']['is_guest'])
   {
      
$MemberGroup "Guest";
   }
else
   {
      
      
$MemberGroup "User";
   }

// Echo's the membergroup of the person.

echo 
'<center><h5>Welcome $MemberGroup!</h5></center>';

?>



otherwise a user is guest and a geust is user...
Sigh...

fluid

i would like to do something that another user here mentioned as well. i am building a site from the ground up without using a CMS. i have SMF installed that is being used, and would like to take the main page from the site and use SSI to handle logins and authentication. my problem with doing it with ssi_login(); is that the form posts to the root page of the forums. is there any way to have ssi_login(); post back to the root page of the site itself, and not take you into the forums?

everything is working flawlessly so far...i just need to get this one thing sorted out :D

willtaka

Is there anyway of adding an actual board into ssi :D

Gruss

#77
Quote from: GiNi3D on December 09, 2004, 11:49:51 PM
@bunkfilms
Did you try your domain name>>  <?php include ('hxxp:www.yourdomainname.com/forums/SSI.php [nonactive]'); ?>


For some reason I can't get the login to pass the credentials. I'm running SMF 1.06 and PHP 4.4.1.

If I use:

require('http://www.mydomain.com/myforum/SSI.php');

it works, but I get this:

QuotePlease don't access SSI.php by URL directly; you may want to use the path ('SSI.php') or add ?ssi_function=something.




if I use the correct path

require('/home/#####/public_html/myforum/SSI.php');

where ##### is my account

or

require('SSI.php')

since the login.php is in the same directory as SSI.php

it doesn't pass the credentials.




My whole code below

Thanks in advance for any assistance.  If I find anything out I'll edit my post and put below.

Gruss




<?php
require('/home/#####/public_html/myforum/SSI.php');

global 
$context;

if (
$context['user']['is_guest'])
{
 echo
 
'<h5>Access Denied</h5>
 We are sorry guest, it seems you dont have premission to view these downloads.'
;
}
else
{
 echo
 
'<h5>Welcome '$context['user']['name'], '!</h5>
 Here are your downloads:'
;
}
?>


FiberOptix

what do you have to when you said open a text file and save it with a extension of .php and then open it and put that code in it then what do you do. im trying to get it so that if you login your logged in on the forums. I dont get it can someone explain in full?

ReD^DeviL

Ok, Someone needsto help me. I took the code from the welcome file from the first post, and put it in my php file at the very top, and I still can't see nothing.

<?php
require("/www/home/goalforums.net/forums/SSI.php"); 

// Script writen by Tomer "Lamper" Dean.
// **NOTE** Always check that the require statement is correct!
// A script that checks if your a guest, and if guest, puts a login box,
// and if user, put a welcome message.

// Checks which membergroup you are in.

if ($context['user']['is_guest'])
   {
      
ssi_login();
   }
else
   {
      
ssi_welcome();
   }

?>


Am I missing something? please help a PHP retard XD
Goal! Football Forums -- Don't let your opinion go to waste!

www.goalforums.net

Advertisement: