Re: PRoblem with consulting tables.
Posted by:
Jose Numis
Date: March 07, 2017 03:30AM
I tried this but no working
$busqueda=mysql_query("SELECT c.Oficina, c.telefono, c.direccion, c.cp, c.Municipio, c.Provincia, c.CCAA, c.delegadoDR,c.ofi, max(cast(STR_TO_DATE(a.fechavisita, '%d/%m/%Y') as date)), c.Oficina FROM registrovisitas a left join oficinas c
ON a.ofi = c.ofi
FROM oficinas WHERE Oficina LIKE '%".$busca."%' OR direccion LIKE '%".$busca."%' OR Municipio LIKE '%".$busca."%' OR Provincia LIKE '%".$busca."%' OR ofi LIKE '%".$busca."%' OR delegadoDR LIKE '%".$busca."%'"
) ;
?>
<table width="1054" border="1" align="left">
<tr>
<td>Oficina</td>
<td>Telefono</td>
<td>ofi</td>
<td>Dirección</td>
<td>CP</td>
<td>Municipio</td>
<td>Provincia</td>
<td>CCAA</td>
<td>DDR</td>
<td>Enlace a Ofi</td>
<td>Registrar</td>
</tr>
<?php
while($muestra=@mysql_fetch_array($busqueda)){
echo '<tr>';
echo '<td>'.$muestra['Oficina'].'</td>';
echo '<td>'.'<a href="tel:+'.$muestra['telefono'].'">'.$muestra['telefono'].'</a>'.'</td>';
echo '<td>'.$muestra['ofi'].'</td>';
echo '<td>'.$muestra['direccion'].'</td>';
echo '<td>'.$muestra['cp'].'</td>';
echo '<td>'.$muestra['Municipio'].'</td>';
Subject
Written By
Posted
Re: PRoblem with consulting tables.
March 07, 2017 03:30AM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.