Jump to content

VACentral pireps to export won't display when inside another div


Recommended Posts

Posted

So, new problem. I am part way through skinning a new admin dashboard and I am now trying to move some of the original dashboard content into separate divs for better displaying of data. So far it's not been too bad (with help from Vangelis and Web541!), but my new problem relates to the VACentral link regarding pireps to submit.

In the original dashboard, the code seems to be as follows:

<?php
if(Config::Get('VACENTRAL_ENABLED') == true && $unexported_count > 0)
{ ?>
<h3>vaCentral Status: </h3>
<p>You have <strong><?php echo $unexported_count?></strong> PIREPS waiting for export to vaCentral.
<a href="<?php echo adminurl('/vacentral/sendqueuedpireps'); ?>">Click here to send them</a> </p>
<?php
} ?>

I have moved that code into a div in my template which now looks like this:

   <div class="box box-primary">
		    <div class="box-header">
			  <i class="ion ion-clipboard"></i>
			  <h3 class="box-title">VA Central Status</h3>
		    </div><!-- /.box-header -->
		    <div class="box-body">
		    <span class="text">
				  <?php
  if(Config::Get('VACENTRAL_ENABLED') == true && $unexported_count > 0)
  { ?>
   You have <strong><?php echo $unexported_count?></strong> PIREPS waiting for export to vaCentral.
   <a href="<?php echo adminurl('/vacentral/sendqueuedpireps'); ?>">Click here to send them</a>
  <?php
  } ?></span>
		    </div>
		  </div>

When I upload the file and refresh it, the text and link to submit the pireps to VACentral never appears. I have tried it inside and outside of divs. I've tried it wrapped in <p> tags <span> tags and with no tags. I have the original dashboard file also loaded into the same page at the bottom and the text is appearing fine there.

Does anyone know if there is code I am missing that is needed to run this or is it dependent on some jquery or something that might not be present? I don't think it is missing code or js but I don't know what else it can be.

Thanks in advance.

Posted

Weirdly enough, this works fine for me without your custom css.

Check to see if your css for the divs doesn't have

display:none;

in any of them

Not as far as I can see, no. It's wierd because it seems like it is just refusing to show the anything inside the php tags like something is stopping it from processing the html within the php tags. I have tried entering some basic text inside <p> tags and it shows up just fine. It's definitely something to do with the element in question not liking php content. Just not sure how to solve it at the moment.

Posted

Are there actually any pireps to export?

&& $unexported_count > 0

Haha, gimme some credit. Yes there is one pirep to be submitted. The original dashboard is still loading at the bottom of my edited page so i can see all the normal items i.e. users online/guests online/1 pirep to be submitted. It's just that the php tags don't seem to be processed on page elements.

When I use "inspect element" in chrome, where the php code and resulting output should be, it's just a blank space with the html coding around it.

Posted

Is there any change that we can see some part of the coding ?

Of course. As I don't know what is causing the issue, I might as well past the entire page content. The section in question is enclosed within comment tags like so <!-- ********************** -->.

I'll also include the head and footer references to css/js files, just in case you spot something there I am missing.

Thanks guys.

<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>phpVMS Admin Panel</title>
<meta http-equiv="Content-Type" content="text/html; charset=<?php echo Config::Get('PAGE_ENCODING');?>">
<link rel="alternate" href="<?php echo SITE_URL?>/lib/rss/latestpireps.rss" title="latest pilot reports" type="application/rss+xml" />
<link rel="alternate" href="<?php echo SITE_URL?>/lib/rss/latestpilots.rss" title="latest pilot registrations" type="application/rss+xml" />
<?php
Template::Show('core_htmlhead.php');
?>
<!--[if IE]>
<style type="text/css">
#sidebar1 { padding-top: 30px; }
#mainContent { zoom: 1; padding-top: 15px; }
</style>
<![endif]-->
</head>
<body class="skin-blue sidebar-mini wysihtml5-supported">
<?php
Template::Show('core_htmlreq.php');
?>
<div class="wrapper">
 <header class="main-header">
 <!-- Logo -->
 <a href="index2.html" class="logo">
	 <!-- mini logo for sidebar mini 50x50 pixels -->
	 <span class="logo-mini"><b>A</b>LT</span>
	 <!-- logo for regular state and mobile devices -->
	 <span class="logo-lg"><b>Global Air</b>Alliance</span>
 </a>
 <!-- Header Navbar: style can be found in header.less -->
 <nav class="navbar navbar-static-top" role="navigation">
	 <!-- Sidebar toggle button-->
	 <a href="#" class="sidebar-toggle" data-toggle="offcanvas" role="button">
	 <span class="sr-only">Toggle navigation</span>
	 </a>
	 <div class="navbar-custom-menu">
	 <ul class="nav navbar-nav">
	 <li class="dropdown user user-menu">
		 <a href="#" class="dropdown-toggle" aria-expanded="false">
			 <span class="hidden-xs">ADMINISTRATION CENTRE</span>
		 </a>
</li>
	 </ul>
	 </div>
 </nav>
 </header>
 <!-- Left side column. contains the logo and sidebar -->
 <?php
Template::Show('core_navigation.php');
?>

 <!-- Content Wrapper. Contains page content -->
 <div class="content-wrapper">
 <!-- Content Header (Page header) -->
 <section class="content-header">
	 <h1>
	 Dashboard
	 <small>Control panel</small>
	 </h1>
	 <ol class="breadcrumb">
	 <li><a href="#"><i class="fa fa-dashboard"></i> Home</a></li>
	 <li class="active">Dashboard</li>
	 </ol>
 </section>
 <!-- Main content -->
 <section class="content">
	 <!-- Small boxes (Stat box) -->
	 <div class="row">
	 <div class="col-lg-2 col-xs-3">
		 <!-- small box -->
		 <div class="small-box bg-aqua">
		 <div class="inner">
			 <h3><?php echo StatsData::TotalFlightsToday();?></h3>
			 <p>Flights Today</p>
		 </div>
		 <div class="icon">
			 <i class="ion ion-bag"></i>
		 </div>
		 </div>
	 </div><!-- ./col -->
	 <div class="col-lg-2 col-xs-3">
		 <!-- small box -->
		 <div class="small-box bg-green">
		 <div class="inner">
			 <h3><?php echo StatsData::TotalFlights(); ?></h3>
			 <p>Total Flights</p>
		 </div>
		 <div class="icon">
			 <i class="ion ion-stats-bars"></i>
		 </div>
		 </div>
	 </div><!-- ./col -->
	 <div class="col-lg-2 col-xs-3">
		 <!-- small box -->
		 <div class="small-box bg-yellow">
		 <div class="inner">
			 <h3><?php echo StatsData::TotalHours(); ?></h3>
			 <p>Total Hours Flown</p>
		 </div>
		 <div class="icon">
			 <i class="ion ion-person-add"></i>
		 </div>
		 </div>
	 </div><!-- ./col -->
	 <div class="col-lg-2 col-xs-3">
		 <!-- small box -->
		 <div class="small-box bg-red">
		 <div class="inner">
			 <h3><?php echo StatsData::TotalMilesFlown(); ?></h3>
			 <p>Total Miles Flown</p>
		 </div>
		 <div class="icon">
			 <i class="ion ion-pie-graph"></i>
		 </div>
		 </div>
	 </div><!-- ./col -->
	 <div class="col-lg-2 col-xs-3">
		 <!-- small box -->
		 <div class="small-box bg-blue">
		 <div class="inner">
			 <h3><?php echo StatsData::TotalSchedules(); ?></h3>
			 <p>Number of Routes</p>
		 </div>
		 <div class="icon">
			 <i class="ion ion-pie-graph"></i>
		 </div>
		 </div>
	 </div><!-- ./col -->
	 <div class="col-lg-2 col-xs-3">
		 <!-- small box -->
		 <div class="small-box bg-green">
		 <div class="inner">
			 <h3><?php echo StatsData::PilotCount(); ?></h3>
			 <p>Number of Pilots</p>
		 </div>
		 <div class="icon">
			 <i class="ion ion-pie-graph"></i>
		 </div>
		 </div>
	 </div><!-- ./col -->
	 </div><!-- /.row -->

	 <!-- Main row -->
	 <div class="row">
	 <!-- Left col -->
	 <section class="col-lg-7 connectedSortable">
		 <div class="box box-default">
		 <div class="box-header with-border">
			 <i class="fa fa-bullhorn"></i>

			 <h3 class="box-title">Last 30 days pireps</h3>
		 </div>
		 <!-- /.box-header -->
			 <div id="myfirstchart" style="height: 250px;"></div>
		 <!-- /.box-body -->
		 </div>

		 <div class="row">
		 <!-- Users & Guests box -->
		 <div class="col-lg-2 col-xs-3">
		 <!-- small box -->
		 <div class="small-box bg-yellow">
		 <div class="inner">
			 <h3><?php echo count(StatsData::UsersOnline()); ?></h3>
			 <p>Users Online:</p>
		 </div>
		 <div class="icon">
			 <i class="ion ion-person-add"></i>
		 </div>
		 </div>
	 </div><!-- ./col -->
<div class="col-lg-2 col-xs-3">
		 <!-- small box -->
		 <div class="small-box bg-green">
		 <div class="inner">
			 <h3><?php echo count(StatsData::GuestsOnline()); ?></h3>
			 <p>Guests Online:</p>
		 </div>
		 <div class="icon">
			 <i class="ion ion-stats-bars"></i>
		 </div>
		 </div>
	 </div><!-- ./col -->
	 </div>

<!-- ********************* This is the relevant php error section *************************** -->
		 <!-- TO DO List -->
		 <div class="box box-primary">
		 <div class="box-header">
			 <i class="ion ion-clipboard"></i>
			 <h3 class="box-title">VA Central Status</h3>
		 </div><!-- /.box-header -->
		 <div class="box-body">
		 <p class="lead">
		 This is tester text
 <?php
				 echo $updateinfo;
				 ?>
				 <?php
 if(Config::Get('VACENTRAL_ENABLED') == true && $unexported_count > 0)
 { ?>
 You have <strong><?php echo $unexported_count?></strong> PIREPS waiting for export to vaCentral.
 <a href="<?php echo adminurl('/vacentral/sendqueuedpireps'); ?>">Click here to send them</a>
 <?php
 } ?></p>
		 </div>
		 </div><!-- /.box -->
<!-- ************************************************************************************************** -->

		 <!-- quick email widget -->
		 <div class="box box-info">
		 <div class="box-header">
			 <i class="fa fa-envelope"></i>
			 <h3 class="box-title">Quick Email</h3>
			 <!-- tools box -->
			 <div class="pull-right box-tools">
			 <button class="btn btn-info btn-sm" data-widget="remove" data-toggle="tooltip" title="Remove"><i class="fa fa-times"></i></button>
			 </div><!-- /. tools -->
		 </div>
		 <div class="box-body">
			 <form action="#" method="post">
			 <div class="form-group">
				 <input type="email" class="form-control" name="emailto" placeholder="Email to:">
			 </div>
			 <div class="form-group">
				 <input type="text" class="form-control" name="subject" placeholder="Subject">
			 </div>
			 <div>
				 <textarea class="textarea" placeholder="Message" style="width: 100%; height: 125px; font-size: 14px; line-height: 18px; border: 1px solid #dddddd; padding: 10px;"></textarea>
			 </div>
			 </form>
		 </div>
		 <div class="box-footer clearfix">
			 <button class="pull-right btn btn-default" id="sendEmail">Send <i class="fa fa-arrow-circle-right"></i></button>
		 </div>
		 </div>
	 </section><!-- /.Left col -->
	 <!-- right col (We are only adding the ID to make the widgets sortable)-->
	 <section class="col-lg-5 connectedSortable">
		 <!-- Map box -->
		 <div class="box box-solid bg-light-blue-gradient">
		 <div class="box-header">
			 <!-- tools box -->
			 <div class="pull-right box-tools">
			 <button class="btn btn-primary btn-sm daterange pull-right" data-toggle="tooltip" title="Date range"><i class="fa fa-calendar"></i></button>
			 <button class="btn btn-primary btn-sm pull-right" data-widget="collapse" data-toggle="tooltip" title="Collapse" style="margin-right: 5px;"><i class="fa fa-minus"></i></button>
			 </div><!-- /. tools -->
			 <i class="fa fa-map-marker"></i>
			 <h3 class="box-title">
			 Latest News
			 </h3>
		 </div>

		 <div class="box-body">
		 </div><!-- /.box-body-->


		 <div class="box-footer no-border">
			 <div class="row">
			 <div class="col-xs-4 text-center" style="border-right: 1px solid #f4f4f4">
				 <div id="sparkline-1"></div>
				 <div class="knob-label">Visitors</div>
			 </div><!-- ./col -->
			 <div class="col-xs-4 text-center" style="border-right: 1px solid #f4f4f4">
				 <div id="sparkline-2"></div>
				 <div class="knob-label">Online</div>
			 </div><!-- ./col -->
			 <div class="col-xs-4 text-center">
				 <div id="sparkline-3"></div>
				 <div class="knob-label">Exists</div>
			 </div><!-- ./col -->
			 </div><!-- /.row -->
		 </div>
		 </div>
		 <!-- /.box -->
		 <!-- solid sales graph -->
		 <div class="box box-solid bg-teal-gradient">
		 <div class="box-header">
			 <i class="fa fa-th"></i>
			 <h3 class="box-title">Sales Graph</h3>
			 <div class="box-tools pull-right">
			 <button class="btn bg-teal btn-sm" data-widget="collapse"><i class="fa fa-minus"></i></button>
			 <button class="btn bg-teal btn-sm" data-widget="remove"><i class="fa fa-times"></i></button>
			 </div>
		 </div>
		 <div class="box-body border-radius-none">
			 <div class="chart" id="line-chart" style="height: 250px;"></div>
		 </div><!-- /.box-body -->
		 <div class="box-footer no-border">
			 <div class="row">
			 <div class="col-xs-4 text-center" style="border-right: 1px solid #f4f4f4">
				 <input type="text" class="knob" data-readonly="true" value="20" data-width="60" data-height="60" data-fgColor="#39CCCC">
				 <div class="knob-label">Mail-Orders</div>
			 </div><!-- ./col -->
			 <div class="col-xs-4 text-center" style="border-right: 1px solid #f4f4f4">
				 <input type="text" class="knob" data-readonly="true" value="50" data-width="60" data-height="60" data-fgColor="#39CCCC">
				 <div class="knob-label">Online</div>
			 </div><!-- ./col -->
			 <div class="col-xs-4 text-center">
				 <input type="text" class="knob" data-readonly="true" value="30" data-width="60" data-height="60" data-fgColor="#39CCCC">
				 <div class="knob-label">In-Store</div>
			 </div><!-- ./col -->
			 </div><!-- /.row -->
		 </div><!-- /.box-footer -->
		 </div><!-- /.box -->
		 <!-- Calendar -->
		 <div class="box box-solid bg-green-gradient">
		 <div class="box-header">
			 <i class="fa fa-calendar"></i>
			 <h3 class="box-title">Calendar</h3>
			 <!-- tools box -->
			 <div class="pull-right box-tools">
			 <!-- button with a dropdown -->
			 <div class="btn-group">
				 <button class="btn btn-success btn-sm dropdown-toggle" data-toggle="dropdown"><i class="fa fa-bars"></i></button>
				 <ul class="dropdown-menu pull-right" role="menu">
				 <li><a href="#">Add new event</a></li>
				 <li><a href="#">Clear events</a></li>
				 <li class="divider"></li>
				 <li><a href="#">View calendar</a></li>
				 </ul>
			 </div>
			 <button class="btn btn-success btn-sm" data-widget="collapse"><i class="fa fa-minus"></i></button>
			 <button class="btn btn-success btn-sm" data-widget="remove"><i class="fa fa-times"></i></button>
			 </div><!-- /. tools -->
		 </div><!-- /.box-header -->
		 <div class="box-body no-padding">
			 <!--The calendar -->
			 <div id="calendar" style="width: 100%"></div>
		 </div><!-- /.box-body -->
		 <div class="box-footer text-black">
			 <div class="row">
			 <div class="col-sm-6">
				 <!-- Progress bars -->
				 <div class="clearfix">
				 <span class="pull-left">Task #1</span>
				 <small class="pull-right">90%</small>
				 </div>
				 <div class="progress xs">
				 <div class="progress-bar progress-bar-green" style="width: 90%;"></div>
				 </div>
				 <div class="clearfix">
				 <span class="pull-left">Task #2</span>
				 <small class="pull-right">70%</small>
				 </div>
				 <div class="progress xs">
				 <div class="progress-bar progress-bar-green" style="width: 70%;"></div>
				 </div>
			 </div><!-- /.col -->
			 <div class="col-sm-6">
				 <div class="clearfix">
				 <span class="pull-left">Task #3</span>
				 <small class="pull-right">60%</small>
				 </div>
				 <div class="progress xs">
				 <div class="progress-bar progress-bar-green" style="width: 60%;"></div>
				 </div>
				 <div class="clearfix">
				 <span class="pull-left">Task #4</span>
				 <small class="pull-right">40%</small>
				 </div>
				 <div class="progress xs">
				 <div class="progress-bar progress-bar-green" style="width: 40%;"></div>
				 </div>
			 </div><!-- /.col -->
			 </div><!-- /.row -->
		 </div>
		 </div><!-- /.box -->
	 </section><!-- right col -->
	 </div><!-- /.row (main row) -->
 </section><!-- /.content -->
 </div><!-- /.content-wrapper -->

 <!-- Control Sidebar -->
 <aside class="control-sidebar control-sidebar-dark">
 <!-- Create the tabs -->
 <ul class="nav nav-tabs nav-justified control-sidebar-tabs">
	 <li><a href="#control-sidebar-home-tab" data-toggle="tab"><i class="fa fa-home"></i></a></li>
	 <li><a href="#control-sidebar-settings-tab" data-toggle="tab"><i class="fa fa-gears"></i></a></li>
 </ul>
 <!-- Tab panes -->
 <div class="tab-content">
	 <!-- Home tab content -->
	 <div class="tab-pane" id="control-sidebar-home-tab">
	 <h3 class="control-sidebar-heading">Recent Activity</h3>
	 <ul class="control-sidebar-menu">
		 <li>
		 <a href="javascript::;">
			 <i class="menu-icon fa fa-birthday-cake bg-red"></i>
			 <div class="menu-info">
			 <h4 class="control-sidebar-subheading">Langdon's Birthday</h4>
			 <p>Will be 23 on April 24th</p>
			 </div>
		 </a>
		 </li>
		 <li>
		 <a href="javascript::;">
			 <i class="menu-icon fa fa-user bg-yellow"></i>
			 <div class="menu-info">
			 <h4 class="control-sidebar-subheading">Frodo Updated His Profile</h4>
			 <p>New phone +1(800)555-1234</p>
			 </div>
		 </a>
		 </li>
		 <li>
		 <a href="javascript::;">
			 <i class="menu-icon fa fa-envelope-o bg-light-blue"></i>
			 <div class="menu-info">
			 <h4 class="control-sidebar-subheading">Nora Joined Mailing List</h4>
			 <p>nora@example.com</p>
			 </div>
		 </a>
		 </li>
		 <li>
		 <a href="javascript::;">
			 <i class="menu-icon fa fa-file-code-o bg-green"></i>
			 <div class="menu-info">
			 <h4 class="control-sidebar-subheading">Cron Job 254 Executed</h4>
			 <p>Execution time 5 seconds</p>
			 </div>
		 </a>
		 </li>
	 </ul><!-- /.control-sidebar-menu -->
	 <h3 class="control-sidebar-heading">Tasks Progress</h3>
	 <ul class="control-sidebar-menu">
		 <li>
		 <a href="javascript::;">
			 <h4 class="control-sidebar-subheading">
			 Custom Template Design
			 <span class="label label-danger pull-right">70%</span>
			 </h4>
			 <div class="progress progress-xxs">
			 <div class="progress-bar progress-bar-danger" style="width: 70%"></div>
			 </div>
		 </a>
		 </li>
		 <li>
		 <a href="javascript::;">
			 <h4 class="control-sidebar-subheading">
			 Update Resume
			 <span class="label label-success pull-right">95%</span>
			 </h4>
			 <div class="progress progress-xxs">
			 <div class="progress-bar progress-bar-success" style="width: 95%"></div>
			 </div>
		 </a>
		 </li>
		 <li>
		 <a href="javascript::;">
			 <h4 class="control-sidebar-subheading">
			 Laravel Integration
			 <span class="label label-warning pull-right">50%</span>
			 </h4>
			 <div class="progress progress-xxs">
			 <div class="progress-bar progress-bar-warning" style="width: 50%"></div>
			 </div>
		 </a>
		 </li>
		 <li>
		 <a href="javascript::;">
			 <h4 class="control-sidebar-subheading">
			 Back End Framework
			 <span class="label label-primary pull-right">68%</span>
			 </h4>
			 <div class="progress progress-xxs">
			 <div class="progress-bar progress-bar-primary" style="width: 68%"></div>
			 </div>
		 </a>
		 </li>
	 </ul><!-- /.control-sidebar-menu -->
	 </div><!-- /.tab-pane -->
	 <!-- Stats tab content -->
	 <div class="tab-pane" id="control-sidebar-stats-tab">Stats Tab Content</div><!-- /.tab-pane -->
	 <!-- Settings tab content -->
	 <div class="tab-pane" id="control-sidebar-settings-tab">
	 <form method="post">
		 <h3 class="control-sidebar-heading">General Settings</h3>
		 <div class="form-group">
		 <label class="control-sidebar-subheading">
			 Report panel usage
			 <input type="checkbox" class="pull-right" checked>
		 </label>
		 <p>
			 Some information about this general settings option
		 </p>
		 </div><!-- /.form-group -->
		 <div class="form-group">
		 <label class="control-sidebar-subheading">
			 Allow mail redirect
			 <input type="checkbox" class="pull-right" checked>
		 </label>
		 <p>
			 Other sets of options are available
		 </p>
		 </div><!-- /.form-group -->
		 <div class="form-group">
		 <label class="control-sidebar-subheading">
			 Expose author name in posts
			 <input type="checkbox" class="pull-right" checked>
		 </label>
		 <p>
			 Allow the user to show his name in blog posts
		 </p>
		 </div><!-- /.form-group -->
		 <h3 class="control-sidebar-heading">Chat Settings</h3>
		 <div class="form-group">
		 <label class="control-sidebar-subheading">
			 Show me as online
			 <input type="checkbox" class="pull-right" checked>
		 </label>
		 </div><!-- /.form-group -->
		 <div class="form-group">
		 <label class="control-sidebar-subheading">
			 Turn off notifications
			 <input type="checkbox" class="pull-right">
		 </label>
		 </div><!-- /.form-group -->
		 <div class="form-group">
		 <label class="control-sidebar-subheading">
			 Delete chat history
			 <a href="javascript::;" class="text-red pull-right"><i class="fa fa-trash-o"></i></a>
		 </label>
		 </div><!-- /.form-group -->
	 </form>
	 </div><!-- /.tab-pane -->
 </div>
 </aside><!-- /.control-sidebar -->
 <!-- Add the sidebar's background. This div must be placed
	 immediately after the control sidebar -->
 <div class="control-sidebar-bg"></div>
</div><!-- ./wrapper -->
</body>
</html>

This is core_htmlhead

<?php if(!defined('IN_PHPVMS') && IN_PHPVMS !== true) { die(); } ?>
<script type="text/javascript">
var baseurl="<?php echo SITE_URL;?>";
var geourl="<?php echo Config::Get('GEONAME_API_SERVER'); ?>";
var airport_lookup = "<?php echo Config::Get('AIRPORT_LOOKUP_SERVER'); ?>";
var phpvms_api_server = "<?php echo Config::Get('PHPVMS_API_SERVER'); ?>";
</script>
<!-- Global Air Admin SKin Files -->
<!-- Tell the browser to be responsive to screen width -->
<meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport">

<!-- Latest compiled and minified bootstrap CSS -->
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap.min.css" integrity="sha512-dTfge/zgoMYpP7QbHy4gWMEGsbsdZeCXz7irItjcC3sPUFtf0kuFbDz/ixG7ArTxmDjLXDmezHubeNikyKGVyQ==" crossorigin="anonymous">
<!-- Font Awesome -->
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.4.0/css/font-awesome.min.css">
<!-- Ionicons -->
<link rel="stylesheet" href="https://code.ionicframework.com/ionicons/2.0.1/css/ionicons.min.css">
<!-- Theme style -->
<link href="<?php echo SITE_URL?>/admin/lib/layout/dist/css/AdminLTE.min.css" rel="stylesheet" type="text/css" />
<!-- AdminLTE Skins. Choose a skin from the css/skins folder instead of downloading all of them to reduce the load. -->
<link href="<?php echo SITE_URL?>/admin/lib/layout/dist/css/skins/_all-skins.min.css" rel="stylesheet" type="text/css" >
<!-- iCheck -->
<link rel="stylesheet" href="<?php echo SITE_URL?>/admin/lib/layout/plugins/iCheck/flat/blue.css">
<!-- Morris chart -->
<link rel="stylesheet" href="<?php echo SITE_URL?>/admin/lib/layout/plugins/morris/morris.css">
<!-- jvectormap -->
<link rel="stylesheet" href="<?php echo SITE_URL?>/admin/lib/layout/plugins/jvectormap/jquery-jvectormap-1.2.2.css">
<!-- Date Picker -->
<link rel="stylesheet" href="<?php echo SITE_URL?>/admin/lib/layout/plugins/datepicker/datepicker3.css">
<!-- Daterange picker -->
<link rel="stylesheet" href="<?php echo SITE_URL?>/admin/lib/layout/plugins/daterangepicker/daterangepicker-bs3.css">
<!-- bootstrap wysihtml5 - text editor -->
<link rel="stylesheet" href="<?php echo SITE_URL?>/admin/lib/layout/plugins/bootstrap-wysihtml5/bootstrap3-wysihtml5.min.css">
<!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries -->
<!-- WARNING: Respond.js doesn't work if you view the page via file:// -->
<!--[if lt IE 9]>
 <script src="https://oss.maxcdn.com/html5shiv/3.7.3/html5shiv.min.js"></script>
 <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
<![endif]-->
<!-- End of global admin files -->

<script type="text/javascript" src="<?php echo fileurl('lib/js/jqModal.js'); ?>"></script>
<script type="text/javascript" src="<?php echo fileurl('lib/js/jquery.form.js'); ?>"></script>
<script type="text/javascript" src="<?php echo fileurl('lib/js/jquery.bigiframe.js'); ?>"></script>
<script type="text/javascript" src="<?php echo fileurl('lib/js/jquery.metadata.js'); ?>"></script>
<script type="text/javascript" src="<?php echo fileurl('lib/js/ckeditor/ckeditor.js'); ?>"></script>
<script type="text/javascript" src="http://maps.google.com/maps/api/js?sensor=true"></script>
<script type="text/javascript" src="<?php echo SITE_URL?>/admin/lib/phpvmsadmin.js"></script>
<link rel="alternate" type="application/rss+xml" title="RSS" href="<?php echo SITE_URL?>/lib/rss/latestpireps.rss">
<?php
if(isset($MODULE_HEAD_INC))
echo $MODULE_HEAD_INC;
?>

This is the footer js references

</div>
</div>
<div style="clear:both"></div>
<footer class="main-footer">
 <div class="pull-right hidden-xs">
	 <p>
		 "<?php echo randquote(); ?>"
		 <br />
		 Copyright © 2007 - <?php echo date('Y')?>
		 <a href="http://www.phpvms.net/" target="_new">phpVMS</a>,
		 <a href="http://www.nsslive.net" target="_new">nsslive.net</a>
		 <br />
		 <a href="<?php echo SITE_URL?>/admin/index.php/dashboard/about">License & About</a> |
		 Version <?php echo PHPVMS_VERSION; ?>
	 </p>
 </div>
 <strong>Template by <a href="http://almsaeedstudio.com">Almsaeed Studio</a> © 2014-2015, All rights reserved.
</footer>
</div>
<?php
Template::Show('core_footer.php');
?>
<!-- Global Air Script Files -->
<!-- jQuery 2.1.4 -->
<script src="<?php echo fileurl('admin/lib/layout/plugins/jQuery/jQuery-2.1.4.min.js'); ?>"></script>
<!-- jQuery UI 1.11.4 -->
<script src="https://code.jquery.com/ui/1.11.4/jquery-ui.min.js"></script>
<!-- Resolve conflict in jQuery UI tooltip with Bootstrap tooltip -->
<script>
 $.widget.bridge('uibutton', $.ui.button);
</script>
<!-- Latest compiled and minified Javascript -->
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/js/bootstrap.min.js" integrity="sha512-K1qjQ+NcF2TYO/eI3M6v8EiNYZfA95pQumfvcVrTHtwQVDG+aHRqLi/ETn2uB+1JqwYqVG3LIvdm9lj6imS/pQ==" crossorigin="anonymous"></script>
<!-- Morris.js charts -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/raphael/2.1.0/raphael-min.js"></script>
<script src="<?php echo fileurl('admin/lib/layout/plugins/morris/morris.min.js'); ?>"></script>
<!-- Sparkline -->
<script src="<?php echo fileurl('admin/lib/layout/plugins/sparkline/jquery.sparkline.min.js'); ?>"></script>
<!-- jvectormap -->
<script src="<?php echo fileurl('admin/lib/layout/plugins/jvectormap/jquery-jvectormap-1.2.2.min.js'); ?>"></script>
<script src="<?php echo fileurl('admin/lib/layout/plugins/jvectormap/jquery-jvectormap-world-mill-en.js'); ?>"></script>
<!-- jQuery Knob Chart -->
<script src="<?php echo fileurl('admin/lib/layout/plugins/knob/jquery.knob.js'); ?>"></script>
<!-- daterangepicker -->
<script src="https://cdnjs.cloudflare.com/ajax/libs/moment.js/2.10.2/moment.min.js"></script>
<script src="<?php echo fileurl('admin/lib/layout/plugins/daterangepicker/daterangepicker.js'); ?>"></script>
<!-- datepicker -->
<script src="<?php echo fileurl('admin/lib/layout/plugins/datepicker/bootstrap-datepicker.js'); ?>"></script>
<!-- Bootstrap WYSIHTML5 -->
<script src="<?php echo fileurl('admin/lib/layout/plugins/bootstrap-wysihtml5/bootstrap3-wysihtml5.all.min.js'); ?>"></script>
<!-- Slimscroll -->
<script src="<?php echo fileurl('admin/lib/layout/plugins/slimScroll/jquery.slimscroll.min.js'); ?>"></script>
<!-- FastClick -->
<script src="<?php echo fileurl('admin/lib/layout/plugins/fastclick/fastclick.min.js'); ?>"></script>
<!-- AdminLTE App -->
<script src="<?php echo fileurl('admin/lib/layout/dist/js/app.min.js'); ?>"></script>
<script type="text/javascript">
var json = (function () {
 var json = null;
 $.ajax({
 'async': false,
 'global': false,
 'url': "<?php echo adminaction('/dashboard/getpireps');?>",
 'dataType': "json",
 'success': function (data) {
	 json = data;
 }
 });
 return json;
})
();

new Morris.Area({
// ID of the element in which to draw the chart.
element: 'myfirstchart',
// Chart data records -- each entry in this array corresponds to a point on
// the chart.
data: json,
// The name of the data record attribute that contains x-values.
xkey: 'ym',
// A list of names of data record attributes that contain y-values.
ykeys: ['total'],
// Labels for the ykeys -- will be displayed when you hover over the
// chart.
labels: ['Flights']
});
</script>
</body>
</html>

Posted

I may have found a solution to your problem,

I have a feeling that it is not that the vaCentral Status wouldn't show up in the div, it's because I'm assuming the first block of code you have used was all put into the header.php file.

What I did was separate the code into their own files and found out that because you had tried to put that status in your header file, it wasn't loading properly, but if you put it in your admin/templates/dashboard.php file (or the skin folder if you did this http://forum.phpvms....in-skin-solved/ ) it seems to work

admin/lib/layout/header.php

<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>phpVMS Admin Panel</title>
<meta http-equiv="Content-Type" content="text/html; charset=<?php echo Config::Get('PAGE_ENCODING');?>">
<link rel="alternate" href="<?php echo SITE_URL?>/lib/rss/latestpireps.rss" title="latest pilot reports" type="application/rss+xml" />
<link rel="alternate" href="<?php echo SITE_URL?>/lib/rss/latestpilots.rss" title="latest pilot registrations" type="application/rss+xml" />
<?php
Template::Show('core_htmlhead.php');
?>
<!--[if IE]>
<style type="text/css">
#sidebar1 { padding-top: 30px; }
#mainContent { zoom: 1; padding-top: 15px; }
</style>
<![endif]-->
</head>
<body class="skin-blue sidebar-mini wysihtml5-supported">
<?php
Template::Show('core_htmlreq.php');
?>
<div class="wrapper">
	 <header class="main-header">
	 <!-- Logo -->
	 <a href="index2.html" class="logo">
			 <!-- mini logo for sidebar mini 50x50 pixels -->
			 <span class="logo-mini"><b>A</b>LT</span>
			 <!-- logo for regular state and mobile devices -->
			 <span class="logo-lg"><b>Global Air</b>Alliance</span>
	 </a>
	 <!-- Header Navbar: style can be found in header.less -->
	 <nav class="navbar navbar-static-top" role="navigation">
			 <!-- Sidebar toggle button-->
			 <a href="#" class="sidebar-toggle" data-toggle="offcanvas" role="button">
			 <span class="sr-only">Toggle navigation</span>
			 </a>
			 <div class="navbar-custom-menu">
			 <ul class="nav navbar-nav">
			 <li class="dropdown user user-menu">
					 <a href="#" class="dropdown-toggle" aria-expanded="false">
							 <span class="hidden-xs">ADMINISTRATION CENTRE</span>
					 </a>
</li>
			 </ul>
			 </div>
	 </nav>
	 </header>
	 <!-- Left side column. contains the logo and sidebar -->
	 <div class="col-md-2">
<?php
Template::Show('core_sidebar.php');
?>
	 <?php
Template::Show('core_navigation.php');
?>
</div>
</body>
</html>

admin/templates/dashboard.php

<div class="col-md-10">
 <!-- Content Header (Page header) -->
	 <section class="content-header">
			 <h1>
			 Dashboard
			 <small>Control panel</small>
			 </h1>
			 <ol class="breadcrumb">
			 <li><a href="#"><i class="fa fa-dashboard"></i> Home</a></li>
			 <li class="active">Dashboard</li>
			 </ol>
	 </section>
	 <!-- Main content -->
	 <section class="content">
			 <!-- Small boxes (Stat box) -->
			 <div class="row">
			 <div class="col-lg-2 col-xs-3">
					 <!-- small box -->
					 <div class="small-box bg-aqua">
					 <div class="inner">
							 <h3><?php echo StatsData::TotalFlightsToday();?></h3>
							 <p>Flights Today</p>
					 </div>
					 <div class="icon">
							 <i class="ion ion-bag"></i>
					 </div>
					 </div>
			 </div><!-- ./col -->
			 <div class="col-lg-2 col-xs-3">
					 <!-- small box -->
					 <div class="small-box bg-green">
					 <div class="inner">
							 <h3><?php echo StatsData::TotalFlights(); ?></h3>
							 <p>Total Flights</p>
					 </div>
					 <div class="icon">
							 <i class="ion ion-stats-bars"></i>
					 </div>
					 </div>
			 </div><!-- ./col -->
			 <div class="col-lg-2 col-xs-3">
					 <!-- small box -->
					 <div class="small-box bg-yellow">
					 <div class="inner">
							 <h3><?php echo StatsData::TotalHours(); ?></h3>
							 <p>Total Hours Flown</p>
					 </div>
					 <div class="icon">
							 <i class="ion ion-person-add"></i>
					 </div>
					 </div>
			 </div><!-- ./col -->
			 <div class="col-lg-2 col-xs-3">
					 <!-- small box -->
					 <div class="small-box bg-red">
					 <div class="inner">
							 <h3><?php echo StatsData::TotalMilesFlown(); ?></h3>
							 <p>Total Miles Flown</p>
					 </div>
					 <div class="icon">
							 <i class="ion ion-pie-graph"></i>
					 </div>
					 </div>
			 </div><!-- ./col -->
			 <div class="col-lg-2 col-xs-3">
					 <!-- small box -->
					 <div class="small-box bg-blue">
					 <div class="inner">
							 <h3><?php echo StatsData::TotalSchedules(); ?></h3>
							 <p>Number of Routes</p>
					 </div>
					 <div class="icon">
							 <i class="ion ion-pie-graph"></i>
					 </div>
					 </div>
			 </div><!-- ./col -->
			 <div class="col-lg-2 col-xs-3">
					 <!-- small box -->
					 <div class="small-box bg-green">
					 <div class="inner">
							 <h3><?php echo StatsData::PilotCount(); ?></h3>
							 <p>Number of Pilots</p>
					 </div>
					 <div class="icon">
							 <i class="ion ion-pie-graph"></i>
					 </div>
					 </div>
			 </div><!-- ./col -->
			 </div><!-- /.row -->

			 <!-- Main row -->
			 <div class="row">
			 <!-- Left col -->
			 <section class="col-lg-7 connectedSortable">
					 <div class="box box-default">
					 <div class="box-header with-border">
							 <i class="fa fa-bullhorn"></i>
							 <h3 class="box-title">Last 30 days pireps</h3>
					 </div>
					 <!-- /.box-header -->
							 <div id="myfirstchart" style="height: 250px;"></div>
					 <!-- /.box-body -->
					 </div>
					 <div class="row">
					 <!-- Users & Guests box -->
					 <div class="col-lg-2 col-xs-3">
					 <!-- small box -->
					 <div class="small-box bg-yellow">
					 <div class="inner">
							 <h3><?php echo count(StatsData::UsersOnline()); ?></h3>
							 <p>Users Online:</p>
					 </div>
					 <div class="icon">
							 <i class="ion ion-person-add"></i>
					 </div>
					 </div>
			 </div><!-- ./col -->
<div class="col-lg-2 col-xs-3">
					 <!-- small box -->
					 <div class="small-box bg-green">
					 <div class="inner">
							 <h3><?php echo count(StatsData::GuestsOnline()); ?></h3>
							 <p>Guests Online:</p>
					 </div>
					 <div class="icon">
							 <i class="ion ion-stats-bars"></i>
					 </div>
					 </div>
			 </div><!-- ./col -->
			 </div>
<!-- ********************* This is the relevant php error section *************************** -->
					 <!-- TO DO List -->
					 <div class="box box-primary">
					 <div class="box-header">
							 <i class="ion ion-clipboard"></i>
							 <h3 class="box-title">VA Central Status</h3>
					 </div><!-- /.box-header -->
					 <div class="box-body">
					 <p class="lead">
					 This is tester text
	 <?php
									 echo $updateinfo;
									 ?>
									 <?php
	 if(Config::Get('VACENTRAL_ENABLED') == true && $unexported_count > 0)
	 { ?>
	 You have <strong><?php echo $unexported_count?></strong> PIREPS waiting for export to vaCentral.
	 <a href="<?php echo adminurl('/vacentral/sendqueuedpireps'); ?>">Click here to send them</a>
	 <?php
	 } ?></p>
					 </div>
					 </div><!-- /.box -->
<!-- ************************************************************************************************** -->
					 <!-- quick email widget -->
					 <div class="box box-info">
					 <div class="box-header">
							 <i class="fa fa-envelope"></i>
							 <h3 class="box-title">Quick Email</h3>
							 <!-- tools box -->
							 <div class="pull-right box-tools">
							 <button class="btn btn-info btn-sm" data-widget="remove" data-toggle="tooltip" title="Remove"><i class="fa fa-times"></i></button>
							 </div><!-- /. tools -->
					 </div>
					 <div class="box-body">
							 <form action="#" method="post">
							 <div class="form-group">
									 <input type="email" class="form-control" name="emailto" placeholder="Email to:">
							 </div>
							 <div class="form-group">
									 <input type="text" class="form-control" name="subject" placeholder="Subject">
							 </div>
							 <div>
									 <textarea class="textarea" placeholder="Message" style="width: 100%; height: 125px; font-size: 14px; line-height: 18px; border: 1px solid #dddddd; padding: 10px;"></textarea>
							 </div>
							 </form>
					 </div>
					 <div class="box-footer clearfix">
							 <button class="pull-right btn btn-default" id="sendEmail">Send <i class="fa fa-arrow-circle-right"></i></button>
					 </div>
					 </div>
			 </section><!-- /.Left col -->
			 <!-- right col (We are only adding the ID to make the widgets sortable)-->
			 <section class="col-lg-5 connectedSortable">
					 <!-- Map box -->
					 <div class="box box-solid bg-light-blue-gradient">
					 <div class="box-header">
							 <!-- tools box -->
							 <div class="pull-right box-tools">
							 <button class="btn btn-primary btn-sm daterange pull-right" data-toggle="tooltip" title="Date range"><i class="fa fa-calendar"></i></button>
							 <button class="btn btn-primary btn-sm pull-right" data-widget="collapse" data-toggle="tooltip" title="Collapse" style="margin-right: 5px;"><i class="fa fa-minus"></i></button>
							 </div><!-- /. tools -->
							 <i class="fa fa-map-marker"></i>
							 <h3 class="box-title">
							 Latest News
							 </h3>
					 </div>

					 <div class="box-body">
					 </div><!-- /.box-body-->


					 <div class="box-footer no-border">
							 <div class="row">
							 <div class="col-xs-4 text-center" style="border-right: 1px solid #f4f4f4">
									 <div id="sparkline-1"></div>
									 <div class="knob-label">Visitors</div>
							 </div><!-- ./col -->
							 <div class="col-xs-4 text-center" style="border-right: 1px solid #f4f4f4">
									 <div id="sparkline-2"></div>
									 <div class="knob-label">Online</div>
							 </div><!-- ./col -->
							 <div class="col-xs-4 text-center">
									 <div id="sparkline-3"></div>
									 <div class="knob-label">Exists</div>
							 </div><!-- ./col -->
							 </div><!-- /.row -->
					 </div>
					 </div>
					 <!-- /.box -->
					 <!-- solid sales graph -->
					 <div class="box box-solid bg-teal-gradient">
					 <div class="box-header">
							 <i class="fa fa-th"></i>
							 <h3 class="box-title">Sales Graph</h3>
							 <div class="box-tools pull-right">
							 <button class="btn bg-teal btn-sm" data-widget="collapse"><i class="fa fa-minus"></i></button>
							 <button class="btn bg-teal btn-sm" data-widget="remove"><i class="fa fa-times"></i></button>
							 </div>
					 </div>
					 <div class="box-body border-radius-none">
							 <div class="chart" id="line-chart" style="height: 250px;"></div>
					 </div><!-- /.box-body -->
					 <div class="box-footer no-border">
							 <div class="row">
							 <div class="col-xs-4 text-center" style="border-right: 1px solid #f4f4f4">
									 <input type="text" class="knob" data-readonly="true" value="20" data-width="60" data-height="60" data-fgColor="#39CCCC">
									 <div class="knob-label">Mail-Orders</div>
							 </div><!-- ./col -->
							 <div class="col-xs-4 text-center" style="border-right: 1px solid #f4f4f4">
									 <input type="text" class="knob" data-readonly="true" value="50" data-width="60" data-height="60" data-fgColor="#39CCCC">
									 <div class="knob-label">Online</div>
							 </div><!-- ./col -->
							 <div class="col-xs-4 text-center">
									 <input type="text" class="knob" data-readonly="true" value="30" data-width="60" data-height="60" data-fgColor="#39CCCC">
									 <div class="knob-label">In-Store</div>
							 </div><!-- ./col -->
							 </div><!-- /.row -->
					 </div><!-- /.box-footer -->
					 </div><!-- /.box -->
					 <!-- Calendar -->
					 <div class="box box-solid bg-green-gradient">
					 <div class="box-header">
							 <i class="fa fa-calendar"></i>
							 <h3 class="box-title">Calendar</h3>
							 <!-- tools box -->
							 <div class="pull-right box-tools">
							 <!-- button with a dropdown -->
							 <div class="btn-group">
									 <button class="btn btn-success btn-sm dropdown-toggle" data-toggle="dropdown"><i class="fa fa-bars"></i></button>
									 <ul class="dropdown-menu pull-right" role="menu">
									 <li><a href="#">Add new event</a></li>
									 <li><a href="#">Clear events</a></li>
									 <li class="divider"></li>
									 <li><a href="#">View calendar</a></li>
									 </ul>
							 </div>
							 <button class="btn btn-success btn-sm" data-widget="collapse"><i class="fa fa-minus"></i></button>
							 <button class="btn btn-success btn-sm" data-widget="remove"><i class="fa fa-times"></i></button>
							 </div><!-- /. tools -->
					 </div><!-- /.box-header -->
					 <div class="box-body no-padding">
							 <!--The calendar -->
							 <div id="calendar" style="width: 100%"></div>
					 </div><!-- /.box-body -->
					 <div class="box-footer text-black">
							 <div class="row">
							 <div class="col-sm-6">
									 <!-- Progress bars -->
									 <div class="clearfix">
									 <span class="pull-left">Task #1</span>
									 <small class="pull-right">90%</small>
									 </div>
									 <div class="progress xs">
									 <div class="progress-bar progress-bar-green" style="width: 90%;"></div>
									 </div>
									 <div class="clearfix">
									 <span class="pull-left">Task #2</span>
									 <small class="pull-right">70%</small>
									 </div>
									 <div class="progress xs">
									 <div class="progress-bar progress-bar-green" style="width: 70%;"></div>
									 </div>
							 </div><!-- /.col -->
							 <div class="col-sm-6">
									 <div class="clearfix">
									 <span class="pull-left">Task #3</span>
									 <small class="pull-right">60%</small>
									 </div>
									 <div class="progress xs">
									 <div class="progress-bar progress-bar-green" style="width: 60%;"></div>
									 </div>
									 <div class="clearfix">
									 <span class="pull-left">Task #4</span>
									 <small class="pull-right">40%</small>
									 </div>
									 <div class="progress xs">
									 <div class="progress-bar progress-bar-green" style="width: 40%;"></div>
									 </div>
							 </div><!-- /.col -->
							 </div><!-- /.row -->
					 </div>
					 </div><!-- /.box -->
			 </section><!-- right col -->
			 </div><!-- /.row (main row) -->
	 </section><!-- /.content -->
	 </div><!-- /.content-wrapper -->

	 <!-- Control Sidebar -->
	 <aside class="control-sidebar control-sidebar-dark">
	 <!-- Create the tabs -->
	 <ul class="nav nav-tabs nav-justified control-sidebar-tabs">
			 <li><a href="#control-sidebar-home-tab" data-toggle="tab"><i class="fa fa-home"></i></a></li>
			 <li><a href="#control-sidebar-settings-tab" data-toggle="tab"><i class="fa fa-gears"></i></a></li>
	 </ul>
	 <!-- Tab panes -->
	 <div class="tab-content">
			 <!-- Home tab content -->
			 <div class="tab-pane" id="control-sidebar-home-tab">
			 <h3 class="control-sidebar-heading">Recent Activity</h3>
			 <ul class="control-sidebar-menu">
					 <li>
					 <a href="javascript::;">
							 <i class="menu-icon fa fa-birthday-cake bg-red"></i>
							 <div class="menu-info">
							 <h4 class="control-sidebar-subheading">Langdon's Birthday</h4>
							 <p>Will be 23 on April 24th</p>
							 </div>
					 </a>
					 </li>
					 <li>
					 <a href="javascript::;">
							 <i class="menu-icon fa fa-user bg-yellow"></i>
							 <div class="menu-info">
							 <h4 class="control-sidebar-subheading">Frodo Updated His Profile</h4>
							 <p>New phone +1(800)555-1234</p>
							 </div>
					 </a>
					 </li>
					 <li>
					 <a href="javascript::;">
							 <i class="menu-icon fa fa-envelope-o bg-light-blue"></i>
							 <div class="menu-info">
							 <h4 class="control-sidebar-subheading">Nora Joined Mailing List</h4>
							 <p>nora@example.com</p>
							 </div>
					 </a>
					 </li>
					 <li>
					 <a href="javascript::;">
							 <i class="menu-icon fa fa-file-code-o bg-green"></i>
							 <div class="menu-info">
							 <h4 class="control-sidebar-subheading">Cron Job 254 Executed</h4>
							 <p>Execution time 5 seconds</p>
							 </div>
					 </a>
					 </li>
			 </ul><!-- /.control-sidebar-menu -->
			 <h3 class="control-sidebar-heading">Tasks Progress</h3>
			 <ul class="control-sidebar-menu">
					 <li>
					 <a href="javascript::;">
							 <h4 class="control-sidebar-subheading">
							 Custom Template Design
							 <span class="label label-danger pull-right">70%</span>
							 </h4>
							 <div class="progress progress-xxs">
							 <div class="progress-bar progress-bar-danger" style="width: 70%"></div>
							 </div>
					 </a>
					 </li>
					 <li>
					 <a href="javascript::;">
							 <h4 class="control-sidebar-subheading">
							 Update Resume
							 <span class="label label-success pull-right">95%</span>
							 </h4>
							 <div class="progress progress-xxs">
							 <div class="progress-bar progress-bar-success" style="width: 95%"></div>
							 </div>
					 </a>
					 </li>
					 <li>
					 <a href="javascript::;">
							 <h4 class="control-sidebar-subheading">
							 Laravel Integration
							 <span class="label label-warning pull-right">50%</span>
							 </h4>
							 <div class="progress progress-xxs">
							 <div class="progress-bar progress-bar-warning" style="width: 50%"></div>
							 </div>
					 </a>
					 </li>
					 <li>
					 <a href="javascript::;">
							 <h4 class="control-sidebar-subheading">
							 Back End Framework
							 <span class="label label-primary pull-right">68%</span>
							 </h4>
							 <div class="progress progress-xxs">
							 <div class="progress-bar progress-bar-primary" style="width: 68%"></div>
							 </div>
					 </a>
					 </li>
			 </ul><!-- /.control-sidebar-menu -->
			 </div><!-- /.tab-pane -->
			 <!-- Stats tab content -->
			 <div class="tab-pane" id="control-sidebar-stats-tab">Stats Tab Content</div><!-- /.tab-pane -->
			 <!-- Settings tab content -->
			 <div class="tab-pane" id="control-sidebar-settings-tab">
			 <form method="post">
					 <h3 class="control-sidebar-heading">General Settings</h3>
					 <div class="form-group">
					 <label class="control-sidebar-subheading">
							 Report panel usage
							 <input type="checkbox" class="pull-right" checked>
					 </label>
					 <p>
							 Some information about this general settings option
					 </p>
					 </div><!-- /.form-group -->
					 <div class="form-group">
					 <label class="control-sidebar-subheading">
							 Allow mail redirect
							 <input type="checkbox" class="pull-right" checked>
					 </label>
					 <p>
							 Other sets of options are available
					 </p>
					 </div><!-- /.form-group -->
					 <div class="form-group">
					 <label class="control-sidebar-subheading">
							 Expose author name in posts
							 <input type="checkbox" class="pull-right" checked>
					 </label>
					 <p>
							 Allow the user to show his name in blog posts
					 </p>
					 </div><!-- /.form-group -->
					 <h3 class="control-sidebar-heading">Chat Settings</h3>
					 <div class="form-group">
					 <label class="control-sidebar-subheading">
							 Show me as online
							 <input type="checkbox" class="pull-right" checked>
					 </label>
					 </div><!-- /.form-group -->
					 <div class="form-group">
					 <label class="control-sidebar-subheading">
							 Turn off notifications
							 <input type="checkbox" class="pull-right">
					 </label>
					 </div><!-- /.form-group -->
					 <div class="form-group">
					 <label class="control-sidebar-subheading">
							 Delete chat history
							 <a href="javascript::;" class="text-red pull-right"><i class="fa fa-trash-o"></i></a>
					 </label>
					 </div><!-- /.form-group -->
			 </form>
			 </div><!-- /.tab-pane -->
	 </div>
	 </aside><!-- /.control-sidebar -->
	 <!-- Add the sidebar's background. This div must be placed
			 immediately after the control sidebar -->
	 <div class="control-sidebar-bg"></div>
	 </div>

The rest of the code you provided (core_htmlhead.php and footer.php) worked as normal.

Posted

Web541, thank you for taking the time and effort to help. Indeed it is because I placed most of the dashboard code in the header file. I didn't really see how it would make any difference (and still don't), but clearly it does as it's now working perfectly!

Note to self: don't mess with the basic phpvms architecture :P

Now I am off to try and work on getting the tables for pilots, fleet etc to show up properly. God give me strength! :wacko:

Posted

Ok next challenge. The built in modal popup is not working now with my new skin. I suspect it is probably jquery conflict with files from the new skin. In the existing "pireps_list" admin page the code for the pirep log is as follows:

<button class="jqModal {button:{icons:{primary:'ui-icon-script'}}}" id="dialog_details"
 href="<?php echo SITE_URL?>/admin/action.php/pirepadmin/viewlog?pirepid=<?php echo $pirep->pirepid;?>">Log</button>

My question is, how would I convert the above code to work with Bootstrap Modal? The code for the BS one is as follows:

<button type="button" class="btn btn-primary btn-lg" data-toggle="modal" data-target="#myModal">Log</button>
    <!-- Modal -->
    <div class="modal fade" id="myModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel">
	  <div class="modal-dialog" role="document">
	    <div class="modal-content">
		  <div class="modal-header">
		    <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
		    <h4 class="modal-title" id="myModalLabel">Modal title</h4>
		  </div>
		  <div class="modal-body">
		    <?php echo SITE_URL?>/admin/action.php/pirepadmin/viewlog?pirepid=<?php echo $pirep->pirepid;?>
		  </div>
		  <div class="modal-footer">
		    <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
		    <button type="button" class="btn btn-primary">Save changes</button>
		  </div>
	    </div>
	  </div>
    </div>

As you can see, I have pasted the code from phpvms into the Bootstrap code, and it pops up perfectly, except the content is just the URL for the pirep. So, clearly the phpvms system is taking that link and applying a look up of some sort in order to return the right content and not just a url.

Any ideas on how the code would need to look to achieve the same with the Bootstrap code?

Thanks

Posted

With your code, it seems that it is returning the URL as you have not specified any action for it.

As a quick solution, try an anchor

<a data-toggle="modal" class="btn btn-primary btn-lg" href="<?php echo SITE_URL?>/admin/action.php/pirepadmin/viewlog?pirepid=<?php echo $pirep->pirepid;?>" data-target="#myModal">Log</a>
<!-- Modal -->
<div class="modal fade" id="myModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel">
<div class="modal-dialog" role="document">
 <div class="modal-content">
	 <div class="modal-header">
		 <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
		 <h4 class="modal-title" id="myModalLabel">Log for <?php echo $report->code.$report->pirepid?></h4>
	 </div>
	 <div class="modal-body">

	 </div>
	 <div class="modal-footer">
		 <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
		 <button type="button" class="btn btn-primary">Save changes</button>
	 </div>
 </div>
</div>
</div>

See if that works

Posted

With your code, it seems that it is returning the URL as you have not specified any action for it.

As a quick solution, try an anchor

<a data-toggle="modal" class="btn btn-primary btn-lg" href="<?php echo SITE_URL?>/admin/action.php/pirepadmin/viewlog?pirepid=<?php echo $pirep->pirepid;?>" data-target="#myModal">Log</a>
<!-- Modal -->
<div class="modal fade" id="myModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel">
<div class="modal-dialog" role="document">
 <div class="modal-content">
	 <div class="modal-header">
		 <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
		 <h4 class="modal-title" id="myModalLabel">Log for <?php echo $report->code.$report->pirepid?></h4>
	 </div>
	 <div class="modal-body">

	 </div>
	 <div class="modal-footer">
		 <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
		 <button type="button" class="btn btn-primary">Save changes</button>
	 </div>
 </div>
</div>
</div>

See if that works

Well bizzarely, I refreshed the page and it seemed to work. Well kind of! The modal box pops up but it keeps showing the same info for all pireps i.e. if I click on the log for one pirep and then go to another pirep, the content from the first still appears in the modal like it's not refreshing the data.

Any thoughts?

Posted

I've noticed that since I've applied my new skin template, the ajax calls don't seem to be working from phpvms. Things like buttons to accept pireps or pilots don't do anything. I know this obviously means that the buttons in question are not able to find the scripts and therefore do nothing. The scripts I am talking about are the ones inside the "module" folders in the admin section eg. the PirepAdmin.php file inside the PirepAdmin folder.

My question is why? I have both the phpvms files and my template files located in the head and foot of the main page. Could it be something as silly as the order in which the files are stacked in the list? I have tried moving one or two but it makes no difference.

  • 3 weeks later...
Posted

In your other post you mentioned that the jquery version is conflicting between the one compatible with phpVMS and the one in your skin, I tried the following and it seems to work without breaking the skin, you will get an error in firebug stating that you need jquery 1.9.1 or higher for bootstrap, but from what I can see, nothing has broken yet and this also brings back functionality of the accepting/rejecting PIREPS and viewing the Pilots/schedules which weren't possible with your version of jquery.

...

Go into your admin/lib/layout/footer.php and find these lines:

<!-- jQuery 2.1.4 -->
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.4/jquery.min.js"></script>
<!-- jQuery UI 1.11.4 -->
<script src="https://code.jquery.com/ui/1.11.4/jquery-ui.min.js"></script>

and then move them into admin/templates/core_htmlhead.php so that it is read on every page

Once done, change the jquery version to an earlier one which is compatible with phpVMS in this case I've tried it with 1.8.3 and the skin hasn't broken

So you should end up like this

<!-- jQuery 2.1.4 -->
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js"></script>
<!-- jQuery UI 1.11.4 -->
<script src="https://code.jquery.com/ui/1.11.4/jquery-ui.min.js"></script>

In your admin/templates/core_htmlhead.php

If you do need some bootstrap functions (e.g. dropdowns), then you may need to change a few core files which isn't recommended.

Otherwise you can google newer versions of the javascript files e.g. jquery.jqgrid.min.js, etc.) and place them into the corresponding position in the phpvms layout (lib/js...) and then replace the above code with a newer version of jQuery (e.g. 1.11.3)

And to fix your log-on-refresh issue,

open bootstrap.js and before your last

}(jQuery);

(very end of the page)

and then put this there

 // Clear Modal On Hide
 // ===================
   // no cache data loaded to modal popup (by default it's cached)
   $('body').on('hidden.bs.modal', '.modal', function (event) {
    $(this).removeData('bs.modal');
   });

Then change all your references of

bootstrap.min.js

to

bootstrap.js

unless you want to minify it first.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...