get_header

Load header template.

Description

getHeader(); 

Usage

  1. if ( !function_exists( 'getHeader' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'ads-ez-plugin-for-google-adsense/admin/header.php'; 
  3.  
  4.  
  5. // NOTICE! Understand what this does before running. 
  6. $result = getHeader(); 
  7.  

Defined (1)

The function is defined in the following location(s).

/admin/header.php  
  1. function getHeader() { 
  2. global $ezAdminUrl; 
  3. ob_start(); 
  4. $plgName = EzGA::getPlgName(__DIR__); 
  5. $plgSlug = EzGA::getSlug(); 
  6. $plgModeName = EzGA::$pluginModes[$plgSlug]; 
  7. $isPro = EzGA::$isPro; 
  8. $plgPrice = EzGA::$plgPrice; 
  9. if ($isPro && !empty(EzGA::$options['eztheme'])) { 
  10. $themeCSS = $ezAdminUrl . "css/bootstrap-" . strtolower(EzGA::$options['eztheme']) . ".min.css"; 
  11. else { 
  12. $themeCSS = $ezAdminUrl . "css/bootstrap-default.min.css"; 
  13. ?> 
  14. <!DOCTYPE html> 
  15. <html lang="en"> 
  16. <head> 
  17. <meta charset="utf-8"> 
  18. <title><?php echo $plgName; ?></title> 
  19. <meta name="viewport" content="width=device-width, initial-scale=1"> 
  20. <meta name="description" content="Ads EZ Plugin for Google AdSense"> 
  21. <meta name="author" content="Manoj Thulasidas"> 
  22.  
  23. <!-- The styles --> 
  24. <link id="bs-css" href="<?php echo $themeCSS; ?>" rel="stylesheet"> 
  25. <link href="<?php echo $ezAdminUrl; ?>css/bootstrap-editable.css" rel="stylesheet"> 
  26. <link href="<?php echo $ezAdminUrl; ?>css/charisma-app.css" rel="stylesheet"> 
  27. <link href='<?php echo $ezAdminUrl; ?>css/bootstrap-tour.min.css' rel='stylesheet'> 
  28. <link href="<?php echo $ezAdminUrl; ?>css/font-awesome.min.css" rel="stylesheet"> 
  29. <link href="<?php echo $ezAdminUrl; ?>css/fileinput.min.css" rel="stylesheet"> 
  30. <link href="<?php echo $ezAdminUrl; ?>css/bootstrap-colorpicker.min.css" rel="stylesheet"> 
  31. <link href="<?php echo $ezAdminUrl; ?>css/ez-admin.css" rel="stylesheet"> 
  32. <style type="text/css"> 
  33. .popover{width:600px;} 
  34. <?php 
  35. if (empty(EzGA::$options['breadcrumbs'])) { 
  36. ?> 
  37. .breadcrumb {display:none;} 
  38. <?php 
  39. ?> 
  40. </style> 
  41. <!-- jQuery --> 
  42. <script src="//ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script> 
  43.  
  44. <!-- The HTML5 shim, for IE6-8 support of HTML5 elements --> 
  45. <!--[if lt IE 9]> 
  46. <script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script> 
  47. <![endif]--> 
  48.  
  49. <!-- The fav icon --> 
  50. <link rel="shortcut icon" href="img/favicon.ico"> 
  51.  
  52. </head> 
  53.  
  54. <body> 
  55. <script> 
  56. parent.clearTimeout(parent.errorTimeout); 
  57. </script> 
  58. <!-- topbar starts --> 
  59. <div class="navbar navbar-default" role="navigation"> 
  60.  
  61. <div class="navbar-inner"> 
  62. <a id="index" class="navbar-brand" href="index.php"> <img alt="Ads EZ Logo" src="<?php echo $ezAdminUrl; ?>img/ads-ez.png" class="hidden-xs"/> 
  63. <span><?php echo $plgName; ?></span></a> 
  64. <div class="btn-group pull-right"> 
  65. <?php 
  66. $standaloneURL = network_site_url() . "/ezadsense-ep/admin/index.php"; 
  67. ?> 
  68. <a id="standAloneMode" href="<?php echo $standaloneURL; ?>" target="_blank" data-content="Open <?php echo $plgName; ?> admin apge in a new window independent of WordPress admin interface. The standalone mode still uses WP authentication, and cannot be accessed unless logged in." data-toggle="popover" data-trigger="hover" data-placement="left" title='Standalone Admin Screen'><span class="btn btn-info"><i class="glyphicon glyphicon-resize-full"></i> Standalone Mode</span></a> 
  69. <a id="update" href="update.php" data-content="If you would like to check for regular updates, or install a purchased module or Pro upgrade, visit the Updates page." data-toggle="popover" data-trigger="hover" data-placement="left" title='Updates Page'><span class="btn btn-info" ><i class="fa fa-cog fa-spin"></i> Updates 
  70. <?php 
  71. if (!$isPro) { 
  72. ?> 
  73.  <span class="badge red">Pro</span> 
  74. <?php 
  75. ?> 
  76. </span> 
  77. </a>  
  78. <?php 
  79. if (!empty(EzGA::$options['show_google_translate'])) { 
  80. ?> 
  81. <span id='GoogleTranslatorWidget' style='display:inline-block'> 
  82. <span id='google_translate_element'></span> 
  83. </span> 
  84. <?php 
  85. ?> 
  86. </div> 
  87. </div> 
  88. </div> 
  89. <!-- topbar ends --> 
  90. <div class="ch-container"> 
  91. <div class="row"> 
  92. <!-- left menu starts --> 
  93. <div class="col-sm-2 col-lg-2"> 
  94. <div class="sidebar-nav"> 
  95. <div class="nav-canvas"> 
  96. <div class="nav-sm nav nav-stacked"> 
  97.  
  98. </div> 
  99. <ul class="nav nav-pills nav-stacked main-menu"> 
  100. <li id="dashboard"><a href="index.php"><i class="glyphicon glyphicon-home"></i><span> Dashboard</span></a> 
  101. </li> 
  102. <?php 
  103. if ($isPro) { 
  104. $optionSets = EzGA::getOptionSets(); 
  105. echo <<<EOF 
  106. <li class="accordion"> 
  107. <a id='$plgSlug' href="#"><i class="glyphicon glyphicon-plus"></i><span> $plgModeName</span></a> 
  108. <ul class="nav nav-pills nav-stacked"> 
  109. <li id='$plgSlug-admin'><a href="$plgSlug-admin.php"><i class="glyphicon glyphicon-check"></i><span> Settings</span></a></li> 
  110. EOF; 
  111. foreach ($optionSets as $o) { 
  112. if (in_array($o, EzGA::$unSettable)) { 
  113. $verb = 'Edit '; 
  114. else { 
  115. $verb = 'Switch to '; 
  116. echo <<<EOF 
  117. <li id="$plgSlug-$o"><a href="$plgSlug-admin.php?optionset=$o"><i class="glyphicon glyphicon-export red"></i><span> $verb <code>$o</code></span></a></li> 
  118. EOF; 
  119. echo <<<EOF 
  120. <li id="$plgSlug-add"><a href="optionset.php"><i class="glyphicon glyphicon-export red"></i><span> Manage Option Sets</span></a></li> 
  121. </ul> 
  122. </li> 
  123. EOF; 
  124. ?> 
  125. <li id='pro'><a href="pro.php" class="red"><i class="glyphicon glyphicon-cog"></i><span><b> Pro Features</b></span></a></li> 
  126. <?php 
  127. else { 
  128. echo <<<EOF 
  129. <li id='$plgSlug-admin'><a href="$plgSlug-admin.php"><i class="glyphicon glyphicon-check"></i><span> $plgModeName</span></a></li> 
  130. EOF; 
  131. ?> 
  132. <li id='goPro'><a href="pro.php" class="red goPro" data-toggle="popover" data-trigger="hover" data-content="Get the Pro version of <?php echo $plgModeName; ?> for <i>only</i> $<?php echo $plgPrice[$plgSlug]; ?>. Tons of extra features. Instant download." data-placement="right" title="Upgrade to Pro" data-product="<?php echo $plgSlug; ?>"><i class="glyphicon glyphicon-shopping-cart"></i><span><b> Go Pro!</b></span></a></li> 
  133. <?php 
  134. ?> 
  135. <li id="options"><a href="options.php"><i class="glyphicon glyphicon-cog"></i><span> Options</span></a></li> 
  136. <li id="i18n"><a href="i18n.php"><i class="glyphicon glyphicon-globe"></i><span> Languages</span></a></li> 
  137. </ul> 
  138. </div> 
  139. </div> 
  140. </div> 
  141. <!--/span--> 
  142. <!-- left menu ends --> 
  143.  
  144. <noscript> 
  145. <div class="alert alert-block col-md-12"> 
  146. <h4 class="alert-heading">Warning!</h4> 
  147.  
  148. <p>You need to have <a href="http://en.wikipedia.org/wiki/JavaScript" target="_blank">JavaScript</a> 
  149. enabled to use this site.</p> 
  150. </div> 
  151. </noscript> 
  152.  
  153. <div id="content" class="col-lg-10 col-sm-10"> 
  154. <!-- content starts --> 
  155. <?php 
  156. $header = ob_get_clean(); 
  157. return $header;