KoolReport's Forum

Official Support Area, Q&As, Discussions, Suggestions and Bug reports.
Forum's Guidelines

Instant package not working #136

Open Rohit opened this topic on on Oct 24, 2017 - 5 comments

Rohit commented on Oct 24, 2017

I downloaded the instant package and unzipped it in koolreport folder. I tried the very first example of the instant package and got this error.

<?php
    require_once APPPATH."/libraries/koolreport/autoload.php";
    use \koolreport\instant\Widget;
    use \koolreport\widgets\google\BarChart;
?>

<html>
    <head>
        <title>Instant BarChart</title>
    </head>
    <body>
    <?php
    Widget::create(BarChart::class,array(
        "data"=>array(
            array("name"=>"Peter","age"=>35),
            array("name"=>"Karl","age"=>32),
        )
    ));
    ?>
    </body>
</html>

KoolReport commented on Oct 24, 2017

I tried to test again and it seems working, please try this example:

<?php
//index.php
require_once "..\koolreport\autoload.php";
use \koolreport\instant\Widget;
use \koolreport\widgets\google\BarChart;


Widget::create(BarChart::class,array(
    "data"=>array(
        array("name"=>"Peter","age"=>32),
        array("name"=>"Karl","age"=>32),
    )
));
Rohit commented on Oct 24, 2017

Even this didn't work. Just an heads up, I'm using koolreports with codeigniter. So the above code was in Instanttest.php file Then I wrote this in a function()
include APPPATH."/reports/Instanttest.php"; and called that function

Rohit commented on Oct 24, 2017

Even tried the same code outside the codeigniter environment. Getting the same error

KoolReport commented on Oct 24, 2017

One question: Have you upgrade the KoolReport to 1.61.5? If you use Instant package with version 1.47.3 or lower you will have this issue.

Rohit commented on Oct 25, 2017

I was using a older version. Just upgraded and it worked. Thank you

Build Your Excellent Data Report

Let KoolReport help you to make great reports. It's free & open-source released under MIT license.

Download KoolReport View demo
help needed

Instant