Commit 3dab0124 authored by Kasper Skårhøj's avatar Kasper Skårhøj
Browse files

* In t3lib_div::linkThisUrl(), remove "?" if no parameters were found.


git-svn-id: https://svn.typo3.org/TYPO3v4/Core/trunk@168 709f56b5-9817-0410-a4d7-c38de5d9e867
parent a6dd330e
2004-03-31 Kasper Skårhøj,,, <kasper@typo3.com>
* In t3lib_div::linkThisUrl(), remove "?" if no parameters were found.
2004-03-31 Kasper Skårhøj,,, <kasper@typo3.com>
* Added "config.doctype = none" support - omits any doctype in the frontend.
......
......@@ -98,7 +98,7 @@
* 1198: function trimExplode($delim, $string, $onlyNonEmptyValues=0)
* 1223: function uniqueArray($valueArray)
* 1246: function removeArrayEntryByValue($array,$cmpValue)
* 1275: function implodeArrayForUrl($name,$theArray,$str='',$skipBlank=0,$rawurlencodeParamName=0)
* 1275: function implodeArrayForUrl($name,$theArray,$str='',$skipBlank=0,$rawurlencodeParamName=0)
* 1302: function compileSelectedGetVarsFromArray($varList,$getArray,$GPvarAlt=1)
* 1326: function addSlashesOnArray(&$theArray)
* 1351: function stripSlashesOnArray(&$theArray)
......@@ -137,7 +137,7 @@
*
* SECTION: SYSTEM INFORMATION
* 2322: function getThisUrl()
* 2339: function linkThisScript($getParams=array())
* 2339: function linkThisScript($getParams=array())
* 2363: function linkThisUrl($url,$getParams=array())
* 2385: function getIndpEnv($getEnvName)
* 2569: function milliseconds()
......@@ -2386,11 +2386,15 @@ class t3lib_div {
$parts = parse_url($url);
if ($parts['query']) {
parse_str($parts['query'],$getP);
} else $getP=array();
} else {
$getP = array();
}
$getP=t3lib_div::array_merge_recursive_overrule($getP,$getParams);
$getP = t3lib_div::array_merge_recursive_overrule($getP,$getParams);
$uP = explode('?',$url);
$outurl = $uP[0].'?'.t3lib_div::implodeArrayForUrl('',$getP);
$params = t3lib_div::implodeArrayForUrl('',$getP);
$outurl = $uP[0].($params ? '?'.substr($params, 1) : '');
return $outurl;
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment