mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-08-29 00:11:08 +02:00
yhook: add helper function ParamList_exist()
Origin commit data
------------------
Commit: 9c7ad87cff
Author: vanhofen <vanhofen@gmx.de>
Date: 2016-03-01 (Tue, 01 Mar 2016)
Origin message was:
------------------
- yhook: add helper function ParamList_exist()
This commit is contained in:
@@ -366,6 +366,19 @@ std::string CyhookHandler::BuildHeader(bool cache) {
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool CyhookHandler::ParamList_exist(std::string keyword)
|
||||||
|
{
|
||||||
|
bool exist = false;
|
||||||
|
unsigned int s = ParamList.size();
|
||||||
|
for (unsigned int i = 1; i <= s; i++)
|
||||||
|
{
|
||||||
|
exist = (ParamList[itoa(i)] == keyword);
|
||||||
|
if (exist)
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
return exist;
|
||||||
|
}
|
||||||
|
|
||||||
//=============================================================================
|
//=============================================================================
|
||||||
// Output helpers
|
// Output helpers
|
||||||
//=============================================================================
|
//=============================================================================
|
||||||
|
@@ -199,6 +199,8 @@ public:
|
|||||||
void SendRedirect(const std::string& url) {httpStatus=HTTP_MOVED_TEMPORARILY; NewURL = url; status = HANDLED_REDIRECTION;}
|
void SendRedirect(const std::string& url) {httpStatus=HTTP_MOVED_TEMPORARILY; NewURL = url; status = HANDLED_REDIRECTION;}
|
||||||
void SendRewrite(const std::string& url) {NewURL = url; status = HANDLED_REWRITE;}
|
void SendRewrite(const std::string& url) {NewURL = url; status = HANDLED_REWRITE;}
|
||||||
|
|
||||||
|
bool ParamList_exist(std::string keyword);
|
||||||
|
|
||||||
int _outIndent;
|
int _outIndent;
|
||||||
TOutType outType; // Outputtpe = plain (default)|xml|json
|
TOutType outType; // Outputtpe = plain (default)|xml|json
|
||||||
TOutType outStart(bool single = false);
|
TOutType outStart(bool single = false);
|
||||||
|
Reference in New Issue
Block a user