Questions tagged [syntaxhighlighter]

SyntaxHighlighter is a code coloring JavaScript library made by Alex Gorbatchev. The syntaxes supported include Java, Javascript, XML, C#, C++, PHP, Perl, SQL and many more.

Questions with this tag concern the use or modification in behavior of Alex Gorbatchev's SyntaxHighlighter code decorator. Typically this is used in blogs or documentation sites to render blocks of code easier to read.

161 questions
0
votes
1 answer

Indenting Syntax Highlighter when starting with a php echo

I am using Alex Gorbatchev's Syntax Highlighter to output some code, but I'm getting an issue where it's not retaining the initial indentation if I start the line with a php echo. For example where I would expect the following:
            
            
unfrev
  • 737
  • 1
  • 5
  • 19
0
votes
1 answer

synthax highlighter - editing the highlighted text in textarea element

I have implemented Alex Gorbatchev's Synthax highlighter, and it's working great, however when the user double clicks on the highlighted text(which by then became a div from textarea), it enters the edit mode(generates nameless textarea on the fly…
andre g
  • 27
  • 5
0
votes
1 answer

How to add an older version of syntaxhighlighter

I have added the latest version of Syntax Highlighter (http://alexgorbatchev.com/SyntaxHighlighter/) for my site and it looks like this I have seen in some blogs a Syntax Highlighter version with printer and copy buttons as shown in the following…
Grant
  • 4,413
  • 18
  • 56
  • 82
0
votes
1 answer

How to get the total number of lines with SyntaxHighlighter

Is it possible to have the total number of lines of a sourcecode using SyntaxHighlighter (http://alexgorbatchev.com/SyntaxHighlighter/) please ? I could use the technique defined here : How to get the number of lines in a textarea? But perhaps…
ncrocfer
  • 2,542
  • 4
  • 33
  • 38
0
votes
1 answer

Syntax highlighter doesn't work in blog feeds and mobile version

I have been using syntax highlighter for my blogs which are hosted on Blogger.com, but recently I noticed that the code which has been highlighted by syntax highlighter doesn't appear on blog's feed and on mobile version. I tried to search over…
Rakesh
  • 3,987
  • 10
  • 43
  • 68
-1
votes
2 answers

Code Beautifier Tool for adding readability to the code

I went to the following link and saw they are using some tool which adds number lines and
 tags but I could not find any script which helps doing so, I also want my code to be seen like that. Can someone help me? 
Link:…
Deadpool
  • 7,811
  • 9
  • 44
  • 88
-1
votes
1 answer

Changing background color of SyntaxHighlighter

I'm using SyntaxHighlighter on my website (using Google Blogger) with the default theme, and this HTML code...
int myFunc()
{
  //do something
  return 1;
}
...produces this output (see a temporarily-created webpage…
Gabriel Staples
  • 36,492
  • 15
  • 194
  • 265
-1
votes
1 answer

why is HTML interpreted while displaying it with syntax highlighter

I want to display some PHP in my HTML page using Alex Gorbatchev SyntaxHighlighter plugin. My problem is that some code is interpreted by browser as I don't want to (just want to dispay it as plain text) Code can be found…
hugsbrugs
  • 3,501
  • 2
  • 29
  • 36
-2
votes
1 answer

How to make syntax highlighter work in textarea

I want to syntax highlighter work in textarea http://alexgorbatchev.com/SyntaxHighlighter/
Skyyy
  • 1,539
  • 2
  • 23
  • 60
-3
votes
2 answers

JScript Syntax Highlighter not working, any ideas?

Hello I am hoping someone can help I am trying to use Syntax Highlighter on a web page of mine. I have followed the installation instructions by extracting the following files: shCore.css shThemeDefault.css shCore.js shBrushPowerShell.js Basically…
d4rkcell
  • 147
  • 3
  • 4
  • 11
-4
votes
1 answer

How to highlight Java syntax in a textview?

I know this is an old question but answers available are either not working or depreciated for the newer versions of android. please provide a solution which will work in Android 5.0 and above. @Override protected void onCreate(Bundle…
1 2 3
10
11