[Klone-users] How to replace .kl1 to .html
Alex Effractor
effractor at gmail.com
Sat Mar 28 07:03:25 EDT 2009
Hi,
Maybe I describe my trouble not clear. I had a web site with a lot of
dynamic .kl1 pages, and my task was showing to user's browser .html pages,
not .kl1. I found a solution for that problem -- I fixed one line in
translat.c file:
static int is_a_script(const char *filename)
{
static const char *script_ext[] = {
".klone", ".kl1", ".klc",
".klx", /* C++ page */
".html", /* my code */
NULL
};
const char **ext;
...
It works well -- now I have a .html files with C code :)
I know that better way is change config filet but I can't find info about
adding new built-in extensions to klone. In line 267 of translat.c file I
found that text:
/* should choose the right translator based on file extensions or config
*/
if(is_a_script(pti->file_in))
{
...
But I can't find any call of functions that have deal with config file, so I
think that changing built-in script extensions via config files does not
implemented yet. I use klone v.2.1.1
PS.
Sorry for my bad English :)
Alex
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://koanlogic.com/pipermail/klone-users/attachments/20090328/075b70f6/attachment.html
More information about the klone-users
mailing list