redirect after login: organize options page

This commit is contained in:
Thomas NOËL 2014-10-29 15:23:20 +01:00
parent 706c7eef7b
commit adcce0a3ed
2 changed files with 35 additions and 27 deletions

View File

@ -515,6 +515,9 @@
<defaultidps>aHR0cHM6Ly90ZXN0LmZlZGVyYXRpb24ucmVuYXRlci5mci9pZHAvc2hpYmJvbGV0aA==</defaultidps>
<geolocations>aHR0cHM6Ly9zdGF0aWMuZGlzY29qdWljZS5vcmcvZmVlZHMvcmVuYXRlcg0KI2h0dHBzOi8vc3RhdGljLmRpc2NvanVpY2Uub3JnL2ZlZWRzL2VkdWdhaW4=</geolocations>
<geoinitialbounds>[[41.1,-5.53],[51.5,9.91]]</geoinitialbounds>
<tilesurl/>
<redirect_url>next_url</redirect_url>
<redirect_delay>5</redirect_delay>
</sp>
<whitelists>
<whitelist>

View File

@ -155,31 +155,6 @@ include("head.inc");
<?php endif; ?>
</td>
</tr>
<tr>
<td width="22%" valign="top" class="vncell"><?=gettext("After login redirect to"); ?></td>
<td width="78%" class="vtable">
<table>
<tr>
<td><input type="radio" name="redirect_url" value="next_url" <?php if($pconfig['redirect_url']=='next_url') echo "checked";?> /> user requested url</td>
</tr>
<tr><td>or</td></tr>
<tr>
<td>
<input type="radio" name="redirect_url" value="defined_redirect_url" <?php if ($pconfig['redirect_url'] && $pconfig['redirect_url']!='next_url') echo "checked";?> />
<input type="url" name="defined_redirect_url" value="<?=htmlspecialchars($pconfig['defined_redirect_url']);?>" /> <br />
<i><?=gettext("accepts variables in like in Django templates ('{{ varname }}')"); ?></i>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td width="22%" valign="top" class="vncell"><?=gettext("Redirect delay"); ?></td>
<td width="78%" class="vtable">
<input type="number" name="redirect_delay" min="0" max="60" value="<?=htmlspecialchars($pconfig['redirect_delay']);?>" /> seconds
</td>
</tr>
<tr>
<td colspan="2" class="list" height="12"></td>
</tr>
@ -219,12 +194,42 @@ include("head.inc");
</td>
</tr>
<tr>
<td valign="top" class="vncell"><?=gettext("Tiles url"); ?> </td>
<td valign="top" class="vncell"><?=gettext("Tiles URL"); ?> </td>
<td class="vtable">
<input name="tilesurl" type="text" class="formfld url" id="tilesurl" size="60" value="<?=htmlspecialchars($pconfig['tilesurl']);?>"><br>
<?php printf(gettext("URL like "));?>: <i>http://maps.yourdomain.org//map/%(z)d/%(x)d/%(y)d.png</i>
<?php printf(gettext("URL like "));?>: http://tiles.example.net/%(z)d/%(x)d/%(y)d.png
</td>
</tr>
<tr>
<td colspan="2" class="list" height="12"></td>
</tr>
<tr>
<td colspan="2" valign="top" class="listtopic"><?=gettext("User interface : Redirect after login");?></td>
</tr>
<tr>
<td width="22%" valign="top" class="vncell"><?=gettext("After login, redirect to"); ?></td>
<td width="78%" class="vtable">
<table>
<tr>
<td><input type="radio" name="redirect_url" value="next_url" <?php if($pconfig['redirect_url']=='next_url') echo "checked";?> />User requested URL</td>
</tr>
<tr>
<td>
<input type="radio" name="redirect_url" value="defined_redirect_url" <?php if ($pconfig['redirect_url'] && $pconfig['redirect_url']!='next_url') echo "checked";?> />
<input type="url" name="defined_redirect_url" value="<?=htmlspecialchars($pconfig['defined_redirect_url']);?>" placeholder="https://www.example.net/" size="50" class="formfld url" /> <br />
<?=gettext("Accepts variables, Django templates format {{ varname }}"); ?>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td width="22%" valign="top" class="vncell"><?=gettext("Redirect delay"); ?></td>
<td width="78%" class="vtable">
<input type="number" name="redirect_delay" min="0" max="60" value="<?=htmlspecialchars($pconfig['redirect_delay']);?>" /> seconds
</td>
</tr>
<tr>
<td width="22%" valign="top">&nbsp;</td>
<td width="78%">