English (United Kingdom)
Jms Multi Site, formerly joomla multisite.
Create, share multiple joomla sites in few clicks !
Message
  • EU e-Privacy Directive

    This website uses cookies to manage authentication, navigation, and other functions. By using our website, you agree that we can place these types of cookies on your device.

    View e-Privacy Directive Documents

Welcome, Guest
Please Login or Register.    Lost Password?

Wildcard subdomains, Addon Domains and Images
(1 viewing) (1) Guest
Go to bottomPage: 1
TOPIC: Wildcard subdomains, Addon Domains and Images
#5423
Wildcard subdomains, Addon Domains and Images 14 Years, 2 Months ago Karma: 0
Hi: I am building a specific structure on my Multisite Project and I would like to know if it is possible...

I need this...
www.site-prefix.addon.domain.com
for example...
www.xxx.mydomain.com/index.php

In order to achieve this I´ve configured wildcard subdomains on cpanel to have dynamic subdomains like… xxx.mydomain.com
This is my structure…

*.addon-domain = points to… /public_html/
Addon-domain document root = /public_html/addon-domain/
Deploy Di = /home/account/public_html/multisites/{site_prefix}

But there is a problem with the images. When I upload an image or use JCE Editor, the images are taken from the master website which is on the root directory, and not from the deployed directory, even touhg I ´ve set the directory folder to be copied and is as a new subdirectory.

I´ve read on the forums that in order to make it work, the wildcard subdomain should be pointed to the same dir as the deploy directory, but that dir is for example...

/public_htm/multisites/site_alias-addon_domain/

And that way all the slaved sites should have the same images folder. I need to have indepenent images and media folder using addoon domain + wildcard subdomains and the images to work.
Is this structure possible and how to achive this?

Thanks...
dglite
Fresh Boarder
Posts: 10
graphgraph
User Offline Click here to see the profile of this user
The administrator has disabled public write access.
 
#5424
Re: Wildcard subdomains, Addon Domains and Images 14 Years, 2 Months ago Karma: 54
You must have the same deploy dir and document root.

So if you defined the subdomain *.addon-domain.com into ..../public_html/addon-domain.com
then the deploy dir = ..../public_html/addon-domain.com
(Full path).

This is normal that you don't have the deploy dir used as the priority is the cPanel.
The deploy dir is just provided when you have to create a directory structure that does not already exists.

If your master website is also located in the wildcard directory then deploy dir is probably empty.

If you want to have specific images directory for each slave site, this is not easy to acheive that with a wildcard that always point in the same root directory.
Most of the extension hardcode the /images to access the files and therefore is a /images directory relative to the document root specified in cPanel.

The most easier solution is to have as many document root directory as subdomain.
But in this case, that mean that you can not use the wildcard.
edwin2win
Moderator
Posts: 5370
graph
User Offline Click here to see the profile of this user
The administrator has disabled public write access.
 
#5425
Re: Wildcard subdomains, Addon Domains and Images 14 Years, 2 Months ago Karma: 0
Hi: thanks for your fast reply and great support. I understood that a wildcard subdomain is generic for an unique document root, but is there any other system to create unlimited slave sites using addon domains as an extension?
I would like to know if there is any solution or architecture to achieve this with JMS...

www.site-alias.addon-domain.com/index.php

for example...

www.aaa.my-domain.com/index.php
www.bbb.my-domain.com/index.php

etc.

It is just like wordpress. BUT each slave site (aaa, bbb, xxx, etc.) must have its own images and template folder.
As I´ve read on manuals and tutorials, this could be done, but I was not able to do it.
In order to build that architecture...

- where do I target my addon domains?
- should I use wildcard subdomains or other system?
- what should be my deply dir?

If I have the answer to that I could have my site working, thanks...
dglite
Fresh Boarder
Posts: 10
graphgraph
User Offline Click here to see the profile of this user
The administrator has disabled public write access.
 
#5426
Re: Wildcard subdomains, Addon Domains and Images 14 Years, 2 Months ago Karma: 54
This can be done when each cPanel subdomain has a speciifc directory.

Normally in cPanel you start to define and AddOn domain and after you define a subdomain using an existing addon domain.
In this case, you can have specific document root for each subdomain.

Something that I suppose is that you want to create website from the front-end (because you mentioned site_alias} and that you don't want to develop something to create the subdomain in cPanel for each new site_alias and specify it own directory.

Concerning the images and templates directory, I told you to get inspired from tutorial video CP-05 but with the limitation that some extension hardcode the "/images" and the "/templates" directory.
So this does not work at 100% and depends on the extension used.

To be sure, the only solution is to have a specific document root for each subdomain.
So the solution is to implement something specific to update the cPanel dynamically or if you absolutely want to use wildcard in subdomain try creating a rule in .htaccess that would have to redirect on a specific directory. Perhaps you would have to write a CGI or specific function to add to the .htaccess and process the case where a domain does not exiists or a directory does not exists.
We never experimented the .htaccess but perhaps it will works with the wildcard
edwin2win
Moderator
Posts: 5370
graph
User Offline Click here to see the profile of this user
Last Edit: 2010/10/06 15:54 By edwin2win.
The administrator has disabled public write access.
 
#5431
Re:Wildcard subdomains, Addon Domains and Images 14 Years, 2 Months ago Karma: 0
Ok thanks for your great explanation. One last question, in case I ask a programmer to do it, taking into account your experience, do you think it is better to generate an .htaccess file that set dynamic document roots per wildcard domain, or it is just better trying to change the joomla images path editing the joomla core files?
Thanks again...
dglite
Fresh Boarder
Posts: 10
graphgraph
User Offline Click here to see the profile of this user
The administrator has disabled public write access.
 
#5435
Re:Wildcard subdomains, Addon Domains and Images 14 Years, 2 Months ago Karma: 54
All depends the extensions that are concerned by the images.

Why do you use the wildcard and don't specify manually the document root ?

Do something in .htaccess does not seems so easy to implement.
We have already read some docs concerning that to try implement something that could be generic.
edwin2win
Moderator
Posts: 5370
graph
User Offline Click here to see the profile of this user
The administrator has disabled public write access.
 
Go to topPage: 1
get the latest posts directly to your desktop
2Win, Multisite(s) are trademarks of Edwin2Win.
Joomla