The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
![]() |
||||||||||||||||||||
![]() This is a simple add-on which will force a specific styleid based on the host url the user visited.
If you have 2 domain names which point to the same forum, you can have a customized style based on the domain name visited. You can do what you want, but it may be as simple as only having a different banner reflecting the host name visited, or if you have merged 2 forums - users could still get the same skin they always have had if they continue to visit the same URL. Other uses may be having wap.domainname.com point to a different style than www.domainname.com. With the HOST matching be aware that if the URL specified in the add-on matches anywhere in the url visited, the add-on will be triggered. e.g. if URL specified in add-on = domainname.com, any subdomains of domainname.com will match this. Version History 1.0.0: product_ddds_36.xml - Initial release, Supports a single additional domain 1.0.1: product-5_ddds_36.xml - Supports up to 5 additional domains 1.0.2: product-5_ddds_36.xml - fixed typo in code - update required! 1.0.4: product-5_ddds_36.xml - fixed bug, added comment code [B]update required! 1.0.5: product-5_ddds_36.xml - removed comment code - caused issues on some systems Show Your Support
|
Comments |
#93
|
|||
|
|||
![]()
If someone types in mobile.mydomain.com this works fine. If they type in mobile.mydomain.com/forum/index.php it uses the default skin instead of the mobile skin. Shouldn't this keep the mobile skin throughout the whole site?
|
#94
|
|||
|
|||
![]()
okay... I'm an actionscript guru... not php/vbulletin gumshoe. I tried monkying around with this add on and got no results... here is what I did...
First I went to the plug in manager from the plug ins and products in vbulletin and then went to the link Force URL to Style and messed around with some of the code from the panel. Please tell me the proper method to place for the variables so I can see this actually work. here is the code... if ($vbulletin->options['ddds_36_enabled'] == 1) { if ($vbulletin->options['ddds_36_en1'] == 1) { $styleurl=$vbulletin->options['ddds_36_url1']; if(preg_match('/'.$styleurl.'/i', $_SERVER['HTTP_HOST'], $match)) { $styleid=$vbulletin->options['ddds_36_style1']; } } if ($vbulletin->options['ddds_36_en2'] == 1) { $styleurl=$vbulletin->options['ddds_36_url2']; if(preg_match('/'.$styleurl.'/i', $_SERVER['HTTP_HOST'], $match)) { $styleid=$vbulletin->options['ddds_36_style2']; } } if ($vbulletin->options['ddds_36_en3'] == 1) { $styleurl=$vbulletin->options['ddds_36_url3']; if(preg_match('/'.$styleurl.'/i', $_SERVER['HTTP_HOST'], $match)) { $styleid=$vbulletin->options['ddds_36_style3']; } } if ($vbulletin->options['ddds_36_en4'] == 1) { $styleurl=$vbulletin->options['ddds_36_url4']; if(preg_match('/'.$styleurl.'/i', $_SERVER['HTTP_HOST'], $match)) { $styleid=$vbulletin->options['ddds_36_style4']; } } if ($vbulletin->options['ddds_36_en5'] == 1) { $styleurl=$vbulletin->options['ddds_36_url5']; if(preg_match('/'.$styleurl.'/i', $_SERVER['HTTP_HOST'], $match)) { $styleid=$vbulletin->options['ddds_36_style5']; } } } I tried the following method... if ($vbulletin->options['ddds_36_en2'] == 1) { $styleurl=$vbulletin->options['http://www.domainname.com/']; if(preg_match('/'.$styleurl.'/i', $_SERVER['HTTP_HOST'], $match)) { $styleid=$vbulletin->options['template_style_name']; } } badda bing... badda broken ! nothen appears to take any effect. Crack all the greenhorn jokes you want... time constraints get the best of any jedi ! |
#95
|
|||
|
|||
![]()
I am getting the following error
Warning: preg_match() [function.preg-match]: Unknown modifier 'h' in /global.php(233) : eval()'d code on line 9 and when I try to log in I get vBulletin Message Unable to add cookies, header already sent. File: /usr/local/www/htdocs/htf/includes/class_core.php Line: 3052 I couldn't log in to turn off the product so I deleted it from the database. I am still getting the error message. The only way I can get my forum to work is to comment out ($hook = vBulletinHook::fetch_hook('style_fetch')) ? eval($hook) : false; Then everything works except now I cannot access my portal page that uses vBAdvanced as it uses the fetch_hook to load. Any ideas how to fix this? Thanks, Parker |
#96
|
|||
|
|||
![]()
Nevermind. I got it fixed.
Parker |
#97
|
|||
|
|||
![]()
@Parker - glad to hear, how about the query in post #92?
@vanistrians - what are you trying to do? |
#98
|
|||
|
|||
![]()
Dartho- I am trying to figure out the proper way to use DDDS of coarse. I have the product installed but just need to know the Standard Order of Procedure of how to use it... the basics 101.
I went to vbulletin options and selected Different Domain Different Style. I'm now @ the DDDS control panel. Here is a link to the image of the control panel... I also have a question if I should change anything in the following php code... if ($vbulletin->options['ddds_36_enabled'] == 1) { if ($vbulletin->options['ddds_36_en1'] == 1) { $styleurl=$vbulletin->options['ddds_36_en1']; if(preg_match('/'.$styleurl.'/i', $_SERVER['HTTP_HOST'], $match)) { $styleid=$vbulletin->options['ddds_36_style1']; } } if ($vbulletin->options['ddds_36_en2'] == 1) { $styleurl=$vbulletin->options['ddds_36_url2']; if(preg_match('/'.$styleurl.'/i', $_SERVER['HTTP_HOST'], $match)) { $styleid=$vbulletin->options['ddds_36_style2']; } } if ($vbulletin->options['ddds_36_en3'] == 1) { $styleurl=$vbulletin->options['ddds_36_url3']; if(preg_match('/'.$styleurl.'/i', $_SERVER['HTTP_HOST'], $match)) { $styleid=$vbulletin->options['ddds_36_style3']; } } if ($vbulletin->options['ddds_36_en4'] == 1) { $styleurl=$vbulletin->options['ddds_36_url4']; if(preg_match('/'.$styleurl.'/i', $_SERVER['HTTP_HOST'], $match)) { $styleid=$vbulletin->options['ddds_36_style4']; } } if ($vbulletin->options['ddds_36_en5'] == 1) { $styleurl=$vbulletin->options['ddds_36_url5']; if(preg_match('/'.$styleurl.'/i', $_SERVER['HTTP_HOST'], $match)) { $styleid=$vbulletin->options['ddds_36_style5']; } } } In other words... what is the simplest way for me to assign a different style to a different domain with this? I do not see anything else in the Different Domain Different Style control panel that show where to input the style... it just shows Style ID and I have a choice of entering 0 to 5. True I can enter the url but how do I assign the different style to the newly selected url input ? |
#99
|
||||
|
||||
![]()
DDDS is not the answer , all you do is set your additional domain names home page to the style id in your server admin cp .
www.dieselbombers.com www.dieselbombers.mobi this will also prevent search engines from indexing your additional domains as different sites and removing links from its listing as duplicate content |
#100
|
|||
|
|||
![]()
diesel.. how do I do this? And what do you mean DDDS is not the answer? I have a total of 4 urls hosted that shares the same data that I want to have similar but different stylesheets. Basically Im trying to develop a vbulletin based social network where the main url defaults to the vbadvanced dynamics article generator. The second url would share the same database but would just default to the vbulletin based blog module. I would like to assign similar but slightly different style sheets (the article url would have different page navagation and the blogger would have its own custom page navagation). As it stands... both the article url and blog url currently share the SAME template navigation. I really hope DDDS is a way to fix this.
|
#101
|
|||
|
|||
![]()
From the looks of things the hype of DDDS was as big of a hype as obama's economic bailout plan. If DDDS is not qualified as a solution... then what is?
lol DDDS = bailout plan for vbulletin site developers wanting to create a multi-url socnet ! ![]() |
![]() |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|