summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--modules/node.module12
-rw-r--r--modules/node/node.module12
2 files changed, 24 insertions, 0 deletions
diff --git a/modules/node.module b/modules/node.module
index 117e2e8a8..3d3f6bf8a 100644
--- a/modules/node.module
+++ b/modules/node.module
@@ -209,6 +209,18 @@ function node_teaser($body) {
return substr($body, 0, $length + 1);
}
+ if ($length = strpos($body, '。', $size)) {
+ return substr($body, 0, $length + 1);
+ }
+
+ if ($length = strpos($body, '、', $size)) {
+ return substr($body, 0, $length + 1);
+ }
+
+ if ($length = strpos($body, '؟ ', $size)) {
+ return substr($body, 0, $length + 1);
+ }
+
/*
** Nevermind, we split it the hard way ...
*/
diff --git a/modules/node/node.module b/modules/node/node.module
index 117e2e8a8..3d3f6bf8a 100644
--- a/modules/node/node.module
+++ b/modules/node/node.module
@@ -209,6 +209,18 @@ function node_teaser($body) {
return substr($body, 0, $length + 1);
}
+ if ($length = strpos($body, '。', $size)) {
+ return substr($body, 0, $length + 1);
+ }
+
+ if ($length = strpos($body, '、', $size)) {
+ return substr($body, 0, $length + 1);
+ }
+
+ if ($length = strpos($body, '؟ ', $size)) {
+ return substr($body, 0, $length + 1);
+ }
+
/*
** Nevermind, we split it the hard way ...
*/