Welcome to Geeklog, Anonymous Saturday, November 23 2024 @ 04:48 pm EST
Geeklog Forums
VB Code highlighter
Status: offline
HighKing Scott
Forum User
Newbie
Registered: 05/10/11
Posts: 5
Location:Malvern, Arkansas
Is there a plugin for Geeklog that will highlight VB code in Stories?
13
12
Quote
Status: offline
::Ben
Forum User
Full Member
Registered: 01/14/05
Posts: 1569
Location:la rochelle, France
Hi,
The jquery plugin bring syntax highlighter from alex gorbatchev and a brushe for Visual Basic (vb, vbnet) is available.
http://alexgorbatchev.com/SyntaxHighlighter/manual/brushes/
Ben
I'm available to customise your themes or plugins for your Geeklog CMS
The jquery plugin bring syntax highlighter from alex gorbatchev and a brushe for Visual Basic (vb, vbnet) is available.
http://alexgorbatchev.com/SyntaxHighlighter/manual/brushes/
Ben
I'm available to customise your themes or plugins for your Geeklog CMS
10
10
Quote
Status: offline
HighKing Scott
Forum User
Newbie
Registered: 05/10/11
Posts: 5
Location:Malvern, Arkansas
Quote by: %3A%3ABen
Hi,
The jquery plugin bring syntax highlighter from alex gorbatchev and a brushe for Visual Basic (vb, vbnet) is available.
http://alexgorbatchev.com/SyntaxHighlighter/manual/brushes/
Ben
I'm sure this works, but I'm not comfortable re-writing PHP code which is why I asked if there was a plugin for geeklog.
8
12
Quote
Status: offline
::Ben
Forum User
Full Member
Registered: 01/14/05
Posts: 1569
Location:la rochelle, France
Yes jQuery plugin is a plugin for geeklog and to highlight VB code you will need to edit 1 line in private/plugins/jquery/functions.inc file ( near line 148 ) :
change from
to
Ben
I'm available to customise your themes or plugins for your Geeklog CMS
change from
Text Formatted Code
$str .= ' brushes: [\'Xml\', \'JScript\', \'CSharp\', \'Plain\', \'Php\'],' . LB;to
Text Formatted Code
$str .= ' brushes: [\'Xml\', \'JScript\', \'CSharp\', \'Plain\', \'Php\', \'Vb\'],' . LB;Ben
I'm available to customise your themes or plugins for your Geeklog CMS
12
11
Quote
Status: offline
HighKing Scott
Forum User
Newbie
Registered: 05/10/11
Posts: 5
Location:Malvern, Arkansas
Quote by: %3A%3ABen
to
Ben
Yes jQuery plugin is a plugin for geeklog and to highlight VB code you will need to edit 1 line in private/plugins/jquery/functions.inc file ( near line 148 ) :
change from
Text Formatted Code
$str .= ' brushes: ['Xml', 'JScript', 'CSharp', 'Plain', 'Php'],' . LB;to
Text Formatted Code
$str .= ' brushes: ['Xml', 'JScript', 'CSharp', 'Plain', 'Php', 'Vb'],' . LB;Ben
I made the change as you suggested above and when I put the code in between the (code | /code) tags I get the following result
http://screencast.com/t/cUQwBA9pc
Is there a special function that I need to put with the "Code" tags?
11
9
Quote
Status: offline
::Ben
Forum User
Full Member
Registered: 01/14/05
Posts: 1569
Location:la rochelle, France
You just need to set the class for the code tag.
<pre><code class="vb">
' Your VB code here
</pre><code>
Ben
I'm available to customise your themes or plugins for your Geeklog CMS
Text Formatted Code
<pre><code class="vb">
' Your VB code here
</pre><code>
Ben
I'm available to customise your themes or plugins for your Geeklog CMS
9
11
Quote
Status: offline
HighKing Scott
Forum User
Newbie
Registered: 05/10/11
Posts: 5
Location:Malvern, Arkansas
Geeklog strips the "Class" from the tag, so I tried to add it into the config filter, but that did'nt work either...
Is there any detailed documentation on this or do you just through it out there?
Is there any detailed documentation on this or do you just through it out there?
14
13
Quote
Status: offline
HighKing Scott
Forum User
Newbie
Registered: 05/10/11
Posts: 5
Location:Malvern, Arkansas
Don't worry about it, I just deleted the plugin. I'll use screenshots instead.
10
12
Quote
Status: offline
::Ben
Forum User
Full Member
Registered: 01/14/05
Posts: 1569
Location:la rochelle, France
In the config you can set Skip HTML Filter for Root to true to allow all html tag in your posts and pages.
Config >> Miscellaneous >> HTML filtering
::Ben
I'm available to customise your themes or plugins for your Geeklog CMS
Text Formatted Code
Config >> Miscellaneous >> HTML filtering
::Ben
I'm available to customise your themes or plugins for your Geeklog CMS
9
7
Quote
All times are EST. The time is now 04:48 pm.
- Normal Topic
- Sticky Topic
- Locked Topic
- New Post
- Sticky Topic W/ New Post
- Locked Topic W/ New Post
- View Anonymous Posts
- Able to post
- Filtered HTML Allowed
- Censored Content