Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2016-05-03 14:58:47

Ji31
Member
Registered: 2005-08-24
Posts: 103

Syntax highlighting in articles

Hi,

can someone advice me a ‘living’ code highlighting plugin for a frontend? When I’m looking for the sytnax highlighting, I get just a highlighting for an administration textareas.
But I need ti highlight syntax in my articles for the readers.

Thanks

Offline

#2 2016-05-03 22:02:37

etc
Developer
Registered: 2010-11-11
Posts: 5,028
Website GitHub

Re: Syntax highlighting in articles

Hello,

you don’t really need a plugin for this, just include some js library in your public pages. Take a look at Prism.js for example, it should be easy to integrate (txp uses it on admin-side).

Offline

#3 2016-05-04 11:40:21

Ji31
Member
Registered: 2005-08-24
Posts: 103

Re: Syntax highlighting in articles

etc wrote #298953:

Hello,

you don’t really need a plugin for this, just include some js library in your public pages. Take a look at Prism.js for example, it should be easy to integrate (txp uses it on admin-side).

Hi etc.

yes, I figured it out later that it is a stupidity what I have written, but I’m not able to delete posts.

Sorry

PS: I have already used highlightjs

Offline

#4 2016-05-04 13:07:30

etc
Developer
Registered: 2010-11-11
Posts: 5,028
Website GitHub

Re: Syntax highlighting in articles

Ji31 wrote #298973:

I’m not able to delete posts.

No problem, this could be useful for someone else.

Offline

Board footer

Powered by FluxBB