|
Участник форума
Регистрация: 25.04.2013
Сообщений: 153
С нами:
6868406
Репутация:
2
|
|
pomogite ispravit kod
uyazvim k sql union/based time/blind
proboval parametr intval() no togda nichego ne rabotaet
[PHP]
';$data.="\n";$icononro=0;//if ($tipolinea=="plural") {foreach ($ids as $ id) {
$icononro++;
$sqlcontexto="";
if ($id=="Contexto")$sqlcontexto="AND SUBSTRING(comienza,1,4) >=$mincomienzaAND SUBSTRING(comienza,1,4) ';
//$texto = str_replace("\"",""",$rowchequeo['texto']);
//$texto = htmlentities($rowchequeo['texto']);
$texto="";
if ($id=="Contexto")$texto.="CONTEXTO HISTÓRICO
";
$texto.=$rowchequeo['texto'];
if ($tipolinea=="plural"AND$id!="Contexto")$texto="(".$rowchequeo['escritor'] .")
".$texto;$texto=str_replace("",">",$texto);$texto=str_replace("&","&",$texto);$data.=$texto;
$fechafinal="";
if ($rowchequeo['termina']!="0000-00-00 00:00:00") {$fechafinal.="desde ";
}$fecha1=substr($rowchequeo['comienza'],0,10);$fecha1=explode("-",$fecha1);
if ($fecha1['2']!='00') {$fechafinal.=$fecha1['2'];
if ($fecha1['1']!='00')$fechafinal.=" de ";
}
if ($fecha1['1']!='00')$fechafinal.=$mes[$fecha1['1']]." de ";
$fechafinal.=$fecha1['0'];
if ($rowchequeo['termina']!="0000-00-00 00:00:00") {$fechafinal.=" hasta ";$fecha2=substr($rowchequeo['termina'],0,10);$fecha2=explode("-",$fecha2);
if ($fecha2['2']!='00') {$fechafinal.=$fecha2['2'];
if ($fecha2['1']!='00')$fechafinal.=" de ";
}
if ($fecha2['2']!='00')$fechafinal.=$mes[$fecha2['1']]." de ";
$fechafinal.=$fecha2['0'];
}
$data.=htmlentities("
").'Fecha: '.$fechafinal.htmlentities("");
if ($rowchequeo['tipo_evento']!="Nacimiento") {//echo "nac".substr($nacimiento,0,10)."acon".substr ($startdate,0,10)."..".strtotime(str_replace("-","/",substr($startdate,0,10)));
//echo "**".str_replace("-","/",substr($startdate,0,10));
if ( ($id!="Contexto"ANDstrpos($rowchequeo['tipo_evento'],"stumo")==false) OR ($id=="Contexto"AND$tipolinea=="singular")) {$data.=htmlentities("
Edad: ").birthday_poemas(substr($nacimiento,0,10),substr(str_replace("-","/",$startdate),0,10)).htmlentities(" años");
if ($rowchequeo['termina']!="0000-00-00 00:00:00")$data.=" al comenzar";$data.=htmlentities("");
}
}
if ($rowchequeo['lugar']!="") {$data.=htmlentities("
").'Lugar: '.$rowchequeo['lugar'].htmlentities("
");$buscarlugar=str_replace(", ",",+",$rowchequeo['lugar']);$data.=htmlentities(utf8_decode(''));
}
$data.='';
}// fin de while} // fin de foreach$data .= '';
echo$data;$data=addslashes($data);$query="INSERT INTO wp_extras_relacionados (refid, it emid, tipo, texto) VALUES ('33','33', '$urllinea','$data')";$result=mysql_query($query)
or die(mysql_error());
}mysql_close($conectausuario);?>
|