mirror of
https://github.com/Relintai/rcpp_framework.git
synced 2025-04-20 01:43:12 +02:00
Added charset helper itno HTMLTag.
This commit is contained in:
parent
53b67b25a2
commit
e1dd9c59a0
@ -58,6 +58,18 @@ HTMLTag *HTMLTag::rel_stylesheet() {
|
||||
return this;
|
||||
}
|
||||
|
||||
HTMLTag *HTMLTag::charset(const std::string &val) {
|
||||
attrib("charset", val);
|
||||
|
||||
return this;
|
||||
}
|
||||
|
||||
HTMLTag *HTMLTag::charset_utf_8() {
|
||||
attrib("charset", "utf-8");
|
||||
|
||||
return this;
|
||||
}
|
||||
|
||||
HTMLTag *HTMLTag::attrib(const std::string &attr, const std::string &val) {
|
||||
result += " " + attr + "=\"" + val + "\"";
|
||||
|
||||
|
@ -24,6 +24,8 @@ public:
|
||||
HTMLTag *type(const std::string &val);
|
||||
HTMLTag *rel(const std::string &val);
|
||||
HTMLTag *rel_stylesheet();
|
||||
HTMLTag *charset(const std::string &val);
|
||||
HTMLTag *charset_utf_8();
|
||||
|
||||
HTMLTag *attrib(const std::string &attr, const std::string &val);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user