[MOD] TinyMCE editor for Story Submission at Step 2

Register an Account
Pligg Chat Room
Closed Thread
 
LinkBack Thread Tools Display Modes
  #21 (permalink)  
Old 07-04-2007, 04:32 AM
Constant Pligger
Pligg Version: 9.7
Pligg Template: Yget
 
Join Date: Nov 2006
Posts: 154
Thanks for this wonderful mod Dollar5. Haven't pligged in a while and thanks for the reply to my prev. query. The user is on dial-up so I guess that's the reason (that's a guess but then...)
Just wondering if there's a way to increase the height of the editor and is there a way to increase the font size of the editor? While editing, the fonts, if you notice are way to small :-/
  #22 (permalink)  
Old 07-04-2007, 08:28 AM
dollars5's Avatar
Pligg Donor
 
Join Date: Dec 2006
Location: India
Posts: 1,961
Sure it can be done:
in submit_step2.tpl add the following two parameters to the tinyMCE.init function, just above the following line
Code:
extended_valid_elements : "a[name|href|target|title|onclick],img[class|src|border=0|alt|title|hspace|vspace|width|height|align|onmouseover|onmouseout|name],hr[class|width|size|noshade],font[face|size|color|style],span[class|align|style]"
add:
Code:
    height:"350px",
    width:"600px",
this will set the height, font setting currently is not supported by TinyMCE - I am not 100% sure - I am just not aware of this. May be you should try their forums at TinyMCE Forum
  #23 (permalink)  
Old 07-04-2007, 09:50 AM
New Pligger
 
Join Date: Dec 2006
Posts: 13
I'm using TinyMCE with my pligg but i would like to use Youtubes with a simple copypaste of the embed code. Is it possible?

In addition, I would like to know if it's possible to configure it for not covert code like <b> (I like to use html code directly) in &nbsp;&lt;b&gt;

Thanks!

(It's very useful)
  #24 (permalink)  
Old 07-05-2007, 10:57 PM
Casual Pligger
 
Join Date: Feb 2007
Posts: 46
careful, peeps. I too thought this mod was cool but it's not compatible with a few browsers such as Safari, and so you would lose the majority of the Mac users.

if you try to submit/edit link using TinyMCE, your whole site becomes unusable and Safari closes by itself.

the only solution currently is to disable the TinyMCE editor on Safari, and other incompatible browsers by adding something like:

Code:
{literal}
	<script language="javascript" type="text/javascript">
		tinyMCE.init({
			mode : "exact",
			elements : "bodytext",
			theme : "advanced",
			plugins : "advimage,advlink,emotions,iespell,insertdatetime,preview,media,visualchars,xhtmlxtras",
			theme_advanced_buttons1 : "bold,italic,underline,|,justifyleft,justifycenter,justifyright,justifyfull,|,bullist,numlist,|,insertdate,inserttime,|,forecolor,backcolor,|,hr,removeformat,formatselect",
			theme_advanced_buttons2 : "link,unlink,image,media,|,undo,redo,cleanup,|,code,preview",
			theme_advanced_buttons3 : "",
			theme_advanced_toolbar_location : "top",
			theme_advanced_toolbar_align : "left",
			theme_advanced_path_location : "bottom",
			extended_valid_elements : "a[name|href|target|title|onclick],img[class|src|border=0|alt|title|hspace|vspace|width|height|align|onmouseover|onmouseout|name],hr[class|width|size|noshade],font[face|size|color|style],span[class|align|style]",
			browsers : "msie,gecko,opera,safari"
		});
	</script>
{/literal}

Last edited by abcdefgary; 07-06-2007 at 12:01 AM.
  #25 (permalink)  
Old 07-05-2007, 11:45 PM
dollars5's Avatar
Pligg Donor
 
Join Date: Dec 2006
Location: India
Posts: 1,961
I knew it was not compatible with a few browsers, but never invested time to see which ones - thanks for posting the tip - with your permission, I am just updating the browser param to the original code in post #1 that every one benefits.

In a recent read from TinyMCE site - I found they are now safari compatible too - but not sure abt it.
  #26 (permalink)  
Old 07-06-2007, 01:59 AM
Constant Pligger
Pligg Version: 9.7
Pligg Template: Yget
 
Join Date: Nov 2006
Posts: 154
So does this mean that we need to add just the following line?
Quote:
browsers : "msie,gecko,opera,safari"
  #27 (permalink)  
Old 08-08-2007, 11:41 PM
New Pligger
 
Join Date: Jun 2007
Posts: 2
I followed the instructions and everything work fine but just one little problem on submit page

Description:
Write your own description of the news story you are submitting. It should be about 2 to 4 sentences long.
HTML tags allowed: %3Cbr%3E%3Cfont%3E%3Cimg%3E%3Cp%3E%3Ca%3E%3Cstrong %3E%3Cul%3E%3Cli%3E%3Col%3E%3Cu%3E%3Cem%3E%3Cspan% 3E%3Cpre%3E%3Ch1%3E%3Ch2%3E%3Ch3%3E%3Chr%3E%3Cembe d%3E

Can anyone help me out ?

Regards
  #28 (permalink)  
Old 08-09-2007, 12:29 AM
dollars5's Avatar
Pligg Donor
 
Join Date: Dec 2006
Location: India
Posts: 1,961
You will need to edit it at admin panel -> configure -> Submit -> HTML tags to allow - seems like you have the ASCII values instead of the normal text.
  #29 (permalink)  
Old 08-30-2007, 12:46 PM
New Pligger
 
Join Date: Aug 2007
Posts: 7
Hia. Great mod. Where do i input the

HTML Code:
{literal}
	<script language="javascript" type="text/javascript">
		tinyMCE.init({
			mode : "exact",
			elements : "bodytext",
			theme : "advanced",
			plugins : "advimage,advlink,emotions,iespell,insertdatetime,preview,media,visualchars,xhtmlxtras",
			theme_advanced_buttons1 : "bold,italic,underline,|,justifyleft,justifycenter,justifyright,justifyfull,|,bullist,numlist,|,insertdate,inserttime,|,forecolor,backcolor,|,hr,removeformat,formatselect",
			theme_advanced_buttons2 : "link,unlink,image,media,|,undo,redo,cleanup,|,code,preview",
			theme_advanced_buttons3 : "",
			theme_advanced_toolbar_location : "top",
			theme_advanced_toolbar_align : "left",
			theme_advanced_path_location : "bottom",
			extended_valid_elements : "a[name|href|target|title|onclick],img[class|src|border=0|alt|title|hspace|vspace|width|height|align|onmouseover|onmouseout|name],hr[class|width|size|noshade],font[face|size|color|style],span[class|align|style]",
			browsers : "msie,gecko,opera,safari"
		});
	</script>
{/literal}
should this be placed in the submit_step_2.tpl >?

thanks in advance.
  #30 (permalink)  
Old 08-30-2007, 02:48 PM
Casual Pligger
 
Join Date: Mar 2007
Posts: 47
Yes, in submit_step_2.tpl

under the line {config_load file="/libs/lang.conf"}


Quote:
Originally Posted by lazynewt View Post
Hia. Great mod. Where do i input the

HTML Code:
{literal}
	<script language="javascript" type="text/javascript">
		tinyMCE.init({
			mode : "exact",
			elements : "bodytext",
			theme : "advanced",
			plugins : "advimage,advlink,emotions,iespell,insertdatetime,preview,media,visualchars,xhtmlxtras",
			theme_advanced_buttons1 : "bold,italic,underline,|,justifyleft,justifycenter,justifyright,justifyfull,|,bullist,numlist,|,insertdate,inserttime,|,forecolor,backcolor,|,hr,removeformat,formatselect",
			theme_advanced_buttons2 : "link,unlink,image,media,|,undo,redo,cleanup,|,code,preview",
			theme_advanced_buttons3 : "",
			theme_advanced_toolbar_location : "top",
			theme_advanced_toolbar_align : "left",
			theme_advanced_path_location : "bottom",
			extended_valid_elements : "a[name|href|target|title|onclick],img[class|src|border=0|alt|title|hspace|vspace|width|height|align|onmouseover|onmouseout|name],hr[class|width|size|noshade],font[face|size|color|style],span[class|align|style]",
			browsers : "msie,gecko,opera,safari"
		});
	</script>
{/literal}
should this be placed in the submit_step_2.tpl >?

thanks in advance.
Closed Thread

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Warning messages in the 3rd step of submission - Please help PurpleCow Questions and Comments 12 10-02-2007 09:27 PM
"Confirm" message box when trying to modify submission in Step 3 nothingman Questions and Comments 0 09-22-2007 05:53 PM
[SOLVED] how to make url submission as not a mandatory step sharatthakur Questions and Comments 2 07-02-2007 12:36 PM
Step 2 Submission Formatting Problem csakon Questions and Comments 0 04-15-2007 10:05 PM
Pligg step 3 of 3 submission error xur17 Questions and Comments 1 04-20-2006 07:22 PM


Pligg Modules and Pligg Templates from Pligg Pro Find support on the Pligg CMS Forum - 24 hours a day! Make a donation to support Pligg CMS development