image_attach images not displayed in 3.3 while they were in 3.1
doc2@drupalfr.org - September 2, 2008 - 13:54
| Project: | editablefields |
| Version: | 5.x-3.3 |
| Component: | Code |
| Category: | bug report |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | postponed (maintainer needs more info) |
Description
On editablefields table and list no form forms, version 3.3, attached images aren't displayed anymore, while they were in 3.1.

#1
Very odd....
Can you investigate a bit - there shouldn't be anything that makes less things work!
Cheers
Mark.
#2
Edit:
Excuse me, I forgot to say that I was using a modified version of EF 3.1. But I don't think this is the problem (skip to just after the latest code area)
Ali27 made it so that we can use javascript to fill all the fields at once. But he's not with us anymore. He added, on line 579 :
<?phpfunction editablefields_form_alter($form_id, &$form) {
// dev-value-080520 : add a link script jquery to editablefiels.js
drupal_add_js(drupal_get_path('module', 'editablefields') . '/editablefields.js');
// dev-value-080520 : add a link script jquery editablefiels.js
foreach ($form as $key=>$f) {
?>
and in the (brand_new) editablefields.js file:
// $Id $
//@file
//Code that operates auto value to copy right field , title field, day select, month select, year select
//@author ali
$(document).ready(function()
{
//moves selection if add is clicked to selected box
$('span.add_copy').click(function() {
$('textarea.copright').val(prompt("Copyright et droits d\'exploitation :",""));
});
$('span.add_titre').click(function() {
$('input.stitles').val(prompt("titre :",""));
});
$('select.oday').change(function(){
$('select.day').val($('select.oday').val());
});
$('select.omonth').change(function(){
$('select.month').val($('select.omonth').val());
});
$('select.oyear').change(function(){
$('select.year').val($('select.oyear').val());
});
});
I don't think these snippets break the code because I've just tested with clean 3.1 and 3.3 versions, and after I:
ran update.php, cleared my server and browser's cache, cleared views' cache, relogged
for both of them, the first worked and the second didn't.
Here are some screenshots:
My view with EF 3.1 :
EF and img are displayed with both form and no-form, be they list :
ef31-list_views.png or table : ef31-table_views.png
My view with EF 3.3 :
EF are displayed BUT NO IMG with both form and no-form, be they list :
ef33-list_views.png or table : ef33-table_views.png
My view with views' default views (for witnessing comparisons) :
EF aren't displayed but img still are, be they list :
views-list_view.png or table : views-table_view.png
Would you have any hint of things I should tell you in order to help? Should I use devel? Should I attach the exported view?
Best Regards,
Arsène
#3
CCK image field also does NOT displayed in EF3.3 in my Drupal 5.10.
I've discovered It depends on line 300 in the file "editablefields.module".
That line looks like:
$field['options']='default';
So I just comment this line:
// $field['options']='default';
And now cck image field is displayed as usualy.
It seems like this modification doesn't destroy any functionality of EF and as far as I know affects only uneditable fields.
So all editable fields are working.
#4
Thanks for sharing!
I won't hack since I prefer to use stable release version and being able to follow upgrades easily (v.1.1 is stable for me). What's more, it *seems* to be an easy fix to commit.
Changing to "need more info" cause one source of problem is identified and to press to know whether dropping this line can be safe or if something else is needed.