Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 739
  • Last Modified:

how to get tinymce to load resources via base protocol (http OR https)?

how do i get tinymce 3.3.9.3 to load resources via base protocol (http OR https, depending on what the calling page is using)?

at the moment, as soon as the tinymce editor from moxiecode finishes loading - it gives the following alert in firefox 3.6.13:

You have requested an encrypted page that contains some unencrypted information. Information that you see or enter on this page could easily be read by a third party.
[ x] Alert me whenever I'm about to view an encrypted page that contains some unencrypted information.


currently i leave this option checked, because it is bad practise to use unencrypted resources in an encrypted page and i need to be aware of whenever this happens.

unfortunately i have not been able to locate a related solution to my problem via google, therefore i need to ask the following:

suggested changes (replace strings "http" with "https" in tiny_mce.js) did not work.  the screencast demonstrates the loading of the page, therafter the tinymce 3.3.9.3 plugin - then the alert from firefox 3.6.15.

what would i have to change within the latest stable version of tinymce (v 3.3.9.3) so it's resources are loaded via the base protocol of the page (wether http OR https)?
<!-- included in a "configuration manager" page as follows: -->
<script language="javascript" src="public/tinymce/jscripts/tiny_mce/tiny_mce.js" defer="defer"></script>
<script language="javascript" src="scripts/ajax_config.js" defer="defer"></script></head>

<!-- and in a "prospecting manager" page as follows: -->
<script language="javascript" src="public/tinymce/jscripts/tiny_mce/tiny_mce.js" defer="defer"></script>
<script language="javascript" src="scripts/ajax_prospects.js" defer="defer"></script>

<!-- both pages are intended to be served via ssl over https. -->

// the following loads the tinymce plugin in both pages' javascripts:

// TinyMCE
tinyMCE.init({
	// General options
	mode : "exact",
	elements : "textarea_fulltext",
	theme : "advanced",
	plugins : "pagebreak,style,layer,table,save,advhr,advimage,advlink,emotions,iespell,inlinepopups,insertdatetime,preview,media,searchreplace,print,contextmenu,paste,directionality,fullscreen,noneditable,visualchars,nonbreaking,xhtmlxtras,template,wordcount,advlist",

	// Theme options
	theme_advanced_buttons1 : "bold,italic,underline,strikethrough,|,justifyleft,justifycenter,justifyright,justifyfull,|,cut,copy,paste,pastetext,pasteword,|,charmap,emotions,iespell",
	theme_advanced_buttons2 : "styleselect,formatselect,fontselect,fontsizeselect|,insertdate,inserttime,preview",
	theme_advanced_buttons3 : "search,replace,|,bullist,numlist,|,outdent,indent,blockquote,|,undo,redo,|,link,unlink,anchor,image",
	theme_advanced_buttons4 : "tablecontrols,|,hr,removeformat,visualaid",
	theme_advanced_buttons5 : "insertlayer,moveforward,movebackward,absolute,|,styleprops,|,cite,abbr,acronym,del,ins,attribs,|,visualchars,nonbreaking,template,restoredraft",
	theme_advanced_buttons6 : "sub,sup,|,forecolor,backcolor,|,media,advhr,|,code,print,|,ltr,rtl,|,fullscreen,|,cleanup,help",
	theme_advanced_toolbar_location : "top",
	theme_advanced_toolbar_align : "left",
	theme_advanced_statusbar_location : "bottom",
	theme_advanced_resizing : true,

	// Forced options
	force_br_newlines : true,
	force_p_newlines : false,
       forced_root_block : 'p',

	// Example content CSS (should be your site CSS)
	content_css : "styles/mailers.css?" + new Date().getTime(),

	// Style formats
	style_formats : [
		{title : 'Float Left', inline : 'div', classes : 'colleft'},
		{title : 'Float Right', inline : 'div', classes : 'colright'},
		{title : 'Clear Black', inline : 'div,p,h1,h2,h3,h4,h5,h6,td,th,div,ul,ol,li,table,img', classes : 'cleart'},
		{title : 'Clear Grey', inline : 'div,p,h1,h2,h3,h4,h5,h6,td,th,div,ul,ol,li,table,img', classes : 'clearb'}
	],

	formats : {
		alignleft : {selector : 'p,h1,h2,h3,h4,h5,h6,td,th,div,ul,ol,li,table,img', classes : 'left'},
		aligncenter : {selector : 'p,h1,h2,h3,h4,h5,h6,td,th,div,ul,ol,li,table,img', classes : 'center'},
		alignright : {selector : 'p,h1,h2,h3,h4,h5,h6,td,th,div,ul,ol,li,table,img', classes : 'right'},
		alignfull : {selector : 'p,h1,h2,h3,h4,h5,h6,td,th,div,ul,ol,li,table,img', classes : 'full'},
		bold : {inline : 'span', 'classes' : 'bold'},
		italic : {inline : 'span', 'classes' : 'italic'},
		underline : {inline : 'span', 'classes' : 'underline', exact : true},
		strikethrough : {inline : 'del'}
	},

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

Open in new window

intellisource-413092.flv
0
intellisource
Asked:
intellisource
  • 2
1 Solution
 
intellisourceAuthor Commented:
ohhh!!!
the css file to style the tinymce window contents (attached), was loading the background image via http!
DOH! :P
fixed by setting it to load from an absolute path, without the domain name and working without the security alert now :D
mailers.css
0
 
intellisourceAuthor Commented:
remember to look at all urls referencing resources OUTSIDE of tinymce! 3.3.9.3 works wonderfully :D
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now