cvs: php-news-web / common.inc
| From: | Wez Furlong | Date: | Wed, 11 Sep 2002 11:15:39 +0000 |
| Subject: | cvs: php-news-web / common.inc | ||
| Groups: | php.mirrors | ||
| Request: | Send a blank email to php-mirrors+get-12415@lists.php.net to get a copy of this message | ||
wez Wed Sep 11 07:15:39 2002 EDT
Modified files:
/php-news-web common.inc
Log:
whitespace (and modelines to stick to coding conventions...)
Index: php-news-web/common.inc
diff -u php-news-web/common.inc:1.15 php-news-web/common.inc:1.16
--- php-news-web/common.inc:1.15 Wed Sep 11 06:04:52 2002
+++ php-news-web/common.inc Wed Sep 11 07:15:38 2002
@@ -1,4 +1,4 @@
-<?php /* vim: set ft=php : */
+<?php /* vim:set ft=php:ts=2:sw=2:et */
function head($title="php news") {
header("Content-type: text/html; charset=utf-8");
@@ -67,22 +67,22 @@
}
if (function_exists("mb_convert_encoding")) {
- function to_utf8($str, $charset)
- {
- return mb_convert_encoding($str, "utf-8", strlen($charset) ? $charset :
"iso-8859-1");
- }
+ function to_utf8($str, $charset)
+ {
+ return mb_convert_encoding($str, "utf-8", strlen($charset) ? $charset :
"iso-8859-1");
+ }
} else if (function_exists("recode_string")) {
- function to_utf8($str, $charset)
- {
+ function to_utf8($str, $charset)
+ {
if (strlen($charset) == 0)
$charset = "iso-8859-1";
- return recode_string("$charset..utf-8", $str);
- }
+ return recode_string("$charset..utf-8", $str);
+ }
} else if (function_exists("iconv")) {
- function to_utf8($str, $charset)
- {
- return iconv(strlen($charset) ? $charset : "iso-8859-1", "utf-8", $str);
- }
+ function to_utf8($str, $charset)
+ {
+ return iconv(strlen($charset) ? $charset : "iso-8859-1", "utf-8", $str);
+ }
}
function decode_header($charset,$encoding,$text) {