eWebEditor Home >> eWebEditor Manual V8.0 >> Developer Guide >> Code Examples

3.10.6 External StyleAPI

This example demonstrates how to use interfaces cited by external style to realize consistency of the editing area and application system's style.

This example is packed in the directory of _example/para_extcss.asp(.php/.aspx/.jsp) in compressed system package.

 

<HTML>

<HEAD>

<TITLE>eWebEditor : Demo of ways of citing external style</TITLE>

<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">

<link rel='stylesheet' type='text/css' href='example.css'>

</HEAD>

<BODY>

 

<p><b>Navigator : <a href="default.asp">Home</a> &gt; Demo of ways of citing external style</b></p>

<p>Using parametric interface of external style, you can set the editing area style.</p>

<p>This is usually used to set the style of editing area as CSS style files which will be identical to your application system. In that way, the displaying effect in the editor will be identical to the output displaying effect in your application system.</p>

<p>In the following example, designating extcss=_example/myeditorarea.css, then inputting some text in the editing area, you will find the displaying effect is the same as that defined in myeditorarea.css</p>

 

 

<FORM method="post" name="myform" action="retrieve.asp">

<TABLE border="0" cellpadding="2" cellspacing="1">

<TR>

       <TD>Content:</TD>

       <TD>

              <INPUT type="hidden" name="content1" value="">

              <IFRAME ID="eWebEditor1" src="../ewebeditor.htm?id=content1&style=coolblue&extcss=_example/myeditorarea.css" frameborder="0" scrolling="no" width="550" height="350"></IFRAME>

       </TD>

</TR>

<TR>

       <TD colspan=2 align=right>

       <INPUT type=submit value="Submit">

       <INPUT type=reset value="Reset">

       <INPUT type=button value="View Source" onclick="location.replace('view-source:'+location)">

       </TD>

</TR>

</TABLE>

</FORM>

 

 

</BODY>

</HTML>