Remove erroneous custom HTML


I added erroneous HTML to the Custom HTML section in Confluence Administration (shame on me) and now I can't rectify it, because I'm locked out.

Is there a possibility to remove all / the specific custom HTML directly from the confluence installation?


5 answers

1 accepted

This widget could not be displayed.

Thanks for your reply, Amalia.

I tried that, but the bug I introduced, resulted in an empty browser window. :) I forgot an </script> tag and the whole page body was considered as part of the script.

Finally, I found someone in our company with knowledge of mySQL and we removed the faulty script via an SQL update.

Now, one question came up to me: Shouldn't the editor of Custom HTML check for such simple errors that have such big consequences?

You should always test things like this in another instance. Even if jira checked for closing tags and so on, it couldn't catch all logic errors. A simple check would just give a false sense of security.

Happily enough it was our staging instance of confluence I messed up. :) But nevertheless, it gave me some embarassment.

I agree, that user can't exspect a fully-featured HTML editor in Confluence, but I also think that some essential checks to avoid lock-out problems wouldn't be just convenient but necessary.

This widget could not be displayed.

Just wanted to add my agreement that it is not acceptable that the 'Custom HTML' editor seems to have no checks whatsoever on the code entered.  It does not have to be a full HTML-syntax checker, but the fact that a missing </script> tag can render your Confluence instance irretrievably hosed, has been a long-standing problem from Confluence 2 through Confluence 5.

A Restore to Default button would also be nice ... for those of us who can see the editor, but can't edit the text boxes.

This widget could not be displayed.

You can navigate your browser directly to <confluence-url>/admin/viewcustomhtml.action to delete/remove the custom HTML

This widget could not be displayed.
Hi Kirstin, Would you mind sharing the sql script you used? Thanks!

Sorry, Abilene. It's too long ago, we couldn't reconstruct the SQL statement.

My colleague who has mySQL knowledge told me that he

  • made a database dump
  • searched for the faulty script in this dump
  • looked for the BANDANAID of the database record, containing the content we wanted to remove
  • applied an update (which removed the custom HTML) to this database record with this BANDANAID

Hope that gives you a hint.

This widget could not be displayed.
Thanks Kirstin. These steps helped a lot. :)

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Sep 17, 2018 in Confluence

Why start from scratch? Introducing four new templates for Confluence Cloud

Hi my Community friends!  For those who don't know me, I'm a product marketer on the Confluence Cloud team - nice to meet you! For those of you who do, you know that I've been all up in your Co...

539 views 7 6
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you