1. Welcome to the eTeknix Forums Guest. Please register or login and remember to read the forum guidelines to make your stay as pleasant as can be.

Help with website php/mysql

Discussion in 'HTML, Graphics & Programming' started by baker556, Feb 18, 2013.

  1. baker556

    baker556 New Member

    Joined:
    Feb 13, 2012
    Messages:
    51
    Likes Received:
    0
    Hi all,

    So been given a task by the boss to download and update some content on the companys currrent website, i suggested downloading the site via ftp then using localhost then updating the content rather than doing it live and causing any issues on the site.

    Anyway turns out this is the way he wants it done, now everything is downloaded the website back end database. Now the website runs fine on localhost after some setting changes in the php file.

    Problem im having i have an account to log into the website as an administrator, now for some reason i cannot log in to the website on the localhost although the database and eveything is linked and connected. Something i need to test out in the website live on the localhost when online as an admin basically.

    So i can't login i have used the mysql command line to work out whats going on, so i'm a user on the database it looks passwords is okay, so my question is why can i not log into the localhost website but i can login to the live website. Although everything is connected correctly to the database?
     
  2. dJabba

    dJabba eTeknix Staff Forum Mod

    Joined:
    Jun 13, 2011
    Messages:
    388
    Likes Received:
    32
    Location:
    Denmark
    Show PC Specs
    CPU:
    Intel Core i5 6600K
    Motherboard:
    Gigabyte Z170 Gaming G7
    Memory (RAM):
    32GB Kingston HyperX Fury
    Storage:
    SM951 256GB in RAID 0
    Graphics Card(s):
    EVGA GTX 980 SC
    Power Supply (PSU):
    be quiet Dark Power Pro 10 850W
    Case:
    Thermaltake Core P5
    Monitor(s):
    ASUS VS248H x3, ProLite B2888UHSU
    Operating System(s):
    Windows 10 Pro
    Internet Connection:
    90 Mbsp Fiber Optical
    Depending on how it's all setup, this could be the problem - not entirely sure from your description. I'm far from an MySQL expert, but have had similar trouble in the past - don't ask me how to fix it step by step (cause I can't), but might give you a pointer in the right direction.

    Most MySQL users are by default and on purpose (for security reasons) set so only the same machine can connect to the SQL database, AKA you can't make a remote connection. This for example prevents you to use database editing programs that are installed locally on a remote database and forces you to use the phpMyAdmin tool (that for the database is on the same server).
    If that is the case, it's a user-setup problem in the database.

    Hope that made a bit of sense
     
  3. Flynn Greenberg

    Flynn Greenberg Moderator Forum Mod

    Joined:
    May 13, 2011
    Messages:
    912
    Likes Received:
    57
    Location:
    Scunthorpe, United Kingdom
    Show PC Specs
    CPU:
    Amd fx 8350
    Motherboard:
    Asus M5A97 R2
    Memory (RAM):
    8gb
    Storage:
    4 tb
    Graphics Card(s):
    MSI R9 290
    Power Supply (PSU):
    750W
    Case:
    Ennermax
    Monitor(s):
    24 inch hd 1920 x 1080
    Operating System(s):
    windows 7
    Internet Connection:
    150mg broadband
    yes indeed if i remenmber from my ipb boards the user and pass details need to be the same also check the php inni file
     
  4. baker556

    baker556 New Member

    Joined:
    Feb 13, 2012
    Messages:
    51
    Likes Received:
    0
    Thanks for the reply, it makes sense but I'm unsure where to go from here really.

    I can't see a user set up problem if thats the case.
     
  5. baker556

    baker556 New Member

    Joined:
    Feb 13, 2012
    Messages:
    51
    Likes Received:
    0
    Checked the php.ini file it all links correctly to the database, user and passwords are correct.

    Really not to sure where i have gone wrong here...
     
  6. baker556

    baker556 New Member

    Joined:
    Feb 13, 2012
    Messages:
    51
    Likes Received:
    0
    Don't worry guys all sorted!


    It was the wrong password in the end which had my suspicions, no worries i learnt alot of mysql along the way!


    I had to enter the new password using a md5 encrypted then command line the update!
     

Share This Page

Users Viewing Thread (Users: 0, Guests: 0)