summaryrefslogtreecommitdiff
path: root/lib/htmloutputter.php
diff options
context:
space:
mode:
authorCraig Andrews <candrews@integralblue.com>2009-08-08 22:56:42 -0400
committerCraig Andrews <candrews@integralblue.com>2009-08-08 22:56:42 -0400
commit060d5c4b8e1eea9561fe9dcad972cb412a5b00ec (patch)
treeff710809e78f1c607f445c3399841ef9332043a0 /lib/htmloutputter.php
parent1330998b9b5ee6ddd5ece50b394ecfe505fb1b24 (diff)
Fix logic that determines if a URL is relative or absolute in script() and cssLink()
Diffstat (limited to 'lib/htmloutputter.php')
-rw-r--r--lib/htmloutputter.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/htmloutputter.php b/lib/htmloutputter.php
index 2684baca6..604597116 100644
--- a/lib/htmloutputter.php
+++ b/lib/htmloutputter.php
@@ -350,7 +350,7 @@ class HTMLOutputter extends XMLOutputter
function script($src, $type='text/javascript')
{
$url = parse_url($src);
- if(! ($url->scheme || $url->host || $url->query || $url->fragment))
+ if( empty($url->scheme) && empty($url->host) && empty($url->query) && empty($url->fragment))
{
$src = common_path($src) . '?version=' . LACONICA_VERSION;
}
@@ -371,7 +371,7 @@ class HTMLOutputter extends XMLOutputter
function cssLink($src,$theme=null,$media=null)
{
$url = parse_url($src);
- if(! ($url->scheme || $url->host || $url->query || $url->fragment))
+ if( empty($url->scheme) && empty($url->host) && empty($url->query) && empty($url->fragment))
{
if(file_exists(theme_file($src,$theme))){
$src = theme_path($src, $theme) . '?version=' . LACONICA_VERSION;