Welcome to the Question2Answer Q&A. There's also a demo if you just want to try it out.
+1 vote
868 views
in Q2A Core by
Hi,
Is it possible to add SyntaxHighlighter integration with Q2A?

It will be helpful to sites dealing with technical questions and answers like mine.

Found one syntax highlighter here.. looks good..  

http://alexgorbatchev.com/SyntaxHighlighter/

4 Answers

0 votes
by
Sure, you can add any post-processing of the content of a Q/A/C inside thefunction qa_post_html_fields(...) in qa-app-format.php within the section:

if (!empty($post['content'])) {
 ...
}

The whole goal of that section is to convert the raw text into HTML, including filtering blocked words and highlighting URLs.
0 votes
by

If someone stumbles upin this question:

There is a plug-in available here:http://quanda.pl/index.php?qa=download

by
link is not working. I need syntax this plugin
0 votes
by

Since this post was brought up again, I'll just add that the Markdown editor now has an option for syntax highlighting - https://github.com/svivian/q2a-markdown-editor

 

0 votes
by
I needed SyntaxHighlighter integration with CKEditor and Q2A (not markdown, but SyntaxHighlighter itself).

Basically, you need to download ckeditor-syntaxhighlighter, a plugin for CKEditor, copy it into CKEditor's plugin folder and enable it in the config file.

I wrote an article with detailed instructions: http://www.inforbiro.com/blog-eng/question2answer-ckeditor-and-syntaxhiglighter-integration/
...