Welcome Guest, Not a member yet? Register   Sign In
Debug Toolbar above of the head tag
#1

I've just try using CI 4 and working on development mode, but I found the debug toolbar script above of the head tag not inside the head:

Code:
<!-- DEBUG-VIEW START 1 APPPATH/Config/../Views/templates/header.php -->
<!doctype html>
<html>


<script type="text/javascript" id="debugbar_loader" data-time="1581796564" src="http://dapp.arnezt.web/?debugbar"></script><script type="text/javascript" id="debugbar_dynamic_script"></script><style type="text/css" id="debugbar_dynamic_style"></style>
<head>...</head>




The debug toolbar did not injected properly into the head block tag and blocked by browser.
vendor/codeigniter4/framework/system/Debug/Toolbar.php

PHP Code:
if (strpos($response->getBody(), '<head>') !== false)
{
    $response->setBody(
        str_replace('<head>'$script '<head>'$response->getBody())
    );
    return;


How to corrected this? Thank you.
Reply


Messages In This Thread
Debug Toolbar above of the head tag - by arnezthe - 02-15-2020, 01:31 PM



Theme © iAndrew 2016 - Forum software by © MyBB