Please login or register.

Login with username, password and session length
Advanced search  

News:

You need/want an older version of sNews ? Download an older/unsupported version here.

Pages: 1 2 [3] 4 5

Author Topic: [Addon Package] Whizzywig editor  (Read 60588 times)

brauck

  • Hero Member
  • *****
  • Karma: 18
  • Posts: 556
    • http://www.hbw-webdesign.nl/
Re: [Addon Package] Whizzywig editor
« Reply #30 on: October 26, 2007, 10:26:27 AM »

Quote from: joost
Preview is not needed

You're right of course  ;D :P
Logged
Confidence is reduced complexity.
brauck.nl for free css templates

Martin2007

  • Newbie
  • *
  • Karma: 0
  • Posts: 20
Re: [Addon Package] Whizzywig editor
« Reply #31 on: November 06, 2007, 11:07:59 AM »

I installed the editor and its great. I just wanted to know if there is a way to switch between the editor and the standard sNews 1.6 word editor where you can manually enter codes. I was thinking along the lines of being able to enter customized <divs> in my stylesheet.

I really appreciate any help. Thanks.

Martin
Logged

Joost

  • Guest
Re: [Addon Package] Whizzywig editor
« Reply #32 on: November 06, 2007, 09:22:25 PM »

As you can see in the first post the default buttons are commented out. You could uncomment them, then click on the sourcecode button in Whizzywig and find out if you can insert tags with the sNews buttons. I haven't tested this.
Logged

Simon Whittaker

  • Newbie
  • *
  • Karma: 0
  • Posts: 14
    • http://Lanonet.se
Re: [Addon Package] Whizzywig editor
« Reply #33 on: November 25, 2007, 05:44:00 PM »

I have tried a number of different html editors for sNews and this one is by far the best!  :)

However, I have just one problem. I wonder if anyone can help me solve it without uncommenting all the normal sNews buttons.

I want to put an iframe on a page, but when I do that with the Whizzywig editor it won't save the page with the iframe in it. The iframe code disappears!

That's all I want to do! Then the Whizzywig editor will suit me just fine!

/Simon
Logged

Joost

  • Guest
Re: [Addon Package] Whizzywig editor
« Reply #34 on: November 26, 2007, 04:36:15 AM »

You can click on the last button (html or <>) Have you tried pasting  the iframe code directly in the textarea ?
Logged

Simon Whittaker

  • Newbie
  • *
  • Karma: 0
  • Posts: 14
    • http://Lanonet.se
Re: [Addon Package] Whizzywig editor
« Reply #35 on: November 26, 2007, 03:15:09 PM »

Yes I have clicked on the html button and passed the iframe directly into the text area. I am quite used to writing pages directly in code, the whizzywig editor is for the benefit of other user users.

If I paste in the code into the text area and then click the "hide html" button I can see the page in the iframe showing in the editor. But when I press the save button the iframe code disappears.  ???

I have the original snews as snews.bak so I have swopped the two and tested the iframe in the original. The iframe works fine.

Interestingly, I put the iframe tag in <p> brackets. When I look at the whizzywig code I see the <p> brackets are still there but the iframe brackets have gone. Whizzywig doesn't seem to like iframes. That is bad news for me.
Logged

Joost

  • Guest
Re: [Addon Package] Whizzywig editor
« Reply #36 on: November 26, 2007, 03:56:49 PM »

That's to bad, Simon. Even without editing with Whizzywig after inserting? Or maybe the cleanbutton is activated, when the submit button is pressed. Perhaps you can find out on http://www.unverse.net/ how to disable that 'feature'.
Logged

Simon Whittaker

  • Newbie
  • *
  • Karma: 0
  • Posts: 14
    • http://Lanonet.se
Re: [Addon Package] Whizzywig editor
« Reply #37 on: November 26, 2007, 04:49:07 PM »

Yes, I looked at www.universe.net before to see if I could find a solution. What I should have done then was to find their online demo page and tried the iframe tag there.

I have done this now and guess what... when you make the page in html view and press the save button you can see the iframe tag disappear before your very eyes!

This is very bad news for me cos whizzywig is so easy and neat. But I need the iframes.

I have even tried to hide the iframe by using a some iframes_buffer code from www.dyn-web.com. But that didn't work either. All I got was the "your browser doesn't support iframes" message.

 :(
Logged

Joost

  • Guest
Re: [Addon Package] Whizzywig editor
« Reply #38 on: November 26, 2007, 05:05:21 PM »

It would be nice if we could make it work. I found this:

There is a cleanfunction named gentleClean

Code: [Select]
var gentleClean = "true";  //true: cleanUp preserves spans, inline styles and classes; false: deletes same; ask: asks.As you can see, it is set to true. Set to false, it is even more nasty, set to ask, it will ask you polite, if you want this to happen. Hope that works.

One more note. Try using it in a different browser.
« Last Edit: November 26, 2007, 05:09:17 PM by Joost »
Logged

Simon Whittaker

  • Newbie
  • *
  • Karma: 0
  • Posts: 14
    • http://Lanonet.se
Re: [Addon Package] Whizzywig editor
« Reply #39 on: November 26, 2007, 05:39:00 PM »

Thank you so very much Joost!

Now I've got it to work!

I set the gentle clean to false, but that didn't work... so I commented out case "clean" and case "word" but that didn't work... so I tried again in Firefox instead of IE ... and then the iframe WORKED!

I'm not quite sure at which point it worked in Firefox, but the important thing is that it now works... I can work my way backwards to find the critical point.

I thank you again for helping out with this - for me - important problem. Whizzywig is now the editor of choice.
Logged

Joost

  • Guest
Re: [Addon Package] Whizzywig editor
« Reply #40 on: November 26, 2007, 05:54:37 PM »

Good old FireFox :D Never let us down.
Logged

Simon Whittaker

  • Newbie
  • *
  • Karma: 0
  • Posts: 14
    • http://Lanonet.se
Re: [Addon Package] Whizzywig editor
« Reply #41 on: November 27, 2007, 12:44:26 AM »

Short lived happiness  :(

Tried to do the same thing again but it didn't work. Tried to look at the code for the page that did work and all the code for that page disappeared. And I mean ALL the code!

Have looked through the whizzywig faqs and forum but found no solution.

The only thing I can think of now is the insHTML function. Have tried a bit but haven't got it to work yet.
Logged

krko

  • Newbie
  • *
  • Karma: 1
  • Posts: 3
Re: [Addon Package] Whizzywig editor
« Reply #42 on: April 12, 2008, 07:11:20 PM »

Hello All,

Just discovered sNews and it's just what I've been looking for.
I'm using the sNewsMU (Multi User) version as this is what I need for my website and I'd very much like to know how can I integrate this addon into the MU version?

Thanks,
Goran
Logged

Keyrocks

  • Doug
  • ULTIMATE member
  • ******
  • Karma: 449
  • Posts: 6019
  • Semantically Challenged
    • snews.ca
Re: [Addon Package] Whizzywig editor
« Reply #43 on: April 12, 2008, 07:41:56 PM »

Hello All,

Just discovered sNews and it's just what I've been looking for.
I'm using the sNewsMU (Multi User) version as this is what I need for my website and I'd very much like to know how can I integrate this addon into the MU version?

Thanks,
Goran

Welcome to sNews Goran.
Follow the steps in the first post by Joost on the first page of this thread.
It appears that all of the steps are the same for the MU package... except for the first one... as the snewsMU.php file uses a longer login-check string file-wide than the one used in the default 1.6 snews.php file. Also, the line number references in Joost's post are no good to you... so just search for noted string-bits using the search function in your "good" code editing application.

Step 1 for sNewsMU 1.6:
Searching with ## MULTI USER will (should) bring you to all of the locations where scripts have been changed or added in relation to the default `.6 file. I am using an older release of the MU package as reference... but you will find this reference at the bottom of the // TITLE function:

Code: [Select]
<?php

## MULTI_USER
if ($_SESSION[db('website').'Logged_In'] == token() && get_identity($_SESSION['id'], 'level') < '4') {js();}
if ($_SESSION[db('website').'Logged_In'] == token()) {js2();}
## END MULTI_USER

?>


Replace it with:

Code: [Select]
<?php

## MULTI_USER
if ($_SESSION[db('website').'Logged_In'] == token() && get_identity($_SESSION['id'], 'level') < '4') {js();}
if ($_SESSION[db('website').'Logged_In'] == token()) {
js2();
echo '<script type="text/javascript" src="whizzywig.js"></script>';
echo '<script type="text/javascript" src="xhtml.js"></script>';
}
## END MULTI_USER

?>


Then follow the rest of Joost's instructions.  ;)
Logged
Do it now... later may not come.
-------------------------------------------------------------------------------------------------
sNews 1.6 MESU | sNews 1.6 MEMU

krko

  • Newbie
  • *
  • Karma: 1
  • Posts: 3
Re: [Addon Package] Whizzywig editor
« Reply #44 on: April 12, 2008, 11:11:55 PM »

Hello Keyrocks,

Works great! Thanks.
I've contributed a Hebrew translation of the Multi User version.
It's here: http://snewscms.com/forum/index.php?topic=4608.0

All best,
Goran
Logged
Pages: 1 2 [3] 4 5