akhilk Posted August 9, 2020 Share Posted August 9, 2020 hello sir, i have to connect database to my live server using <?php define('DB_HOST', 'localhost'); define('DB_NAME', 'oop_pdo_crud'); define('DB_USER', 'root'); define('DB_PASS', ''); ?> or Quote Link to comment Share on other sites More sharing options...
akhilk Posted August 9, 2020 Author Share Posted August 9, 2020 i have uploaded all files on my server but index file is not opening please help. Quote Link to comment Share on other sites More sharing options...
requinix Posted August 9, 2020 Share Posted August 9, 2020 2 hours ago, akhilk said: or Or? 2 hours ago, akhilk said: i have uploaded all files on my server but index file is not opening please help. If you need technical help from people with technical knowledge then you need to be very, very specific with your questions. What does "not opening" mean? What is happening and what did you expect would happen? Quote Link to comment Share on other sites More sharing options...
Phi11W Posted August 10, 2020 Share Posted August 10, 2020 On 8/9/2020 at 7:08 AM, akhilk said: define('DB_USER', 'root'); define('DB_PASS', ''); Never use the root (or any other "superuser") account for running applications. These uber-powerful accounts should be kept solely for your use to clean up the mess when an Application goes wrong. Keep the Biggest and Best tools in the toolbox for yourself. Create an account specifically for the application to use and grant that account only the permissions that it needs to do its job. +1 for not showing us your [root] password. -1 again, though, for hard-coding it into your PHP source code. Database credentials need to be carefully guarded and having them lying around in plain text, even in a PHP file, is not a Good Idea. All that said, we have no idea why your "index file is not opening" ... you've shown us no PHP code to examine, nor [database or PHP] errors to diagnose. Details, details, details ... 🙂 Regards, Phill W. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.