You are not logged in.
Pages: 1
Hi first thanks for this great wysiwyg editor
(I search so many, but this seems the best)
Now my problem:
I have problems with FireFox and Xinha when the content as BreakSpaces Entities [ ]
I try to explain here with a simple example:
I edit the \examples\testbed.html and add a sample line inside of textarea to prove the problem, this way when the file open, it as the sample text inside xinha textarea
sample text:
XXX[ ]XXX
If I read it with IExplorer all Ok we can view the 3 spaces inside the [ ]
But if we open it with Firefox, we view the 3 spaces [ ] when xinha is not initiated, but after it initiate or show, the 3 spaces are converted in one space [ ], this is the problem, it turns all spaces into on space........:(
If i add HTMLArea.setMode('text'); I can see the 3 spaces [ ] inside the normal textarea
Can anyone help me solve this, I have Tryed many things, like utf-8, htmlentities, search the forum etc, but nothing
Its strange that this problems is not reported, or may it has, and I cannot find it
I cannot post this topic, if the forum editor rips my spaces, this way my post turnt into an unformatted space post
(note my spaces like here [ ] <<< turns into this >>> [ ])
PS-Strange I try to add a double space in first line (here Hi first thanks... and it dont works!!!, try to post a topic with first chars as 4 spaces, and it rip off the 4 spaces, bad luck, seems that this is a bad day for my space theories LOL
Thanks in advance, ppl
Last edited by keepkool_pt (2006-03-17 19:54:52)
Offline
I'm curious, why do you need three spaces in a row, and would this always be preloaded content, or user entered content?
Offline
First Thanks for the Repply
Q: why do you need three spaces in a row?
The three spaces are here only to prove the bug theory in a simple way
The problem arrises everywhere, not only in rows....
Example
<textarea> BYE BYE Spaces</textarea>
Many of my users uses spaces as a format indentation method,
like this (me too, is simple and is a must have funcionality):
EX OK (IExplorer Without Ripped Spaces)
TOC
1
1.1
1.2
1.3
1.3.1
1.3.2
...
(this is impossible to achive if xinha+firefox converts more than 1 space into one visible html space)
EX BAD (FireFox + Xinha Ripped Spaces)
TOC
1
1.1
1.2
1.3
1.3.1
1.3.2
...
I know there many other ways that users can achieve this, but THEY cant do that,
in fact is more simple to add spaces than create tables and other complicated things for a newbie users......
Q: would this always be preloaded content?
yes is always a preloaded content like the example in first topic
<textarea>XXX[ ]XXX</textarea>
if I edit a blank content (<textarea></textarea>) with Xinha + FireFox everything works well,
even when I store and/or output it from database, but when I try to edit it, load the content in a preloaded way, it rips the spaces
I upload the modified testbed.html to this link, please try to load the link with FireFox and IExplorer and the Error in FireFox is obvious, when Xinha inits, The spaces are ripped, look at the link above
http://www.softcontrolweb.com/~xinha/ex … stbed.html
...
line 146 <textarea id="myTextArea" name="myTextArea" style="width:100%;height:320px;">
line 147 <B>TOC</B><br />
line 148 1<br />
line 149 1.1<br />
line 150 1.2<br />
line 151 1.3<br />
line 152 1.4<br />
line 153 1.4.1<br />
line 154 1.4.2<br />
line 155 ....<br />
line 156 </textarea>
...
Last edited by keepkool_pt (2006-03-18 16:18:26)
Offline
Have you considered doing the same thing with blockquotes, which users create when they use the indent right button?
You could try defining a smaller indentation distance for blockqoutes in CSS, if you wanted to.
The reason I asked was because Xinha primarily just controls HTML changes in IE, Mozilla is usually trusted and free to decide what it wants to do. Sometimes this has very undesirable results, such as body events being stripped from full-page HTML.
But, it seems to me that the reason that you want to be able to use multiple unbreakable spaces is something of a hack, why not use indent right instead, which is the proper way to do what you provided as an example?
Offline
Thanks once again for your answear mharrisonline
Q: Have you considered doing the same thing with blockquotes, which users create when they use the indent right button?
A: No, I will try, but its not the same thing..........
Q: You could try defining a smaller indentation distance for blockqoutes in CSS, if you wanted to.
A: OK, I will try It
...Mozilla is usually trusted and free to decide what it wants to do. Sometimes this has very undesirable results...
yes its seems right, maybe this is a undesirable firefox result
But, it seems to me that the reason that you want to be able to use multiple unbreakable spaces is something of a hack, why not use indent right instead, which is the proper way to do what you provided as an example?
Belive me its not a hack, think this way please:
1) A user creates a content with spaces and other entities, everything fine
2) but when he trys to re-edit the same content, it notes that the spaces are ripped off, and the html is corrupted, and what do you think he thinks?
It Thinks its a Bug, and ask where are my spaces!!!!!!!!!
It is not a hack, its only to prevent future problems for me and my contentmanager, in fact If I choose this great wysiwyg from many that exits, I want thrust that this is the one for all my future projects, and it must be stable and works well, and corrupt code is not a good thing to explain to a client....
I belive someone as the solution and helps me/us,
in fact I make it work with php and htmlentities, its easy, but for this work I must store the content in a database with entities replaced by its character codes!!!!,
It works well, but I dont want to store the content in dabase this way ...........
Please try to help me solve this problem, I know someone as the solution.........
Thanks once again
Last edited by keepkool_pt (2006-03-19 10:38:39)
Offline
I have made like you said, and it works well
its not the same thing,
but it bypasses the indentation problem and works even better (after the newbiews learn it)
I used this css
blockquote{
padding-left: 10px;
margin: 0px;
}
thanks for the excelent tip and your help (mharrisonline)
Last edited by keepkool_pt (2006-03-19 20:15:32)
Offline
I understand the way you feel. I think you're right, the end user should be able to enter anything, and be able to trust that it won't be altered.
Currently I process my HTML before and after Xinha in the PHP page that loads it with a series of regular expressions to fix other problems. I grab the body events and then put them back in because I know Mozilla will remove them, I convert php to long script notation because otherwise Mozilla will destroy it, and I strip any surviving unwanted absolute paths. I block JavaScript execution in the editor by changing the name of the script language, and then return it to JavaScript on save.
Xinha is the only higher end WYSIWYG that I know of that does not support HTML entities, but as I do not have control over encoding in my server environment or the CMS I use, I very much do have to convert special characters into HTMLentities. Every time the GetHtml plugin is changed, I save its js file as UTF-8 and add a regular expression for every character I need to prevent the destruction of.
In other words, I feel your pain.
Despite all of these things, I think Xinha is the most powerful editor you will find, and I really like it best. When I do find something that it breaks or doesn't do well, I always seem to find a way to either fix it, a work around that works as well, or someone here figures out a great way to fix it perfectly. Either way, nothing has ever been impossible.
Last edited by mharrisonline (2006-03-20 05:16:31)
Offline
I understand the way you feel. I think you're right, the end user should be able to enter anything, and be able to trust that it won't be altered.
Thats the Point
I In other words, I feel your pain.
Despite all of these things, I think Xinha is the most powerful editor you will find, and I really like it best.
First thanks for your repply, so well written
I m with you, this is the best,
I view so many, that i dont waste more time only to talk about it, but I know one thing, theres no perfect wysiwyg in the world, I try all and all have common problems, like table manager, imagemanager, DOM (very Important Feature), Multi Language, Custimization, Royalityes, CSS etc.....
and In my point of view this is the best I know, Comercial and Free/OpenSource
And the best is......we have this forum to share our knowledge about it (Not me, I´m a Newbie, I´m just learning)
Last edited by keepkool_pt (2006-03-20 16:53:32)
Offline
Pages: 1