Commit 3a2fc0ab856b87fb673687f33f4be68e45a98ac3

Authored by nbm
1 parent 9576d09d

getURL() is now expected to include KTRootUrl itself.


git-svn-id: https://kt-dms.svn.sourceforge.net/svnroot/kt-dms/trunk@4309 c91229c3-7414-0410-bfa2-8a42b809f60b
lib/actions/documentaction.inc.php
@@ -70,7 +70,7 @@ class KTDocumentAction extends KTStandardDispatcher { @@ -70,7 +70,7 @@ class KTDocumentAction extends KTStandardDispatcher {
70 } 70 }
71 71
72 function getURL() { 72 function getURL() {
73 - return sprintf("/action.php/%s?fDocumentId=%d", $this->sName, $this->oDocument->getID()); 73 + return sprintf("%s/action.php/%s?fDocumentId=%d", $GLOBALS['KTRootUrl'], $this->sName, $this->oDocument->getID());
74 } 74 }
75 75
76 function getInfo() { 76 function getInfo() {
@@ -79,9 +79,6 @@ class KTDocumentAction extends KTStandardDispatcher { @@ -79,9 +79,6 @@ class KTDocumentAction extends KTStandardDispatcher {
79 } 79 }
80 80
81 $url = $this->getURL(); 81 $url = $this->getURL();
82 - if (substr($url, 0, 1) == '/') {  
83 - $url = generateLink($url, "");  
84 - }  
85 82
86 $aInfo = array( 83 $aInfo = array(
87 'disabled' => $this->_disable(), 84 'disabled' => $this->_disable(),
@@ -194,19 +191,4 @@ class KTDocumentActionUtil { @@ -194,19 +191,4 @@ class KTDocumentActionUtil {
194 } 191 }
195 } 192 }
196 193
197 -class KTBuiltInDocumentAction extends KTDocumentAction {  
198 - var $sBuildInAction;  
199 - function getURL() {  
200 - return sprintf("/control.php?action=%s&fDocumentID=%d", $this->sBuiltInAction, $this->oDocument->getID());  
201 - }  
202 -}  
203 -  
204 -class KTBuiltInDocumentActionSingle extends KTBuiltInDocumentAction {  
205 - function getURL() {  
206 - return sprintf("/control.php?action=%s&fDocumentIDs[]=%d&fReturnDocumentID=%d", $this->sBuiltInAction, $this->oDocument->getID(), $this->oDocument->getID());  
207 - }  
208 -}  
209 -  
210 -/* require_once(KT_DIR . '/plugins/ktcore/documentaction.inc.php'); */  
211 -  
212 ?> 194 ?>