Details
-
Bug
-
Resolution: Duplicate
-
Medium
-
None
-
4.0.0alpha1, 4.0.0trunk
-
None
Description
in function ezwebdavcontentserver->fetchnodeinfo($node), the href attibute emitted for a node wich is deeper than 1 level in the content tree is broken:
it is built by using $node->urlAlias, appended to $_SERVER('SCRIPT_URL')
script_url = http://my.test.server/siteaccess/Content/toplevelfolder/
url_alias = toplevelfolder/secondlevelobj
result:
http://my.test.server/siteaccess/Content/toplevelfolder/toplevelfolder/secondlevelobj
(dirty) fix: in fetchnodeinfo: replace
$scriptURL = $_SERVER["SCRIPT_URL"];
if ( strlen( $scriptURL ) > 0 and $scriptURL[ strlen( $scriptURL ) - 1 ] != "/" )
$scriptURL .= "/";
with
$scriptURL = $_SERVER["SCRIPT_URL"];
if ( strlen( $scriptURL ) > 0)
{
// dirty hack: find dav 'virtual root' of content
if (($pos = strpos($scriptURL, '/Content')) !== false)
else if (($pos = strpos($scriptURL, '/Media')) !== false)
{ /// @todo: test with media folder $scriptURL = substr($_SERVER["SCRIPT_URL"], 0, $pos + 6); } if ($scriptURL[ strlen( $scriptURL ) - 1 ] != "/" )
$scriptURL .= "/";
}
Attachments
Issue Links
- duplicates
-
EZP-11503 WebDAV does not work since certain level
- Closed