like always windows OS is driving me crazy.I have localhost and I did run n98-magerun sys:check for troubleshoot magento and I know the problem as follows:

Invalid Secure BaseURL Store: default Wrong hostname configured. Hostname must
contain a dot

through installation when magento asked me to enter the host name I did use instead of localhost, I tried to use www.localhost.com to solve the problem in the hosts file of located in C:\Windows\System32\drivers\etc       www.localhost.com

then I went to httpd.conf and I did the following:

<VirtualHost *:80>
    ServerAdmin webmaster@dummy-host.example.com
    DocumentRoot "c:/wamp/www/magento"
    ServerName localhost.com
    ServerAlias www.localhost.com
    ErrorLog "logs/dummy-host.example.com-error.log"
    CustomLog "logs/dummy-host.example.com-access.log" common

I didn't change Logs because I didn't need them then in .htaccess of magento I wrote this:

 Order allow,deny
    Allow from all

and I can see the page:

enter image description here

but if I click on any link again I will be signed out because the domain is localhost and doesn't have dots

I tried to go core_config_data table and search for the base url, I didn't find anything

I tried every solution on the internet, literally everything.

P.S:I just found out that I can login through firefox but not chrome, I know the solution of changing Varien.php but I don't like it and I don't want to change core files it should have a better solution

P.S: As adeel said I increased cookie life time in php.ini from 0 to 3600

session.cookie_lifetime = 3600

still not working in chrome


Check in below image there you need to set your base_url set for both row, Try both localhost & , for me both are working fine. Table name is core_cofig_data

If you can't able to find the base url rows, just do a search in core_cofig_data table in path column web/unsecure/base_url OR web/secure/base_url.

Also increase Cookie Life Time & it will start working fine on Chrome too.

enter image description here

  • as I said I dont have them MySQL returned an empty result set (i.e. zero rows). (Query took 0.0380 sec) SELECT * FROM core_config_data WHERE path LIKE 'web/secure/base_url' – Nickool Apr 12 '15 at 16:32
  • I also increased cookie life time and restarted apache no result yet – Nickool Apr 12 '15 at 17:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.