[tag]Ron Fredericks[/tag] writes: In my last two posts:
- I discovered [tag]Dean Lee[/tag]’s [tag]Code Highlighter[/tag] plugin for [tag]Wordpress[/tag] as the blogging solution for my source code display needs.
- I fixed a word wrap problem in Dean’s plugin.
During my research to solve the word wrap problem, I discovered a few more issues leading me to update Dean’s plugin with the latest version of GeSHI (an open-source project: Generic Syntax Highlighter for php. Highlight many languages, including PHP, CSS, HTML, SQL, Java, Assembler, and C for XHTML compliant output) and removal of unused files. I thought other WordPress bloggers might like to take advantage of the latest code too, so I document the steps needed to build a clean [tag]plugin[/tag] with the latest [tag]component[/tag]s.
[tag]Flow Chart[/tag] / [tag]Swim Lanes[/tag] Widget
Below is a [tag]Flash[/tag] [tag]widget[/tag] I built to document the steps needed so you can roll your own up-to-date plugin. Follow these steps and you won’t have to be a programmer to get the benefits from the latest versions of these program components. The widget actively links to the latest [tag]PHP[/tag] files and [tag]CSS[/tag] classes:
[flash https://www.embeddedcomponents.com/wp-content/uploads/2007/05/how2installplugin.swf w=450 h=583]
Why Roll Your Own Plugin?
I have been working with components and tools on various projects long enough to realize a common problem. Whenever components are used from different projects, such as Dean’s plugin integrated with the [tag]GeSHi[/tag] language components, each file and/or component continues to receive bug fixes and enhancements in real-time without regard to the other components and files. This is natural because each component’s project is managed by a different group.
So now I have an idea on how to fix this evolving problem of diverging code bases: create a flow-chart showing how to assemble the individual components into a final product. Use swim-lanes to highlight the different component resources being used. Document the whole work-flow into a Flash document so links to other web pages and/or live video’s can be included as hot-links to demonstrate the process.
Detailed Notes on the Problems Solved Here
Here are the issues I solve in this blog post:
- The version of GeSHi included with Dean’s code-base is now obsolete. The latest version of GeSHi includes a few bug fixes and a few new supported languages for syntax highlighting. By the time you read this blog post, perhaps GeSHi will have yet an even more improved and stable code base.
- One of the optional modules supplied by GeSHi, PHP samples found in the “contrib” directory; include a recently-identified security risk if included on a web server – such as your WordPress blog installation. Dean’s plugin includes this GeSHi directory by default.
- Dean’s plugin also includes a Mac temporary file called .DS_Store that is not used by WordPress either.
The Components and Their Versions
Dean’s original code has the following versions:
- WordPress should be version 1.5 or later
- Dean’s Code Highlighter v1.1
- Download link:
www.deanlee.cn/wordpress/code_highlighter_plugin_for_wordpress/ - Dean’s code includes the following GeSHi components:
geshi.php, contrib and geshi directories
GESHI_VERSION, 1.0.7.14 - CSS classes for WordPress template style.css file
www.deanlee.cn/wordpress/code_highlighter_plugin_for_wordpress/#ch_css_class
My rebuilt version of Dean’s plugin has the following components and version detail:
- I’m using Worpress version 2.0.4
- Deans_code_highlighter.php
Version 1.1
Download link:
www.deanlee.cn/wordpress/code_highlighter_plugin_for_wordpress/ - geshi.php, and geshi directory
GESHI_VERSION, 1.0.7.19
Download link:
sourceforge.net/projects/geshi/ - New CSS classes for WordPress template style.css file
Version 1.0 from Embedded Components
www.embeddedcomponents.com/2007/05/how-to-fix-dean-lees-source-code-highlight-plugin/#ch_css_class
A Final Note
The GeSHi code base continues to go through updates. At some point the logic behind my approach – mix and match the latest code from all resources required for Dean’s WordPress plugin – might break down. Perhaps GeSHi will adopt a new interface that’s not suitable to Dean’s WordPress plugin code, for example. In any case, if you are having trouble getting Dean’s plugin to work, I suggest the following:
Revert back to Dean’s complete code base. Install it as he suggests and try it. If Dean’s original code base does not work, then maybe you are not following the install instructions correctly or perhaps WordPress itself is at an incompatible version. If the plugin works, then try replacing code one step at a time. With each new file change, try your updated WordPress plugin to see if it still can be deactivated, reactivated, and highlights code correctly in a blog post. When the offending component has been identified, let me know so we can work out a new swim-lane diagram for others to follow.
Hello! Good Site! Thanks you! xdqlfgouwcli
Comment by yqwvcewism — July 31, 2007 @ 3:01 pm
[…] This post from Ron Fredericks includes a custom Flash widget flowcharting the steps required to get a particular WordPress plugin working — some of the bubbles in the flowchart are “live”, in that you can click them and jump to the appropriate places. Very neat… […]
Pingback by The Third Bit » Blog Archive » I’m Behind the Curve Again — July 31, 2007 @ 3:02 pm
can you sue this in PHP?
Comment by ketan — September 25, 2007 @ 2:58 am
Hi Ketan:
Indeed you can use this in PHP. You can find all the details you need from the GeSHi open-source project located here: http://qbnz.com/highlighter/
Best regards
Comment by Ron Fredericks — September 25, 2007 @ 2:02 pm
Amazing post.
I hope you will check out my website..
Thanks
Comment by Best Folding Chair — December 22, 2007 @ 12:35 am
lexapro compared lexapro v.
Comment by chat lexapro — January 6, 2008 @ 4:06 pm
very interesting.
i’m adding in RSS Reader
Comment by music — January 6, 2008 @ 5:19 pm
??? ??? ??
Embedded Components and Tools Blog Center » Blog Archive » How to build Dean Lee’s Syntax Highlighter from latest components
Trackback by ??? ??? ?? — January 1, 2020 @ 9:31 pm
http://www.markhortours.com link for more info
Embedded Components and Tools Blog Center » Blog Archive » How to build Dean Lee’s Syntax Highlighter from latest components
Trackback by www.markhortours.com link for more info — February 12, 2020 @ 12:55 am
?? ??? ??
Embedded Components and Tools Blog Center » Blog Archive » How to build Dean Lee’s Syntax Highlighter from latest components
Trackback by ?? ??? ?? — February 27, 2020 @ 8:38 pm
?? ?????
Embedded Components and Tools Blog Center » Blog Archive » How to build Dean Lee’s Syntax Highlighter from latest components
Trackback by ?? ????? — March 5, 2020 @ 2:30 pm
??? ???
Embedded Components and Tools Blog Center » Blog Archive » How to build Dean Lee’s Syntax Highlighter from latest components
Trackback by ??? ??? — March 5, 2020 @ 11:16 pm
?????????????????
Embedded Components and Tools Blog Center » Blog Archive » How to build Dean Lee’s Syntax Highlighter from latest components
Trackback by ????????????????? — April 3, 2020 @ 12:45 am
??????
Embedded Components and Tools Blog Center » Blog Archive » How to build Dean Lee’s Syntax Highlighter from latest components
Trackback by ?????? — April 6, 2020 @ 9:55 am
??????????
Embedded Components and Tools Blog Center » Blog Archive » How to build Dean Lee’s Syntax Highlighter from latest components
Trackback by ?????????? — April 15, 2020 @ 3:29 pm
???????
Embedded Components and Tools Blog Center » Blog Archive » How to build Dean Lee’s Syntax Highlighter from latest components
Trackback by ??????? — April 24, 2020 @ 7:25 pm
SM???
Embedded Components and Tools Blog Center » Blog Archive » How to build Dean Lee’s Syntax Highlighter from latest components
Trackback by SM??? — April 28, 2020 @ 2:02 pm
Iammadein.com write an article
Embedded Components and Tools Blog Center » Blog Archive » How to build Dean Lee’s Syntax Highlighter from latest components
Trackback by Iammadein.com write an article — May 2, 2020 @ 6:02 pm
???????
Embedded Components and Tools Blog Center » Blog Archive » How to build Dean Lee’s Syntax Highlighter from latest components
Trackback by ??????? — May 7, 2020 @ 3:39 am
007?????
Embedded Components and Tools Blog Center » Blog Archive » How to build Dean Lee’s Syntax Highlighter from latest components
Trackback by 007????? — May 11, 2020 @ 4:03 pm
Napolin Accident Injury Lawyer
Embedded Components and Tools Blog Center » Blog Archive » How to build Dean Lee’s Syntax Highlighter from latest components
Trackback by Napolin Accident Injury Lawyer — May 14, 2020 @ 6:26 pm
Ontario Lyft Accident Lawyer
Embedded Components and Tools Blog Center » Blog Archive » How to build Dean Lee’s Syntax Highlighter from latest components
Trackback by Ontario Lyft Accident Lawyer — May 14, 2020 @ 6:47 pm
Going at Tech Intheheadline
Embedded Components and Tools Blog Center » Blog Archive » How to build Dean Lee’s Syntax Highlighter from latest components
Trackback by Going at Tech Intheheadline — May 14, 2020 @ 7:31 pm
Ontario Auto Accident
Embedded Components and Tools Blog Center » Blog Archive » How to build Dean Lee’s Syntax Highlighter from latest components
Trackback by Ontario Auto Accident — May 19, 2020 @ 1:05 pm
?????
Embedded Components and Tools Blog Center » Blog Archive » How to build Dean Lee’s Syntax Highlighter from latest components
Trackback by ????? — May 19, 2020 @ 3:56 pm
??????
Embedded Components and Tools Blog Center » Blog Archive » How to build Dean Lee’s Syntax Highlighter from latest components
Trackback by ?????? — May 22, 2020 @ 12:58 pm
??????
Embedded Components and Tools Blog Center » Blog Archive » How to build Dean Lee’s Syntax Highlighter from latest components
Trackback by ?????? — June 22, 2020 @ 1:36 pm
???????
Embedded Components and Tools Blog Center » Blog Archive » How to build Dean Lee’s Syntax Highlighter from latest components
Trackback by ??????? — June 26, 2020 @ 6:18 pm
??????
Embedded Components and Tools Blog Center » Blog Archive » How to build Dean Lee’s Syntax Highlighter from latest components
Trackback by ?????? — July 18, 2020 @ 12:47 am
??????
Embedded Components and Tools Blog Center » Blog Archive » How to build Dean Lee’s Syntax Highlighter from latest components
Trackback by ?????? — August 17, 2020 @ 7:20 am
??????????
Embedded Components and Tools Blog Center » Blog Archive » How to build Dean Lee’s Syntax Highlighter from latest components
Trackback by ?????????? — September 8, 2020 @ 5:43 pm
We wish to thank you again for the wonderful ideas you gave Jeremy
when preparing her own post-graduate research and, most importantly, pertaining to providing each of the ideas in one blog post.
If we had been aware of your site a year ago, i’d have
been saved the unwanted measures we were employing. Thank you very much.
Comment by apartments lafeyette la — October 7, 2020 @ 2:26 pm