示例#1
0
  	  If (!isset($TimeStamp)) $TimeStamp=date("Y-m-d H:i:s"); else $TimeStamp=_StringToDate($TimeStamp);
  	  //$Stamp=strtotime($TimeStamp);
  	  
	//http://localhost/FZZ/mzData.php?&TypeData=Attaque&TimeStamp=06/05/2007_22:00:02&TiD=28468&Attaque=0&MeID=1479841&DEG=140&REG=0&SR=0&RM=0&ARM=3&NIV=0&ESQ=15&AGE=Nouvelle&CODE=%0AVous%20avez%20%3Cb%3ER%C9USSI%3C/b%3E%20%E0%20utiliser%20cette%20comp%E9tence%20%3Cb%3E%2818%20sur%2086%20%25%29%3C/b%3E.%3Cp%3EVotre%20%3Cb%3EJet%20d%27am%E9lioration%3C/b%3E%20est%20de%20%3Cb%3E34%3C/b%3E.%3Cbr%3EVous%20n%27avez%20donc%20%3Cb%3Epas%20r%E9ussi%20%E0%20am%E9liorer%3C/b%3E%20cette%20comp%E9tence.%3C/p%3E%3Cp%3EVous%20avez%20attaqu%E9%20une%20Manticore%20Gargantuesque%20%5BNouvelle%5D%20%281479841%29%3Cbr%3E%3C/p%3E%3Cp%3EVotre%20Jet%20d%27Attaque%20est%20de............................%3A%2067%3Cbr%3ELe%20Jet%20d%27Esquive%20de%20votre%20adversaire%20est%20de...%3A%2017%3C/p%3E%3Cp%3EVous%20avez%20donc%20%3Cb%3ETOUCH%C9%3C/b%3E%20votre%20adversaire%20par%20un%20coup%20critique%3C/p%3E%3Cp%3EVous%20lui%20avez%20inflig%E9%20%3Cb%3E78%20points%20de%20d%E9g%E2ts%3C/b%3E.%3Cbr%3ESon%20Armure%20le%20prot%E8ge%20et%20il%20ne%20perdra%20que%20%3Cb%3E75%20points%20de%20vie%3C/b%3E.%3Cbr%3EIl%20sera%2C%20de%20plus%2C%20fragilis%E9%20lors%20des%20prochaines%20esquives.%3C/p%3E%3Cp%3EPour%20cette%20action%2C%20vous%20avez%20gagn%E9%20un%20total%20de%20%3Cb%3E2%20PX%3C/b%3E.%3C/p%3E%3Cp%3EVous%20avez%20attaqu%E9%20une%20Manticore%20Gargantuesque%20%5BNouvelle%5D%20%281479841%29%3Cbr%3E%3C/p%3E%3Cp%3EVotre%20Jet%20d%27Attaque%20est%20de............................%3A%2056%3Cbr%3ELe%20Jet%20d%27Esquive%20de%20votre%20adversaire%20est%20de...%3A%2015%3C/p%3E%3Cp%3EVous%20avez%20donc%20%3Cb%3ETOUCH%C9%3C/b%3E%20votre%20adversaire%20par%20un%20coup%20critique%3C/p%3E%3Cp%3EVous%20lui%20avez%20inflig%E9%20%3Cb%3E68%20points%20de%20d%E9g%E2ts%3C/b%3E.%3Cbr%3ESon%20Armure%20le%20prot%E8ge%20et%20il%20ne%20perdra%20que%20%3Cb%3E65%20points%20de%20vie%3C/b%3E.%3Cbr%3EVous%20l%27avez%20%3Cb%3ETU%C9%3C/b%3E%20d%E9barrass%E9%20le%20Monde%20Souterrain%20de%20sa%20pr%E9sence%20mal%E9fique.%3Cbr%3E%3Cbr%3EIl%20a%2C%20de%20plus%2C%20laiss%E9%20tomber%20un%20tr%E9sor%20et%20%3Cstrong%3E2%20centaines%20de%20Gigots%20de%20Gob%27%3C/strong%3E.%3C/p%3E%3Cp%3EVous%20n%27avez%20gagn%E9%20%3Cb%3Eaucun%20PX%3C/b%3E%20pour%20cette%20action.%20%3C/p%3E%3Cp%3E%0A%0A
	

	  $mysql=_sqlconnect();	# -------------- Ouverture DB  
	  for ($i=0; $i<sizeof($MeID); $i++) {

		// ==-- On vérifie que la donnée n'est pas déjà saisie --===================
		$Filter_Att="Attaque='$Attaque'";
		if (($Attaque=='IdSort') || ($Attaque=='IdComp')) $Filter_Att="Attaque like '$Attaque%'"; 	// sur message du bot, elargir le critère
		
		//$query =  "select distinct TimeStamp from `MZ_Attaque` where ".roundTime("TimeStamp", $TimeStamp)." and Tid=$TiD and $Filter_Att and MeID=$MeID[$i] and DEG=$DEG[$i] and REG='$REG' and SR=$SR[$i] and RM='$RM[$i]' and ARM=$ARM[$i] and NIV=$NIV and ESQ=$ESQ[$i]";
		// reduction du filtre car Attaque pas toujours bien saisie et le SR a put changer. 		
		$query =  "select distinct TimeStamp from `MZ_Attaque` where ".roundTime("TimeStamp", $TimeStamp)." and Tid=$TiD and MeID=$MeID[$i] and DEG=$DEG[$i] and REG='$REG' and RM='$RM[$i]' and ARM=$ARM[$i] and NIV=$NIV and ESQ=$ESQ[$i]";
		//echo "$query<BR>";
		$result = MySQL_QUERY($query);
		if (@MySQL_NUM_ROWS($result)>0)  die("setDBMsgZZ('Attaque déjà dans la DB de ZoryaZilla!'); ");		// à 15 seconde près (différence entre date MH et capture de la page
		// ==-- fin de vérification de la donnée n'est pas déjà saisie --===========
  	  	  
	  	  //$TimeStamp=date("Y-m-d H:i:s",mktime(date("H",$Stamp),date("i",$Stamp),date("s",$Stamp)+$i,date("m",$Stamp),date("d",$Stamp),date("Y",$Stamp)));
		  $query =  "INSERT INTO `MZ_Attaque` Values('$TimeStamp', $TiD, '$Attaque', $MeID[$i], $DEG[$i], '$REG', $SR[$i], '$RM[$i]', $ARM[$i], $NIV, $ESQ[$i])";
		  //echo "//$query<BR>";
	  	  $result = MySQL_QUERY($query);
	  }
      #$UpdateCDM="";	# Mise à jour de la DB avec niveau et RM s'il y a les infos.
	  #if ($NIV>0) $UpdateCDM.="NivMin=$NIV, NivMax=$NIV, ";
	  #if (substr($RM,0,1)=="=") $UpdateCDM.="RMMin=".substr($RM,1).", RMMax=".substr($RM,1).", ";
	  #if ((isset($AGE)) && ($UpdateCDM!="")) {
	  #   $query =  "UPDATE `MZ_CdmPUB` SET $UpdateCDM Id=$MeID where (Id=$MeID) and (Age=\"$AGE\")";
    echo '<div class="col-md-6">';
    echo '<div class="panel panel-default">';
    echo '<div class="panel-heading">Comments </div>';
    echo '<div class="panel-body">' . $comments . '</div>';
    echo '</div></div>';
}
?>
		    	</div>

		    	<?php 
$llmc_lgu = "";
$str_entry_timestamp = strtotime($release[0]->entry_timestamp);
if (isInstantaneous($str_entry_timestamp)) {
    $str_entry_timestamp = roundTime($str_entry_timestamp) - 4 * 3600;
} else {
    $str_entry_timestamp = roundTime($str_entry_timestamp);
}
$temp = date("j F Y, h:i A", $str_entry_timestamp + 3.5 * 3600);
$time = date("h:i A", $str_entry_timestamp + 3.5 * 3600);
$time = date_create_from_format('h:i A', $time);
$date1 = date_create('3:30 PM');
$date2 = date_create('7:30 AM');
if ($time > $date1 || $time < $date2) {
    if ($time > $date1) {
        $datetime = date("j F Y,", strtotime('+1 day', strtotime($temp))) . " 7:30 AM";
    } else {
        $datetime = date("j F Y,", strtotime($temp)) . " 7:30 AM";
    }
} else {
    $datetime = $temp;
}
?>
images/bulletin/alert-table.png"><i>Alert Levels and Recommended Responses</a></i> for references.</p></div>
				</div>

			</div>
		</div>

	</div>
</div>


<div class="row rowIndent" id="footer">
	<div class="col-sm-12">
		<div class="row">
    		<?php 
$next_release = isInstantaneous(strtotime($release->data_timestamp)) ? roundTime(strtotime($release->data_timestamp)) : roundTime(strtotime($release->data_timestamp)) + 4 * 3600;
if ($public_alert_level != 'A0') {
    echo '<b>Next bulletin on: </b>' . amPmConverter(date("j F Y, h:i A", $next_release));
}
?>
		</div>    
    	<div class="row" style="margin-top: 5px; margin-bottom: 5px;"><b>Prepared by: </b>
    	<?php 
preg_match_all('#([A-Z]+)#', $reporters['reporter_mt'], $matches);
foreach ($matches[0] as $key) {
    echo $key;
}
echo ", ";
preg_match_all('#([A-Z]+)#', $reporters['reporter_ct'], $matches);
foreach ($matches[0] as $key) {
    echo $key;