- Поисковые системы
- Практика оптимизации
- Трафик для сайтов
- Монетизация сайтов
- Сайтостроение
- Социальный Маркетинг
- Общение профессионалов
- Биржа и продажа
- Финансовые объявления
- Работа на постоянной основе
- Сайты - покупка, продажа
- Соцсети: страницы, группы, приложения
- Сайты без доменов
- Трафик, тизерная и баннерная реклама
- Продажа, оценка, регистрация доменов
- Ссылки - обмен, покупка, продажа
- Программы и скрипты
- Размещение статей
- Инфопродукты
- Прочие цифровые товары
- Работа и услуги для вебмастера
- Оптимизация, продвижение и аудит
- Ведение рекламных кампаний
- Услуги в области SMM
- Программирование
- Администрирование серверов и сайтов
- Прокси, ВПН, анонимайзеры, IP
- Платное обучение, вебинары
- Регистрация в каталогах
- Копирайтинг, переводы
- Дизайн
- Usability: консультации и аудит
- Изготовление сайтов
- Наполнение сайтов
- Прочие услуги
- Не про работу
Авторизуйтесь или зарегистрируйтесь, чтобы оставить комментарий
Подскажите как увеличить высоту поля ввода подробной части новости? Редактор tinymce - height стоит 310 px. Но найти где это выставляется все никак не могу. По поиску 310 не помогло - там видимо что-то суммируется..
Вот картинка. хз почему стоит 310px, а поле намного больше - но это именно его параметры. Пиксели какие-то великанские видимо... =)
[ATTACH]101354[/ATTACH]
height для WYSIWYG изменяется в файлах .php в папке /engine/editor/
Ну в fullsite.php есть параметры:
но это ж только если простой BBCODES редактор стоит, а не wysiwyg.
P.s. мне нужно изменить размер поля хотя бы при добавлении новости с сайта.
---------- Post added at 22:35 ---------- Previous post was at 22:17 ----------
сорри. нашел. shortsite.php Спасибо!
---------- Post added at 22:48 ---------- Previous post was at 22:35 ----------
Тогда подскажите как разделить параметры. В этом файле такой код:
т.е. height: 700 используется и для #short_story и для #full_story. А как можно задать разные величины для них?
Т.к. для #full_story высота нормальная, а для #short_story многовато... в синтаксисе яваскриптов не разбираюсь...
Kel_Kimpbell, попробуйте внутри
$(function(){...}
переназначить высоту персонально для #short_story после завершения назначения параметров совместно для #short_story и #full_story
$('#short_story,#full_story').tiny...
но до закрывающей фигурной скобки в $(function(){...} (Вы не привели эту часть кода полностью, поэтому сказать точнее в каком месте не могу)
вставив код:
$('#short_story').tinymce.height="400";
Я вот так сделал. После этого:
$(function(){
' + ed.selection.getContent() + ' ');
$('#short_story').tinymce({
script_url : 'engine/editor/jscripts/tiny_mce/tiny_mce.js',
theme : "advanced",
skin : "cirkuit",
language : "{$lang['wysiwyg_language']}",
width : "98%",
height : "400",
plugins : "advhr,advimage,emotions,inlinepopups,insertdatetime,media,searchreplace,print,contextmenu,paste,fullscreen,nonbreaking",
relative_urls : false,
convert_urls : false,
media_strict : false,
dialog_type : 'window',
extended_valid_elements : "noindex,div[align|class|style|id|title]",
custom_elements : 'noindex',
paste_auto_cleanup_on_paste : false,
paste_text_use_dialog: true,
// Theme options
theme_advanced_buttons1 : "cut,copy,paste,pastetext,pasteword,|,search,|,outdent,indent,|,undo,redo,|,dle_upload,image,media,dle_mp,dle_tube,dle_mp3,emotions,|,dle_break,dle_page",
theme_advanced_buttons2 : "fontselect,fontsizeselect,|,sub,sup,|,charmap,advhr,|,insertdate,inserttime,|,nonbreaking,dle_quote,dle_code,dle_hide,|,visualaid",
theme_advanced_buttons3 : "bold,italic,underline,strikethrough,|,justifyleft,justifycenter,justifyright,justifyfull,|,bullist,numlist,dle_spoiler,|,link,dle_leech,|,forecolor,backcolor,|,removeformat,cleanup,|,code",
theme_advanced_toolbar_location : "top",
theme_advanced_toolbar_align : "left",
theme_advanced_statusbar_location : "bottom",
plugin_insertdate_dateFormat : "%d-%m-%Y",
plugin_insertdate_timeFormat : "%H:%M:%S",
// Example content CSS (should be your site CSS)
content_css : "{$config['http_home_url']}engine/editor/css/content.css",
setup : function(ed) {
// Add a custom button
ed.addButton('dle_quote', {
title : '{$lang['bb_t_quote']}',
image : '{$config['http_home_url']}engine/editor/jscripts/tiny_mce/themes/advanced/img/dle_quote.gif',
onclick : function() {
// Add you own code to execute something on click
ed.execCommand('mceReplaceContent',false,'
}
});
ed.addButton('dle_hide', {
title : '{$lang['bb_t_hide']}',
image : '{$config['http_home_url']}engine/editor/jscripts/tiny_mce/themes/advanced/img/dle_hide.gif',
onclick : function() {
// Add you own code to execute something on click
ed.execCommand('mceReplaceContent',false,'[hide]' + ed.selection.getContent() + '[/hide]');
}
});
ed.addButton('dle_code', {
title : '{$lang['bb_t_code']}',
image : '{$config['http_home_url']}engine/editor/jscripts/tiny_mce/themes/advanced/img/dle_code.gif',
onclick : function() {
// Add you own code to execute something on click
ed.execCommand('mceReplaceContent',false,'');
}
});
ed.addButton('dle_spoiler', {
title : '',
image : '{$config['http_home_url']}engine/editor/jscripts/tiny_mce/themes/advanced/img/dle_spoiler.gif',
onclick : function() {
// Add you own code to execute something on click
ed.execCommand('mceReplaceContent',false,'[spoiler]' + ed.selection.getContent() + '[/spoiler]');
}
});
ed.addButton('dle_break', {
title : '{$lang['bb_t_br']}',
image : '{$config['http_home_url']}engine/editor/jscripts/tiny_mce/themes/advanced/img/dle_break.gif',
onclick : function() {
// Add you own code to execute something on click
ed.execCommand('mceInsertContent',false,'{PAGEBREAK}');
}
});
ed.addButton('dle_page', {
title : '{$lang['bb_t_p']}',
image : '{$config['http_home_url']}engine/editor/jscripts/tiny_mce/themes/advanced/img/dle_page.gif',
onclick : function() {
ed.execCommand('mceReplaceContent',false,"[page=1]{\$selection}[/page]");
}
});
ed.addButton('dle_leech', {
title : '{$lang['bb_t_leech']}',
image : '{$config['http_home_url']}engine/editor/jscripts/tiny_mce/themes/advanced/img/dle_leech.gif',
onclick : function() {
ed.execCommand('mceReplaceContent',false,"[leech=http://]{\$selection}[/leech]");
}
});
ed.addButton('dle_mp', {
title : '{$lang['bb_t_video']} (BB Codes)',
image : '{$config['http_home_url']}engine/editor/jscripts/tiny_mce/themes/advanced/img/dle_mp.gif',
onclick : function() {
ed.execCommand('mceInsertContent',false,"[video=http://]");
}
});
ed.addButton('dle_tube', {
title : '{$lang['bb_t_yvideo']} (BB Codes)',
image : '{$config['http_home_url']}engine/editor/jscripts/tiny_mce/themes/advanced/img/dle_tube.gif',
onclick : function() {
ed.execCommand('mceInsertContent',false,"[media=http://]");
}
});
ed.addButton('dle_upload', {
title : '{$lang['bb_t_upload']}',
image : '{$config['http_home_url']}engine/editor/jscripts/tiny_mce/themes/advanced/img/dle_upload.gif',
onclick : function() {
window.open('{$config['http_home_url']}engine/images.php?area=short_story&wysiwyg=yes&add_id={$id}', '_Addimage', 'toolbar=0,location=0,status=0, left=0, top=0, menubar=0,scrollbars=yes,resizable=0,width=640,height=550');
}
});
ed.addButton('dle_mp3', {
title : '',
image : '{$config['http_home_url']}engine/editor/jscripts/tiny_mce/themes/advanced/img/dle_mp3.gif',
onclick : function() {
ed.execCommand('mceInsertContent',false,"[audio=http://]");
}
});
}
});
Вставил это:
$('#full_story').tinymce({
' + ed.selection.getContent() + ' ');
script_url : 'engine/editor/jscripts/tiny_mce/tiny_mce.js',
theme : "advanced",
skin : "cirkuit",
language : "{$lang['wysiwyg_language']}",
width : "98%",
height : "700",
plugins : "advhr,advimage,emotions,inlinepopups,insertdatetime,media,searchreplace,print,contextmenu,paste,fullscreen,nonbreaking",
relative_urls : false,
convert_urls : false,
media_strict : false,
dialog_type : 'window',
extended_valid_elements : "noindex,div[align|class|style|id|title]",
custom_elements : 'noindex',
paste_auto_cleanup_on_paste : false,
paste_text_use_dialog: true,
// Theme options
theme_advanced_buttons1 : "cut,copy,paste,pastetext,pasteword,|,search,|,outdent,indent,|,undo,redo,|,dle_upload,image,media,dle_mp,dle_tube,dle_mp3,emotions,|,dle_break,dle_page",
theme_advanced_buttons2 : "fontselect,fontsizeselect,|,sub,sup,|,charmap,advhr,|,insertdate,inserttime,|,nonbreaking,dle_quote,dle_code,dle_hide,|,visualaid",
theme_advanced_buttons3 : "bold,italic,underline,strikethrough,|,justifyleft,justifycenter,justifyright,justifyfull,|,bullist,numlist,dle_spoiler,|,link,dle_leech,|,forecolor,backcolor,|,removeformat,cleanup,|,code",
theme_advanced_toolbar_location : "top",
theme_advanced_toolbar_align : "left",
theme_advanced_statusbar_location : "bottom",
plugin_insertdate_dateFormat : "%d-%m-%Y",
plugin_insertdate_timeFormat : "%H:%M:%S",
// Example content CSS (should be your site CSS)
content_css : "{$config['http_home_url']}engine/editor/css/content.css",
setup : function(ed) {
// Add a custom button
ed.addButton('dle_quote', {
title : '{$lang['bb_t_quote']}',
image : '{$config['http_home_url']}engine/editor/jscripts/tiny_mce/themes/advanced/img/dle_quote.gif',
onclick : function() {
// Add you own code to execute something on click
ed.execCommand('mceReplaceContent',false,'
}
});
ed.addButton('dle_hide', {
title : '{$lang['bb_t_hide']}',
image : '{$config['http_home_url']}engine/editor/jscripts/tiny_mce/themes/advanced/img/dle_hide.gif',
onclick : function() {
// Add you own code to execute something on click
ed.execCommand('mceReplaceContent',false,'[hide]' + ed.selection.getContent() + '[/hide]');
}
});
ed.addButton('dle_code', {
title : '{$lang['bb_t_code']}',
image : '{$config['http_home_url']}engine/editor/jscripts/tiny_mce/themes/advanced/img/dle_code.gif',
onclick : function() {
// Add you own code to execute something on click
ed.execCommand('mceReplaceContent',false,'');
}
});
ed.addButton('dle_spoiler', {
title : '',
image : '{$config['http_home_url']}engine/editor/jscripts/tiny_mce/themes/advanced/img/dle_spoiler.gif',
onclick : function() {
// Add you own code to execute something on click
ed.execCommand('mceReplaceContent',false,'[spoiler]' + ed.selection.getContent() + '[/spoiler]');
}
});
ed.addButton('dle_break', {
title : '{$lang['bb_t_br']}',
image : '{$config['http_home_url']}engine/editor/jscripts/tiny_mce/themes/advanced/img/dle_break.gif',
onclick : function() {
// Add you own code to execute something on click
ed.execCommand('mceInsertContent',false,'{PAGEBREAK}');
}
});
ed.addButton('dle_page', {
title : '{$lang['bb_t_p']}',
image : '{$config['http_home_url']}engine/editor/jscripts/tiny_mce/themes/advanced/img/dle_page.gif',
onclick : function() {
ed.execCommand('mceReplaceContent',false,"[page=1]{\$selection}[/page]");
}
});
ed.addButton('dle_leech', {
title : '{$lang['bb_t_leech']}',
image : '{$config['http_home_url']}engine/editor/jscripts/tiny_mce/themes/advanced/img/dle_leech.gif',
onclick : function() {
ed.execCommand('mceReplaceContent',false,"[leech=http://]{\$selection}[/leech]");
}
});
ed.addButton('dle_mp', {
title : '{$lang['bb_t_video']} (BB Codes)',
image : '{$config['http_home_url']}engine/editor/jscripts/tiny_mce/themes/advanced/img/dle_mp.gif',
onclick : function() {
ed.execCommand('mceInsertContent',false,"[video=http://]");
}
});
ed.addButton('dle_tube', {
title : '{$lang['bb_t_yvideo']} (BB Codes)',
image : '{$config['http_home_url']}engine/editor/jscripts/tiny_mce/themes/advanced/img/dle_tube.gif',
onclick : function() {
ed.execCommand('mceInsertContent',false,"[media=http://]");
}
});
ed.addButton('dle_upload', {
title : '{$lang['bb_t_upload']}',
image : '{$config['http_home_url']}engine/editor/jscripts/tiny_mce/themes/advanced/img/dle_upload.gif',
onclick : function() {
window.open('{$config['http_home_url']}engine/images.php?area=short_story&wysiwyg=yes&add_id={$id}', '_Addimage', 'toolbar=0,location=0,status=0, left=0, top=0, menubar=0,scrollbars=yes,resizable=0,width=640,height=550');
}
});
ed.addButton('dle_mp3', {
title : '',
image : '{$config['http_home_url']}engine/editor/jscripts/tiny_mce/themes/advanced/img/dle_mp3.gif',
onclick : function() {
ed.execCommand('mceInsertContent',false,"[audio=http://]");
}
});
}
} );
$('textarea.mceEditor').tinymce({
Работает. Но насколько это правильно? Может как-то упростить.