Giter Site home page Giter Site logo

Comments (2)

AlfredoRamos avatar AlfredoRamos commented on July 18, 2024

What's the correct way to do this?

@photonstorm You can see how to temporarily disable it in the Helper section on the README.

markdown('Hello world', ['purifier' => false])

Note that the enabled key is not passed when using the facade or the markdown() helper function.

However, if you don't want it enabled anywhere, you can completely turn off in the configuration file by setting this key to false (ref):

[
	'purifier'	=> [
		'enabled'	=> false,
	# Other config keys...
]

Please check the Configuration section for instructions to create a copy of the config file.

from parsedown-extra-laravel.

photonstorm avatar photonstorm commented on July 18, 2024

Thanks for explaining! I honestly feel your answer is so useful it should be part of the README. Especially how you cannot do enabled: false in the config when using the helper function, as that was the first thing I tried.

I've run into loads of problems with HTML Purifier being tyrannical on perfectly valid content (the less said about its treatments of iframes, the better), so this was a last resort but solved everything.

from parsedown-extra-laravel.

Related Issues (13)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.