Forum

Thread tagged as: Problem, Error, Installation

Trouble adding HTML widget to dashboard

Hi, I am having some weird trouble adding a widget to the dash. I followed the directions here and created a widget on my live server perch Runway install. It worked for a minute, and then when the site was refreshed the dash had disappeared. Now it looks like this:

ugh

I can still access settings to turn the dash off. If I remove the dashboard.php file from the app folder, the dash reappears also. Here's what I have in the folders (note I've mostly copied direct from the docs to minimize my mistakes and test)...

admin.php:

<?php
if ($CurrentUser->logged_in()) {
  $this->register_app('perch_dashboard', 'Dashboard', 1, 'Welcome', '1', false);
  $this->require_version('perch_dashboard', '2.0.8');
}
?>

dashboard.php

<div class="widget">
  <h2>
  <?php echo $Lang->get('Title of your widget'); ?>
  </h2>
  <div class="bd">
      <p>Your content goes here.</p>    
  </div>
</div>

This is definitely something dumb I'm doing, I'm sure of it. Can someone please point it out? :)

Lindsay Masten

Lindsay Masten 0 points

  • 5 years ago
Drew McLellan

Drew McLellan 2638 points
Perch Support

It looks like your getting an error. Have you checked the PHP error log?

Is $Lang defined?