Hi,
I have installed subdomain on Drupal 6.5 with all the module dependencies. Followed readme.txt to the letter. The first two, and the fourt tests:
DNS server
Web server
Drupal's outbound URL rewriting
pass with green, but the third: "Drupal's inbound URL rewriting" does not pass.
Also, right now I get "Page not found" for any URL I try to access.
I checked the code in settings.php that I copied and pasted from readme.txt. This is it:
function custom_url_rewrite_outbound(&$path, &$options, $original_path) {
// Used by the Subdomain module to generate URLs with subdomains
if (module_exists('subdomain')) {
subdomain_url_rewrite_outbound($path, $options);
}
}
function custom_url_rewrite_inbound(&$result, $path, $path_language) {
// Used by the Subdomain module to correctly interpret URLs with subdomains
if (module_exists('subdomain')) {
subdomain_url_rewrite_inbound($result, $path, $path_language);
}
}
I have no idea what I am doing wrong. By the way, I already set the tilde setting to none.
Do you have any any advice?
| Comment | File | Size | Author |
|---|---|---|---|
| #3 | subdomain-panel.png | 151.99 KB | sam6 |
Comments
Comment #1
setvik commentedCan you paste the exact message given for the "Drupal's inbound URL rewriting" test that fails?
Comment #2
sam6 commentedHi, this is the message:
(keeping in mind I visit the admin/build/path/subdomain page using test.domain.com, since the regular www.domain.com gives "page not found" no matter which URL I try to vist)
"HTTP request to http://subdomain-test.test.withsrichinmoy.org/subdomain/test resulted in an internal Drupal path of subdomain/test. It should have been ~subdomain-test/subdomain/test
The custom_url_rewrite_inbound() function in settings.php is rewriting the internal path incorrectly. Did you patch settings.php? See readme.txt for instructions."
Thank you for all the help
Comment #3
sam6 commentedI am attaching a snapshot of the subomain panel in the "URL aliases" section.
Also note that there are no other extra modules or themes enabled beside the core ones and the dependencies. I tried re-creating the site from scratch (and I mean, from the bare directory and db), always with same issue.
The cookie part is not set since, if I do, even test.domain.com would show "Page not found" for any URL, thus preventing me to reach the the subdomain panel.
Comment #4
sam6 commentedWould anybody have any advice please?
Anything to try, or at least a way to know why that is happening?
Does this module have any debug possibility, any file I could look at?
Comment #5
gster commentedI've got the same question and then solved it.I think you maybe forgot to uncomment the "$cookie_domain" in setting.php.
em~sorry for my bad english,hope you got what i mean.
and good luck!
gster
Comment #6
setvik commentedSorry for the belated reply.
I think gster is correct. It looks like you need to uncomment the $cookie_domain line in settings.php and set it to the name of your domain.
Comment #7
setvik commentedComment #8
sam6 commentedThank you very, very much for your help.
I thought that uncommenting the $cookie_domain assures that the user remains logged in as he cross between the various sub-domains.
Anyway, I didi that but unfortunately it does not seem to fix it. The moment I uncomment the $cookie_domain line I also start getting "page not found", no matter which third level domain or URL inside the domain I try to access (www.domain, test.domain, etc).
If I leave that line commented out, at least I can still reach the admin page.
Here is the settings.php file:
Comment #9
Korak1 commentedI'm having the same problem. When I enabled the subdomain modude, I suddenly started getting "Page Not Found" messages even for the www.example.com domain. (Or example.com) If I rename the subdomain folder in the module directory, then the site will be accessible for a couple of pages before returning a constant stream again of "page not found". In my case, I've installed the module in sites/all/modules since I anticipate a mutli-site scenario for this code. My cookies statement is uncommented. I've been trying to figure out the problem with no success. I'm not even sure what to try this point so any suggestions will be very much appreciated.
Thanks!
Comment #10
sam6 commentedI am still in the dark with this module.
I just wish there would be some kind of debug log file. I am trying Domain Access as well, but it is quite more than I need. Subdomain would be perfect, if only it would work.
Comment #11
Korak1 commentedI'm adding a little more detail here in the hope that it will help... when the subdomain module is enabled every page on the domain including the base domain returns the "Page not found" message of the Drupal install. Additionally, if I attempt to go to a subdomain, then I get the install screen.
If I unenable the subdomain module, (which I can only access by renaming the subdomain module on the server so it doesn't run), then the site functions normally.
So, I can see that I have configured something incorrectly but have tried to step through the configuration steps and don't see anything wrong. Has anyone encountered this problem before and solved it?
Thanks!
Korak