break, teaser, and php input

fax8 - February 17, 2006 - 19:38
Project:Drupal
Version:4.7.x-dev
Component:node system
Category:bug report
Priority:normal
Assigned:chx
Status:closed
Description

Creating a node with php input and editing it like below
let 'hello2' be displayed also on teasers on node listing pages.
(I had to separate minus from 'break' to let drupal.org post this)

hello
< !-- break -- >

<?php
print 'hello2';

?>

#1

chx - March 27, 2006 - 18:19
Assigned to:Anonymous» chx
Status:active» patch (reviewed & tested by the community)

[20:14] chx: what's our take with PHP node teasers?
[20:14] chx: if I have a PHP node which spits out 50K of text (just tested) then the teaser will be 50K long
[20:14] chx: not nice.
[20:14] UnConeD: chx: dries wanted to change it to support break
[20:14] UnConeD: and have it be your own fault if you make parse errors

AttachmentSize
break_php.patch1.09 KB

#2

chx - March 27, 2006 - 18:20

one hunk too more.

AttachmentSize
break_php_0.patch679 bytes

#3

Steven - March 27, 2006 - 21:36
Status:patch (reviewed & tested by the community)» patch (code needs work)

Actually, what we /should/ do for PHP code is to use the break tag if it's there, but do no automatic splitting otherwise (because that is surely to result in problems).

#4

JohnAlbin - December 4, 2006 - 00:04
Version:x.y.z» 5.x-dev

Taking Steven's advice, we get... (for 4.7)

AttachmentSize
break_php_1.patch893 bytes

#5

JohnAlbin - December 4, 2006 - 00:05

And... (for 5.x-dev)

AttachmentSize
break_php_2.patch893 bytes

#6

JohnAlbin - December 4, 2006 - 03:23
Status:patch (code needs work)» patch (code needs review)

New patch for 4.7.x-dev undoes (now unneeded) code added in http://drupal.org/node/80989

AttachmentSize
break_php_3.patch1.08 KB

#7

JohnAlbin - December 4, 2006 - 03:24

New patch for 5.x-dev undoes (now unneeded) code added in http://drupal.org/node/80989

AttachmentSize
break_php_4.patch1.11 KB

#8

Steven - December 12, 2006 - 10:05
Version:5.x-dev» 4.7.x-dev
Status:patch (code needs review)» patch (reviewed & tested by the community)

Committed to HEAD, works as advertised. Good job.

#9

killes@www.drop.org - December 12, 2006 - 12:49
Status:patch (reviewed & tested by the community)» fixed

applied

#10

Anonymous - December 26, 2006 - 13:00
Status:fixed» closed
 
 

Drupal is a registered trademark of Dries Buytaert.