source: extensions/Google2Piwigo/admin/config.php @ 28832

Last change on this file since 28832 was 28832, checked in by mistic100, 10 years ago

fix oauth flow

File size: 911 bytes
Line 
1<?php
2defined('PICASA_WA_PATH') or die('Hacking attempt!');
3
4if (isset($_POST['save_config']))
5{
6  $conf['google2piwigo'] = array(
7    'api_key' => trim($_POST['api_key']),
8    'secret_key' => trim($_POST['secret_key']),
9    'auth_endpoint' => $conf['google2piwigo']['auth_endpoint'],
10    'token_endpoint' => $conf['google2piwigo']['token_endpoint'],
11    );
12  unset($_SESSION['gata_auth_token']);
13
14  conf_update_param('google2piwigo', serialize($conf['google2piwigo']));
15  $page['infos'][] = l10n('Information data registered in database');
16}
17
18
19$template->assign(array(
20  'google2piwigo' => $conf['google2piwigo'],
21  'PICASA_WA_HELP_CONTENT' => load_language('help_api_key.html', PICASA_WA_PATH, array('return'=>true)),
22  'PICASA_WA_CALLBACK' => get_absolute_root_url() . PICASA_WA_ADMIN . '-import',
23  ));
24
25
26$template->set_filename('picasa_web_albums', realpath(PICASA_WA_PATH . 'admin/template/config.tpl'));
Note: See TracBrowser for help on using the repository browser.