Redirect from non-www to www in Clip-Bucket v2

Hello,

Learn how to make your Clip-Bucket website redirect from non-www to www. This might be useful for those implementing SEO strategies that require this behavior. Written for v2.

1. Open ./includes/common.php

2. Find

        $wwwcheck = preg_match('/:\/\/www\./',$baseurl,$matches);
	if(count($matches)>0)
	{
		$baseurl = preg_replace('/:\/\/www\./','://',$baseurl);
	}

and comment the whole block by adding /* …code… */, just like this:

        /*$wwwcheck = preg_match('/:\/\/www\./',$baseurl,$matches);
	if(count($matches)>0)
	{
		$baseurl = preg_replace('/:\/\/www\./','://',$baseurl);
	}
        */

3. Save & Upload.

4. We’ll now modify a record in your database. Open your preferred SQL manager, for example phpMyAdmin.

5. Go to the cb_config table

6. Edit the baseurl row and add www. to the domain

7. Save changes

 

That’s it! Your site should now redirect to www. If you get stuck at any step, please let me know so I can personally assist you. Article suggestions and comments are welcome.

 

Best Regards,

Richi

Looking for quality Clip-Bucket hosting? Try out Arvixe and you won’t be disappointed.
Tags: , , , , , , , , , , | Posted under ClipBucket | RSS 2.0

Author Spotlight

Richi González

Richi González

I started programming when I was 12. I'm a Developer and have been working with the Clip-Bucket script since it came out. I'm the Liaison between Arvixe and Clip-Bucket, so anything you need regarding Clip-Bucket or any particular computer-related subject you need, let me know so I can assist you.

4 Comments on Redirect from non-www to www in Clip-Bucket v2

  1. Laurentiu says:

    hello, does not work: ((I made ​​all the changes but it still gives me redirect without http://www., and now is not working or most watched section or recently added.

  2. Sam says:

    Same with me, it does not load being watch , most viewed and recent videos etc and redirection link is shown in all categories but if i click it again redirect as if there is a wildcard. e.g the ‘Videos’ link is http://www.domain.com/videos/ if we click on ‘Videos’ it redirects to http://domain.com/videos/

Leave a Reply

Your email address will not be published. Required fields are marked *


4 + 5 =

You may use these HTML tags and attributes: <a href="" title="" rel=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>