Serving XOOPSers in the Nordic Countries

XOOPS NORDIC

Nordic Support Site for XOOPS CMS

Login

Username:

Password:

Remember me



Lost Password?

Register now!

Who's Online

4 user(s) are online (1 user(s) are browsing Articles)

Members: 0
Guests: 4

more...

New Members

ITYKenny 2013/5/18
WinfredJo 2013/5/5
patricksch 2013/5/3
HomerMont 2013/4/27
JadeUPT 2013/4/27
edbjan 2013/4/26
LenardKet 2013/4/15
FancyHalto 2013/4/15
max 2013/4/12
AugustusN 2013/4/11
http://www.danordesign.com/

Author : anderssk
Article ID : 6
Audience : Default
Version 1.00.08
Published Date: 2008/12/16 12:50:00
Reads : 9907





Then we made www.xoopsnordic.org, we needed to search for old messages on
www.xoops.dk, www.xoops.se og www.xoops.no
– This would of course preferably be from the www.xoopsnordic.org website.

Google Custom Search has this option, but how do I integrate that into Xoops?

I did't found any modules, that I could used, so I had to do it all from scratch.

The task was very simple.



Google Custom Search is a tool you can use to search on one or more websites that you define.
The user can search your and related pages, just as they do at Google.
As mentioned, so is our need to relevant content through a period will be spread over several websites,
but Google Custom Search can also be used as a substitute for Xoops's internal search function,
you can of course try to experiment with the results themselves and see what best suits your page.

Another argument for using Google Custom Search is the ability to integrate AdSense for search and perhaps earn a little money on your work.

The following must be done.
First, go into Google Custom Search Engine homepage and click on "create a custom search engine"

Click to see original Image in a new window

Enter a name in "Search engine name"
Enter a description of "Search engine description"
Enter a few keywords in "Search engine keywords"
Choose the language in "Search engine language"

Select where you want to search.
Enter any pages (if you currently have selected "only sites I selected")
Read and agree Terms of Service
Click Next

Click to see original Image in a new window

You can now test your search, or click "Finish"

Click to see original Image in a new window

After you click "Finish" you will receive an email with some links.
Select link number 2 "To incorporate your search engine into your site or blog, you can find the necessary code to"
You are now in the search engine's Control Panel.

Mark "Host results on your website" and check "iframe"
In "specify search results details", enter your URL, followed by a filename.
In this example, I used the file name "googlesearch.php" so that the full URL will be http://www.xoopsnordic.org/googlesearch.php
Indicate where you want the advertising shown.
You now have two boxes with the code.

Click to see original Image in a new window

Content from the first box, you just ad as a custom block in XOOPS.
The contents of the second block is copied into an empty file locally on your PC.

The file should contain:

<? php 
require ( "mainfile.php"); 
require (
XOOPS_ROOT_PATH"/ header.php"); 
?> 
// Place the content of the block number 2 here 
<? php 
require (XOOPS_ROOT_PATH"/ footer.php"); 
?>


Upload the file to the root of your website, and your own personal search engine is up and running.

5
Printer Friendly Page Send this Article to a Friend
The comments are owned by the author. We aren't responsible for their content.
Translate to other languages
 
Create a XOOPS module
This site have PageRank
Min PageRank!
Powered by Danordesign