Odyssey
shell.prg
1 <?php
2 
3 $sharedLibrary = dirname(__FILE__) . "/../../shared/library";
4 require_once("$sharedLibrary/hcuCommon.i");
5 require_once("$sharedLibrary/dms_imp_val.i");
6 require_once("$sharedLibrary/hcuEnv.i");
7 
8 $string = array("filter" => HCUFILTER_INPUT_STRING);
9 $shell = null; $title = null;
10 HCU_ImportVars($parameters, "a", array("shell" => $string, "title" => $string));
11 extract($parameters["a"]);
12 
13 $title = is_null($title) ? "" : trim($title);
14 $title = $title == "" ? "HomeCU Admin Portal" : $title;
15 
16 // * SET the Kendo Versions on Amazon
17 $cloudfrontDomainName = GetCloudFrontDomainName();
18 $homecuKendoVersion = GetHomecuKendoVersion();
19 $bootstrapVersion = GetHomecuBootstrapVersion();
20 $fontawesomeVersion = GetFontawesomeVersion();
21 $loadStyleSheet = GetAdminDefaultKendoStyle();
22 
23 header ("Pragma: no-cache");
24 header ("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT");
25 header ("Cache-Control: no-cache, no-store, must-revalidate, max_age=0");
26 header ("Expires: 0");
27 header('X-Frame-Options: sameorigin');
28 ?><!DOCTYPE html>
29 <html>
30  <head>
31  <title><?php echo $title; ?></title>
32  <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
33  <meta name="robots" content="noindex,nofollow" />
34  <meta http-equiv="X-UA-Compatible" content="IE=edge" />
35 
36  <meta name="viewport" content="width=device-width, initial-scale=1" />
37  <?php
38  /* START PASTE */
39  print <<< HTML_INCLUDES
40  <link rel='stylesheet' media='all' type='text/css' href='https://{$cloudfrontDomainName}/homecu/css/reset.4085.min.css' />
41 
42  <!-- BASE BOOTSTRAP -->
43  <link href='https://{$cloudfrontDomainName}/homecu/css/bootstrap/{$bootstrapVersion}/css/bootstrap.min.css' rel='stylesheet'/>
44 
45  <!-- KENDO BOOTSTRAP COMMON STYLES --- REPLACES kendo.common.css -->
46  <link href='https://{$cloudfrontDomainName}/homecu/css/KendoUI/{$homecuKendoVersion}/kendo.common-bootstrap.min.css' rel='stylesheet'/>
47 
48  <!-- KENDO BOOTSTRAP THEME */ -->
49  <link href='https://{$cloudfrontDomainName}/homecu/css/KendoUI/{$homecuKendoVersion}/kendo.{$loadStyleSheet}.min.css' rel='stylesheet'/>
50 
51  <!-- METIS MENU -->
52  <link href='/static/css/metisMenu.css' rel='stylesheet'/>
53 
54  <!-- /* HOMECU BASE LAYOUT */ -->
55  <link rel='stylesheet' media='all' type='text/css' href='/admbin/static/css/layout.css' />
56 
57  <!-- /* FONT AWESOME */ -->
58  <link href='https://{$cloudfrontDomainName}/homecu/css/font-awesome/font-awesome-4.6.3/css/font-awesome.css' rel='stylesheet'/>
59 
60  <!-- /* CREDIT UNION BRANDING CUSTOM STYLES */ -->
61  <link rel='stylesheet' media='all' type='text/css' href='/admbin/static/css/brand.css' />
62 
63  <!-- /* CREDIT UNION BRANDING CUSTOM STYLES */ -->
64  <link rel='stylesheet' media='all' type='text/css' href='/admbin/static/css/admin_master.css' />
65 
66  <style>
67  html,body {
68  background-color: white;
69  color: black
70  }
71  </style>
72 
73 HTML_INCLUDES;
74 
75  /* END PASTE */
76 
77  // Make it safe by removing any script tags.
78  $html = "";
79 
80  if (!is_null($shell) && trim($shell) != "") {
81  $dom = new DOMDocument();
82  $dom->loadHTML($shell);
83 
84  $noTags = array("script", "frame", "iframe");
85 
86  foreach($noTags as $noTag) {
87  $noes = $dom->getElementsByTagName($noTag);
88 
89  foreach($noes as $no) {
90  $item->parentNode->removeChild($no);
91  }
92  }
93 
94  $html = $dom->saveHTML();
95  }
96  ?>
97 
98  </head>
99  <body>
100  <?php echo $html; ?>
101  </body>