Hi,
I'm working with a Drupal 5.11 and with the #translatable module 5.x-1.3. I'm happy with this module, but I'm having some troubles when translating Webform pages (from the Webform module).
The _translatable_filter_form(...) function doesn't seem to handle this content type correctly even so it is based on the form API.
What happens :
- I get PHP errors on preg_match() in the drupal_validate_utf8(...) function which is in "includes/bootstrap.inc". It recieves an array in stead of a string.
What the array contains :
$text = array (
'date' => 'date',
'email' => 'email',
'file' => 'fichier',
'fieldset' => 'fieldset',
'grid' => 'grid',
'hidden' => 'hidden',
'markup' => 'markup',
'pagebreak' => 'pagebreak',
'select' => 'select',
'textarea' => 'textarea',
'textfield' => 'textfield',
'time' => 'time',
);
after printing the debug_backtrace(), I notice that it comes from the filter module (function filter_xss()) and if I go lower in the stack, I notice that it is initiated by "translatable.module", line 333, on the call to filter_xss_admin().
My questions :
- Is this a bug or is it simply because #translatable cannot handle Webforms?
The recursive calls in the _translatable_filter_form(...) function perhaps don't go deap enough in the form values. - Did anybody have similar problems?
If yes, is there an easy solution or patch to correct this. (The code seems to be quite complecated if you don't know how the form API works).
| Comment | File | Size | Author |
|---|---|---|---|
| #1 | debug_backtrace_translatable.zip | 45.26 KB | patacra |
Comments
Comment #1
patacra commentedI forgot to attach the backtrace result.
The line numbers printed in the backtrace can be shifted, as I had to add some code to print debug infos to see what was happening.
Comment #2
sunAny updates? I've never tried to translate Webforms until now, so unfortunately, I cannot help here.
Comment #3
sunClosing this issue. As stated on the project page, there is no support in this project.