[geeklog-hg] geeklog: Merged with HEAD
geeklog-cvs at lists.geeklog.net
geeklog-cvs at lists.geeklog.net
Tue Jan 14 08:18:01 EST 2014
changeset 9428:1d7563f167ab
url: http://project.geeklog.net/cgi-bin/hgwebdir.cgi/geeklog/rev/1d7563f167ab
user: Kenji ITO <mystralkk at gmail.com>
date: Tue Jan 14 22:17:02 2014 +0900
description:
Merged with HEAD
diffstat:
public_html/admin/auth.inc.php | 2 +-
public_html/admin/install/bigdump.php | 2 +-
public_html/admin/install/lib-install.php | 18 ++++++++++++++++++
public_html/lib-common.php | 21 +++++++++++++++------
public_html/webservices/atom/index.php | 2 +-
5 files changed, 36 insertions(+), 9 deletions(-)
diffs (95 lines):
diff -r 937f11e49ef6 -r 1d7563f167ab public_html/admin/auth.inc.php
--- a/public_html/admin/auth.inc.php Mon Jan 13 09:17:11 2014 +0900
+++ b/public_html/admin/auth.inc.php Tue Jan 14 22:17:02 2014 +0900
@@ -39,7 +39,7 @@
// MAIN
COM_clearSpeedlimit($_CONF['login_speedlimit'], 'login');
if (COM_checkSpeedlimit('login', $_CONF['login_attempts']) > 0) {
- COM_displayMessageAndAbort($LANG04[112], '', 403, 'Access denied');
+ COM_displayMessageAndAbort(82, '', 403, 'Access denied');
}
$uid = '';
diff -r 937f11e49ef6 -r 1d7563f167ab public_html/admin/install/bigdump.php
--- a/public_html/admin/install/bigdump.php Mon Jan 13 09:17:11 2014 +0900
+++ b/public_html/admin/install/bigdump.php Tue Jan 14 22:17:02 2014 +0900
@@ -268,7 +268,7 @@
// Execute query if end of query detected (; as last character) AND NOT in parents
if (preg_match("/;$/",trim($dumpline)) && !$inparents) {
if (!TESTMODE && !mysql_query(trim($query), $dbconnection)) {
- echo INST_getAlertMsg($LANG_BIGDUMP[17] . $linenumber . ': ' . trim($dumpline) . '.<br ' . XHTML . '>' . $LANG_BIGDUMP[18] . trim(COM_nl2br(htmlentities($query))) . '<br ' . XHTML . '>' . $LANG_BIGDUMP[19] . mysql_error());
+ echo INST_getAlertMsg($LANG_BIGDUMP[17] . $linenumber . ': ' . trim($dumpline) . '.<br ' . XHTML . '>' . $LANG_BIGDUMP[18] . trim(INST_nl2br(htmlentities($query))) . '<br ' . XHTML . '>' . $LANG_BIGDUMP[19] . mysql_error());
$error=true;
break;
}
diff -r 937f11e49ef6 -r 1d7563f167ab public_html/admin/install/lib-install.php
--- a/public_html/admin/install/lib-install.php Mon Jan 13 09:17:11 2014 +0900
+++ b/public_html/admin/install/lib-install.php Tue Jan 14 22:17:02 2014 +0900
@@ -1438,4 +1438,22 @@
return $permError;
}
+/**
+ * Replaces all newlines in a string with <br> or <br />,
+ * depending on the detected setting. Ported from "lib-common.php"
+ *
+ * @param string $string The string to modify
+ * @return string The modified string
+ */
+function INST_nl2br($string)
+{
+ if (! defined('XHTML')) {
+ define('XHTML', '');
+ }
+
+ $replace = '<br' . XHTML . '>';
+ $find = array("\r\n", "\n\r", "\r", "\n");
+ return str_replace($find, $replace, $string);
+}
+
?>
diff -r 937f11e49ef6 -r 1d7563f167ab public_html/lib-common.php
--- a/public_html/lib-common.php Mon Jan 13 09:17:11 2014 +0900
+++ b/public_html/lib-common.php Tue Jan 14 22:17:02 2014 +0900
@@ -7001,14 +7001,23 @@
function COM_makeClickableLinksCallback( $http, $link )
{
global $_CONF;
-
+
+ // When $link ends with a period, the period will be moved out of the link
+ // text (bug #0001675)
+ if (substr($link, -1) === '.') {
+ $link = substr($link, 0, -1);
+ $end = '.';
+ } else {
+ $end = '';
+ }
+
if ($_CONF['linktext_maxlen'] > 0) {
- $text = COM_truncate( $link, $_CONF['linktext_maxlen'], '...', '10' );
+ $text = COM_truncate($link, $_CONF['linktext_maxlen'], '...', 10);
} else {
- $text = $link;
- }
-
- return "<a href=\"$http$link\">$text</a>";
+ $text = $link;
+ }
+
+ return "<a href=\"{$http}{$link}\">{$text}</a>{$end}";
}
/**
diff -r 937f11e49ef6 -r 1d7563f167ab public_html/webservices/atom/index.php
--- a/public_html/webservices/atom/index.php Mon Jan 13 09:17:11 2014 +0900
+++ b/public_html/webservices/atom/index.php Tue Jan 14 22:17:02 2014 +0900
@@ -35,7 +35,7 @@
/* Check if WS component is enabled */
if ($_CONF['disable_webservices']) {
/* Pretend the WS doesn't exist */
- COM_displayMessageAndAbort($LANG_404[3], '', 404, 'Not Found');
+ COM_displayMessageAndAbort(79, '', 404, 'Not Found');
}
// Set the default content type
More information about the geeklog-cvs
mailing list