Welcome, Guest
Username Password: Remember me
  • Page:
  • 1
  • 2

TOPIC: site redirection

Re: site redirection 13 years, 9 months ago #3302

  • jekkil
  • OFFLINE
  • Fresh Boarder
  • Posts: 11
  • Karma: -1
Here is a better explaination fo the situation:
I have tried to find the solution, but had no luck
here is the problem:
on my dynamic cloud server (with root acces) I have several domains, two of these are concerned:

* domainXX.biz and domainAA.com
* both have joomla installations, with the same features
* both have joomla installed in their correspoding httpdocs/main folder
* due to that, i had created first an htaccess rule to redirect to /main , but the results were not satisfying ( I wish I had found this forum earlier!)

RewriteEngine on
RewriteCond %{HTTP_HOST} ^www\.domainXX\.biz$ [OR]
RewriteCond %{HTTP_HOST} ^domainXX\.biz$
RewriteRule ^(.*)$ domainXX.biz/main/ [R=301,L]

* then i created a redirection in an index.php file that I placed in the httpdcos folder

<?php
Header( "HTTP/1.1 301 Moved Permanently" );
Header( "Location: domainXX.biz/main" );
?>

this was done for both domains btw with the same rules


I installed afterwards a joomla module that for adapting the joomla template to mobile sites on domainXX.biz, which worked quite well, and it redirects the mobile users to the corresponding site , ex. iphone.domainXX.biz/main or pda.domainXX.biz/main. so far so good!

now i decided to add the module to domainAA, using exactly the same procedures, but here the trouble starts:
the URL iphone(pda).domainAA.com/main shows iphone(pda).domainXX.biz/main! notice that the url does not show any redirection!

Ok, after a few days i decide, just to take everything back to normal, so :

* I remove ALL redirection
* I remove all modules
* I clean ALL the caches
* I check that all folders are removed and databases are also clean

and then...

when i type domainXX.biz/main :all OK
when i type domainAA.com/main :all OK

BUT if i type any combination of letters like xyw.domainAA.com/main I am redirected without url change to the site of domainXX.biz/main !!
And for a test, i checked the image url (which is physically in
domainXX.biz/main/images/stories/europe.png) and i get the following link :
xyw.domainAA.com/main/images/stories/europe.png
note that this image does NOT exist in the above named folder!

I have sent a live header file to check the behaviour of the wld redirections, but the experts on a specialized APache Forum confirmed that it does not come form a server problem but is module related.:


I really like this module, and if I can help by sending logs and files to find the problem and a solution to it, no problem, but it would be too bad if the devs ( @bazza14: sorry i thought you were part of the dev team) put this aside, as the costumer was very interested, and I announced already that this module has a price ( a sum I would forward to you directly) because it is a commercial use.

So I hope we can get this problem solved.

Re: site redirection 13 years, 9 months ago #3304

  • dryabov
  • OFFLINE
  • Administrator
  • Denis Ryabov, Lead Developer
  • Posts: 4867
  • Karma: 105
To prove that it's not DNS-related issue, post here A and MX records of both domain names. Also post aliases for both virtual hosts from httpd.conf/vhost.conf.

Re: site redirection 13 years, 9 months ago #3307

  • bazza14
  • OFFLINE
  • Junior Boarder
  • Posts: 20
  • Karma: -2
@ dryabov, you and I are thinking the same thing.
@ jekkil. The behaviour you describe is typical. You have no virtual host in your http.conf for a subdomain of domainAA.com. DomainXX.biz is the first and default vhost, in the event that apache cannot find a vhost that matches it will return the default vhost and I don't give a monkeys who you thought I was. JM came to you at no cost, you are using it for financial gain and now you are bleating at the devs 'cause you can't get it to work. Maybe if you paid them they'd teach you how to set up your server.

Re: site redirection 13 years, 9 months ago #3308

  • jekkil
  • OFFLINE
  • Fresh Boarder
  • Posts: 11
  • Karma: -1
well you just hold your breath about paying, because I wrote to dryabov and stated that i would be paying for the module since YES i am using it for a costumer, so dont accuse before you dont know the what has bees said ! And you are right, I dont give a damm who you are!

Re: site redirection 13 years, 9 months ago #3310

  • bazza14
  • OFFLINE
  • Junior Boarder
  • Posts: 20
  • Karma: -2
I really regret trying to help you. Won't happen again.

Re: site redirection 13 years, 9 months ago #3330

  • jekkil
  • OFFLINE
  • Fresh Boarder
  • Posts: 11
  • Karma: -1
bazza14 wrote:
@ dryabov, you and I are thinking the same thing.
@ jekkil. The behaviour you describe is typical. You have no virtual host in your http.conf for a subdomain of domainAA.com. DomainXX.biz is the first and default vhost, in the event that apache cannot find a vhost that matches it will return the default vhost ....


sorry i do not quite understand this, but this is my missing know-how, forget it
Last Edit: 13 years, 9 months ago by jekkil.

Re: site redirection 13 years, 9 months ago #3339

  • miohtama
  • OFFLINE
  • Expert Boarder
  • Posts: 112
  • Karma: 4
Usually you can work around this by added ServerName and ServerAlias to all domains in Apache configuration

 
ServerName yourhost.com
ServerAlias iphone.yourhost.com
ServerAlias mobile.yourhost.com
 

Re: site redirection 13 years, 9 months ago #3341

  • jekkil
  • OFFLINE
  • Fresh Boarder
  • Posts: 11
  • Karma: -1
will it work the same if I add a domain alias in the cpanel of my webhosting admin, or do i have to interact directly in the Apache config?
  • Page:
  • 1
  • 2
Time to create page: 0.11 seconds

By continuing to use this site you consent to the use of cookies on your device as described in our cookie policy unless you have disabled them. This site will not function correctly without cookies.

I accept cookies from this site.