Hey, folks. Appreciate your help. The DNN code editor reformats comments when the HTML module is saved. For example, this is what I want:
</div> <!-- End Card --> </div> <!-- End Book Item --> <!-- Insert new book card above this line --> </div> <!-- End Row --> </div> <!-- End Container -->
But when I save the HTML module, this is what I get:
</div> <!-- END CARD --></div> <!-- END BOOK ITEM --><!-- INSERT NEXT BOOK ABOVE HERE --></div> <!-- END ROW --></div> <!-- END CONTAINER -->
Is there a way to lock in my formatting when the code is saved? Thank you.
John
See: https://dnncommunity.org/...-is-cleaning-my-HTML
Hmm, I'm not sure if my previous link helps against reformatting. When you want exact control over the HTML, IMO it's better to use a structured content module like Open Content or 2sxc
The DNN HTML Editor is not a very good fit in that case (and not made for it).
As a general rule, there still remains not a single HTML editor that handles the HTML source exactly the way some of us "power users" will expect. Something will undoubtedly get changed or removed. A large number of these instances are related to the syntax updating faster than the various online editors. However, the biggest reason is that most of these editors are trying to protect the rest of the users that are using the same tool.
So, as Timo suggested, if you want full and unbridled control over your HTML, you really should use any structured content solution out there. Lucky for us all, the two most popular ones are both open-source and listed for you below. 😎
These Forums are dedicated to the discussion of DNN Platform.
For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:
Awesome! Simply post in the forums using the link below and we'll get you started.