Module: appdb Branch: master Commit: a00bb7ba016822b990246b4972a42d7276c945ef URL: http://source.winehq.org/git/appdb.git/?a=commit;h=a00bb7ba016822b990246b497...
Author: Jeremy Newman jnewman@codeweavers.com Date: Tue Nov 22 11:25:24 2016 -0600
allow additional header code to be loaded
---
include/appdb.php | 4 +++- include/header.php | 6 +++++- 2 files changed, 8 insertions(+), 2 deletions(-)
diff --git a/include/appdb.php b/include/appdb.php index 4a92df6..4130bb0 100644 --- a/include/appdb.php +++ b/include/appdb.php @@ -233,8 +233,10 @@ function appdb_fullpath($path)
/** * output the common apidb header + * title => sets the page title + * sHeaderCode => add additional code to <head> block */ -function apidb_header($title = 0) +function apidb_header($title = 0, $sHeaderCode = "") { $realname = $_SESSION['current']->sRealname;
diff --git a/include/header.php b/include/header.php index 1df07cc..516fba0 100644 --- a/include/header.php +++ b/include/header.php @@ -29,7 +29,11 @@ $iJStime = filemtime(BASE."utils.js"); <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js" integrity="sha384-0mSbJDEHialfmuBBQP6A4Qrprq5OVfW37PRR3j5ELqxss1yVqOtnepnHVP9aJ7xS" crossorigin="anonymous"></script> <script src="https://code.jquery.com/ui/1.11.4/jquery-ui.min.js" type="text/javascript"></script> <script src="<?php echo BASE; ?>utils.js?f=<?php echo $iJStime; ?>"></script> - +<?php +// additional header code +if (!empty($sHeaderCode)) + echo " {$sHeaderCode}\n"; +?> <link rel="shortcut icon" type="image/png" href="<?php echo BASE; ?>images/winehq_logo_16.png"> <link title="AppDB" type="application/opensearchdescription+xml" rel="search" href="<?php echo BASE; ?>opensearch.xml"> </head>