TP-Docs
HTML5 Icon HTML5 Icon HTML5 Icon
TP on Social Media

Recent

Welcome to TinyPortal. Please login or sign up.

Members
  • Total Members: 3,963
  • Latest: BiZaJe
Stats
  • Total Posts: 195,917
  • Total Topics: 21,308
  • Online today: 884
  • Online ever: 8,223 (February 19, 2025, 04:35:35 AM)
Users Online
  • Users: 1
  • Guests: 206
  • Total: 207
  • @rjen

Add Wikipedia To Your Site.

Started by Xarcell, April 26, 2006, 12:19:32 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Xarcell

I'm not php savy enough to come up with a solution that doesn't involve an iframe.

However, I did try to put the code from the topics.html into an article, and put the index.template.php code into the a.php. Although, it did create a problem. It would only show that one theme. If a user changed themes, the pedia would only show the code I inserted from the index.template.php file.

stormlrd

yea i was trying similiar by hard coding it but again it would only be that theme

dkaye315

I installed the wiki and modified a.php using stormlrd's code.  The script has it calling the menubar from the ssi.php, but as I have a lot of buttons in my header, the center block runs off the page - badly - unless the block is minimized.  

Possible solution (haven't tried yet), but what if a menu item was created that called up the topics.html page in the header menubar?  Could the requires be called up via the template file instead?  I don't know what code would be necessary to include in the template file.

stormlrd

well the other option i was considering was adding a link at bottom and top instead of menubar that returns you to the forum home page.

stormlrd

ok i just added return to forum links at top and bottom, thats about the best i can come up.

dkaye315

OK - after thinking some more (yep, killed more brain cells with this one), what's the feasibility of having this mimick the help function?  I briefly scanned the help.php and help.template.php files - seems it could be adapted (renamed, of course) to accommodate the wiki??? 

stormlrd

the problem is the code it calling at the wiki site, its looking back for the topics and a.php file if we could rename it than alot more would be possible.

dkaye315

Ok. I took the easy way out - ended up setting the wiki as an article withinin a borderless iframe and linking via content box.  The article title (header) served as the link back to the Wiki index, negating the use of the ssi sidebar. 

Link: http://dkaye.com/ecafe/index.php?page=22

Seems when all else fails, articles are the way to go??

stormlrd

nice care to share the exact setup?

dkaye315

The How-To:

In the top section of the a.php file (cut and paste the following and insert into file, adjusting the path to your ssi.php file, and set background color, if necessary):


<!!!! You may customize until the next horizontal line///////////////////!>

<?php
require("/var/www/html/FORUM/SSI.php"); // set path
global $context$settings$options$txt;

echo 
'
<link rel="stylesheet" type="text/css" href="'
$settings['theme_url'], '/style.css" />
<link rel="stylesheet" type="text/css" href="'
$settings['default_theme_url'], '/print.css" media="print" />';
echo 
' <style type="text/css" media="screen">
body{
background: #FFFFFF; } //set bgcolor to theme, or set to transparent
</style>'
;

echo
' <table cellspacing="0" cellpadding="0" border="0" align="center" width="100%" class="tborder">
'
;
echo
' <tr class="windowbg"><td valign="middle" align="left" class="windowbg" style="border-width: 1px 0 0 0; font-size: smaller; padding: 10px 10px 10px 10px;">';

?>



<!///////////////////////// leave this alone/////////////////////////////////!>



in the bottom section of the a.php (cut and paste into file):


<!///////////////////////// begin customizing again /////////////!>

<?
echo '</td></tr></table>';

?>


Then create an article (cut and paste the following):


<DIV align=center><IFRAME id=wikie align=center marginWidth=0 marginHeight=0 src="a.php" frameBorder=0 width="100%" height=1000 allowTransparency></IFRAME></DIV>


For the article options, check (select) the following:

Display: 
Use just the title

Viewing options: 
Show title
Show linktree
Show top
Show centerblocks
Show rightblocks
Show leftblocks

Finally, go into the MenuManager through Admin: Blocks, and activate the article you just created.

Edit menu item:
Title:     Wikipedia
(open): Same window
Type:    Article
Item:    Wikipedia, the Free Encyclopedia


This website is proudly hosted on Crocweb Cloud Website Hosting.