Skip to content
This repository was archived by the owner on Sep 19, 2022. It is now read-only.

Commit dddfb97

Browse files
committed
Added new method for generating ContinueUrl
* Added new method for generating ContinueUrl without idPEntityId
1 parent 111a1d6 commit dddfb97

File tree

2 files changed

+21
-0
lines changed

2 files changed

+21
-0
lines changed

lib/Disco.php

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -197,5 +197,20 @@ public static function buildContinueUrl($entityID, $return, $returnIDParam, $idp
197197
return $url;
198198
}
199199

200+
/**
201+
* @param $entityID
202+
* @param $return
203+
* @param $returnIDParam
204+
* @return string url where user should be redirected when he choose idp
205+
*/
206+
public static function buildContinueUrlWithoutIdPEntityId($entityID, $return, $returnIDParam) {
207+
$url = '?' .
208+
'entityID=' . urlencode($entityID) . '&' .
209+
'return=' . urlencode($return) . '&' .
210+
'returnIDParam=' . urlencode($returnIDParam);
211+
212+
return $url;
213+
}
214+
200215

201216
}

lib/DiscoTemplate.php

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,12 @@ public function getContinueUrl($idpEntityId) {
103103
return sspmod_perun_Disco::buildContinueUrl($this->data['entityID'], $this->data['return'], $this->data['returnIDParam'], $idpEntityId);
104104
}
105105

106+
/**
107+
* @return string url where user should be redirected when he choose idp
108+
*/
109+
public function getContinueUrlWithoutIdPEntityId() {
110+
return sspmod_perun_Disco::buildContinueUrlWithoutIdPEntityId($this->data['entityID'], $this->data['return'], $this->data['returnIDParam']);
111+
}
106112

107113
/**
108114
* @param array $metadata

0 commit comments

Comments
 (0)