You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by Mark Frazier <mm...@me.com> on 2015/06/29 17:50:39 UTC

Wiki pages not displaying all content?

Anybody know what is up with the Camel wiki pages? They are not displaying the example (source code) content
in Safari, Firefox, or Chrome for me right now.

The content is actually there when “view page source” though.

???????

Re: Wiki pages not displaying all content?

Posted by Nathan Jones <na...@ncjones.com>.
Yeah I posted the same question yesterday. The following Greasemonkey
script fixes the issue for me:

// ==UserScript==
// @name        Camel Code Snippets
// @namespace   ncjones
// @include     https://camel.apache.org/*
// @version     1
// @grant       none
// ==/UserScript==

document.getElementsByClassName('codeContent').forEach(function(codeDiv) {
  var script = codeDiv.querySelector('script');
  var oParser = new DOMParser();
  var oDOM = oParser.parseFromString('<p>' + script.innerHTML + '</p>',
"text/xml");
  var codeText = oDOM.childNodes[0].childNodes[0].textContent;
  codeDiv.innerHTML = '<pre>' + codeText + '</pre>';
});

On 30/06/15 03:50, Mark Frazier wrote:
> Anybody know what is up with the Camel wiki pages? They are not displaying the example (source code) content
> in Safari, Firefox, or Chrome for me right now.
> 
> The content is actually there when “view page source” though.
> 
> ???????
>