Ver código fonte

FIX :15373 Reset invalid email script

lmarcouiller 4 anos atrás
pai
commit
a1f26f2b55

+ 2 - 2
htdocs/compta/bank/graph.php

@@ -793,7 +793,7 @@ if ($mode == 'standard')
 	if ($nextmonth > 12) { $nextmonth = 1; $nextyear++; }
 
 	// For month
-	$link = "<a href='".$_SERVER["PHP_SELF"]."?account=".$account.($_GET["option"] != 'all' ? '' : '&option=all')."&year=".$prevyear."&month=".$prevmonth."'>".img_previous('', 'class="valignbottom"')."</a> ".$langs->trans("Month")." <a href='".$_SERVER["PHP_SELF"]."?account=".$account."&year=".$nextyear."&month=".$nextmonth."'>".img_next('', 'class="valignbottom"')."</a>";
+	$link = "<a href='".$_SERVER["PHP_SELF"]."?account=".$account."&year=".$prevyear."&month=".$prevmonth."'>".img_previous('', 'class="valignbottom"')."</a> ".$langs->trans("Month")." <a href='".$_SERVER["PHP_SELF"]."?account=".$account."&year=".$nextyear."&month=".$nextmonth."'>".img_next('', 'class="valignbottom"')."</a>";
 	print '<div class="right clearboth">'.$link.'</div>';
 
 	print '<div class="center clearboth margintoponly">';
@@ -807,7 +807,7 @@ if ($mode == 'standard')
 
 	// For year
 	$prevyear = $year - 1; $nextyear = $year + 1;
-	$link = "<a href='".$_SERVER["PHP_SELF"]."?account=".$account.($_GET["option"] != 'all' ? '' : '&option=all')."&year=".($prevyear)."'>".img_previous('', 'class="valignbottom"')."</a> ".$langs->trans("Year")." <a href='".$_SERVER["PHP_SELF"]."?account=".$account."&year=".($nextyear)."'>".img_next('', 'class="valignbottom"')."</a>";
+	$link = "<a href='".$_SERVER["PHP_SELF"]."?account="."&year=".($prevyear)."'>".img_previous('', 'class="valignbottom"')."</a> ".$langs->trans("Year")." <a href='".$_SERVER["PHP_SELF"]."?account=".$account."&year=".($nextyear)."'>".img_next('', 'class="valignbottom"')."</a>";
 
 	print '<div class="right clearboth margintoponly">'.$link.'</div>';
 

+ 11 - 0
scripts/emailings/reset-invalid-emails.php

@@ -68,6 +68,17 @@ if (!empty($login))
 
 $db->begin();
 
+$myfile = fopen($id, "r") or die("Unable to open file\n");
+$groupofemails=array();
+for ($i=0; $i < MAXEMAILS; $i++)
+{
+	$tmp =fgets($myfile);
+	if ($tmp == null)
+	{
+		break;
+	}
+	$groupofemails[$i] = trim($tmp, "\n");
+}
 
 $myfile = fopen($fileofinvalidemail, "r");
 if (!$myfile)