Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - RTE 3.0 b2 input/output to Access 2000
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Forum LockedRTE 3.0 b2 input/output to Access 2000

 Post Reply Post Reply Page  <123
Author
dj1811 View Drop Down
Newbie
Newbie


Joined: 11 February 2005
Status: Offline
Points: 26
Post Options Post Options   Thanks (0) Thanks(0)   Quote dj1811 Quote  Post ReplyReply Direct Link To This Post Posted: 14 February 2005 at 1:34am

also if there was some javascript in the editor to prevent right clicks and possibly "ctrl+v" --- to prevent people from pasting manually -- this would be a neat feature perhaps.   Maybe as an option off/on in the setup file?

Back to Top
WebWiz-Bruce View Drop Down
Admin Group
Admin Group
Avatar
Web Wiz Developer

Joined: 03 September 2001
Location: Bournemouth
Status: Offline
Points: 9844
Post Options Post Options   Thanks (0) Thanks(0)   Quote WebWiz-Bruce Quote  Post ReplyReply Direct Link To This Post Posted: 14 February 2005 at 4:25am
You are right in IE <p> is changed with <div> instead of <br> now when hitting return.

The default for IE is <p> which courses double line spacing, this was a problem for allot of users, so I tried capturing the 'ENTER' key and replacing <p> with <br> when pressed, I then discovered loads of problems like within tables, ordered lists etc. if <br> was used, so instead <div> is used, this creates the same effect as <br> but doesn't course any of the problems <br> does.

Maybe an idea would be an option to disable the single line spacing for IE from the setup file, so that it runs as standard.

An iframe is used to replace the textarea otherwise the whole document would become editable.

Placing the onclick event on the reset button could be a problem when people intergarte the RTE into their own form.

CTRL+V could be detected easily in Mozilla, but in IE it's difficult, if not almost impossible, to detect of CTRL is pressed with the V key, as I spent many hours on just that type of thing.

I did look at detecting Right Clicks and replacing them with my own menu, again I spent around 25 hours working on this, in IE no problem, but in Mozilla as soon as you enable an frame to be editable you can no longer suppress the Right Click Context Menu from appearing, so I eventually abandon this.
Back to Top
dj1811 View Drop Down
Newbie
Newbie


Joined: 11 February 2005
Status: Offline
Points: 26
Post Options Post Options   Thanks (0) Thanks(0)   Quote dj1811 Quote  Post ReplyReply Direct Link To This Post Posted: 14 February 2005 at 5:06pm
The most troublesome part about how the ENTER key is implemented in IE, is that it is not consistent.  While it usually replaces the <P> tags with <DIV> it does not always do so.
 
What about using CSS to correct the ugly <P> tags in IE, and then not replacing the <P> with <DIV>? For example (from RTE_javascript.asp):
 
iframeContent += '<style>\n';
iframeContent += 'html,body{border: 0px;}\n';
iframeContent += 'p{margin:0px 0px 0px 0px;}\n';
iframeContent += '</style>\n';
 
Obviously the display would have to use the same paragraph style.... so perhaps this is not such a great idea?
 
Alternatives in the setup file for handling ENTER in IE would be beneficial I would think.
 
Truth be told I would greatly prefer <BR> if it were at all feasible...
 
Originally posted by -boRg- -boRg- wrote:


Placing the onclick event on the reset button could be a problem when people intergarte the RTE into their own form
 
What about this (also from RTE_javascript.asp):
 
//resetting the form
textArea.form.onreset = function(){
if (window.confirm('WARNING!  This will erase any changes you have made.')){
    editor.body.innerHTML = textArea.value;
    self.focus();
    return true;
   }
 return false;
 }
 
Note: I also made a couple of changes with this function so that it would perform more like a standard reset button.
 
This has improved some of the peculiarities in IE for me.  I don't know if this is really advantageous over using the OnClick event on the reset button, however.
 
****************************
 
I still experience a very annoying "bug" (in MSIE of course), where if I:
 
#1) start with an empty editor
#2) type text
#3) BACKSPACE over the text so the editor is again empty
#4) type text
 
1 or 2 odd things will happen:
 
1: the textarea will begin with <P>&nbsp;<P> --- the <P> tags occur without pressing ENTER .. which is why they are not being captured and replaced.
 
2: I occasionally get text with a white background .. or less frequently a gray background.
Back to Top
 Post Reply Post Reply Page  <123

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.08
Copyright ©2001-2026 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Notice

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT at 20% unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2026 Web Wiz Ltd. All rights reserved.