* Optimize createLink for every request type.

This commit is contained in:
dingguodong
2021-08-10 10:42:45 +08:00
parent 944ac9aec7
commit 0fd19fec5b
2 changed files with 8 additions and 8 deletions
+4 -4
View File
@@ -106,17 +106,17 @@ class projectIssueEntry extends entry
private function createLink($module, $method, $vars)
{
$link = helper::createLink($module, $method, $vars, 'html');
$pos = strpos($link, '.php');
/* The requestTypes are: GET, PATH_INFO2, PATH_INFO */
if($this->config->requestType == 'GET')
{
$pos = strpos($link, '.php');
$link = '/index' . substr($link, $pos);
}
else
elseif($this->config->requestType == 'PATH_INFO2')
{
$pos = strpos($link, '.php');
$link = substr($link, $pos + 4);
}
return common::getSysURL() . $link;
}
+4 -4
View File
@@ -222,17 +222,17 @@ class projectIssuesEntry extends entry
private function createLink($module, $method, $vars)
{
$link = helper::createLink($module, $method, $vars, 'html');
$pos = strpos($link, '.php');
/* The requestTypes are: GET, PATH_INFO2, PATH_INFO */
if($this->config->requestType == 'GET')
{
$pos = strpos($link, '.php');
$link = '/index' . substr($link, $pos);
}
else
elseif($this->config->requestType == 'PATH_INFO2')
{
$pos = strpos($link, '.php');
$link = substr($link, $pos + 4);
}
return common::getSysURL() . $link;
}