PDA

View Full Version : تعیین اندازه فونت در tinyeditor



sara_aryanfar
دوشنبه 24 بهمن 1390, 16:23 عصر
با سلام خدمت دوستان من از tinyeditor استفاده کردم ولی گزینه تغییر اندازه فونت رو نداره از کجا باید اضافه کرد ؟

fakhravari
دوشنبه 24 بهمن 1390, 19:06 عصر
این همون ادیتور هست.
چون اسمش tinymce:متفکر:

bilim.ir
دوشنبه 24 بهمن 1390, 20:50 عصر
سلام ,دوست من
تو تابع tinyMCE.init را کجا فراخوانی میکنی در همینجا یک خاصیت داره به نام , theme_advanced_buttons1 تو این خاصیت مشخص میکنی , امکاناتی رو که از این کنترل میخوای مثال:


// Theme options
theme_advanced_buttons1: "fullscreen,code,|,cut,copy,paste,|,undo,redo,|,bol d,italic,underline,strikethrough,|,justifyleft,jus tifycenter,justifyright,justifyfull,|,bullist,numl ist,outdent,indent,|,iespell,link,unlink,sub,sup,r emoveformat,cleanup,charmap,emotions,|,formatselec t,fontselect,fontsizeselect",



همانطور که می بینی من fontsizeselect را هم اضافه کردم.
اگه کارت با همین حل نشد پیام بزار بهم , مفصل تر بهت پاسخ بدم.

sara_aryanfar
دوشنبه 24 بهمن 1390, 21:38 عصر
با تشکر این کد مربوط به ادیتور من هست
<script type="text/javascript">
tinyMCE.init({
// General options
mode: "textareas",
theme: "advanced",
plugins: "autolink,lists,spellchecker,pagebreak,style,layer, table,save,advhr,advimage,advlink,emotions,iespell ,inlinepopups,insertdatetime,preview,media,searchr eplace,print,contextmenu,paste,directionality,full screen,noneditable,visualchars,nonbreaking,xhtmlxt ras,template",

// Theme options
theme_advanced_buttons1: "bold,italic,underline,strikethrough,|,justifyleft, justifycenter,justifyright,justifyfull,|,stylesele ct,formatselect,fontselect,fontsizeselect|,ltr,rtl ,|,nonbreaking,insertimage,|,fullscreen",
theme_advanced_buttons2: "cut,copy,paste,pastetext,pasteword,|,search,replac e,|,bullist,numlist,|,outdent,indent|,undo,redo,|, preview,|,link,unlink,anchor,image,media,code,|,fo recolor,backcolor,|hr,removeformat,|,emotions",
theme_advanced_buttons3: "",
theme_advanced_buttons4: "",
theme_advanced_toolbar_location: "top",
theme_advanced_toolbar_align: "left",
theme_advanced_statusbar_location: "bottom",
theme_advanced_resizing: true,

// Skin options
skin: "o2k7",
skin_variant: "Black",

// Example content CSS (should be your site CSS)
content_css: "css/example.css",

// Drop lists for link/image/media/template dialogs
template_external_list_url: "js/template_list.js",
external_link_list_url: "js/link_list.js",
external_image_list_url: "js/image_list.js",
media_external_list_url: "js/media_list.js",

// Replace values for the template plugin
template_replace_values: {
username: "Some User",
staffid: "991234"
}
});

</script>
همانطور که می بینید فونت سایز داره اما نشون نمیده
82614

fakhravari
دوشنبه 24 بهمن 1390, 21:49 عصر
برای من که درسته.
<script type="text/javascript" src="tinymce/jscripts/tiny_mce/tiny_mce.js"></script>
<script type="text/javascript">
tinyMCE.init({
// General options
mode : "textareas",
theme : "advanced",
plugins : "autolink,lists,spellchecker,pagebreak,style,layer, table,save,advhr,advimage,advlink,emotions,iespell ,inlinepopups,insertdatetime,preview,media,searchr eplace,print,contextmenu,paste,directionality,full screen,noneditable,visualchars,nonbreaking,xhtmlxt ras,template",

// Theme options
theme_advanced_buttons1 : "save,newdocument,|,bold,italic,underline,strikethr ough,|,justifyleft,justifycenter,justifyright,just ifyfull,|,styleselect,formatselect,fontselect,font sizeselect",
theme_advanced_buttons2 : "cut,copy,paste,pastetext,pasteword,|,search,replac e,|,bullist,numlist,|,outdent,indent,blockquote,|, undo,redo,|,link,unlink,anchor,image,cleanup,help, code,|,insertdate,inserttime,preview,|,forecolor,b ackcolor",
theme_advanced_buttons3 : "tablecontrols,|,hr,removeformat,visualaid,|,sub,su p,|,charmap,emotions,iespell,media,advhr,|,print,| ,ltr,rtl,|,fullscreen",
theme_advanced_buttons4 : "insertlayer,moveforward,movebackward,absolute,|,st yleprops,spellchecker,|,cite,abbr,acronym,del,ins, attribs,|,visualchars,nonbreaking,template,blockqu ote,pagebreak,|,insertfile,insertimage",
theme_advanced_toolbar_location : "top",
theme_advanced_toolbar_align : "left",
theme_advanced_statusbar_location : "bottom",
theme_advanced_resizing : true,

// Skin options
skin : "o2k7",
skin_variant : "silver",

// Example content CSS (should be your site CSS)
content_css : "css/example.css",

// Drop lists for link/image/media/template dialogs
template_external_list_url : "js/template_list.js",
external_link_list_url : "js/link_list.js",
external_image_list_url : "js/image_list.js",
media_external_list_url : "js/media_list.js",

// Replace values for the template plugin
template_replace_values : {
username : "Some User",
staffid : "991234"
}
});
</script>

sara_aryanfar
دوشنبه 24 بهمن 1390, 22:06 عصر
ممنون با کد شما مال من هم درست شد ممنون

farzadfree
دوشنبه 16 مرداد 1391, 11:31 صبح
این ادیتور ایا سایتی برای پشتیبانی فارسی دارد ؟