mirror of
https://github.com/danpros/htmly.git
synced 2026-04-17 19:26:08 +05:30
jQuery
Loading jQuery without using it is stupid. Add options for it.
This commit is contained in:
parent
c7fb74859f
commit
2f86b2780d
2 changed files with 10 additions and 1 deletions
|
|
@ -68,6 +68,9 @@ rss.char = ""
|
|||
img.thumbnail = "true"
|
||||
default.thumbnail = ""
|
||||
|
||||
;Enable or disable jQuery, if Lightbox is "on" then this option ignored.
|
||||
jquery = "disable"
|
||||
|
||||
; Lightbox inline image handling. This can slowdown your page load, especially when Disqus enabled. "on" or "off".
|
||||
lightbox = "off"
|
||||
|
||||
|
|
|
|||
|
|
@ -1398,6 +1398,7 @@ function authorinfo($title=null, $body=null) {
|
|||
function head_contents($title, $description, $canonical) {
|
||||
|
||||
$styleImage = config('lightbox');
|
||||
$jq = config('jquery');
|
||||
$output = '';
|
||||
|
||||
$title = '<title>' . $title . '</title>';
|
||||
|
|
@ -1419,7 +1420,12 @@ function head_contents($title, $description, $canonical) {
|
|||
$output .= $title ."\n". $favicon ."\n". $charset ."\n". $generator ."\n". $xua ."\n". $viewport ."\n". $description ."\n". $sitemap ."\n". $canonical ."\n". $feed ."\n". $lightboxcss ."\n". $jquery ."\n". $lightbox ."\n" .$corejs ."\n";
|
||||
}
|
||||
else {
|
||||
$output .= $title ."\n". $favicon ."\n". $charset ."\n". $generator ."\n". $xua ."\n". $viewport ."\n". $description ."\n". $sitemap ."\n". $canonical ."\n". $feed ."\n". $jquery ."\n";
|
||||
if($jq == 'enable') {
|
||||
$output .= $title ."\n". $favicon ."\n". $charset ."\n". $generator ."\n". $xua ."\n". $viewport ."\n". $description ."\n". $sitemap ."\n". $canonical ."\n". $feed ."\n". $jquery ."\n";
|
||||
}
|
||||
else {
|
||||
$output .= $title ."\n". $favicon ."\n". $charset ."\n". $generator ."\n". $xua ."\n". $viewport ."\n". $description ."\n". $sitemap ."\n";
|
||||
}
|
||||
}
|
||||
|
||||
return $output;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue