I turned on clean links, and everything works fine except the admin link. I have to use ?q=admin to get to the admin page. Why would this be?

Thanks for your help.

Trent

Comments

bart jansens’s picture

Category: bug » support

I remember a few years ago someone else had that problem as well and it was because the hosting provider had some kind of control panel located at yourdomain/admin which intercepted all requests to /admin pages.

Can you check if that is the case? If so, the easiest way to fix this would be to have your host move that admin panel to a different URL. If they can't (or won't), you can always try adding this to your settings.php:

function custom_url_rewrite($op, $result, $path) {
  switch ($op) {
    case 'alias':
      // translate all paths below /admin to /administer
      if (preg_match('#^admin($|/.*)#', $path, $matches)) {
          return 'administer'. $matches[1];
      }
      break;
    case 'source':
      // other way around, translate /administer paths back to the original
      if (preg_match('#^administer($|/.*)#', $path, $matches)) {
          return 'admin'. $matches[1];
      }
      break;
  }
  return $result;
}

This should translate all the /admin paths to /administer instead.

scoutbaker’s picture

This has come up recently as well, and the culprit was the Plesk control panel software. It was installed into the /admin directory. I can't find the exact issue I was thinking of, but I believe the solution was their host moved the Plesk software.

Macromuzz’s picture

Version: 5.5 » 6.1

I have installed wamp 2.0 and drupal 6.1, running on Windows xp. When I am logged in as admin and I try to open the administer link (Firefox tries to open http://localhost/?q=admin) after getting no response from the server, it returns a blank page.

Annoyingly I did once manage to get the administer link working but I can't seem to replicate it. Is 6.1 really this buggy? Should I start again on 5.7?

keith.smith’s picture

Status: Active » Postponed (maintainer needs more info)

It could be that update_status module is trying to query for module status on that page, and for some reason the requests are not, or cannot, get through.

Bypass the admin page completely by going to something like http://localhost/?q=admin/build/modules and try disabling the update status module.

If you were on a vista box, this would most likely be due to vista's [currently faulty] ipv6 implementation that sometimes fubar's localhost name resolution.

Please report back as to success.

Macromuzz’s picture

This only happened to me after I tried installing 6.1. - 5.7 worked fine.

I get the white screen of death when I try clicking the administer link. I wonder if it might have something to do with the wamp 2 server settings, though I have checked and rechecked all the permissions settings. The localhost server does take a long time (much longer than 5.7) to retrieve other pages (using the links that do work).

Wierdly though, if I go in through the help screen (http://localhost/?q=admin/help) then I can get to the administer page that way.

Is 6.1 really still so buggy?

ainigma32’s picture

Status: Postponed (maintainer needs more info) » Fixed

Solutions for both problems were given. Assuming that solved both problems.

If not feel free to reopen.

- Arie

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.

seanr’s picture

Bart Jansens, thanks! This just saved my life, or at least my hair! ;-)

BTW, OpenSourceHost is officially off my list of hosting options for this reason and several others (like totally crippled SSH). Ugh.