The Instructure Community will enter a read-only state on November 22, 2025 as we prepare to migrate to our new Community platform in early December.
Read our blog post for more info about this change.
Found this content helpful? Log in or sign up to leave a like!
When wrapping HTML page code in comment tags
<!--
Some lines of HTML page code here
-->
and saving, the commented-out code disappears for good.
This is bad, what can one do?
Solved! Go to Solution.
Looks like that's just code that Canvas won't allow unfortunately. Here's another post someone had on this topic.
If you're using comments to hide things on a page, a workaround could be adding a div around the things you're wanting hidden with a display: none attribute.
EX)
<div style="display: none;">
content you'd like hidden
</div>
Hello @Andreas_Hopf - I like Elijah's suggestion but also wish to share the Canvas HTML Editor Allowlist.
Looks like that's just code that Canvas won't allow unfortunately. Here's another post someone had on this topic.
If you're using comments to hide things on a page, a workaround could be adding a div around the things you're wanting hidden with a display: none attribute.
EX)
<div style="display: none;">
content you'd like hidden
</div>
Ok, thanks. Wish I had known this before.
This has worked for me. Do you know if it gets read aloud by screen readers?
Hello @Andreas_Hopf - I like Elijah's suggestion but also wish to share the Canvas HTML Editor Allowlist.
It is absolutely absurd to me that Canvas has stripped this functionality. Comments tags are incredibly useful, a hidden attribute doesn't change the syntax display in the same way comment tags do, making it much more difficult to navigate longer code.
Community helpTo interact with Panda Bot, our automated chatbot, you need to sign up or log in:
Sign inTo interact with Panda Bot, our automated chatbot, you need to sign up or log in:
Sign in