Dashboard

Components

The main dahsboard generates a thumbnail link for each row entry in the database.

It also contains a link to the login page (which can be removed if you are not using the backend).

../_images/frontend.png

Main Code

The main code block for generating the map links is below:

<?PHP foreach($rows as $row) { ?>
          <?PHP
              $image = file_exists("assets/maps/{$row['id']}.png") ? "assets/maps/{$row['id']}.png" : "assets/maps/default.png";
          ?>
          <a href="map.php?id=<?=$row['id']?>" style="text-decoration:none; color: #6c757d!important; font-size: 1.25rem; font-weight: 300;">
              <div class="col">
                  <img src="<?=$image?>" height="225" width="100%">

                  <div class="card-body">
                      <p class="card-text text-center"><?=$row['name']?></p>
                  </div>
              </div>
          </a>
      <?PHP } ?>