1
hughs
two Domains, one Xoops
  • 2004/4/20 12:51

  • hughs

  • Not too shy to talk

  • Posts: 117

  • Since: 2003/10/7


Hi.

I would like to ask, if it would be possible to have two domains running under the same xoops.
Example:
www.domain1.com
www.domain2.com

Help,tipps, etc will be much appreciated..
Thanks

hughs

2
phppp
Re: two Domains, one Xoops
  • 2004/4/20 13:03

  • phppp

  • XOOPS Contributor

  • Posts: 2857

  • Since: 2004/1/25


I am also looking at it
there is a problem with database

share if solution comes out ...

3
karuna
Re: two Domains, one Xoops
  • 2004/4/20 14:20

  • karuna

  • Not too shy to talk

  • Posts: 171

  • Since: 2002/5/29


there was such a hack alow u to use one XOOPS with different mainfile.php via different domain.

you can config the same database in the mainfile.

you can find this hack inhttps://xoops.org/modules/news/

4
BoDGie
Re: two Domains, one Xoops
  • 2004/4/20 14:38

  • BoDGie

  • Just popping in

  • Posts: 65

  • Since: 2003/8/4 1


https://xoops.org/modules/news/article.php?storyid=1413

is that what you're after?

Or do you want to run 2 completely different sites with different databases using only one copy of the XOOPs installation?

If so just make 2 coppies of your mainfile and name one something like domain1.mainfile.php and the other domain2.mainfile.php then replace mainfile.php with this code

<?phpif (!(isset($serverName))) { $serverName $SERVER_NAME$serverName str_replace("www.","",$serverName);$serverName str_replace(".com","",$serverName); $serverName str_replace(".net","",$serverName); $serverName str_replace(".org","",$serverName); } if (!(empty($serverName))) { include($serverName."mailfile.php"); ?>

5
phppp
Re: two Domains, one Xoops
  • 2004/4/20 15:11

  • phppp

  • XOOPS Contributor

  • Posts: 2857

  • Since: 2004/1/25


mainfile configuration is not the big deal ...


6
hughs
Re: two Domains, one Xoops
  • 2004/4/20 15:16

  • hughs

  • Not too shy to talk

  • Posts: 117

  • Since: 2003/10/7


Hi there.
Yes, i want to have two completely different sites with different Db in the same Server.
I'll like also to know, if i can have both of them at the same level, and call them both with ".com", at the end or do i have to have one as Sub-domain.
Thank you for your help.
hughs

7
phppp
Re: two Domains, one Xoops
  • 2004/4/20 15:23

  • phppp

  • XOOPS Contributor

  • Posts: 2857

  • Since: 2004/1/25


the biggest concern, at least to me

any solution or hints?

8
BoDGie
Re: two Domains, one Xoops
  • 2004/4/20 15:31

  • BoDGie

  • Just popping in

  • Posts: 65

  • Since: 2003/8/4 1


hughs that code i posted will work no matter what tld you use... just rename the mainfile.php to yourdomain.mainfile.php


So if you have www.xoops.org you would call its mainfile xoops.mainfile.php and then if you had www.virtuepark.com you would call its mainfile virtuepark.mainfile.php

9
hughs
Re: two Domains, one Xoops
  • 2004/4/20 15:52

  • hughs

  • Not too shy to talk

  • Posts: 117

  • Since: 2003/10/7


Hello

Thank you for your help..!!
I'm going to have a go at it, i'll let you know the results.
I'll keep in touch..
hughs

10
hughs
Re: two Domains, one Xoops
  • 2004/4/21 7:02

  • hughs

  • Not too shy to talk

  • Posts: 117

  • Since: 2003/10/7


Hello.
Well.. i did have a go at it. i followed your advise and replaced my mainfile with your code,( without changing anything in it )
i've copied my mainfile and renamed it mydomain.mainfile.php, both of them are at the same level..now
i get this error

Parse error: parse error in /home/w10919/web/public_html/mainfile.php on line 1

Warning: main(XOOPS_ROOT_PATH/class/xoopsblock.php): failed to open stream:
No such file or directory in /home/w10919/web/public_html/header.php on line 28

Warning: main(): Failed opening 'XOOPS_ROOT_PATH/class/xoopsblock.php' for inclusion
(include_path='.:/usr/lib/php') in /home/w10919/web/public_html/header.php on line 28

Warning: main(XOOPS_ROOT_PATH/class/template.php): failed to open stream: No such
file or directory in /home/w10919/web/public_html/header.php on line 62

Fatal error: main(): Failed opening required 'XOOPS_ROOT_PATH/class/template.php'
(include_path='.:/usr/lib/php') in /home/w10919/web/public_html/header.php on line 62

Well unfortunately my understandig does not go that far..
Can you help me again please..
thanks
hughs

Login

Who's Online

164 user(s) are online (82 user(s) are browsing Support Forums)


Members: 0


Guests: 164


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: May 31
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits