0

On my page the following TEXT is getting displayed:

<p>Hello,<br>I am a <a href="http://example.com">text</a></p>

It is not appearing in HTML since Typo3 won't allow me to.

Is there a way to make the browser understand that they are HTML tags? Maybe with jQuery?

Chris
  • 57,622
  • 19
  • 111
  • 137
Pom Canys
  • 369
  • 2
  • 5
  • 16
  • It's an encoding issue. I'm not familiar with Typo3, but does it no have a method of allowing you to enter HTML without it being encoded? – Rory McCrossan May 13 '16 at 13:17
  • @RoryMcCrossan I have tried almost everything but I couldn't find out how to make it allow HTML. The only way as far as I know would be changing the core file but I don't want to do this. – Pom Canys May 13 '16 at 13:24
  • 1
    Select the element with `JQuery`, get the `innerHTML`, then check out this question: http://stackoverflow.com/questions/11047670/creating-a-jquery-object-from-a-big-html-string – Randy May 13 '16 at 13:29
  • @randy thank you, this helped me a lot. – Pom Canys May 13 '16 at 13:51
  • Where is that text coming from? The RTE in the backend? – sven May 14 '16 at 07:34

2 Answers2

0

This is how it works:

var string = '<p>Hello,<br>I am a <a href="http://example.com">text</a></p></a></p>';
$('.tx-felogin-pi1 > div').html(string);
Pom Canys
  • 369
  • 2
  • 5
  • 16
0

Switch the RTE to plain text mode by clicking the <> button.

sven
  • 609
  • 5
  • 14