Display Suite Code is normally not used for content, so it shouldn't be used by devel_generate, mostly because it doesn't format the p and br tags.

CommentFileSizeAuthor
#1 no-ds_code-1964340-1.patch532 bytesold_toby
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

old_toby’s picture

Status: Active » Needs review
FileSize
532 bytes

And here's the patch:

rodrigoaguilera’s picture

I tested the generation of content with the display suite text filter activated and I didn't see much problem in the nodes with that filter.
If there's a ds code filter it shouldn't be disabled in the code.

I think that a option to select text filters for text fields must be given so users are aware of what text are generating.

salvis’s picture

Status: Needs review » Needs work

It's odd that filter_formats() would return a format that we're not supposed to use. If that's really how it should work, then we need a more general way for third-party modules to tell us about the unusual situation.

(The patch does not follow the http://drupal.org/coding-standards.)

old_toby’s picture

The problem is that the ds_code filter is not intended to use in nodes, just for the ds custom fields. It doesn't use any other filters like auto break tags. So if nodes are created with the ds_code text filter, it can break your layout.

I don't know if there are more modules with text filters which shouldn't be used for content. If it should be solved more generally, the settings page should probably have a list of format filters to exclude.

salvis’s picture

Project: Devel » Display Suite
Component: devel_generate » Code

I'm not sure how to proceed here. DS is breaking core by adding a filter format that cannot be used as a filter format. I tend to think that DS needs to fix this, maybe develop a core patch that lets them do what they need without breaking core assumptions, if that's what it takes.

Let's ask for their view on this.

aspilicious’s picture

Issue summary: View changes
Status: Needs work » Closed (won't fix)

D7 is to "old" to change this. I removed the filter in D8...