Update of /cvsroot/php-blog/serendipity
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv5038
Modified Files:
NEWS serendipity_sidebar_items.php
Log Message:
add https-option to sidebar plugin. RFE #996320
Index: serendipity_sidebar_items.php
===================================================================
RCS file: /cvsroot/php-blog/serendipity/serendipity_sidebar_items.php,v
retrieving revision 1.74
retrieving revision 1.75
diff -u -d -r1.74 -r1.75
--- serendipity_sidebar_items.php 19 Jul 2004 11:46:17 -0000 1.74
+++ serendipity_sidebar_items.php 23 Jul 2004 09:24:19 -0000 1.75
@@ -460,6 +460,7 @@
{
$propbag->add('name', SUPERUSER);
$propbag->add('description', ALLOWS_YOU_BLAHBLAH);
+ $propbag->add('configuration', array('https'));
}
function generate_content(&$title)
@@ -467,7 +468,31 @@
global $serendipity;
$title = SUPERUSER . ':';
- echo "<a href=\"{$serendipity['serendipityHTTPPath']}" . ($serendipity['rewrite'] == 'none' ? 'serendipity_entries.php?/' : '') . PATH_ENTRIES."\" title=\"$title\">\$ su -</a>";
+ if ($this->get_config('https', 'false') == 'true') {
+ $base = str_replace('http://', 'https://', $serendipity['baseURL']);
+ } else {
+ $base = $serendipity['serendipityHTTPPath'];
+ }
+
+ $link = $base . ($serendipity['rewrite'] == 'none' ? 'serendipity_entries.php?/' : '') . PATH_ENTRIES;
+
+ echo '<a href="' . $link . '" title="' . $title . '">$ su -</a>';
+ }
+
+ function introspect_config_item($name, &$propbag)
+ {
+ switch($name) {
+ case 'https':
+ $propbag->add('type', 'boolean');
+ $propbag->add('name', PLUGIN_SUPERUSER_HTTPS);
+ $propbag->add('description', PLUGIN_SUPERUSER_HTTPS_DESC);
+ $propbag->add('default', 'false');
+ break;
+
+ default:
+ return false;
+ }
+ return true;
}
}
Index: NEWS
===================================================================
RCS file: /cvsroot/php-blog/serendipity/NEWS,v
retrieving revision 1.185
retrieving revision 1.186
diff -u -d -r1.185 -r1.186
--- NEWS 23 Jul 2004 04:19:06 -0000 1.185
+++ NEWS 23 Jul 2004 09:24:19 -0000 1.186
@@ -3,6 +3,9 @@
Version 0.7 ()
------------------------------------------------------------------------
+ * RFE #996320: Added https-option to login sidebar-plugin
+ (garvinhicking)
+
* Removed full plaintext URI from trackback section and replaced it
with a link to that URI (tomsommer, garvinhicking)
|