aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMax Kostikov <max@kostikov.co>2020-02-13 08:33:20 +0100
committerMax Kostikov <max@kostikov.co>2020-02-13 08:33:20 +0100
commit1b216e60199b9426930f37c5b67eec8904f77445 (patch)
tree366f749cdfaef3f3ad44de33e29a62023dc8d183
parent9f029336cab322e04d29af842ba0a666189c8683 (diff)
parent83256c9ccd2cf3cff74ac10c0ea8e46cb9f77aca (diff)
downloadvolse-hubzilla-1b216e60199b9426930f37c5b67eec8904f77445.tar.gz
volse-hubzilla-1b216e60199b9426930f37c5b67eec8904f77445.tar.bz2
volse-hubzilla-1b216e60199b9426930f37c5b67eec8904f77445.zip
Merge branch 'dev' into 'dev'
issue with multi-line poll elements See merge request hubzilla/core!1831
-rw-r--r--Zotlabs/Module/Item.php8
1 files changed, 4 insertions, 4 deletions
diff --git a/Zotlabs/Module/Item.php b/Zotlabs/Module/Item.php
index dbcbe5d22..4b866eace 100644
--- a/Zotlabs/Module/Item.php
+++ b/Zotlabs/Module/Item.php
@@ -1414,7 +1414,7 @@ class Item extends Controller {
$matches = null;
$obj['type'] = 'Question';
- if (preg_match_all('/\[answer\](.*?)\[\/answer\]/',$body,$matches,PREG_SET_ORDER)) {
+ if (preg_match_all('/\[answer\](.*?)\[\/answer\]/ism',$body,$matches,PREG_SET_ORDER)) {
foreach ($matches as $match) {
$ptr[] = [ 'name' => $match[1], 'type' => 'Note', 'replies' => [ 'type' => 'Collection', 'totalItems' => 0 ]];
$body = str_replace('[answer]' . $match[1] . '[/answer]', EMPTY_STR, $body);
@@ -1423,7 +1423,7 @@ class Item extends Controller {
$matches = null;
- if (preg_match('/\[question\](.*?)\[\/question\]/',$body,$matches)) {
+ if (preg_match('/\[question\](.*?)\[\/question\]/ism',$body,$matches)) {
$obj['content'] = bbcode($matches[1]);
$body = str_replace('[question]' . $matches[1] . '[/question]', $matches[1], $body);
$obj['oneOf'] = $ptr;
@@ -1431,7 +1431,7 @@ class Item extends Controller {
$matches = null;
- if (preg_match('/\[question=multiple\](.*?)\[\/question\]/',$body,$matches)) {
+ if (preg_match('/\[question=multiple\](.*?)\[\/question\]/ism',$body,$matches)) {
$obj['content'] = bbcode($matches[1]);
$body = str_replace('[question=multiple]' . $matches[1] . '[/question]', $matches[1], $body);
$obj['anyOf'] = $ptr;
@@ -1439,7 +1439,7 @@ class Item extends Controller {
$matches = null;
- if (preg_match('/\[ends\](.*?)\[\/ends\]/',$body,$matches)) {
+ if (preg_match('/\[ends\](.*?)\[\/ends\]/ism',$body,$matches)) {
$obj['endTime'] = datetime_convert(date_default_timezone_get(),'UTC', $matches[1],ATOM_TIME);
$body = str_replace('[ends]' . $matches[1] . '[/ends]', EMPTY_STR, $body);
}