+csv dep for PG'OCaml.
[cocanwiki.git] / scripts / edit_page_css.ml
index 8b18b9b..70be88e 100644 (file)
@@ -1,7 +1,7 @@
 (* COCANWIKI - a wiki written in Objective CAML.
  * Written by Richard W.M. Jones <rich@merjis.com>.
  * Copyright (C) 2004 Merjis Ltd.
- * $Id: edit_page_css.ml,v 1.23 2006/08/14 11:36:50 rich Exp $
+ * $Id: edit_page_css.ml,v 1.25 2006/12/06 09:46:57 rich Exp $
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
@@ -79,9 +79,10 @@ let run r (q : cgi) dbh hostid {hostname = hostname} user =
   let pageid = PGOCaml.serial4 dbh "pages_id_seq" in
 
   PGSQL(dbh) "insert into contents (pageid, ordering,
-                                    sectionname, content, divname, jsgo)
+                                    sectionname, content, divname, divclass,
+                                    jsgo)
               select $pageid as pageid, ordering, sectionname,
-                     content, divname, jsgo
+                     content, divname, divclass, jsgo
                 from contents
                where pageid = $oldpageid";
 
@@ -103,7 +104,7 @@ let run r (q : cgi) dbh hostid {hostname = hostname} user =
                    Template.StdPages.method_ = None;
                    Template.StdPages.params = [ "page", page ] } ] in
   ok ~title:"Stylesheet changed" ~buttons
-    dbh hostid q
+    dbh hostid q
     ("The stylesheet was changed successfully.  " ^
      "Note: You must RELOAD the page to see changes to stylesheets.")