Solved

TinyMCE and default needs to be Source Code

Posted on 2010-08-23
6
329 Views
Last Modified: 2012-05-10
Hello experts:

Is there any way for the textarea to show the Source Code by default when a user enters the page....??  At present it shows the "pretty version".

Below is the code that I am using at present for TinyMCE.

Any help will be greatly appreciated.

--d.
<script type="text/javascript">
tinyMCE.init({
	theme : "advanced",
	mode : "textareas",
//	plugins : "fullpage",

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

Open in new window

0
Comment
Question by:driven13
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 2
6 Comments
 
LVL 13

Expert Comment

by:StormITSolutions
ID: 33506845
You can set the users preference to use no editor and you will always see html only

but i reckon this isnt what your after

Storm
0
 

Author Comment

by:driven13
ID: 33506857
Hi:

Thanx for the response.

Where and/or how can I set the user's preference to use no editor..???

Maybe if I see what it looks like I will know better.

--d.
0
 
LVL 13

Expert Comment

by:StormITSolutions
ID: 33506882
site>user manager> select user> user editor> editor - no editor

Storm
0
Technology Partners: 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!

 
LVL 13

Expert Comment

by:StormITSolutions
ID: 33506883
in the joomla backend

Storm
0
 

Author Comment

by:driven13
ID: 33506890
Ahhh sorry Storm.  I am not using Joomla.  I am using this with Classic ASP pages.  

Sorry for not mentioning this before.

I figured there might be a setting in the TinyMCE controls that will let me do this.

--d.
0
 
LVL 13

Accepted Solution

by:
StormITSolutions earned 500 total points
ID: 33506925
ah, not sure why this appeared within joomla section

Best bet is to use the tinymce website and follow the advice there

http://tinymce.moxiecode.com/

Storm
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The task A number given should be formatted for easy reading by separating digits into triads. Format must be made inline via JavaScript, i.e., frameworks / functions are not welcome. So let’s take a number like this “12345678.91¿ and format i…
This article demonstrates how to create a simple responsive confirmation dialog with Ok and Cancel buttons using HTML, CSS, jQuery and Promises
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

749 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question