27 $par->armor[
'MakeWellFormed_TagClosedError'] =
true;
39 if (empty($this->currentNesting) || strpos($text,
"\n\n") !==
false) {
51 if (!$token->is_whitespace || $this->_isInline($current)) {
60 $token = array($this->
_pStart());
80 $token = array($this->
_pStart(), $token);
90 } elseif (!empty($this->currentNesting) &&
91 $this->currentNesting[count($this->currentNesting) - 1]->name ==
'p') {
117 if (!empty($this->currentNesting)) {
129 substr($prev->data, -2) ===
"\n\n"
134 $token = array($this->
_pStart(), $token);
150 $token = array($this->
_pStart(), $token);
169 $token = array($this->
_pStart(), $token);
182 if (!is_array($token)) {
183 $token = array($token);
185 array_unshift($token,
new HTMLPurifier_Token_Text(
"\n\n"));
214 $raw_paragraphs = explode(
"\n\n", $data);
215 $paragraphs = array();
216 $needs_start =
false;
219 $c = count($raw_paragraphs);
226 for ($i = 0; $i < $c; $i++) {
227 $par = $raw_paragraphs[$i];
228 if (trim($par) !==
'') {
229 $paragraphs[] = $par;
252 } elseif ($i + 1 == $c) {
262 if (empty($paragraphs)) {
272 foreach ($paragraphs as $par) {
300 return isset($this->htmlDefinition->info[
'p']->child->elements[$token->name]);
343 if (strpos($current->data,
"\n\n") !==
false) {