Example #1
0
	function fetchElement($name, $value, &$node, $control_name)
	{
		global $gantry;
		
		gantry_import('core.gantrydiagnostic');
		$diagnose = new GantryDiagnostic();
		$errors = $diagnose->checks();
		
		$output = "";
		
		if (count($errors) > 0) {
			$klass = "errors";
			$output = implode("", $errors);
		} else {
			$klass = "success";
			$output = "Diagnostic checks successfully passed.";
		}
        $output .= '<br/><a href="'.JURI::base(true).'?option=com_admin&tmpl=gantry-ajax-admin&model=diagnostics&template='.$gantry->templateName.'">Download Diagnostic Info</a>';
		
		return "
		<div id='diagnostic' class='".$klass."'>
			<div id='diagnostic-bar' class='g-title'>".JText::_('DIAGNOSTICS')." - ". ucfirst($klass) ." <span class='arrow'></span></div>
			<div id='diagnostic-desc' class='g-inner'>
			".$output."
			</div>
		</div>";
		
	}
Example #2
0
 function fetchElement($name, $value, &$node, $control_name)
 {
     global $gantry;
     gantry_import('core.gantrydiagnostic');
     $diagnose = new GantryDiagnostic();
     $errors = $diagnose->checks();
     $output = "";
     if (count($errors) > 0) {
         $klass = "errors";
         $output = implode("", $errors);
     } else {
         $klass = "success";
         $output = "Diagnostic checks successfully passed.";
     }
     return "\n\t\t<div id='diagnostic' class='" . $klass . "'>\n\t\t\t<div id='diagnostic-bar' class='g-title'>" . JText::_('DIAGNOSTICS') . " - " . ucfirst($klass) . " <span class='arrow'></span></div>\n\t\t\t<div id='diagnostic-desc' class='g-inner'>\n\t\t\t" . $output . "\n\t\t\t</div>\n\t\t</div>";
 }