XStandard interferes with content when input filter is PHP
g011um - March 20, 2008 - 05:05
| Project: | XStandard WYSIWYG Editor |
| Version: | 6.x-1.0-beta2 |
| Component: | Code |
| Category: | feature request |
| Priority: | normal |
| Assigned: | henrrrik |
| Status: | postponed |
Jump to:
Description
I can't seem to create any PHP content in my nodes or blocks when XStandard is enabled, even when the Input Filter is PHP. I think the solution is to have the ability to turn XStandard off on demand (as suggested in another issue) or have it disabled completely when the input filter is something other Filtered HTML or Full HTML.
Any PHP code I enter gets HTML encoded, both in WYSIWYG mode (which I fully expected) or XML mode (which I thought might work).
Or am I missing something obvious? Is there a way to insert (PHP) code into XStandard and have it remain as code?

#1
I don't think it's possible to get the XStandard plugin to allow PHP code to pass through.
The ideal solution would be to disable XStandard for certain input filters. However, there's no way of knowing what input filter will be used before XStandard is inserted since the user might be able to switch between several different ones on the form page. I believe this problem of context is something that Gábor Hojtsy is looking into for a possible WYSIWYG API for Drupal 7.
A possible solution might be adding a link to the form page which could reload the form page with a GET parameter that would tell the module not to insert XStandard. I'll give it a go as soon as I have some spare time.
#2