CodeIgniter Forums
CI 4.2 Debug Toolbar not working - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: CodeIgniter 4 (https://forum.codeigniter.com/forumdisplay.php?fid=28)
+--- Forum: CodeIgniter 4 Support (https://forum.codeigniter.com/forumdisplay.php?fid=30)
+--- Thread: CI 4.2 Debug Toolbar not working (/showthread.php?tid=82098)



CI 4.2 Debug Toolbar not working - univerbau - 06-12-2022

I installed CI 4.2 on web hosting server and did following changes:

1. app/config/app.php -> public $baseURL = 'http://myurl.com/ci4/public/'
2. myurl.com/ci4/env to .env renamed
3. in .env file uncomment and set its value -> CI_ENVIRONMENT  = development
4. in .env file change app.baseURL value -> 'http://myurl.com/ci4/public/'

still doesnt show up, thanks


RE: CI 4.2 Debug Toolbar not working - kenjis - 06-12-2022

It seems you are doing right.

Is your server's URL http://myurl.com/ci4/public/ ?


RE: CI 4.2 Debug Toolbar not working - nayo - 06-13-2022

(06-12-2022, 12:36 AM)univerbau Wrote: I installed CI 4.2 on web hosting server and did following changes:

1. app/config/app.php -> public $baseURL = 'http://myurl.com/ci4/public/'
2. myurl.com/ci4/env to .env renamed
3. in .env file uncomment and set its value -> CI_ENVIRONMENT  = development
4. in .env file change app.baseURL value -> 'http://myurl.com/ci4/public/'

still doesnt show up, thanks



RE: CI 4.2 Debug Toolbar not working - murugappan - 06-13-2022

(06-12-2022, 12:36 AM)univerbau Wrote: I installed CI 4.2 on web hosting server and did following changes:

1. app/config/app.php -> public $baseURL = 'http://myurl.com/ci4/public/'
2. myurl.com/ci4/env to .env renamed
3. in .env file uncomment and set its value -> CI_ENVIRONMENT  = development
4. in .env file change app.baseURL value -> 'http://myurl.com/ci4/public/'

still doesnt show up, thanks

My suggestions are as follows:

(1) Install CI4 using composer
(2) Move ".htaccess" and "index.php" files from ci4->public folder to the ci4 root folder.
(3) edit index.php file and change line 20 from [require FCPATH . '../app/Config/Paths.php';] to [require FCPATH . '/app/Config/Paths.php';].
(4) rename "env" file to ".env" file
(5) edit .env file change
    - [CI_ENVIRONMENT = production] to [CI_ENVIRONMENT = development]
    - [app.baseURL = ' '] to [app.baseURL = 'http://<hostname>/ci4/' (enter you host name).

(6) To run your instance enter the URL: http://<hostname>/ci4. (no need to enter 'public" folder name in the url.

Thats it.


RE: CI 4.2 Debug Toolbar not working - kenjis - 06-13-2022

(06-13-2022, 06:54 AM)murugappan Wrote: (2) Move ".htaccess" and "index.php" files from ci4->public folder to the ci4 root folder.

There are so many places that suggest like that, but it is definitely wrong way.
Because index.php was moved to public/ intentionally for security reasons.

The right and easy way is to set your Document Root to the public/ folder.

If your hosting service does not provide a way to change the Document Root, you have to use
the wrong way. But I recommend you use another hosting services that can do it.


RE: CI 4.2 Debug Toolbar not working - univerbau - 06-14-2022

(06-13-2022, 05:39 PM)kenjis Wrote:
(06-13-2022, 06:54 AM)murugappan Wrote: (2) Move ".htaccess" and "index.php" files from ci4->public folder to the ci4 root folder.

There are so many places that suggest like that, but it is definitely wrong way.
Because index.php was moved to public/ intentionally for security reasons.

The right and easy way is to set your Document Root to the public/ folder.

If your hosting service does not provide a way to change the Document Root, you have to use
the wrong way. But I recommend you use another hosting services that can do it.

ok, looks like this was a problem, thanks alot guys Wink