added: to htmlfilter: html "col" tag is a 'simple' tag
added: ezc functions: winix_function_param_value_is and winix_function_param_value_is_not they take two arguments: param_name and param_value git-svn-id: svn://ttmath.org/publicrep/winix/trunk@780 e52654a7-88a9-db11-a3e9-0013d4bc506e
This commit is contained in:
parent
dce68221ad
commit
d135c31ca0
|
@ -1202,6 +1202,7 @@ void HTMLFilter::CheckExceptions()
|
||||||
IsLastTag(L"img") ||
|
IsLastTag(L"img") ||
|
||||||
IsLastTag(L"link") ||
|
IsLastTag(L"link") ||
|
||||||
IsLastTag(L"param") ||
|
IsLastTag(L"param") ||
|
||||||
|
IsLastTag(L"col") ||
|
||||||
IsLastTag(L"area") )
|
IsLastTag(L"area") )
|
||||||
{
|
{
|
||||||
LastItem().type = Item::simple;
|
LastItem().type = Item::simple;
|
||||||
|
|
|
@ -527,26 +527,27 @@ void ExportThread::ChangeSiteNames(std::string & buf)
|
||||||
// objects not locked
|
// objects not locked
|
||||||
void ExportThread::ChangeAdresses(std::string & buf)
|
void ExportThread::ChangeAdresses(std::string & buf)
|
||||||
{
|
{
|
||||||
// changing: (http or https)
|
// http:// in sources here means either http:// or https://
|
||||||
|
|
||||||
|
// changing:
|
||||||
// http://domain.tld/sitename/[...]/file.jpg/-/thumb -> http://otherdomain.tld/download/[...]/file.jpg
|
// http://domain.tld/sitename/[...]/file.jpg/-/thumb -> http://otherdomain.tld/download/[...]/file.jpg
|
||||||
// http://domain.tld/sitename/[...]/file.jpg/download/thumb -> http://otherdomain.tld/download/[...]/file.jpg
|
// http://domain.tld/sitename/[...]/file.jpg/download/thumb -> http://otherdomain.tld/download/[...]/file.jpg
|
||||||
ChangeAdressesThumb(buf);
|
ChangeAdressesThumb(buf);
|
||||||
|
|
||||||
// changing: (http or https)
|
// changing:
|
||||||
// http://domain.tld/static/sitename/ -> http://otherdomain.tld/static/
|
// http://domain.tld/static/sitename/ -> http://otherdomain.tld/static/
|
||||||
ChangeBaseAdress(buf, "/static", "", "/static/");
|
ChangeBaseAdress(buf, "/static", "", "/static/");
|
||||||
|
|
||||||
// changing: (http or https)
|
// changing:
|
||||||
// http://domain.tld/common/sitename/ -> http://otherdomain.tld/common/
|
// http://domain.tld/common/sitename/ -> http://otherdomain.tld/common/
|
||||||
//ChangeAdresss(buf, "/common", "", "/common/");
|
//ChangeAdresss(buf, "/common", "", "/common/");
|
||||||
|
|
||||||
// changing: (http or https)
|
// changing:
|
||||||
// http://domain.tld/sitename/ -> http://otherdomain.tld/
|
// http://domain.tld/sitename/ -> http://otherdomain.tld/
|
||||||
ChangeBaseAdress(buf, "", "", "/");
|
ChangeBaseAdress(buf, "", "", "/");
|
||||||
|
|
||||||
// changing:
|
// changing:
|
||||||
// http://domain.tld/sitename" -> http://otherdomain.tld"
|
// http://domain.tld/sitename" -> http://otherdomain.tld"
|
||||||
// !! dodac no last slash na zrodle
|
|
||||||
ChangeBaseAdress(buf, "", "\"", "\"", true);
|
ChangeBaseAdress(buf, "", "\"", "\"", true);
|
||||||
|
|
||||||
// changing:
|
// changing:
|
||||||
|
|
|
@ -488,6 +488,8 @@ void Templates::CreateFunctions()
|
||||||
ezc_functions.Insert("winix_function_param_is", winix_function_param_is);
|
ezc_functions.Insert("winix_function_param_is", winix_function_param_is);
|
||||||
ezc_functions.Insert("winix_function_param_is_not", winix_function_param_is_not);
|
ezc_functions.Insert("winix_function_param_is_not", winix_function_param_is_not);
|
||||||
ezc_functions.Insert("winix_function_param_value", winix_function_param_value);
|
ezc_functions.Insert("winix_function_param_value", winix_function_param_value);
|
||||||
|
ezc_functions.Insert("winix_function_param_value_is", winix_function_param_value_is);
|
||||||
|
ezc_functions.Insert("winix_function_param_value_is_not", winix_function_param_value_is_not);
|
||||||
ezc_functions.Insert("winix_has_plugin", winix_has_plugin);
|
ezc_functions.Insert("winix_has_plugin", winix_has_plugin);
|
||||||
ezc_functions.Insert("winix_loadavg_now", winix_loadavg_now);
|
ezc_functions.Insert("winix_loadavg_now", winix_loadavg_now);
|
||||||
ezc_functions.Insert("winix_loadavg_1", winix_loadavg_1);
|
ezc_functions.Insert("winix_loadavg_1", winix_loadavg_1);
|
||||||
|
|
|
@ -411,6 +411,8 @@ namespace TemplatesFunctions
|
||||||
void winix_function_param_is(Info & i);
|
void winix_function_param_is(Info & i);
|
||||||
void winix_function_param_is_not(Info & i);
|
void winix_function_param_is_not(Info & i);
|
||||||
void winix_function_param_value(Info & i);
|
void winix_function_param_value(Info & i);
|
||||||
|
void winix_function_param_value_is(Info & i);
|
||||||
|
void winix_function_param_value_is_not(Info & i);
|
||||||
void winix_has_plugin(Info & i);
|
void winix_has_plugin(Info & i);
|
||||||
void winix_loadavg_now(Info & i);
|
void winix_loadavg_now(Info & i);
|
||||||
void winix_loadavg_1(Info & i);
|
void winix_loadavg_1(Info & i);
|
||||||
|
|
|
@ -77,6 +77,22 @@ void winix_function_param_value(Info & i)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// first parameter is param_name
|
||||||
|
// second parameter is param_value
|
||||||
|
void winix_function_param_value_is(Info & i)
|
||||||
|
{
|
||||||
|
if( i.params.size() == 2 )
|
||||||
|
i.res = (cur->request->ParamValue(i.params[0]) == i.params[1]);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void winix_function_param_value_is_not(Info & i)
|
||||||
|
{
|
||||||
|
if( i.params.size() == 2 )
|
||||||
|
i.res = (cur->request->ParamValue(i.params[0]) != i.params[1]);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
void winix_has_plugin(Info & i)
|
void winix_has_plugin(Info & i)
|
||||||
{
|
{
|
||||||
size_t exist = 0;
|
size_t exist = 0;
|
||||||
|
|
Loading…
Reference in New Issue