Jump to content
Sign in to follow this  
danthony2

Has anyone got HTMLArea v3.0 to work?

Recommended Posts

Hello Everyone,

I am having massive issues with this install, I think it has to do with paths but not fully sure. Can someone talk alook at my code?

 

<html <?php echo HTML_PARAMS; ?>>
<head>
  <!-- DWD Modify -> Add: HTMLArea v3.0 !-->
  <!-- Load HTMLArea Core Files. !-->
  <script type="text/javascript" src="htmlarea/htmlarea.js"></script>
  <script type="text/javascript" src="htmlarea/dialog.js"></script>
  <script type="text/javascript" src="htmlarea/lang/en.js"></script>

  <!-- Load HTMLArea Plugins. !-->
  <script type="text/javascript">
    HTMLArea.loadPlugin("TableOperations");
    HTMLArea.loadPlugin("SpellChecker");
  </script>

  <!-- Load HTMLArea StyleSheet. !-->
  <style type="text/css">
    @import url(/htmlarea/htmlarea.css);
  </style>
  <!-- DWD Modify End. !-->

 

Also....

 

<body marginwidth="0" marginheight="0" topmargin="0" bottommargin="0" leftmargin="0" rightmargin="0" bgcolor="#FFFFFF" onload="SetFocus(); onload="HTMLArea.replaceAll()">

 

and...

 

<?php echo tep_draw_textarea_field('products_description[' . $languages[$i]['id'] . ']', 'soft', '100%', '20', .....

 

I have the htmlarea located in my admin directory, and even /store/htmlarea.

I keep getting java errors stating that something wasn't defined.

So thats why I think its purley path issures.

 

Thanks

David

Share this post


Link to post
Share on other sites

onload="SetFocus(); onload="HTMLArea.replaceAll()"

 

This does not seem right. Try removing:

 

onload="SetFocus();


"Use no way as way, have no limitation as limitation." - Bruce Lee

Share this post


Link to post
Share on other sites

well acording to the author the statement looks right, the original thread is here:

http://forums.oscommerce.com/index.php?showtopic=74826

 

I started this new one so it wouldn't be barried so deep in the original one.

 

The error that I get is more of htmlarea not defined so I still think its a path issue.

 

THanks

David

Edited by danthony2

Share this post


Link to post
Share on other sites

Paths for admin/categories.php are :-

 

<!-- DWD Modify -> Add: HTMLArea v3.0 !-->
   <!-- Load HTMLArea Core Files. !-->
   <script type="text/javascript" src="htmlarea/htmlarea.js"></script>
   <script type="text/javascript" src="htmlarea/dialog.js"></script>
   <script type="text/javascript" src="htmlarea/lang/en.js"></script>

   <!-- Load HTMLArea Plugins. !-->
   <script type="text/javascript">
     HTMLArea.loadPlugin("TableOperations");
     HTMLArea.loadPlugin("SpellChecker");
   </script>

   <!-- Load HTMLArea StyleSheet. !-->
   <style type="text/css">
     @import url(htmlarea/htmlarea.css);
   </style>
   <!-- DWD Modify End. !-->

 

 

Body tag should be this :-

 

<body marginwidth="0" marginheight="0" topmargin="0" bottommargin="0" leftmargin="0" rightmargin="0" bgcolor="#FFFFFF" onload="SetFocus(); HTMLArea.replaceAll()">

 

The code above is different on other pages such as mail.php and newsletters.php

For these pages use

 

<body marginwidth="0" marginheight="0" topmargin="0" bottommargin="0" leftmargin="0" rightmargin="0" bgcolor="#FFFFFF" onload="HTMLArea.replaceAll()">

 

 

Edit htmlarea.js so it resembles this :-

 

// found on lines 53 and 54

 

this.imgURL = "images/";
this.popupURL = "htmlarea/popups/";

 

Change the image paths starting at line 147

 

should look like this

 

bold: [ "Bold", "htmlarea/images/ed_format_bold.gif", false, function(e) {e.execCommand("bold");} ],
 italic: [ "Italic", "htmlarea/images/ed_format_italic.gif", false, function(e) {e.execCommand("italic");} ],
 underline: [ "Underline", "htmlarea/images/ed_format_underline.gif", false, function(e) {e.execCommand("underline");} ],
 strikethrough: [ "Strikethrough", "htmlarea/images/ed_format_strike.gif", false, function(e) {e.execCommand("strikethrough");} ],
 subscript: [ "Subscript", "htmlarea/images/ed_format_sub.gif", false, function(e) {e.execCommand("subscript");} ],
 superscript: [ "Superscript", "htmlarea/images/ed_format_sup.gif", false, function(e) {e.execCommand("superscript");} ],
 justifyleft: [ "Justify Left", "htmlarea/images/ed_align_left.gif", false, function(e) {e.execCommand("justifyleft");} ],
 justifycenter: [ "Justify Center", "htmlarea/images/ed_align_center.gif", false, function(e) {e.execCommand("justifycenter");} ],
 justifyright: [ "Justify Right", "htmlarea/images/ed_align_right.gif", false, function(e) {e.execCommand("justifyright");} ],

 

Notice the path is different and for all images should be htmlarea/images/

 

 

Copy the htmlarea folder into your admin folder

 

Upload and enjoy

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×