Monthly Archives: January 2011

Integrating CKEditor into the ErfurtWiki system

Today I was trying to integrate CKEditor into the wiki system called ErfurtWiki, which I use as an internal documentation for one of my projects. The reason why I decided to use CKEditor is problem with encoding of czech characters in ErfurtWiki. Those characters are transformed into the html entities, which makes the topics hard to read when editing again.
But implementation of CKEditor in this case is not as easy as one would expect. The problem here is with html tags, which are also automatically transformed into the html entities. So when the topic is saved html tags appear as text.
To allow use html tags in topics in ErfurtWiki follow these steps:

Set follwing constants:
define(“EWIKI_ALLOW_HTML”, 1);
define(“EWIKI_HTML_CHARS”, 1);

Disable transformation of html tags into html entities:
$ewiki_config[“htmlentities”] = array();

And finally change the textarea to appear as CKEditor:
<script type=”text/javascript”>
window.onload = function()
CKEDITOR.replace(‘ewiki_content’, {
toolbar : [
[ ‘Source’ ]
forceEnterMode : true,
forcePasteAsPlainText : true,

Replacing files in existing MSI packages

Today I faced a problem where I needed to replace one file in existing MSI package. I did not want to rebuild the package again from SVN using some branch or tag. So I was looking for some utility, which would allow me to replace a file in MSI with new version. There is an Orca utility in the Windows SDK, but doing such operation with it is quite tricky.
After some digging I found quite nice application on the internet which allows you rebuild cab files inside the MSI and so allows you to replace files. The application is called InstEd.
Download the free version and open it. It looks a bit similar to the Orca, but has more features. To replace file in a specified cab, you have to first put the files next to the MSI package using the same folder structure as defined in the MSI. Find file you would like to update and replace it. Then go to the Tables tab and select Media. Right click the cab, which contains the updated file and click Rebuild selected CABs. After replace is finished save the MSI and you are done.