X-Git-Url: https://git.pterodactylus.net/?a=blobdiff_plain;f=include%2Fhttp%2Fipagehandler.h;h=f6f2cc042597a5999ee58b6cb4767202a44ce940;hb=f2545574af789b63fc655decfe31a3d9f1b30504;hp=11bdc229ff2769813f9bab2a7bb8048b7c4b64ed;hpb=fcb124f8d6d3f5678e82049fb8e5e23c8cfaec6d;p=fms.git diff --git a/include/http/ipagehandler.h b/include/http/ipagehandler.h index 11bdc22..f6f2cc0 100644 --- a/include/http/ipagehandler.h +++ b/include/http/ipagehandler.h @@ -16,9 +16,9 @@ class IPageHandler:public Poco::Net::HTTPRequestHandler,public ILogger { public: IPageHandler() {} - IPageHandler(const std::string &templatestr) { m_template=templatestr; } + IPageHandler(const std::string &templatestr, const std::string &pagename):m_template(templatestr),m_pagename(pagename) { } virtual ~IPageHandler() {} - virtual const bool WillHandleURI(const std::string &uri)=0; + virtual const bool WillHandleURI(const std::string &uri); virtual IPageHandler *New()=0; // returns a new instance of the object @@ -39,8 +39,11 @@ protected: // replaces html elements with encoded characters (i.e. < becomes <) const std::string SanitizeOutput(const std::string &input); + // don't replace space with  , because browser might convert to unicode non breaking space character + const std::string SanitizeTextAreaOutput(const std::string &input); std::string m_template; + std::string m_pagename; };