You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@lenya.apache.org by Ethan Schroeder <Et...@nsighttel.com> on 2004/02/25 23:57:43 UTC

escaped characters

"less than" and "greater than" are converted into &lt; and &gt; when
adding blog entries.  I wish markup to stay intact.  Anyone know how I
can go about this?
 
Thanks,
Ethan

RE: escaped characters

Posted by Ethan Schroeder <et...@netnet.net>.
I should have given a better description of what I was doing.  I built
in a old version of epoz, the one that uses a form inside of a page to
edit a piece of content.  I then let the user edit the content in the
box however they want, convert it to clean xhtml then insert it into the
blog content structure.  Unfortunately, this xhtml content looks like
&lt;i&gt;Ethan&lt;i&gt;  I would like to figure out how to get this
content in as xhtml so it displays properly.

Thanks,
Ethan

-----Original Message-----
From: Michael Wechner [mailto:michael.wechner@wyona.com] 
Sent: Wednesday, February 25, 2004 5:32 PM
To: Lenya Users List
Subject: Re: escaped characters


Ethan Schroeder wrote:

> "less than" and "greater than" are converted into &lt; and &gt; when
> adding blog entries.  I wish markup to stay intact.  Anyone know how I

> can go about this?


this is a feature in order to be able to have mixed content, e.g.

Hello <i>Ethan</i> &amp; <i>Alice</i>

Michi

>  
> Thanks,
> Ethan



-- 
Michael Wechner
Wyona Inc.  -   Open Source Content Management   -   Apache Lenya
http://www.wyona.com              http://cocoon.apache.org/lenya/
michael.wechner@wyona.com                        michi@apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: lenya-user-unsubscribe@cocoon.apache.org
For additional commands, e-mail: lenya-user-help@cocoon.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: lenya-user-unsubscribe@cocoon.apache.org
For additional commands, e-mail: lenya-user-help@cocoon.apache.org


RE: escaped characters [solved] + enhanced blogging functionality

Posted by Ethan Schroeder <et...@netnet.net>.
Whew!  I finally solved this.

I extended org.apache.lenya.cms.authoring.NewBlogEntryCreator,
overriding the transformXML method.  I then called the super method to
perform all the DOM manipulation on the default title, author, created
date, issued date, and modified date.  Then I added some code to also
update the /echo:entry/echo:content[@type = 'application/xhtml+xml']
element.  Because the content I am feeding this is valid xhtml, I had to
create a new DOM Document from a DocumentBuilder parsed string, then
insert it into the blog DOM Document using the Document importNode
method.  This avoided the xhtml being escaped with &lt; and &gt;  The
last thing I needed to do was point the doctypes.xconf "entry" at my new
class.

The new blogging functionality comes into play when I updated the form
where you create a new blog.  The default interface had inputs for
identifier and title, and getting content in was performed after the
creation of the blog by using Forms, one For or BXE.  I made this
simpler by creating a new input for the content of the blog.  This input
was an older version of Epoz (0.7.5, I believe), which was does inline
browser-based editing, as opposed to the new Epoz which does entire
document editing.  I merged the html --> xhtml capabilities of the newer
1.x Epoz into this older version so I didn't have to use the xmlRPC
conversion in the older Epoz.  The new version of Epoz uses Sarissa and
browser-based DOM manipulation to clean up html into valid xhtml.

In the end, I can create a blog using a single form, including the
content with the xhtml RTE functionality of Epoz (toolbar and all).  I
have attached a screenshot of the interface, though I don't know if it
will make it through the mailing list.  Now I just have to figure out
how to either a.) provide auto-publishing of the entry or b.) at least
push the user directly to the publish screen upon creating the new blog
entry.  If anyone has any suggestions pertaining to this, please let me
know.

If anyone wants the full implementation of all this, feel free to email
me directly.

Ethan

-----Original Message-----
From: Ethan Schroeder [mailto:ethan@netnet.net] 
Sent: Friday, February 27, 2004 9:55 AM
To: 'Lenya Users List'
Subject: RE: escaped characters


I don't mean to be a pest, but I've spent a lot of time trying to figure
this out and am just completely stumped.  Is there anyway to circumvent
this functionality and get html tags entered in a form to just pass
through to generated xml without having the opening and closing brackets
being converted (&lt;b&gt;Hello, world&lt;/b&gt;) ?

I really appreciate your help.

Thanks,
Ethan

-----Original Message-----
From: Michael Wechner [mailto:michael.wechner@wyona.com] 
Sent: Wednesday, February 25, 2004 5:32 PM
To: Lenya Users List
Subject: Re: escaped characters


Ethan Schroeder wrote:

> "less than" and "greater than" are converted into &lt; and &gt; when 
> adding blog entries.  I wish markup to stay intact.  Anyone know how I

> can go about this?


this is a feature in order to be able to have mixed content, e.g.

Hello <i>Ethan</i> &amp; <i>Alice</i>

Michi

>  
> Thanks,
> Ethan



-- 
Michael Wechner
Wyona Inc.  -   Open Source Content Management   -   Apache Lenya
http://www.wyona.com              http://cocoon.apache.org/lenya/
michael.wechner@wyona.com                        michi@apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: lenya-user-unsubscribe@cocoon.apache.org
For additional commands, e-mail: lenya-user-help@cocoon.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: lenya-user-unsubscribe@cocoon.apache.org
For additional commands, e-mail: lenya-user-help@cocoon.apache.org

RE: escaped characters

Posted by Ethan Schroeder <et...@netnet.net>.
I don't mean to be a pest, but I've spent a lot of time trying to figure
this out and am just completely stumped.  Is there anyway to circumvent
this functionality and get html tags entered in a form to just pass
through to generated xml without having the opening and closing brackets
being converted (&lt;b&gt;Hello, world&lt;/b&gt;) ?

I really appreciate your help.

Thanks,
Ethan

-----Original Message-----
From: Michael Wechner [mailto:michael.wechner@wyona.com] 
Sent: Wednesday, February 25, 2004 5:32 PM
To: Lenya Users List
Subject: Re: escaped characters


Ethan Schroeder wrote:

> "less than" and "greater than" are converted into &lt; and &gt; when
> adding blog entries.  I wish markup to stay intact.  Anyone know how I

> can go about this?


this is a feature in order to be able to have mixed content, e.g.

Hello <i>Ethan</i> &amp; <i>Alice</i>

Michi

>  
> Thanks,
> Ethan



-- 
Michael Wechner
Wyona Inc.  -   Open Source Content Management   -   Apache Lenya
http://www.wyona.com              http://cocoon.apache.org/lenya/
michael.wechner@wyona.com                        michi@apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: lenya-user-unsubscribe@cocoon.apache.org
For additional commands, e-mail: lenya-user-help@cocoon.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: lenya-user-unsubscribe@cocoon.apache.org
For additional commands, e-mail: lenya-user-help@cocoon.apache.org


Re: escaped characters

Posted by Michael Wechner <mi...@wyona.com>.
Ethan Schroeder wrote:

> "less than" and "greater than" are converted into &lt; and &gt; when 
> adding blog entries.  I wish markup to stay intact.  Anyone know how I 
> can go about this?


this is a feature in order to be able to have mixed content, e.g.

Hello <i>Ethan</i> &amp; <i>Alice</i>

Michi

>  
> Thanks,
> Ethan



-- 
Michael Wechner
Wyona Inc.  -   Open Source Content Management   -   Apache Lenya
http://www.wyona.com              http://cocoon.apache.org/lenya/
michael.wechner@wyona.com                        michi@apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: lenya-user-unsubscribe@cocoon.apache.org
For additional commands, e-mail: lenya-user-help@cocoon.apache.org