diff options
author | Robin Appelman <icewind1991@gmail.com> | 2011-08-08 23:32:54 +0200 |
---|---|---|
committer | Robin Appelman <icewind1991@gmail.com> | 2011-08-08 23:46:52 +0200 |
commit | 7b38e5d7c73cb29a5b57bb36b9f22ce2672cb325 (patch) | |
tree | 132b282b41ab4ac2c2374b455255b8514b6b000c /settings | |
parent | 82d2c45e14e5089defef8712dafa0fe97e16f8e0 (diff) | |
download | nextcloud-server-7b38e5d7c73cb29a5b57bb36b9f22ce2672cb325.tar.gz nextcloud-server-7b38e5d7c73cb29a5b57bb36b9f22ce2672cb325.zip |
apps can now add their own forms to the Personal page
Diffstat (limited to 'settings')
-rw-r--r-- | settings/index.php | 8 | ||||
-rw-r--r-- | settings/js/main.js | 11 | ||||
-rw-r--r-- | settings/templates/index.php | 14 |
3 files changed, 8 insertions, 25 deletions
diff --git a/settings/index.php b/settings/index.php index 12f48f23838..60cfd19c3fd 100644 --- a/settings/index.php +++ b/settings/index.php @@ -29,10 +29,10 @@ $tmpl->assign('usage',OC_Helper::humanFileSize($used)); $tmpl->assign('total_space',OC_Helper::humanFileSize($total)); $tmpl->assign('usage_relative',$relative); $tmpl->assign('languages',$languages); -$tmpl->assign('hasopenid',OC_App::isEnabled( 'user_openid' )); -if(OC_App::isEnabled( 'user_openid' )){ - $identity=OC_Preferences::getValue(OC_User::getUser(),'user_openid','identity',''); - $tmpl->assign('identity',$identity); + +$forms=OC_App::getForms('personal'); +foreach($forms as $form){ + $tmpl->append('forms',$form); } $tmpl->printPage(); diff --git a/settings/js/main.js b/settings/js/main.js index e6ca30d0ce4..f6b7eeb7584 100644 --- a/settings/js/main.js +++ b/settings/js/main.js @@ -19,17 +19,6 @@ $(document).ready(function(){ return false; }); - $('#openidform').submit(function(event){ - event.preventDefault(); - var post = $( "#openidform" ).serialize(); - $.post( 'ajax/openid.php', post, function(data){ - if( data.status == "success" ){ - }else{ - alert('error while setting OpenID'); - } - }); - }); - $("#languageinput").change( function(){ // Serialize the data var post = $( "#languageinput" ).serialize(); diff --git a/settings/templates/index.php b/settings/templates/index.php index 6e68cfa148c..0b5a14626fe 100644 --- a/settings/templates/index.php +++ b/settings/templates/index.php @@ -18,16 +18,6 @@ </fieldset> </form> -<?php if($_['hasopenid']):?> - <form id="openidform"> - <fieldset> - <legend><?php echo $l->t( 'OpenID' );?></legend> - <input type="text" name='identity' id='identity' value="<?php echo $_['identity']; ?>" placeholder="OpenID for <?php echo OC_User::getUser();?>" /> - <input type="submit" value="Save" /></p> - </fieldset> - </form> -<?php endif;?> - <form id="languageform"> <fieldset> <legend><?php echo $l->t( 'Language' );?></legend> @@ -39,3 +29,7 @@ </select> </fieldset> </form> + +<?php foreach($_['forms'] as $form){ + echo $form; +};?> |