Laravel .env file not changing the database

Posted 5 months ago by AbdulBazith

Guys I worked with a project name PROJECT1 . I hosted it in an domain in Cpanel. For testing purpose I duplicated the project and renamed it as PROJECT2 in the same domain. Now I changed the DB_DATABASE,DB_USERNAME,DB_PASSWORD in the .env file in the PROJECT2. Now whats my problem is I changed the db name for PROJECT2 but it still works with the old DB. Still it fetched data from the old db how?

the PROJRCT1 is also in the same domain..

Whats the reason for this problem. Do I need to change any other file to change the DB.

Please suggest your ideas

Please sign in or create an account to participate in this conversation.

Laracasts Mascot

Hi, Have We Met Yet?

Did you know that, in addition to the forum, Laracasts includes well over 1000 lessons on modern web development? All for the price of one lunch out per month.

Sign Me Up

Channels

Reply to

Use Markdown with GitHub-flavored code blocks.