0

I have my personal website that I am developing so I can showcase my code, photography and digital art and also blogs to the public.

Currently my site structure is :

www.mysite.co.uk/sub-folder

e.g.

www.mysite.co.uk/blog

However I would like to make my site domain structure like what I have seen on some sites:

www.blog.mysite.co.uk

or

www.code.mysite.co.uk

What is this technique called?

How is it achieved? htaccess mod?

Any links or resources please could you send me them.

Thanks

tomaytotomato
  • 3,788
  • 16
  • 64
  • 119
  • 1
    http://stackoverflow.com/questions/8899805/edit-htaccess-with-php/8900619#8900619 – Gerben Jan 18 '12 at 13:11
  • possible duplicate of [Create sub domain using only htaccess?](http://stackoverflow.com/questions/7085712/create-sub-domain-using-only-htaccess) – 3Dave Jan 18 '12 at 22:53
  • @DavidLively , thats not me. As I do not really know much about domains my question was to establish how, what and where to do this. – tomaytotomato Jan 19 '12 at 11:58

2 Answers2

1

www.mysite.co.uk/sub-domain istn't called "Sub Domain". Its only a sub folder.

This "blog.mysite.co.uk" are subdomains. You must configure them in your Apache Server configuration: http://edwardawebb.com/apache/create-subdomains-apache-easy

PKeidel
  • 2,559
  • 1
  • 21
  • 29
0

You can't add subdomains using htaccess. I suggest you to contact your hosting provider. Usually they give you an ability to add subdomains using their control panel.

Cyberon
  • 289
  • 1
  • 4
  • 16