Decaf mobile: an (almost) Javascript-free theme
This commit is contained in:
parent
8e62c8b27c
commit
488a38cd85
300 changed files with 11117 additions and 328 deletions
30
boot.php
30
boot.php
|
@ -1935,6 +1935,36 @@ function build_querystring($params, $name=null) {
|
|||
return $ret;
|
||||
}
|
||||
|
||||
function explode_querystring($query) {
|
||||
$arg_st = strpos($query, '?');
|
||||
if($arg_st !== false) {
|
||||
$base = substr($query, 0, $arg_st);
|
||||
$arg_st += 1;
|
||||
}
|
||||
else {
|
||||
$base = '';
|
||||
$arg_st = 0;
|
||||
}
|
||||
|
||||
$args = explode('&', substr($query, $arg_st));
|
||||
foreach($args as $k=>$arg) {
|
||||
if($arg === '')
|
||||
unset($args[$k]);
|
||||
}
|
||||
$args = array_values($args);
|
||||
|
||||
if(!$base) {
|
||||
$base = $args[0];
|
||||
unset($args[0]);
|
||||
$args = array_values($args);
|
||||
}
|
||||
|
||||
return array(
|
||||
'base' => $base,
|
||||
'args' => $args,
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the complete URL of the current page, e.g.: http(s)://something.com/network
|
||||
*
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue