Recent Topics

1 Dec 12, 2007 17:45    

This is a version 2.2 question.

OK, I have been experimenting with b2evolution for a couple of weeks. I am just amazed by the greatness of this thing. Basically, b2evo is a light CMS in addition to a top-notch blog, and that is just what I wanted. I feel like a little kid at Christmas.

So, I have a question. I need some advice on my "final setup."

I want to run multiple (unrelated) blogs on mutiple unrelated domains all from the same server (virtual host). I'm using a Lunarpages linux host. I want to have one blog install -- but I want that to be transparent to the users. That mostly means that I want to keep the domains correct in the permalinks. I do not want to just use a redirect from foo.com to bar.com and then find that all of my foo-blog posts have bar.com in the permalink.

Does that make sense?

I think you can see what I don't want here. If you go to http://www.aggiestop.com you can see there are 2 blogs. URL is OK (but not great since stbus are not implemented). If you go to http://www.goodbullblog.com that takes you directly to one of the blogs on http://www.aggiestop.com just fine. The problem is that the URLs are aggiestop (not goodbullblog).

So, I am looking for advice on how to merge the following 4 blogs :

http://www.masonworld.com
http://www.cochlearworld.com
http://www.goodbullblog.com
http://www.aggiestop.com

into one b2evolution install with the best looking URLs (and user experience).

I think I am going to need stubs and 301 redirects.

Comments very much appreciated.

Thanks!
Mark

2 Dec 13, 2007 10:59

I don't exactly remember one of my experiments with b2evo, so please try this:

Steps:
1) Blog Settings
2) URLs
3) Choose "Absolute URL:" and type your new domain (example: http://www.goodbullblog.com)
4) Go to your host's cpanel
5) Somewhere there, click "Add New Domain"
6) Add your goodbullblog.com domain

Reply back if it doesn't work.. I'm trying to separate different menthods on my mind ^_^

3 Dec 13, 2007 13:27

Thanks. Will try tonight (I am out of town at the moment).

Not sure I understand how this is intended to work. I guess I must need a stub file called index.php at the absolute URL location?

4 Dec 14, 2007 15:27

OK -- some progress -- but not all working.

I got the absolute URL working, but some links are broken.

Here is my setup. I have multiple domains hosted on a Lunarpages shared linux server (their $6.95 plan). All of my files live in /home/myuserid/public_html. My primary domain on the machine is http://www.preciousonpaper.com

My goal for this test is to get two blogs working in the same install -- one on http://www.preciousonpaper.com and one on http://test.masonworld.com

I have installed b2evo 2.2 in the public_htlm/blogs directory. That works. You can see it at http://www.preciousonpaper.com/blogs

I have created a new blog called testblog (blogID=4) with an absolute URL of http://test.masonworld.com. Note that the test.masonworld.com subdomain exists as a redirect to the directory public_html/test. I copied a_stub.php into that public_html/test directory as index.php. I changed the blog id to 4, and changed the config file path to the following crude relative path.


require_once dirname(__FILE__).'/../blogs/conf/_config.php';

Recall that the main install is in /home/myuserID/public_html/blogs and that the domain http://test.masonworld.com is redirected to /home/myuserID/public_html/test. So, when you hit /home/myuserID/public_html/test/index.php, the _config.php file is up one level over in ../blogs/cong. That URL gets resolved OK by dirname.

You can see that appears to work - sort of.

One problem is that the test post has broken links to the category and feedback. It looks to me like it is asking for links like this: http://test.masonworld.com/testcat/ -- I am not sure how that works. I guess that is an htaccess trick?

Another problem is logins and cookies. I get this alot from the http://test.masonworld.com blog:


WARNING: you are trying to log in to http://test.masonworld.com/?blog=4 but your cookie domain is .preciousonpaper.com. You will not be able to successfully log in to the requested domain until you fix your cookie domain in your b2evolution configuration. 

Any comments on either of these?

Thanks!
Mark

7 Dec 15, 2007 22:40

Yep -- that helps. I don't really understand the cookies code (need to look at that a bit) and that article implies that all of the blog dirs need be beneath the baseurl (not alonbg side it in a separate path, which is what I have.) I will have to experiment tonight.

8 Dec 16, 2007 04:29

I think what I did broke trackbacks. Ugh.

This is harder than it should be (I am dummer than I should be). Might be neat to move this multiple domain stuff to the backoffice by setting a baseurl for each blog in the admin interface and working out the details some how.

Not giving up yet, though....

9 Dec 16, 2007 07:58

OK, now I am ready to give up.

I am able to get the $baseurl set right, and the #cookie_domain set correctly as well. Still does not work well -- I keep getting logged out when I go from domain to domain (like the cookies get lost or overwritten).

To bed!

Mark

10 Dec 16, 2007 13:39

Hi folks, I am interested in much the same thing as texasag90 and I first thought, in my country boy way, that it would be better to download a version of b2e for each new domain name so that each blog is a seperate entity even though they are all on the one host. Apart from using up more storage space there wouldn't be a down side, would there?

11 Dec 16, 2007 13:58

texasag90 wrote:

I am able to get the $baseurl set right, and the #cookie_domain set correctly as well. Still does not work well -- I keep getting logged out when I go from domain to domain (like the cookies get lost or overwritten).

Here's how I have it setup

On the server my blogs folder is

/home/innervisions/html/

Both of my domains point to the same folder by adding my second domain ( waffleson ) as an alias to my main domain ( innervisions ). This gives me one set of files to maintain for both domains.

Then, in conf/_basic.config.php I set my $baseurl to match the current requests uri, a tad further down the file I set the cookie path to "/"

$baseurl = ( strpos( $_SERVER[ 'HTTP_HOST' ], 'innervisions.org.uk' ) ? 'http://innervisions.org.uk/' : 'http://waffleson.co.uk/' );

$cookie_path = '/';

Then, in admin, for each of my blogs I've entered the urls in the "absolute url" box, which also has the effect of getting rid of index.php in the urls, but means I have to piss about with .htaccess to make it work ;)

The end result is I have 1 set of files, a single database, and one login ( although I have to login to both sites first ).

l.theman wrote:

Apart from using up more storage space there wouldn't be a down side, would there?

Only the fact that if you want to make any changes ( to a skin for example ) then you need to change the files for every install

¥

12 Dec 17, 2007 12:47

The cookie path hint helped.

OK -- looks like the following did it

1. symbloic link from http:/extradomain/blogs to the maindomain/blogs dir
2. edit _basic.config_php to get the baseurl right.
3. edit _advanced.php to set the cookie path to slash.
4. edit .htaccess in each domains' root dir to do the normal mod rewrite stuff.
5. create a stub file index.php in each domain

I will post some details later after I do some testing.

Thanks for all the help.

14 Dec 18, 2007 05:44

Working better now -- not sure why.
Mark

15 Dec 24, 2007 17:11

texasag90,

I'm planning on consolidating multiple blogs / multiple domains onto one instance of v2.X, so will you please post all of the changes your made to get this to work?

Thanks very much for being the trailblazer,

Rocketdude

16 Dec 26, 2007 07:30

Yes -- I've been putting this off. Will do.
Mark

18 Dec 27, 2007 19:12

Any feedback on this?

19 Dec 29, 2007 07:28

That looks good texas aggie. I am not understanding the symbolic link and how to set that up... but I will google that bit and then try to set one of these up with multiple domains. It's something I have been wanting to do.

20 Dec 29, 2007 17:10

A sym link is just a pointer to another location. So ln -s bar foo creates a pointer called foo that actually just points to bar. In our case, I am just tricking apache into thinking that the blogs subdirectory is under the default docs directory. I don't think this is required, but it is clean from an maintainence standpoint.

21 Dec 29, 2007 17:32

I will play with this some, I learned enough about the sym link from googling... to be able to set that up.. I must say also that the ¥åßßå site is very useful... ,

http://waffleson.co.uk/2007/10/multi-domains-on-a-single-evo-install

I plan to spend some time on this... but, we are having a bit of cool weather here today (Dallas), and on the off-chance that this is our winter, I am going to spend some time outside enjoying the chill.

22 Dec 29, 2007 19:00

I'm in Dallas too (Allen, actually). Definately recommend you get outside today.


Form is loading...