-
Jul 1st, 2015, 07:19 AM
#1
Thread Starter
Lively Member
How to connect MySQL Database to cakePHP v3.0 using XAMPP
Good morning/evening to all members here!
I have a problem to connect the database of MySQL to cakePHP v3.0
I already follow the instructions here
when I run localhost/nameOfMyWebsite
this is the result
another screenshot on phpMyAdmin
cakePHP version: v3.0
XAMPP version: v5.6.8 VC11
I saw a user post a fix here
but in my "C:\xampp\htdocs\cake" there are no app folder so that I can configure the database.php
Last edited by MeSH; Jul 1st, 2015 at 07:22 AM.
-
Jul 1st, 2015, 07:24 AM
#2
Re: How to connect MySQL Database to cakePHP v3.0 using XAMPP
Then you need to find it...
I woudln't expect to find it in the htdocs folder... but rather a couple levels down from there. xampp installs I've worked with in the past typically point xampp\htdocs\wwwroot for the root of the site... this is so that you can put things into htdocs for reference but still keep them out of the public zone. Go back to your htdocs folder and look at some of the other folders in there ... at some point you'll find the right public folder in which will be your cake install and your database.php file to set up the database access.
-tg
-
Jul 1st, 2015, 07:35 AM
#3
Thread Starter
Lively Member
Re: How to connect MySQL Database to cakePHP v3.0 using XAMPP
Originally Posted by techgnome
Then you need to find it...
I woudln't expect to find it in the htdocs folder... but rather a couple levels down from there. xampp installs I've worked with in the past typically point xampp\htdocs\wwwroot for the root of the site... this is so that you can put things into htdocs for reference but still keep them out of the public zone. Go back to your htdocs folder and look at some of the other folders in there ... at some point you'll find the right public folder in which will be your cake install and your database.php file to set up the database access.
-tg
inside C:\xampp\ folder I-type in the search box "database.php" but no luck... so what's the problem? it is the new version of cakePHP?
-
Jul 1st, 2015, 08:51 PM
#4
Re: How to connect MySQL Database to cakePHP v3.0 using XAMPP
Originally Posted by MeSH
inside C:\xampp\ folder I-type in the search box "database.php" but no luck... so what's the problem? it is the new version of cakePHP?
Take a look at the "Config" folder for a file named "app.php" : http://book.cakephp.org/3.0/en/quick...-configuration
Then change the values of these: http://i.imgur.com/0jitvoJ.png
Use the correct db username and password. In WAMP, the default the username is "root" and there's no password (if you haven't set one manually). Don't know about XAMPP. Also make sure that you have created the db. Take a look at the quick start guide if you are not familiar with CakePHP.
If my post was helpful to you, then express your gratitude using Rate this Post.
And if your problem is SOLVED, then please Mark the Thread as RESOLVED (see it in action - video)
My system: AMD FX 6100, Gigabyte Motherboard, 8 GB Crossair Vengance, Cooler Master 450W Thunder PSU, 1.4 TB HDD, 18.5" TFT(Wide), Antec V1 Cabinet
Social Group: VBForums - Developers from India
Skills: PHP, MySQL, jQuery, VB.Net, Photoshop, CodeIgniter, Bootstrap,...
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|