#include "../../../include/http/pages/addpeerpage.h"\r
#include "../../../include/stringfunctions.h"\r
-#include "../../../include/datetime.h"\r
+\r
+#include <Poco/DateTime.h>\r
+#include <Poco/DateTimeFormatter.h>\r
\r
#ifdef XMEM\r
#include <xmem.h>\r
\r
if(queryvars.find("formaction")!=queryvars.end() && (*queryvars.find("formaction")).second=="add")\r
{\r
- DateTime date;\r
+ Poco::DateTime date;\r
std::string publickey="";\r
if(queryvars.find("publickey")!=queryvars.end())\r
{\r
}\r
if(publickey!="" && publickey.find("SSK@")==0 && publickey[publickey.size()-1]=='/')\r
{\r
- date.SetToGMTime();\r
SQLite3DB::Statement st=m_db->Prepare("INSERT INTO tblIdentity(PublicKey,DateAdded,AddedMethod) VALUES(?,?,?);");\r
st.Bind(0,publickey);\r
- st.Bind(1,date.Format("%Y-%m-%d %H:%M:%S"));\r
+ st.Bind(1,Poco::DateTimeFormatter::format(date,"%Y-%m-%d %H:%M:%S"));\r
st.Bind(2,"manually");\r
st.Step();\r
st.Reset();\r
content+="<input type=\"submit\" value=\"Add\">";\r
content+="</form>";\r
\r
- return "HTTP/1.1 200 OK\r\nContent-Type: text/html\r\n\r\n"+StringFunctions::Replace(m_template,"[CONTENT]",content);\r
+ return StringFunctions::Replace(m_template,"[CONTENT]",content);\r
}\r
\r
const bool AddPeerPage::WillHandleURI(const std::string &uri)\r