X-Git-Url: http://git.archive.openwrt.org/?p=project%2Fluci.git;a=blobdiff_plain;f=modules%2Fluci-base%2Fsrc%2Ftemplate_utils.h;h=872ecb072f5ad2bd71bcb498b93c01a1e823e79f;hp=32a79f93bcd33ad30c6e626244b46dd263b68266;hb=ad7dc4a4928e77ae142d0fe040f9e9e64b530e82;hpb=41d2b33087da393453c45f5d923d690c88ee5474 diff --git a/modules/luci-base/src/template_utils.h b/modules/luci-base/src/template_utils.h index 32a79f93b..872ecb072 100644 --- a/modules/luci-base/src/template_utils.h +++ b/modules/luci-base/src/template_utils.h @@ -1,7 +1,7 @@ /* * LuCI Template - Utility header * - * Copyright (C) 2010-2012 Jo-Philipp Wich + * Copyright (C) 2010-2018 Jo-Philipp Wich * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -22,6 +22,8 @@ #include #include #include +#include +#include /* buffer object */ @@ -42,6 +44,8 @@ char * buf_destroy(struct template_buffer *buf); char * utf8(const char *s, unsigned int l); char * pcdata(const char *s, unsigned int l); char * striptags(const char *s, unsigned int l); +char * urlencode(const char *s, size_t *encoded_len); +char * urldecode(const char *s, size_t *decoded_len, bool keep_plus); void luastr_escape(struct template_buffer *out, const char *s, unsigned int l, int escape_xml); void luastr_translate(struct template_buffer *out, const char *s, unsigned int l, int escape_xml);