"MDL-17316, non-js file manager, support externel authentication"

This commit is contained in:
dongsheng 2009-06-11 02:54:33 +00:00
parent a0c4bc65fc
commit 5e98ab966f
3 changed files with 29 additions and 13 deletions

View file

@ -124,14 +124,16 @@ class repository_flickr extends repository {
* @param <type> $ajax
* @return <type>
*/
public function print_login($ajax = true) {
if ($ajax) {
public function print_login() {
if ($this->options['ajax']) {
$ret = array();
$popup_btn = new stdclass;
$popup_btn->type = 'popup';
$popup_btn->url = $this->flickr->auth();
$ret['login'] = array($popup_btn);
return $ret;
} else {
echo '<a target="_blank" href="'.$this->flickr->auth().'">Login</a>';
}
}