Converted all URLs to be truly relative using the $base_url variable to render all URLs.
This commit is contained in:
parent
caa3c95332
commit
746b28d261
22
index.php
22
index.php
@ -66,7 +66,7 @@ software, even if advised of the possibility of such damage.
|
||||
require_once('libs/functions.php');
|
||||
|
||||
$options = get_options();
|
||||
$tree = get_tree("docs");
|
||||
$tree = get_tree("docs", $base_url);
|
||||
$homepage_url = homepage_url($tree);
|
||||
$docs_url = docs_url($tree);
|
||||
|
||||
@ -87,9 +87,9 @@ if ($homepage && $homepage_url !== '/') {
|
||||
<meta name="description" content="<?php echo $options['tagline'];?>" />
|
||||
<meta name="author" content="<?php echo $options['title']; ?>">
|
||||
<?php if ($options['colors']) { ?>
|
||||
<link rel="icon" href="img/favicon.png" type="image/x-icon">
|
||||
<link rel="icon" `<?php echo $base_url ?>img/favicon.png" type="image/x-icon">
|
||||
<?php } else { ?>
|
||||
<link rel="icon" href="img/favicon-<?php echo $options['theme'];?>.png" type="image/x-icon">
|
||||
<link rel="icon" href="<?php echo $base_url ?>/img/favicon-<?php echo $options['theme'];?>.png" type="image/x-icon">
|
||||
<?php } ?>
|
||||
<!-- Mobile -->
|
||||
<meta name="apple-mobile-web-app-capable" content="yes" />
|
||||
@ -104,20 +104,20 @@ if ($homepage && $homepage_url !== '/') {
|
||||
<?php foreach($options['colors'] as $k => $v) { ?>
|
||||
@<?php echo $k;?>: <?php echo $v;?>;
|
||||
<?php } ?>
|
||||
@import "less/import/daux-base.less";
|
||||
@import "<?php echo $base_url ?>/less/import/daux-base.less";
|
||||
</style>
|
||||
<script src="js/less.min.js"></script>
|
||||
<script src="<?php echo $base_url ?>/js/less.min.js"></script>
|
||||
<?php } else { ?>
|
||||
<link rel="stylesheet" href="css/daux-<?php echo $options['theme'];?>.css">
|
||||
<link rel="stylesheet" href="<?php echo $base_url ?>/css/daux-<?php echo $options['theme'];?>.css">
|
||||
<?php } ?>
|
||||
|
||||
<!-- hightlight.js -->
|
||||
<script src="js/highlight.min.js"></script>
|
||||
<script src="<?php echo $base_url ?>/js/highlight.min.js"></script>
|
||||
<script>hljs.initHighlightingOnLoad();</script>
|
||||
|
||||
<!-- Navigation -->
|
||||
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.10.0/jquery.min.js"></script>
|
||||
<script src="js/custom.js"></script>
|
||||
<script src="<?php echo $base_url ?>/js/custom.js"></script>
|
||||
<!--[if lt IE 9]>
|
||||
<script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script>
|
||||
<![endif]-->
|
||||
@ -128,7 +128,7 @@ if ($homepage && $homepage_url !== '/') {
|
||||
<div class="navbar navbar-fixed-top">
|
||||
<div class="navbar-inner">
|
||||
<div class="container">
|
||||
<a class="brand pull-left" href="<?php echo $homepage_url;?>"><?php echo $options['title']; ?></a>
|
||||
<a class="brand pull-left" href="<?php echo $base_url ?>/<?php echo $homepage_url;?>"><?php echo $options['title']; ?></a>
|
||||
<p class="navbar-text pull-right">
|
||||
Generated by <a href="http://daux.io">Daux.io</a>
|
||||
</p>
|
||||
@ -148,7 +148,7 @@ if ($homepage && $homepage_url !== '/') {
|
||||
<div class="row">
|
||||
<div class="span10 offset1">
|
||||
<?php if ($options['image']) { ?>
|
||||
<img class="homepage-image" src="<?php echo $options['image'];?>" alt="<?php echo $options['title'];?>">
|
||||
<img class="homepage-image" src="<?php echo $base_url ?>/<?php echo $options['image'];?>" alt="<?php echo $options['title'];?>">
|
||||
<?php } ?>
|
||||
</div>
|
||||
</div>
|
||||
@ -217,7 +217,7 @@ if ($homepage && $homepage_url !== '/') {
|
||||
<div class="container-fluid fluid-height wrapper">
|
||||
<div class="navbar navbar-fixed-top">
|
||||
<div class="navbar-inner">
|
||||
<a class="brand pull-left" href="<?php echo $homepage_url;?>"><?php echo $options['title']; ?></a>
|
||||
<a class="brand pull-left" href="<?php echo $base_url ?><?php echo $homepage_url;?>"><?php echo $options['title']; ?></a>
|
||||
<p class="navbar-text pull-right">
|
||||
Generated by <a href="http://daux.io">Daux.io</a>
|
||||
</p>
|
||||
|
Loading…
Reference in New Issue
Block a user