2
0
forked from Wavyzz/dolibarr

Merge branch '8.0' of git@github.com:Dolibarr/dolibarr.git into develop

This commit is contained in:
Laurent Destailleur
2018-07-24 19:37:04 +02:00
18 changed files with 79 additions and 29 deletions

View File

@@ -487,10 +487,10 @@ function GETPOST($paramname, $check='none', $method=0, $filter=null, $options=nu
elseif ($reg[1] == 'MONTH') { $tmp=dol_getdate(dol_now(), true); $newout = $tmp['mon']; }
elseif ($reg[1] == 'YEAR') { $tmp=dol_getdate(dol_now(), true); $newout = $tmp['year']; }
elseif ($reg[1] == 'PREVIOUS_DAY') { $tmp=dol_getdate(dol_now(), true); $tmp2=dol_get_prev_day($tmp['mday'], $tmp['mon'], $tmp['year']); $newout = $tmp2['day']; }
elseif ($reg[1] == 'PREVIOUS_MONTH') { $tmp=dol_getdate(dol_now(), true); $tmp2=dol_get_prev_month($tmp['mday'], $tmp['mon'], $tmp['year']); $newout = $tmp2['month']; }
elseif ($reg[1] == 'PREVIOUS_MONTH') { $tmp=dol_getdate(dol_now(), true); $tmp2=dol_get_prev_month($tmp['mon'], $tmp['year']); $newout = $tmp2['month']; }
elseif ($reg[1] == 'PREVIOUS_YEAR') { $tmp=dol_getdate(dol_now(), true); $newout = ($tmp['year'] - 1); }
elseif ($reg[1] == 'NEXT_DAY') { $tmp=dol_getdate(dol_now(), true); $tmp2=dol_get_next_day($tmp['mday'], $tmp['mon'], $tmp['year']); $newout = $tmp2['day']; }
elseif ($reg[1] == 'NEXT_MONTH') { $tmp=dol_getdate(dol_now(), true); $tmp2=dol_get_next_month($tmp['mday'], $tmp['mon'], $tmp['year']); $newout = $tmp2['month']; }
elseif ($reg[1] == 'NEXT_MONTH') { $tmp=dol_getdate(dol_now(), true); $tmp2=dol_get_next_month($tmp['mon'], $tmp['year']); $newout = $tmp2['month']; }
elseif ($reg[1] == 'NEXT_YEAR') { $tmp=dol_getdate(dol_now(), true); $newout = ($tmp['year'] + 1); }
elseif ($reg[1] == 'MYCOMPANY_COUNTRY_ID' || $reg[1] == 'MYCOUNTRY_ID' || $reg[1] == 'MYCOUNTRYID')
{
@@ -5520,7 +5520,7 @@ function dol_string_nohtmltag($stringtoclean, $removelinefeed=1, $pagecodeto='UT
function dol_string_onlythesehtmltags($stringtoclean)
{
$allowed_tags = array(
"html", "head", "meta", "body", "b", "br", "div", "em", "font", "img", "ins", "hr", "i", "li", "link",
"html", "head", "meta", "body", "article", "a", "b", "br", "div", "em", "font", "img", "ins", "hr", "i", "li", "link",
"ol", "p", "s", "section", "span", "strong", "title",
"table", "tr", "th", "td", "u", "ul"
);
@@ -6139,9 +6139,9 @@ function getCommonSubstitutionArray($outputlangs, $onlykey=0, $exclude=null, $ob
$tmp=dol_getdate(dol_now(), true);
$tmp2=dol_get_prev_day($tmp['mday'], $tmp['mon'], $tmp['year']);
$tmp3=dol_get_prev_month($tmp['mday'], $tmp['mon'], $tmp['year']);
$tmp3=dol_get_prev_month($tmp['mon'], $tmp['year']);
$tmp4=dol_get_next_day($tmp['mday'], $tmp['mon'], $tmp['year']);
$tmp5=dol_get_next_month($tmp['mday'], $tmp['mon'], $tmp['year']);
$tmp5=dol_get_next_month($tmp['mon'], $tmp['year']);
$substitutionarray=array_merge($substitutionarray, array(
'__DAY__' => (string) $tmp['mday'],