Вызов Функции
<script language="Javascript" type="text/javascript">
editAreaLoader.init({ id: "edit" // id of the textarea to transform ,start_highlight: true // if start with highlight ,allow_resize: "both" ,allow_toggle: true ,word_wrap: true ,language: "en" ,syntax: "c" ,allow_toggle: false ,load_callback: "my_load" ,save_callback: "my_save" ,toolbar: "*" ,replace_tab_by_spaces: 4 }); function toogle_editable(id) { editAreaLoader.execCommand(id, 'set_editable', !editAreaLoader.execCommand(id, 'is_editable')); } toogle_editable("edit"); </script> Не вызывается toogle_editable("edit"). А когда по событию onclick от кнопки все работает. Подскажите пожалуйста в чем проблема? |
На момент вызова в документе уже есть элемент с id «edit»?
|
Попробовал переместить вызов, но не помогло! Возможно проблема в editAreaLoader.execCommand(id, 'set_editable', !editAreaLoader.execCommand(id, 'is_editable')); Эта штука Делает недоступным для редактирования поле textarea в editarea_0_8_2.
|
Часовой пояс GMT +3, время: 10:10. |