The Dashboards.PHP viewer is created on the server with the PHP SDK, which emits the JavaScript viewer into the page. A dashboard is just a report loaded from a .mrt file.

Create the viewer, load the dashboard.
$viewer = new StiViewer();
$viewer->javascript->relativePath = '../';
$viewer->process();

$report = new StiReport();
$report->loadFile('../reports/Christmas.mrt');
$viewer->report = $report;

$viewer->printHtml();

How it works. PHP configures and wires the viewer, but the dashboard renders client-side, so the same page both serves the viewer and answers its requests.
In the screenshot below you can see the result of the sample code:

Showing a Dashboard in the Viewer

Hi. Need any help?