I built my site on my local computer, then uploaded the files and database files from localhost to a live server. The home page appears but all links to other pages are broken saying "The requested URL /node/2 was not found on this server." also, I can't get to the administrator account, my password doesn't work. Could someone point me in the right direction with a link or file I need to work on. Some of the forums mention the .htaccess file needs to be modified, but doesn't explain how. Some forums said it is the clean urls that's the problem. Some forums say there are other files that need their configuration changed. I realize this issue has been brought up by several others, but I never seemed to find a clear answer to the problem.

Comments

blackarma’s picture

Hmm don't remember actually how i solved this while ago, but you can get to the login page ? if not then www.yourhost/?q=user
If that don't work you should disable clean-url to sort it out futher you can do that by altering table contents in your database
So inside databasename -> variables -> clean_url
change this
s:1:"1";
to
s:1:"0";

Also notice that you might also clear catche data from database manually before it takes action. Or sometimes not needed.

iraszl’s picture

But, this looks like a .htaccess problem. Are you sure you copied the .htaccess file up to the server?

JohnnyW’s picture

All I had to do is loging...

localhost/website/?q=user

Login.

Clear Drupal Cache.

CLEAR your browser cache!

Clearing your browser cache is VERY important.

JohnnyW’s picture

Actually, I noticed i could only use localhost/website?q=user

AFTER I removed the port in the settings.php file... was like 3306 between the '' and so I removed it.

 'port' => '',
JohnnyW’s picture

Okay, I noticed that that whole website worked, but the homepage

Drupal kept sending me to www.localhost/website

instead of localhost/website

BUT I didn't clear my browser cache, though I cleared Drupal database cache... .

I was able to confirm this with using another browser (develop on Firefox, used Chrome to confirm).

NOTE: I did keep the setttings.php and did NOT comment this out... you will have to play with your settings, as you have noticed...

$base_url = 'http://localhost/website';