Révision f2fc85df
Ajouté par Assos Assos il y a presque 7 ans
drupal7/sites/all/modules/media_ckeditor/media_ckeditor.module | ||
---|---|---|
81 | 81 |
'audio', |
82 | 82 |
'image', |
83 | 83 |
'video', |
84 |
'document' |
|
84 |
'document',
|
|
85 | 85 |
)); |
86 | 86 |
} |
87 | 87 |
} |
... | ... | |
110 | 110 |
function media_ckeditor_pre_render_media($element) { |
111 | 111 |
// If the media widget has been configured to have an Insert button, we'll |
112 | 112 |
// communicate that information through javascript settings. |
113 |
$instance = field_info_instance($element['#entity_type'], $element['#field_name'], $element['#bundle']); |
|
113 |
if (!isset($element['#entity_type']) && !isset($element['#field_name']) && !isset($element['#bundle'])) { |
|
114 |
$instance = FALSE; |
|
115 |
} |
|
116 |
else { |
|
117 |
$instance = field_info_instance($element['#entity_type'], $element['#field_name'], $element['#bundle']); |
|
118 |
} |
|
114 | 119 |
if (!empty($instance['settings']['wysiwyg_insert'])) { |
115 | 120 |
$element['#attached']['js'][] = array( |
116 | 121 |
'type' => 'setting', |
Formats disponibles : Unified diff
Weekly update of contrib modules