TP-Docs
HTML5 Icon HTML5 Icon HTML5 Icon
TP on Social Media

Recent

Welcome to TinyPortal. Please login or sign up.

May 18, 2024, 09:43:44 AM

Login with username, password and session length
Members
  • Total Members: 3,886
  • Latest: Grendor
Stats
  • Total Posts: 195,189
  • Total Topics: 21,220
  • Online today: 112
  • Online ever: 3,540 (September 03, 2022, 01:38:54 AM)
Users Online
  • Users: 0
  • Guests: 93
  • Total: 93

Whizzywig is removing span tags and inline styles

Started by pbarney, April 01, 2009, 11:10:33 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

pbarney

Link to my site: http://www.columbustownhall.com
SMF version: 1.1.8
TP version: 1.0b3
Theme name and version: smFox by Pixelslot (most recent)
Mods installed:

Mod NameVersion
SMF 1.0.16 / 1.1.8 Update1.0
SMF 1.0.14 / 1.1.6 Update1.0
Auto Embed Video/Audio Clips3.1.2
SMF Articles1.0.1.8
SMF 1.0.15 / 1.1.7 Update1.0
TinyPortal1.052
TinyPortal1.075
Amazon Search1.0
Ignore user1.4
Related Error messages: No Message

Description of problem:

If I paste or enter any inline styles into the HTML-view of Whizzywig (after pressing the <> button), it automatically strips all inline styles and span tags, including the content contained within the span tags.

For example:
<p style='color:green;'><span style='font-weight:bold'>Title</span> by Author</p>
is automatically converted to:
<p> by Author</p>

Does anyone know why? Or more importantly, how I can stop this from happening?

Thanks

Ken.

pbarney, please give us the info called for in the posting guidelines so that we may be better able to help.
Please read the Posting Guidelines.html
" If everything seems under control, you're not going fast enough." - Mario Andretti
Yesterday When I was Young.

G6Cad

Also check the bugtracker as there are some fixes of the editor issues posted there.

pbarney

My apologies for failing to read the posting guidelines. I've updated the original post to follow the format. Feel free to remove this message once you see it.

ZarPrime

pbarney,

As stated by G6, there are quite a few issues with the editor in beta 3 that have been fixed for beta 4.  Bloc has made the fix and made available a new version of the editor for those who would like to use it prior to the release of beta 4.  To download it see this post ---> http://www.tinyportal.net/index.php/topic,28788.msg229572.html#msg229572

ZarPrime

pbarney

I updated the .js with the version in the post you referenced. Unfortunately, I've still got the issue.

I'd like to know if it's just me. Would you be willing to go into whizzywig and do the following?

1. Click the button at the end of the toolbar to switch to html mode

2. type this:
     <h1 style='color:green'>This is a test. <span>Is this still here?</span></h1>

3. Click the "hide HTML" button at the bottom. At this point, it looks fine to me, but if I submit it, it strips the style and span.

4. To confirm, just press the button. When I do this, the HTML then renders as:
     <h1>This is a test. </h1>

Does this happen to you?  FYI, I'm using Firefox 3.0.7 on WinXP.

Thanks

Ken.

Just tried your code and got the desired result:
http://www.ourfamilyforum.org/tptest2/index.php?page=12

The version of TP on my test site is newer than the one you are using but if the fix was done correctly your result should be the same.
Check your edits to see if they are OK.
" If everything seems under control, you're not going fast enough." - Mario Andretti
Yesterday When I was Young.

IchBin

Working fine on my site as well testing the same exact code you are referring to.

pbarney

I double-checked the file, and it was updated. But the problem was still there. Then it dawned on me.  Ctrl-F5 to refresh the cache, and that fixed it.

So THANK YOU. Problem solved.

But I noticed one other thing. I have a wysiwyg directory in my SMF root, with it's own whizzywig.js. Is that supposed to be there?

IchBin

Thats the old editor. You can delete that directory. Make a backup of it just in case something goes wrong.