htmlArea

A directory of browser-based WYSIWYG editors

  MAIN
INDEX
SEARCH
POSTS
WHO'S
ONLINE
LOG
IN

Home: htmlArea 3 (beta): htmlArea 2 & 3 archive (read only): htmlArea v3.0 - Discussion:
Forward slash added to <br> tag


The htmlArea 2 & 3 editors have been discontinued.

We've made these forums available as a read-only reference and knowledge-base for people using or developing editors based on htmlArea 2 or 3.

Anyone who is interested in taking over version 2 or 3 is free to do so. All we ask is that you choose a new name that doesn't have "htmlarea" in it to avoid confusion with this site. We'll even give you a link in the directory to make it easier for people to find you. If you are developing or hosting an htmlArea based-editor under a new name, please submit it to our directory.

 


NickW
Novice

Jan 16, 2005, 4:06 PM

Post #1 of 5 (2795 views)
Shortcut
Forward slash added to <br> tag Can't Post

If I enter some text and select shift+enter to give a new line (or if I copy two lines of text displayed in an html page) then if I look at the code I see htmlarea has added a forward slash to the br tag, like this <br />.

How can this be avoided?


sleemanj
User

Jan 16, 2005, 8:24 PM

Post #2 of 5 (2788 views)
Shortcut
Re: [NickW] Forward slash added to <br> tag [In reply to] Can't Post

That is correct syntax. "br" is an empty tag, xml requires empty tags to be closed in this manner.

If you really want to revert back to html unclosed tags ("<br>"), then you could just replace <br /> with <br> when you get the html back to your serverside script(s).


James Sleeman
PHP Programmer


NickW
Novice

Jan 17, 2005, 1:01 AM

Post #3 of 5 (2779 views)
Shortcut
Re: [sleemanj] Forward slash added to <br> tag [In reply to] Can't Post

I don't understand, I've never seen <br /> used in code or html before, </td> yes and escapes \', but not a space and then / inside a tag ..... is there any further reading on this?

Also when I retrieve the content of the replced textarea via a form post I find the '<' and '>' is replaced with '_' .


(This post was edited by NickW on Jan 17, 2005, 1:24 AM)


sleemanj
User

Jan 17, 2005, 4:56 AM

Post #4 of 5 (2767 views)
Shortcut
Re: [NickW] Forward slash added to <br> tag [In reply to] Can't Post

All tags must be closed within XML and thus xhtml. <br /> is how you write the empty tag br properly.

XHTML Overview (click)


In Reply To
'<' and '>' is replaced with '_'


You mean, in the "source view" something like

<strong>foo</strong>

comes out

_strong_foo_/strong_

when you save it?? I would say you have a coding problem in your server side code. What you see in the "source view" of the editor is exactly what is copied back into the textarea when you submit the form.


James Sleeman
PHP Programmer


NickW
Novice

Jan 17, 2005, 5:15 AM

Post #5 of 5 (2760 views)
Shortcut
Re: [sleemanj] Forward slash added to <br> tag [In reply to] Can't Post

Thank you for your help, I've learnt something with regards to closing tags and xml.

The underscores were due to the osCommerce function 'tep_db_prepare_input' that I had applied to the returned content. I've now tested with simple one page of code and there are no underscores.


(This post was edited by NickW on Jan 17, 2005, 6:43 AM)

 
 
 


Search for (options)