Solved

PHP Nuke

Posted on 2002-03-21
4
299 Views
Last Modified: 2006-11-17
Hello

I use php nuke 5.1 as a forum for my apache hosted web site. I'd like to access the forum from an another web page and not directly when typing my url.

Eg : to access the forum I have to type http://myhost.fr/nuke/

and I'd like to type http://myshost.fr/, to access a web page and to access the forum from a link...

How to do ?

-----------------------

Additional question:

  Is it possible to run several php nuke forums on one host. I can create several web site with my apache server (http://myhost.fr/~site1 , http://myshost.fr/~site2 ...) I'd like to provide a forum for each site. How can I do this ?
0
Comment
Question by:Pleinpopossum
  • 2
  • 2
4 Comments
 
LVL 5

Expert Comment

by:dkjariwala
ID: 6885092
I am not sure what you want to do,

But if you want to type http://myshost.fr/ and go to

http://myhost.fr/nuke,

You can have an index.htm file at document root for http://myshost.fr reading
<html>
<head>
<title>Redirecting</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<meta http-equiv="refresh" content="0;URL=http://myhost.fr/nuke/">
</head>

<body bgcolor="#FFFFFF" text="#000000">

</body>
</html>


or you can have page which has link to the forum like,

<html>
<head>
<title>Redirecting</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<meta http-equiv="refresh" content="0;URL=http://myhost.fr/nuke/">
</head>

<body bgcolor="#FFFFFF" text="#000000">
<a href="http://myhost.fr/nuke">Click to go to forums.</A>
</body>
</html>

Still I am not sure this is what you want to have.
JD

0
 

Author Comment

by:Pleinpopossum
ID: 6885113
Not really...

Noone must be able to access the url http://myhost.fr/nuke/ without clicking on the forum link of my web page. The scheme of my web site would be:

* a welcome page
* some links and informations
--> when you click on the forum link you go to the forum.

I probably have to change the location or someting else in my config files but I don't know what and where to do it...

I'm hosting several web sites. If I let the forum on the "root" of my sites, the forum would be considered beeing the same for each site.

http://myhost.fr/~site1/nuke1/
http://myhost.fr/~site2/nuke2/
http://myhost.fr/~siten/nuken/

would be perfect

Thanks
0
 
LVL 5

Accepted Solution

by:
dkjariwala earned 300 total points
ID: 6885162
Okie, got it.

What you can do is,

in your forum's index page, I mean the file which gets executed when you call

http://myhost.fr/nuke/ . Lets say it is index.php so that

http://myhost.fr/nuke/  transforms into

http://myhost.fr/nuke/index.php

Now add following code in index.php

<?

if(empty($HTTP_REFERER) or $HTTP_REFERER != "http://myhost.fr")
     header("Location:http://myhost.fr");

So if the referer is EMPTY or It is not your homepage, person would be redirected to homepage.

JD
0
 

Author Comment

by:Pleinpopossum
ID: 6965211
It doesn't solve my problem but I found an another solution :-)
Thank you very much for having tried.

Cheers
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Part of the Global Positioning System A geocode (https://developers.google.com/maps/documentation/geocoding/) is the major subset of a GPS coordinate (http://en.wikipedia.org/wiki/Global_Positioning_System), the other parts being the altitude and t…
Introduction This article is intended for those who are new to PHP error handling (https://www.experts-exchange.com/articles/11769/And-by-the-way-I-am-New-to-PHP.html).  It addresses one of the most common problems that plague beginning PHP develop…
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn how to count occurrences of each item in an array.

726 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question