vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Beta Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=34)
-   -   Use same vB on different Domains (cookies) (https://vborg.vbsupport.ru/showthread.php?t=70113)

Paris Holley 10-02-2004 10:00 PM

Use same vB on different Domains (cookies)
 
I haven't tested it in all circumstances but in only the way i needed. This may not be the best method but I think its the only one that works as of right now.

Tested Domain Situations:
-------------------------------
1site.com
2site.com ( which the real url is 1site.com/2site/ )
-------------------------------

Open Functions.php and find
PHP Code:

// try unsetting without the / at the end 

before each setcookie function ( should be 3 within about 25 lines or so ) add

PHP Code:

setcookie($name$value$expire"your-path""your-domain"$secure); 

this should write the cookies for each domain you set it for and allow people to view each one and not have to log in. Please give me feed back on this for i would love to see my first vb hack work :)

Velocd 10-02-2004 10:34 PM

From vBulletin.com:

Quote:

Originally Posted by vBulletin License Agreement
vBulletin license grants you the right to run one instance (a single installation) of the Software on one web server and one web site for each license purchased. Each license may power one instance of the Software on one domain. For each installed instance of the Software, a separate license is required. Modifications to the software or database to circumvent the one-license-one-board rule are prohibited.

I'm uncertain, but your suggested use of this hack may violate that rule (in bold).

Paris Holley 10-02-2004 10:36 PM

well I have my site, and my forums, and I use it so that if they are on the site they have to login using the forums system....I guess this could be used to violate that rule, but it all depends on the person using it...

by saying that i mean,

on site1 it includes the global site1/site2/global.php but people see the forums as site2.com, so if people want to integrate the vbulletin login system on differen't domains they can...

Talisman 10-02-2004 10:56 PM

Umm.. congrats on the hack, Paris ... (I think).

Not to take away from the enthusiasm of the moment, but I think I'm missing something here. Why would we want to do this? Could you give some example of how this might be used?

... and does this violate Jelsoft's terms and conditions, or not?

Paris Holley 10-02-2004 11:03 PM

u can have a vb installed if its not being viewed by the public....and yes this can be found on the 2 domains but is only being used on one...

secondly im using it so that, you have to be logged on the forums to view the site ( must be logged on site2.com to view site1.com content ) and in order to do that, you must include the global file from the site2 directory ( which is located on the site1.com/site2 folder but the public accesses it from site2.com )..and since cookies are created for both domains it will work...make sense?

Talisman 10-02-2004 11:30 PM

I guess I'm still confused, so let me see if I can follow what you're saying. It's one (single) forum that you (and your admins, I presume) can access from both domains. But the viewing public and your forum members can only see the board from Site 2.

If they go to Site 1, it's not visible to them at all?

Or, you mean this is really a site within a site? ... Or that Site 2 is more of a sub-site to Site 1? From the way you have this set up, I guess Site 2 is really a subdomain of Site 1.... you just want it to appear as someplace different, yes?

(...sigh)

Sorry to be such a pain on this, I'm sure it's really simple. I'm just trying to figure out what/why we might do this.

Paris Holley 10-02-2004 11:40 PM

ok...site2.com is just another way to go site1/site2 but site1/site2 is not accessible by the public...no one goes to site1/site2, I just use that directory to include the global file so that you can use the $bbuserinfo["username"] variable on site1, but in order to do that you have to create cookies for both domains so when they login site2 and view site1 the variable is register and not showing as "Unregistered"...and yes basicly site2 is a subdomain or the site within the site but appears that it is somewhere else...

Talisman 10-02-2004 11:53 PM

Okay. Thanks, again.

I think I get it now. Your members get to this forum by going to Site 2. Since they don't know the rest of this, they think the forum is located ... there. This really takes them to a subdomain of Site 1 but you don't want them to know Site 1 exists at all, so that's why you have the domains shuffled around like this.

Erwin 10-03-2004 12:24 AM

Interesting. What about logouts? You'd want to delete all those cookies too.

Paris Holley 10-03-2004 12:29 AM

Quote:

Originally Posted by Erwin
Interesting. What about logouts? You'd want to delete all those cookies too.

ah yes, i forgot about that....


All times are GMT. The time now is 12:27 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01055 seconds
  • Memory Usage 1,740KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (2)bbcode_php_printable
  • (2)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete