Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LibXML2 2.9.0+ problems #100

Closed
jumph4x opened this issue Jul 22, 2013 · 1 comment
Closed

LibXML2 2.9.0+ problems #100

jumph4x opened this issue Jul 22, 2013 · 1 comment

Comments

@jumph4x
Copy link

jumph4x commented Jul 22, 2013

Symptoms identical to #84.

Ends up generating invalid html by prematurely closing </head> and dumping all head contents into <body>.

Cause: libxml2[-dev]-2.9.0 on Ubuntu 13.04 (and probably other stuffs).

Solution: installed synaptic and added quantal repositories. Then used synaptic to force libxml2 to 2.8.0, also required downgrading of libxslt since it uses libxml2 as a dep.

Now outputting HTML correctly.

@swrobel
Copy link

swrobel commented Aug 8, 2013

My guess is this is because LibXML2 2.9.0+ is actually being more strict (correct?) about what is allowed in <head> like in my comment on #84 (comment)

@jhawthorn jhawthorn mentioned this issue Sep 3, 2013
jhawthorn added a commit to jhawthorn/deface that referenced this issue Sep 3, 2013
This changes the ERB template parser to use `<erb>` rather than `<code>`
to designate code blocks in a template.

For example:

    <%= render template: 'foo/bar' %>

Used to parse as:

    <code erb-loud> render template: 'foo/bar' </code>

But not parses as:

    <erb erb-loud> render template: 'foo/bar' </erb>

This fixes a number of problems that result from using `<code>`:

* There may be </code> tags in the original ERB, which would be turned
  into `%>`
  (Fixes spree#101)

* Any <code> tags in the <head> of a document would be moved to the
  body, since <code> is a real HTML tag, and isn't allowed in the head.
  This happens in nokogiri under jRuby or libXML 2.9.0
  (Fixes spree#84, Fixes spree#100)
@BDQ BDQ closed this as completed in 415422f Sep 4, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants