(append-file symbol symbol) not working?
Posted: Thu Oct 18, 2012 6:34 am
I'm writing a script which takes additional code for the content container from txt files and creates html sites with different content. Now I have a problem.
Stuff like this works:
But, here is a problem.
Stuff like this works:
aktuell is a symbol with e.g. index.html ... other.html from a dolist function(append-file aktuell {<div id="center" style="background-color:#EEEEEE;height:800px;width:420px;font-size:0.875em;float:left;">})
(append-file aktuell "\n")
But, here is a problem.
If I use (trace true) like above I get:(trace true)
(define contentname (chop aktuell 5))
(define contentname (push ".txt" contentname -1))
(change-dir "/home/myUsername/Folder/Content/")
(setq content (read-file contentname))
(change-dir "/home/myUsername/Folder/HTML/")
(append-file aktuell (eval-string (string {(append-file aktuell content)} )))
;; cause (append-file aktuell content) isn't working.
Strange to me is also, that it works through the whole list of html file names, but if I don't use (trace true) it crashes and doesn't create more than a uncomplete index.html. So far it was no problem, cause it created the html files correctly if I had "trace true" into the code, but now a have one more error and it may be related to that.ERR: string expected in function append-file : aktuell}
ERR: string expected : (eval-string (string "(append-file aktuell content)"))
ERR: missing argument