It would be helpful to have exportables for input formats, seeing as how they are set numerically. This ties into #624018: Exportables and Features support for WYSIWYG 7.x since any exported WYSIWYG settings need to relate to a given input filter.

Comments

jazzslider’s picture

Spent some time on this this morning; really, it wouldn't be particularly difficult to add apart from the fact that the filter module doesn't expose its saving and deleting logic as independent functions …rather, they've put the queries directly into a couple of admin form_submit functions where it can't easily be reused.

Possible solutions?

1. Try to get the core filter module patched such that saving and deleting are each encapsulated in their own reusable functions.
2. Add such functions to exportables instead.

#1 is obviously the better solution, but probably not possible for Drupal 6 at this point since it's core functionality. #2 would work, but it's pretty hacky.

Any thoughts?

Thanks!
Adam

jazzslider’s picture

Actually, on further review, it looks like the features module already includes a foundation for exporting input formats, but it doesn't look like it's quite ready yet.

One thing worth noting, however, is that the features module's own implementation of this uses the filter_formats.name field as a machine-readable name, which seems to work fine given that that field is unique. As a result, given that input formats already have machine-readable names (more or less), I'm not sure that exportables is the best place to do this particular integration…would be better to try and find out why the features module's implementation isn't ready yet, and get it taken care of there.

This is also under consideration in the Better Formats module via #616496: Features integration …again, though, I'd personally rather see the features module handle this directly, since it looks like they've already done most of the necessary work.

Comments?

rickvug’s picture

Issue tags: +CTools exportables

In #643566: Text formats yhahn (Features maintainer) states that input filters are a "won't fix" so I don't think that this will happen in Features itself. I'll update that issue asking for some clarification as Features does have some input code to use. In the better formats thread (#616496: Features integration) catch states that the "real problems are how to deal with numeric / arbitrary user roles and format ids". Based on the module description, Exportables seems to be the right place to provide machine names to get around arbitrary role and format ids. Better Formats and WYSIWYG could then build off of what Exportables provides.

Does this sound like the right way forward?

Cyberwolf’s picture

Subscribing.

pcambra’s picture

suscribe

KarenS’s picture

There is a module for that now: http://drupal.org/project/input_formats, I haven't tried it but it looks like it should work.

dagmar’s picture

Status: Active » Fixed

Input Formats now uses the API of exportables, Ctools and strongarm to achieve this task.

Status: Fixed » Closed (fixed)
Issue tags: -CTools exportables

Automatically closed -- issue fixed for 2 weeks with no activity.