TinyPortal

Development => Block Codes => Topic started by: Xarcell on April 26, 2006, 12:19:32 AM

Title: Add Wikipedia To Your Site.
Post by: Xarcell on April 26, 2006, 12:19:32 AM
Here is a script I found, that will allow you to add the whole wikipedia to your website. However, I can get it to work, but not all of it within the theme.

I do not know php enough to intergrade it properly with TP/SMF.

I was hoping someone here would take a look at it to make it work better with the theme.

http://www.serebella.com/cyclo_script/

It updates itself, and does not use your storage/bandwidth.

Thanks,

-Xarcell
Title: Re: Add Wikipedia To Your Site.
Post by: stormlrd on April 26, 2006, 12:41:28 AM
Ill give it a wack
Title: Re: Add Wikipedia To Your Site.
Post by: stormlrd on April 26, 2006, 12:56:01 AM
lol well i need to get my portal upgrade to 86 working correctly first but I already downloaded it and was wondering why you cant just install the php section in between the <? ?> directly into a php block therefore picking up the current theme settings.
Title: Re: Add Wikipedia To Your Site.
Post by: stormlrd on April 26, 2006, 01:00:23 AM
http://stormlrdsreality.co.uk/RC2/index.php

worked like a charm on my rc2 test forum check it out

just insert this code directly into a center block phpbox


$search_string=$_GET['title'];

$sss=array("http://www.serebella.com/cyclo_script/article.php?title=",$search_string);
$ssss=implode('',$sss);
if($search_string=="")$ssss="http://www.serebella.com/cyclo_script/topics.html";
$file = fopen ($ssss, "r");
if (!$file) {
    echo "<p>Unable to open remote file.\n";
    exit;
}

$html_code="";
while (!feof ($file))
   {
    $line = fgets ($file, 1024);
    $array = array($html_code, $line);
    $html_code = implode(' ', $array);
   }

fclose($file);

print $html_code;


nothing else required bro.
Title: Re: Add Wikipedia To Your Site.
Post by: Xarcell on April 26, 2006, 01:06:59 AM
As I said, I can get part of it to work properly.

Your links do not work. You can change the url's in the file, but then the pages load without the theme, outside of TP/SMF.

Any other ideas?
Title: Re: Add Wikipedia To Your Site.
Post by: stormlrd on April 26, 2006, 01:42:06 AM
hmm let me see i just noticed the links myself as well
Title: Re: Add Wikipedia To Your Site.
Post by: stormlrd on April 26, 2006, 02:44:48 AM
ok solved.

Upload the a.php and the topics.html to your root folder

than place the following in a php block:
require("/home/stormlrd/public_html/RC2/SSI.php");
require('[[[url to your root folder]]]]/a.php');

I recommend a center block

than open the a.php file and add the following:

at the top:


<!!!! You may customize until the next horizontal line///////////////////!>
<?php
require("/home/stormlrd/public_html/RC2/SSI.php");
global 
$context$settings$options$txt;
echo 
'
<link rel="stylesheet" type="text/css" href="'
$settings['theme_url'], '/style.css?rc2" />
<link rel="stylesheet" type="text/css" href="'
$settings['default_theme_url'], '/print.css?rc2" media="print" />';

echo
' <table cellspacing="0" cellpadding="0" border="0" align="center" width="95%" class="tborder">
       '
;
echo
' <tr class="windowbg2">
<td  valign="middle" align="center" class="catbg" style="border-width: 1px 0 0 0; font-size: smaller;">'
;


ssi_menubar();

    echo 
'</td></tr><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/////////////////////////////////!>


at the bottom:


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

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



?>


modify the table to suit

ok sorted just need to play with it a little bit but thats got it
http://stormlrdsreality.co.uk/RC2/index.php  home page of forum

a article:

http://stormlrdsreality.co.uk/RC2/a.php?title=Astronomy

Title: Re: Add Wikipedia To Your Site.
Post by: biffking on April 26, 2006, 04:12:26 AM
QuoteFatal error: (null)(): Failed opening required '/public_html/smf/SSI.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/americas/public_html/smf/Sources/Load.php(1608) : eval()'d code(34) : eval()'d code on line 1
I keep getting this error
Title: Re: Add Wikipedia To Your Site.
Post by: stormlrd on April 26, 2006, 04:19:22 AM
try using the full link

require('http://stormlrdsreality.co.uk/RC2/SSI.php');
require('http://stormlrdsreality.co.uk/RC2/a.php');
Title: Re: Add Wikipedia To Your Site.
Post by: Xarcell on April 26, 2006, 04:30:56 AM
I tried the paths and got a problem. When I click the links I get the message: No input file specified.

I tried the url's and got this error:

Please don't access SSI.php by URL directly; you may want to use the path ('SSI.php') or add ?ssi_function=something.
Notice: SSI.php was unable to load a session! This may cause problems with logout and other functions - please make sure SSI.php is included before *anything* else in all your scripts! in /home/.abigaildryer/xarcell/xarchology.com/smf/SSI.php on line 158
Title: Re: Add Wikipedia To Your Site.
Post by: Xarcell on April 26, 2006, 04:37:19 AM
I figured it out, I had to edit the links within the file. But still, I still have the same problem. Whne i view the information, it is not within TP/SMF.
Title: Re: Add Wikipedia To Your Site.
Post by: Xarcell on April 26, 2006, 04:49:46 AM
Any other ideas?

An iframe just doesn't work good.
Title: Re: Add Wikipedia To Your Site.
Post by: Xarcell on April 26, 2006, 04:50:06 AM
Maybe I should try a dynamic iframe.
Title: Re: Add Wikipedia To Your Site.
Post by: stormlrd on April 26, 2006, 12:02:30 PM
this is weird x because it works fine on mine.

Thats a totally fresh install of rc2 and v86 done yesterday, that burgundy theme was added yesterday. There are no mods on the forum other than tp. I uploaded the html and the a.php directly to the root of that test forum.

I created a php block with this exact info in it:

require("/home/stormlrd/public_html/RC2/SSI.php");
require('/home/stormlrd/public_html/RC2/a.php');

i changed nothing on the topics.html

I changed the top and bottom of the a.php to this exactly:


<!!!! You may customize until the next horizontal line///////////////////!>
<?php
require("/home/stormlrd/public_html/RC2/SSI.php");
global 
$context$settings$options$txt;
echo 
'
<link rel="stylesheet" type="text/css" href="'
$settings['theme_url'], '/style.css?rc2" />
<link rel="stylesheet" type="text/css" href="'
$settings['default_theme_url'], '/print.css?rc2" media="print" />';

echo
' <table cellspacing="0" cellpadding="0" border="0" align="center" width="95%" class="tborder">
          '
;
echo
' <tr class="windowbg2">
<td  valign="middle" align="center" class="catbg" style="border-width: 1px 0 0 0; font-size: smaller;">'
;

// Show the menu here, according to the menu sub template.
ssi_menubar();

    echo 
'</td></tr><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/////////////////////////////////!>


bottom:


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

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



?>


so Im not sure why yours is not working at all.

Please note i call the ssi twice once in the phpblock and once on the a.php file it has to be in both places or you get that 2nd error you got.
Title: Re: Add Wikipedia To Your Site.
Post by: Xarcell on April 26, 2006, 02:23:20 PM
I don't think we are on the same page here.

Ok, I have mine working just like yours. I've done it 2 different ways. However, when you click astrology, it does not show up within TP, with top blocks, left or right blocks, etc...

Title: Re: Add Wikipedia To Your Site.
Post by: stormlrd on April 26, 2006, 02:59:19 PM
got a link bro? let me see what your trying to do because mine shows style sheet on all

problem with using the ssi is that it puts the page in a block like iframe with a second menu bar the only other thing i can think of is doing as some sort of iframe but i think thats more trouble than its worth. I think a return link to the forum would probably be best rather than the menubar that way its runs as a separate entity
Title: Re: Add Wikipedia To Your Site.
Post by: Xarcell on April 26, 2006, 03:12:18 PM
Show stylesheet on all and showing within TP is 2 different things.
Title: Re: Add Wikipedia To Your Site.
Post by: stormlrd on April 26, 2006, 03:14:18 PM
lol ok so exactly what are you wanting bro? I'll help but need to know what exactly you want.
Title: Re: Add Wikipedia To Your Site.
Post by: Xarcell on April 26, 2006, 03:18:12 PM
I don't know how to explain it any better.

Every since link within you click within the pedia should load within TP with blocks and all, without using an iframe.
Title: Re: Add Wikipedia To Your Site.
Post by: stormlrd on April 26, 2006, 03:20:42 PM
ok I see what you want now let me think on it
Title: Re: Add Wikipedia To Your Site.
Post by: Xarcell on April 26, 2006, 03:38:02 PM
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.
Title: Re: Add Wikipedia To Your Site.
Post by: stormlrd on April 26, 2006, 03:44:59 PM
yea i was trying similiar by hard coding it but again it would only be that theme
Title: Re: Add Wikipedia To Your Site.
Post by: dkaye315 on April 26, 2006, 03:47:31 PM
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.
Title: Re: Add Wikipedia To Your Site.
Post by: stormlrd on April 26, 2006, 03:51:09 PM
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.
Title: Re: Add Wikipedia To Your Site.
Post by: stormlrd on April 26, 2006, 04:00:11 PM
ok i just added return to forum links at top and bottom, thats about the best i can come up.
Title: Re: Add Wikipedia To Your Site.
Post by: dkaye315 on April 26, 2006, 04:37:09 PM
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??? 
Title: Re: Add Wikipedia To Your Site.
Post by: stormlrd on April 26, 2006, 04:48:09 PM
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.
Title: Re: Add Wikipedia To Your Site.
Post by: dkaye315 on April 27, 2006, 12:42:53 AM
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??
Title: Re: Add Wikipedia To Your Site.
Post by: stormlrd on April 27, 2006, 12:48:01 AM
nice care to share the exact setup?
Title: Re: Add Wikipedia To Your Site.
Post by: dkaye315 on April 27, 2006, 01:19:54 AM
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

Title: Re: Add Wikipedia To Your Site.
Post by: Xarcell on April 27, 2006, 02:15:44 AM
I guess using stylesheet with dynamic iframe is the best way to go? This way, you have the colors and everything matching, while it stays within TP without scrollbar.

Title: Re: Add Wikipedia To Your Site.
Post by: Crystallas on April 30, 2006, 11:10:01 AM
Are the logins bridged too?

I have a wiki and smf_tp on one site, but as a few have said, never thought of integrating them.
Title: Re: Add Wikipedia To Your Site.
Post by: Xarcell on April 30, 2006, 07:22:46 PM
It's displays text & links only...
No login, no images.
Title: Re: Add Wikipedia To Your Site.
Post by: bloc on April 30, 2006, 09:09:50 PM
I think you are over-complicating it. You can use the code in the a.php file..but you don't need to have the a.php file itself.

- start a php article and insert:
$search_string=$_REQUEST['title'];

$sss=array("http://www.serebella.com/cyclo_script/article.php?title=",$search_string);
$ssss=implode('',$sss);
if($search_string=="")$ssss="http://www.serebella.com/cyclo_script/topics.html";
$file = fopen ($ssss, "r");
if (!$file) {
    echo "<p>Unable to open remote file.\n";
    exit;
}

$html_code="";
while (!feof ($file))
   {
    $line = fgets ($file, 1024);
    $array = array($html_code, $line);
    $html_code = implode(' ', $array);
   }

fclose($file);

print $html_code;


This is the "work" page, which you send the request too. Get the page=xx number for it.

- create another page, php or html, and simply add something that will link as follows: index.php?page=xx;title=yoursubject.

Then the "work" page will show the result from wiki in full, no iframe and no ssi. You can add  something on top or bottom to get back to your "search page"..or add another link. The "search page" could be like the "topics.html" or even better: a simple form, which goes to index.php?page=xx. Call the input field "title". The page will then pick up the $_REQUEST['title'].

example: http://www.tinyportal.net/smf/index.php?page=31 - try searching for "Astronomy". ;)
Title: Re: Add Wikipedia To Your Site.
Post by: Xarcell on April 30, 2006, 09:16:24 PM
Quote from: Bloc on April 30, 2006, 09:09:50 PM
I think you are over-complicating it.

Yep, that's me.

I'm trying to follow you, but I'd have to do it to understand it exactly. I will start on it soon.

However, I noticed something. In your example, after searching for "Astronomy", it comes up. However, when I click a link within that article, it comes up blank.
Title: Re: Add Wikipedia To Your Site.
Post by: bloc on April 30, 2006, 09:25:09 PM
Yes, I see it. That might need some redirecting...hm, one moment.
Title: Re: Add Wikipedia To Your Site.
Post by: bloc on April 30, 2006, 09:32:23 PM
A simple redirect is done..but its not optimal.
Title: Re: Add Wikipedia To Your Site.
Post by: Xarcell on April 30, 2006, 09:34:29 PM
That seems good enough. Your slick...

What would we ever do without you?

:)
Title: Re: Add Wikipedia To Your Site.
Post by: Xarcell on April 30, 2006, 10:50:41 PM
Ok, I'm trying to get this working so I can understand it better and try to offer support for it.

I cannot seem to get it to work. This is the part where I get confused:

Quote- create another page, php or html, and simply add something that will link as follows: index.php?page=xx;title=yoursubject

To link to the "work" article? ex: index.php?page=4;title=Astronomy

When I do that, it comes up with a message saying: Unable to open remote file.
Title: Re: Add Wikipedia To Your Site.
Post by: bloc on April 30, 2006, 11:04:55 PM
Here are my code for the 2 pages, plus the redirect code:

"search page" (page=31) PHP-type:
echo '<br><br><h3>
type your serch word here, and the result from wiki will appear in another article</h3>
<form name="wikisearch" action="index.php?page=30" method="post">
<input name="title" type="text" value=""><input type="submit" value="Search wiki"></form>';


"result page" (page=30) PHP type:
$search_string=$_REQUEST['title'];

$sss=array("http://www.serebella.com/cyclo_script/article.php?title=",$search_string);
$ssss=implode('',$sss);
if($search_string=="")$ssss="http://www.serebella.com/cyclo_script/topics.html";
$file = fopen ($ssss, "r");
if (!$file) {
    echo "<p>Unable to open remote file.n";
    exit;
}

$html_code="";
while (!feof ($file))
   {
    $line = fgets ($file, 1024);
    $array = array($html_code, $line);
    $html_code = implode(' ', $array);
   }

fclose($file);

echo '<div style="background: white; border: solid 3px #d0d0d0; padding: 30px;">'.$html_code.'</div>';



a.php, uploaded into the forum folder:
<?php

$title
=$_GET['title'];



echo 
'
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>Bloc Zone</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<script language="JavaScript" type="text/JavaScript">
<!--
function MM_goToURL() { //v3.0
  var i, args=MM_goToURL.arguments; document.MM_returnValue = false;
  for (i=0; i<(args.length-1); i+=2) eval(args[i]+".location=\'"+args[i+1]+"\'");
}
//-->
</script>
</head>

<body onLoad="MM_goToURL(\'parent\',\'http://www.tinyportal.net/smf/index.php?page=30;title='
.$title.'\');return document.MM_returnValue">

</body>
</html>'
;

?>


You start with "search" page, type what you need, and get sent to "result page". Any link in "result page" points to a.php, so a redirect file must send you back to "result apge" - with the new search string, just as Wiki works.

In this result page, another link to the first "search page" could be added, like "search for another" etc.
Title: Re: Add Wikipedia To Your Site.
Post by: Xarcell on April 30, 2006, 11:12:19 PM
Hrmmmm... I dunno what I'm doing wrong. I get: Unable to open remote file.n

I did edit the urls from: index.php?page=30; to index.php?page=4; in teh search & a.php
Title: Re: Add Wikipedia To Your Site.
Post by: Xarcell on April 30, 2006, 11:21:35 PM
I deleted my articles and started over. I'm still doing it wrong I guess. I copied and pasted what you had into php articles. One named "Search Wiki" and "Result Wiki". I changed the url's accordlying in "search wiki" and "a.php". The a.php I uploaded to my smf root directory.
Title: Re: Add Wikipedia To Your Site.
Post by: Xarcell on April 30, 2006, 11:24:01 PM
Does the a.php need to be named "a.php" or can we call it "redirect_wiki.php"?
Title: Re: Add Wikipedia To Your Site.
Post by: bloc on May 01, 2006, 03:04:25 PM
No, it needs to be named a.php, because the wiki site puts that in the links. Your site will then append your site url in front of it.
Title: Re: Add Wikipedia To Your Site.
Post by: Xarcell on May 03, 2006, 03:35:41 AM
I hate to be a pain, but this just doesn't work for me.
Title: Re: Add Wikipedia To Your Site.
Post by: bloc on May 03, 2006, 08:47:18 AM
Hm, how does your "search" page look? and your "result" page + the a.php file?
Title: Re: Add Wikipedia To Your Site.
Post by: Xarcell on May 03, 2006, 05:17:50 PM
Quote from: Xarcell on April 30, 2006, 11:21:35 PM
I deleted my articles and started over. I'm still doing it wrong I guess. I copied and pasted what you had into 2 php articles. One named "Search Wiki" and the other "Result Wiki". I changed the url's accordlying in "search wiki" and "a.php". The a.php I uploaded to my smf root directory.

Search page = great.
Result page = Unable to open remote file.n

a.php file:

<?php

$title
=$_GET['title'];



echo 
'
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>Bloc Zone</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<script language="JavaScript" type="text/JavaScript">
<!--
function MM_goToURL() { //v3.0
  var i, args=MM_goToURL.arguments; document.MM_returnValue = false;
  for (i=0; i<(args.length-1); i+=2) eval(args[i]+".location=\'"+args[i+1]+"\'");
}
//-->
</script>
</head>

<body onLoad="MM_goToURL(\'parent\',\'http://xarchology.com/smf/index.php?page=6;title='
.$title.'\');return document.MM_returnValue">

</body>
</html>'
;
Title: Re: Add Wikipedia To Your Site.
Post by: bloc on May 04, 2006, 01:03:55 AM
hm, seems the problem is the server not being able to open the remote file then?
Title: Re: Add Wikipedia To Your Site.
Post by: Xarcell on May 04, 2006, 02:23:19 AM
I thought that at first, but it seems it only happens when I try to do as you suggested. It makes no sense to me. Maybe it has something to do with "my" server settings, is that possiable?
Title: Re: Add Wikipedia To Your Site.
Post by: Xarcell on May 04, 2006, 02:23:48 AM
It works on yours, but not mine.
Title: Re: Add Wikipedia To Your Site.
Post by: Xarcell on May 04, 2006, 02:29:06 AM
Can you copy and paste your result script for me again. I just wanna make sure it's the same as what I had.

PHP Article "Result Wiki":

$search_string=$_REQUEST['title'];

$sss=array("http://www.serebella.com/cyclo_script/article.php?title=",$search_string);
$ssss=implode('',$sss);
if($search_string=="")$ssss="http://www.serebella.com/cyclo_script/topics.html";
$file = fopen ($ssss, "r");
if (!$file) {
    echo "<p>Unable to open remote file.n";
    exit;
}

$html_code="";
while (!feof ($file))
   {
    $line = fgets ($file, 1024);
    $array = array($html_code, $line);
    $html_code = implode(' ', $array);
   }

fclose($file);

echo '<div style="background: white; border: solid 3px #d0d0d0; padding: 30px;">'.$html_code.'</div>';
Title: Re: Add Wikipedia To Your Site.
Post by: StanJ on June 01, 2006, 03:30:30 PM
Can we put our own adsense number in???
Title: Re: Add Wikipedia To Your Site.
Post by: Xarcell on June 01, 2006, 04:02:09 PM
No, that's how the author of the script gets compensation for writing the script.



Title: Re: Add Wikipedia To Your Site.
Post by: RoarinRow on August 22, 2006, 04:23:38 PM
Cool, thanks it works  8)
Title: Re: Add Wikipedia To Your Site.
Post by: RoarinRow on August 22, 2006, 07:23:16 PM
I tried a search using two words such as 'United States' and get this back:

Unable to open remote file.n

Any ideas?   :o

Edit - same thing happens here - http://www.tinyportal.net/smf/index.php?page=31
Title: Re: Add Wikipedia To Your Site.
Post by: bloc on August 22, 2006, 11:06:23 PM
You need to replace any spaces with %20. So search for "united%20states", not "united states".
Title: Re: Add Wikipedia To Your Site.
Post by: RoarinRow on August 22, 2006, 11:22:04 PM
Quote from: Bloc on August 22, 2006, 11:06:23 PM
You need to replace any spaces with %20. So search for "united%20states", not "united states".

Wow, I wouldn't have known that in a million years, thanks Bloc!   :up:
Title: Re: Add Wikipedia To Your Site.
Post by: Joshsux on August 29, 2006, 11:11:09 AM
i don't understand, is this adding the WHOLE wikipedia to your website? is there a demo of it? i saw a link on the front page but its only 1 article? wikipedia is pretty Effin big, what / how does it work? can somebody show me it in action? i would love to have a whole wikipediao n the site
Title: Re: Add Wikipedia To Your Site.
Post by: bloc on August 29, 2006, 11:23:48 AM
No, its not the whole thing lol..rather a script that search, collect and presents the results from Wikipedia - within your site.
Title: Re: Add Wikipedia To Your Site.
Post by: Joshsux on August 29, 2006, 01:38:57 PM
ohhhh lol! i thought it was too good to be true i was going to say "Oh my god, how the heck can somebody steal the whole wikipedia, lmao.
Title: Re: Add Wikipedia To Your Site.
Post by: Techdomain on November 25, 2006, 08:57:46 AM
did you ever get past that error xarcell? it seems to be happening to me.

having said that, http://www.serebella.com/ doesnt seem to exist.
Title: Re: Add Wikipedia To Your Site.
Post by: Xarcell on December 27, 2006, 04:56:57 AM
this script no longer seems to be working.
Title: Re: Add Wikipedia To Your Site.
Post by: RoarinRow on December 27, 2006, 05:58:41 AM
Not working on my site either.  I'm getting the same error as before:

Unable to open remote file.n
Title: Re: Add Wikipedia To Your Site.
Post by: Xarcell on December 27, 2006, 01:04:46 PM
the script ran on files located on thier server. Now there server is down.


I really liked this script and was wondering if anyone else wanna try and duplicate the effect? or rewrite the script...
Title: Re: Add Wikipedia To Your Site.
Post by: katers on March 14, 2007, 05:08:45 AM
This would have been a great script if someone could figure it out.
Title: Re: Add Wikipedia To Your Site.
Post by: RoarinRow on March 14, 2007, 06:03:18 AM
Quote from: twister on March 14, 2007, 05:08:45 AM
This would have been a great script if someone could figure it out.

I used this scriptbox on a right block

<form action="http://www.wikipedia.org/search-redirect.php" method="get">
  <input type="hidden" name="language" value="en" />
  <input type="text" name="search" size="20" />
  <br>
  <br>
  <input type="submit" name="go" value=" Go! " />
</form>


You can change the length of the input field, just change 20 to a bigger number.
Title: Re: Add Wikipedia To Your Site.
Post by: Gourgi on March 14, 2007, 01:13:41 PM
Quote from: RoarinRow on March 14, 2007, 06:03:18 AM
I used this scriptbox on a right block

<form action="http://www.wikipedia.org/search-redirect.php" method="get">
  <input type="hidden" name="language" value="en" />
  <input type="text" name="search" size="20" />
  <br>
  <br>
  <input type="submit" name="go" value=" Go! " />
</form>


You can change the length of the input field, just change 20 to a bigger number.
this code works fine !
what about if i wanna Wiki open in new window ?
Title: Re: Add Wikipedia To Your Site.
Post by: katers on March 14, 2007, 01:29:41 PM
Wow, ask and you shall receive.  Thank you Xarcell, it works great.
Title: Re: Add Wikipedia To Your Site.
Post by: TPnewbie on March 25, 2007, 09:34:00 AM
This should do the trick if you want it in its own window.  ;D

<form action="http://www.wikipedia.org/search-redirect.php" method="get" target="_blank">
  <input type="hidden" name="language" value="en" />
  <input type="text" name="search" size="20" />
  <br>
  <br>
  <input type="submit" name="go" value=" Go! " />
</form>



Peace,
TPnewbie
Title: Re: Add Wikipedia To Your Site.
Post by: RoarinRow on March 25, 2007, 04:50:57 PM
Quote from: TPnewbie on March 25, 2007, 09:34:00 AM
This should do the trick if you want it in its own window.  ;D

<form action="http://www.wikipedia.org/search-redirect.php" method="get" target="_blank">
  <input type="hidden" name="language" value="en" />
  <input type="text" name="search" size="20" />
  <br>
  <br>
  <input type="submit" name="go" value=" Go! " />
</form>



Peace,
TPnewbie


Cool, thanks that worked!   ;)
Title: Re: Add Wikipedia To Your Site.
Post by: maxg on June 01, 2007, 04:28:04 PM
Yes Cool, I place this in a scriptbox and works great, thanks!

regards,
Max
Title: Re: Add Wikipedia To Your Site.
Post by: Tommy on June 05, 2007, 01:50:20 AM
A search box for your own wiki :)
http://www.ipbwiki.com/Media_Wiki[...] (http://www.ipbwiki.com/Media_Wiki:Add_a_wikipedia_search_box_from_your_main_website_or_blog)
Title: Re: Add Wikipedia To Your Site.
Post by: asklife on June 12, 2007, 05:09:27 PM
hello i tried your this code, but its not working at all, i am getting this error

QuoteParse error: syntax error, unexpected '<' in /home/asklife/public_html/mysitefolder/Sources/Load.php(1860) : eval()'d code(35) : eval()'d code on line 1
Title: Re: Add Wikipedia To Your Site.
Post by: Maya on June 12, 2007, 05:31:28 PM
make sure you put in in a 'scriptbox' , and that you have all the code in there, including the </form> at the end ....

Quote<form action="http://www.wikipedia.org/search-redirect.php" method="get" target="_blank">
  <input type="hidden" name="language" value="en" />
  <input type="text" name="search" size="20" />
 

 

  <input type="submit" name="go" value=" Go! " />
</form>

... hope this helps
Title: Re: Add Wikipedia To Your Site.
Post by: asklife on June 12, 2007, 07:55:42 PM
Quote from: Maya on June 12, 2007, 05:31:28 PM
make sure you put in in a 'scriptbox' , and that you have all the code in there, including the </form> at the end ....

Quote<form action="http://www.wikipedia.org/search-redirect.php" method="get" target="_blank">
  <input type="hidden" name="language" value="en" />
  <input type="text" name="search" size="20" />
 

 

  <input type="submit" name="go" value=" Go! " />
</form>

... hope this helps

nope i tried this also, still its not working, i have put this in scriptbox only
Title: Re: Add Wikipedia To Your Site.
Post by: Maya on June 12, 2007, 08:27:25 PM
hmmm. can you please post the exact code you have in your script box...

I just tried this code to see if I got the same error, and it works fine ;)
Title: Re: Add Wikipedia To Your Site.
Post by: asklife on June 12, 2007, 08:48:02 PM
this was the code i had put in my site

Quote<form action="http://www.wikipedia.org/search-redirect.php" method="get" target="_blank">
  <input type="hidden" name="language" value="en" />
  <input type="text" name="search" size="20" />
 

 

  <input type="submit" name="go" value=" Go! " />
</form>
Title: Re: Add Wikipedia To Your Site.
Post by: Peregrinus on October 26, 2007, 09:06:54 PM
I take it then that because the serebella.com site is no longer active, that it is now not possible to have wikipedia articles appear on your own tp_smf site? anybody know what the "cyclo_script" contained?

This would be so good if it could work again. Anybody interested in getting it working again?

Peregrinus~
Title: Re: Add Wikipedia To Your Site.
Post by: Rus on October 26, 2007, 09:38:05 PM
That code just worked for me, all it did was launch a new page, go to wiki and do the search but thats kinda cool on its own
Title: Re: Add Wikipedia To Your Site.
Post by: Freddy on November 16, 2007, 07:19:01 PM
Works fine for me too...here's a slightly extended version using two search buttons, one to get a direct hit and the other to search all of WIKI for the phrase...just like WIKI's own search boxes...I center it just for looks...

<center>
<form action="http://www.wikipedia.org/search-redirect.php" method="get" target="_blank">
<input type="hidden" name="language" value="en" />
<input type="text" name="search" size="20" />
<br>
<br>
<input type="submit" name="go" value=" Go! " title="Go to a page with this exact name if exists." />
<input type="submit" name="fulltext" value="Search" title="Search the pages for this text"/>
</form>
</center>
Title: Re: Add Wikipedia To Your Site.
Post by: Peregrinus on November 16, 2007, 07:57:01 PM
What I mean is so that the pages/results could somehow be incorporated into an article or something, with your own theme etc...That is what the original script did I believe, the cyclo script.
Title: Re: Add Wikipedia To Your Site.
Post by: Xarcell on November 16, 2007, 09:28:33 PM
Originally, the wiki article, appeared within your own article. That was the script's intentions. To make it look like wikipedia was inside your own site.
Title: Re: Add Wikipedia To Your Site.
Post by: electrojit on April 04, 2010, 09:51:24 PM
Hello all,

Can anyone upload the tutorial and required files to integrate the Mediawiki or docuwiki in tinyportal?

Thanks in advance,
electrojit
Title: Re: Add Wikipedia To Your Site.
Post by: ZarPrime on April 05, 2010, 05:07:40 PM
Doubtful.  This topic was last posted in over 2 and a half years ago.  At this point, you would be better off posting a new [request] in our requests board.  The link to that board is here--> http://www.tinyportal.net/index.php?board=133.0

ZarPrime