Se adapta ofertas para que solo tenga nombre, descripcion, foto y pdf en el caso que lo tenga
git-svn-id: https://192.168.0.254/svn/Proyectos.ClaveAudio_Web/trunk@16 44ade383-bb54-5b4f-835b-923f7702b206
This commit is contained in:
parent
75bd9cca22
commit
dd89620ad7
@ -27,7 +27,7 @@
|
|||||||
.oferta_precio {
|
.oferta_precio {
|
||||||
font-family: "Times New Roman", Times, serif;
|
font-family: "Times New Roman", Times, serif;
|
||||||
position: relative;
|
position: relative;
|
||||||
font-size: 36px;
|
font-size: 24px;
|
||||||
color: #CB2C54;
|
color: #CB2C54;
|
||||||
font-weight: normal;
|
font-weight: normal;
|
||||||
top: 12px;
|
top: 12px;
|
||||||
@ -35,6 +35,7 @@
|
|||||||
|
|
||||||
.oferta_texto {
|
.oferta_texto {
|
||||||
font-family: Verdana, Arial, Helvetica, sans-serif;
|
font-family: Verdana, Arial, Helvetica, sans-serif;
|
||||||
|
color: #555555;
|
||||||
font-size: 10px;
|
font-size: 10px;
|
||||||
position: relative;
|
position: relative;
|
||||||
top: 14px;
|
top: 14px;
|
||||||
|
|||||||
@ -80,9 +80,8 @@ var $curTipo;
|
|||||||
|
|
||||||
$conn = db_connect();
|
$conn = db_connect();
|
||||||
if($conn) {
|
if($conn) {
|
||||||
$query = 'SELECT oferta_id, oferta_fab_id, fab_nombre, oferta_categoria, oferta_nombre, oferta_estado, oferta_pvp, oferta_descripcion
|
$query = 'SELECT oferta_id, oferta_fab_id, oferta_categoria, oferta_nombre, oferta_estado, oferta_pvp, oferta_descripcion
|
||||||
FROM shoop_oferta
|
FROM shoop_oferta
|
||||||
LEFT JOIN shoop_fabricantes on (oferta_fab_id=fab_id)
|
|
||||||
WHERE oferta_unidades > 0
|
WHERE oferta_unidades > 0
|
||||||
ORDER BY RAND() LIMIT '. $cuantos;
|
ORDER BY RAND() LIMIT '. $cuantos;
|
||||||
|
|
||||||
@ -107,7 +106,6 @@ var $curTipo;
|
|||||||
'id' => $row['oferta_id'],
|
'id' => $row['oferta_id'],
|
||||||
'estado' => $row['oferta_estado'],
|
'estado' => $row['oferta_estado'],
|
||||||
'fab_id' => $row['oferta_fab_id'],
|
'fab_id' => $row['oferta_fab_id'],
|
||||||
'fab_nombre' => $row['fab_nombre'],
|
|
||||||
'pvp' => $row['oferta_pvp'],
|
'pvp' => $row['oferta_pvp'],
|
||||||
'descripcion' => $row['oferta_descripcion']);
|
'descripcion' => $row['oferta_descripcion']);
|
||||||
// } else {
|
// } else {
|
||||||
|
|||||||
@ -24,19 +24,15 @@ include('../db.php');
|
|||||||
<?php
|
<?php
|
||||||
$conn = db_connect();
|
$conn = db_connect();
|
||||||
if($conn) {
|
if($conn) {
|
||||||
$query = "SELECT oferta_id, oferta_categoria, fab_nombre, oferta_nombre, oferta_estado, oferta_pvp, oferta_unidades, oferta_descripcion
|
$query = "SELECT oferta_id, oferta_categoria, oferta_nombre, oferta_estado, oferta_pvp, oferta_unidades, oferta_descripcion
|
||||||
FROM shoop_oferta
|
FROM shoop_oferta
|
||||||
LEFT JOIN shoop_fabricantes on (oferta_fab_id=fab_id)
|
|
||||||
/* WHERE oferta_unidades > 0 */
|
|
||||||
ORDER BY oferta_categoria, oferta_id";
|
ORDER BY oferta_categoria, oferta_id";
|
||||||
$result = mysql_query($query, $conn);
|
$result = mysql_query($query, $conn);
|
||||||
?>
|
?>
|
||||||
<tr>
|
<tr>
|
||||||
<td width="100" valign="top" class="hdr" align="left">Marca</td>
|
<td width="455" valign="top" class="hdr">Nombre</td>
|
||||||
<td width="355" valign="top" class="hdr">Nombre</td>
|
<td width="100" valign="top" class="hdr" align="right">PVP</td>
|
||||||
<td width="40" valign="top" class="hdr" align="right">Uds.</td>
|
<td width="100" valign="top" class="hdr"> </td>
|
||||||
<td width="80" valign="top" class="hdr" align="right">PVP</td>
|
|
||||||
<td width="90" valign="top" class="hdr"> </td>
|
|
||||||
</tr>
|
</tr>
|
||||||
<?php
|
<?php
|
||||||
$secciones = array('', 'Altavoces', 'Electrónicas', 'Reproductores de CD, convertidores D/A, etc.', 'Varios');
|
$secciones = array('', 'Altavoces', 'Electrónicas', 'Reproductores de CD, convertidores D/A, etc.', 'Varios');
|
||||||
@ -48,26 +44,12 @@ include('../db.php');
|
|||||||
$oferta_nombre = $row['oferta_nombre'];
|
$oferta_nombre = $row['oferta_nombre'];
|
||||||
$oferta_estado = $row['oferta_estado'];
|
$oferta_estado = $row['oferta_estado'];
|
||||||
$oferta_pvp = $row['oferta_pvp'];
|
$oferta_pvp = $row['oferta_pvp'];
|
||||||
$oferta_fab_nombre = $row['fab_nombre'];
|
|
||||||
$oferta_unidades = $row['oferta_unidades'];
|
$oferta_unidades = $row['oferta_unidades'];
|
||||||
$oferta_descripcion = $row['oferta_descripcion'];
|
$oferta_descripcion = $row['oferta_descripcion'];
|
||||||
|
|
||||||
if($oferta_categoria != $curSeccion){
|
|
||||||
$curSeccion = $oferta_categoria;
|
|
||||||
?>
|
|
||||||
<tr>
|
|
||||||
<td colspan="5" class="lbl"><?php echo $secciones[$oferta_categoria]; ?><img src="../_imgs/d.gif" width="15" height="20"></td>
|
|
||||||
</tr>
|
|
||||||
|
|
||||||
<?php
|
|
||||||
}
|
|
||||||
|
|
||||||
?>
|
?>
|
||||||
<tr>
|
<tr>
|
||||||
<td width="100" valign="top" align="left" class="data"><?php echo $oferta_fab_nombre; ?></td>
|
<td valign="top" class="data"> <?php echo '<span class="lbl">' . $oferta_nombre . '</span>' . (strlen($oferta_estado) ? ' (' . $oferta_estado . ')': "") . (strlen($oferta_descripcion) ? '<br> <i>' . $oferta_descripcion . '</i>': "") ; ?></td>
|
||||||
<td width="355" valign="top" class="data"> <?php echo '<span class="lbl">' . $oferta_nombre . '</span>' . (strlen($oferta_estado) ? ' (' . $oferta_estado . ')': "") . (strlen($oferta_descripcion) ? '<br> <i>' . $oferta_descripcion . '</i>': "") ; ?></td>
|
<td valign="top" align="right" class="data"><?php echo number_format($oferta_pvp, 2, ',', '.');; ?></td>
|
||||||
<td width="40" valign="top" align="right" class="data"><?php echo $oferta_unidades; ?></td>
|
|
||||||
<td width="80" valign="top" align="right" class="data"><?php echo number_format($oferta_pvp, 2, ',', '.');; ?></td>
|
|
||||||
<td valign="top" class="data" align="center"> <a href="oferta_edit.php?op=edit&id=<?php echo $oferta_id; ?>" class="button">[ editar ]</a></td>
|
<td valign="top" class="data" align="center"> <a href="oferta_edit.php?op=edit&id=<?php echo $oferta_id; ?>" class="button">[ editar ]</a></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
|
|||||||
@ -70,7 +70,7 @@ define("MAX_SIZE", $max_size);
|
|||||||
</table>
|
</table>
|
||||||
<table border="0" cellspacing="0" cellpadding="0">
|
<table border="0" cellspacing="0" cellpadding="0">
|
||||||
<tr>
|
<tr>
|
||||||
<td><span class="lbl">Categoría</span><br/>
|
<!--td><span class="lbl">Categoría</span><br/>
|
||||||
<select name="oferta_categoria" id="oferta_categoria" style="width:250px">
|
<select name="oferta_categoria" id="oferta_categoria" style="width:250px">
|
||||||
<option value="1">Altavoces</option>
|
<option value="1">Altavoces</option>
|
||||||
<option value="2">Electrónicas</option>
|
<option value="2">Electrónicas</option>
|
||||||
@ -78,7 +78,7 @@ define("MAX_SIZE", $max_size);
|
|||||||
<option value="4">Varios</option>
|
<option value="4">Varios</option>
|
||||||
</select>
|
</select>
|
||||||
<script language="JavaScript" type="text/JavaScript"> selectOption('oferta_categoria', '<?= $oferta_categoria; ?>'); </script>
|
<script language="JavaScript" type="text/JavaScript"> selectOption('oferta_categoria', '<?= $oferta_categoria; ?>'); </script>
|
||||||
</td>
|
</td-->
|
||||||
|
|
||||||
<td rowspan="16" valign="top">
|
<td rowspan="16" valign="top">
|
||||||
<table width="250" border="0" cellspacing="0" cellpadding="0">
|
<table width="250" border="0" cellspacing="0" cellpadding="0">
|
||||||
@ -133,19 +133,19 @@ define("MAX_SIZE", $max_size);
|
|||||||
</tr>
|
</tr>
|
||||||
|
|
||||||
|
|
||||||
<tr>
|
<!--tr>
|
||||||
<td width="200" class= "lbl">Marca</td>
|
<td width="200" class= "lbl">Marca</td>
|
||||||
<td></td>
|
<td></td>
|
||||||
</tr>
|
</tr-->
|
||||||
|
|
||||||
<tr>
|
<!--tr>
|
||||||
<td class="data"><select name="oferta_fab_id" id="oferta_fab_id" style="width:200px" class="data">
|
<td class="data"><select name="oferta_fab_id" id="oferta_fab_id" style="width:200px" class="data">
|
||||||
<option value="" selected>Marcas</option>
|
<option value="" selected>Marcas</option>
|
||||||
<?php include("menu_marcas.php"); ?>
|
<?php include("menu_marcas.php"); ?>
|
||||||
</select>
|
</select>
|
||||||
<script language="JavaScript" type="text/JavaScript"> selectOption('oferta_fab_id', '<?php echo $oferta_fab_id; ?>'); </script>
|
<script language="JavaScript" type="text/JavaScript"> selectOption('oferta_fab_id', '<?php echo $oferta_fab_id; ?>'); </script>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr-->
|
||||||
|
|
||||||
<tr>
|
<tr>
|
||||||
<td width="200" class= "lbl">Nombre</td>
|
<td width="200" class= "lbl">Nombre</td>
|
||||||
@ -157,8 +157,8 @@ define("MAX_SIZE", $max_size);
|
|||||||
<tr><td width="200" class= "lbl">Descripción</td></tr>
|
<tr><td width="200" class= "lbl">Descripción</td></tr>
|
||||||
<tr><td width="" class="data"><textarea name="oferta_descripcion" cols="50"><?= $oferta_descripcion; ?></textarea></td></tr>
|
<tr><td width="" class="data"><textarea name="oferta_descripcion" cols="50"><?= $oferta_descripcion; ?></textarea></td></tr>
|
||||||
|
|
||||||
<tr><td width="200" class= "lbl">Estado</td></tr>
|
<!--tr><td width="200" class= "lbl">Estado</td></tr>
|
||||||
<tr><td width="" class="data"><input name="oferta_estado" style="width:px" value="<?= $oferta_estado; ?>">
|
<tr><td width="" class="data"><input name="oferta_estado" style="width:px" value="<?= $oferta_estado; ?>"-->
|
||||||
|
|
||||||
<tr><td width="200" class= "lbl">PVP</td></tr>
|
<tr><td width="200" class= "lbl">PVP</td></tr>
|
||||||
<tr><td width="" class="data"><input name="oferta_pvp" type="text" value="<?= $oferta_pvp; ?>" size="10" maxlength="10"></td></tr>
|
<tr><td width="" class="data"><input name="oferta_pvp" type="text" value="<?= $oferta_pvp; ?>" size="10" maxlength="10"></td></tr>
|
||||||
|
|||||||
@ -8,38 +8,48 @@
|
|||||||
|
|
||||||
<tr>
|
<tr>
|
||||||
<td width="247" align="center" valign="middle">
|
<td width="247" align="center" valign="middle">
|
||||||
<div class="destacado_foto">
|
|
||||||
<?php
|
|
||||||
//LOGOTIPO FABRICANTE
|
|
||||||
$path = '_logos/c/' . $arrayOferta['fab_id'] . '.gif';
|
|
||||||
if (file_exists($path)) {
|
|
||||||
echo '<img src="'.$path.'"><br>';
|
|
||||||
}
|
|
||||||
?>
|
|
||||||
<img src="_imgs/d.gif" height="6"><br>
|
|
||||||
|
|
||||||
<a href="oferta_ficha.php?id=<?php echo $arrayOferta['id']; ?>"><img src="_ofr/<?php echo $arrayOferta['id']; ?>_247.jpg" border="0" alt=""></a>
|
<div class="destacado_foto">
|
||||||
|
<?php
|
||||||
|
//SI TIENE PDF la imagen irá al pdf si no a la ficha
|
||||||
|
$path_pdf = '_ofr/' . $arrayOferta['id'] . '.pdf';
|
||||||
|
$path_jpg = '_ofr/' . $arrayOferta['id'] . '_247.jpg';
|
||||||
|
if (!file_exists($path_pdf))
|
||||||
|
$path_pdf = "";
|
||||||
|
if (!file_exists($path_jpg))
|
||||||
|
$path_jpg = "";
|
||||||
|
|
||||||
|
if ($path_pdf != "") {
|
||||||
|
$enlace = $path_pdf;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
$enlace = "oferta_ficha.php?id=". $arrayOferta['id'];
|
||||||
|
?>
|
||||||
|
|
||||||
|
<a href="<?php echo $enlace; ?>">
|
||||||
|
<?php
|
||||||
|
if ($path_jpg != "") {
|
||||||
|
?>
|
||||||
|
<img src="<?php echo $path_jpg; ?>" border="0">
|
||||||
|
<?php } ?>
|
||||||
|
</a>
|
||||||
</div>
|
</div>
|
||||||
<div class="destacado_precio"><?php echo ($arrayOferta['pvp'] == '-1' ? 'Consultar' : 'Oferta ' . miNumberFormat($arrayOferta['pvp']) . '<span class="euro">€</span>'); ?></div>
|
|
||||||
</td>
|
</td>
|
||||||
|
|
||||||
<td width="12"><img src="_imgs/d.gif" width="12" alt=""></td>
|
<td width="12"><img src="_imgs/d.gif" width="12" alt=""></td>
|
||||||
|
|
||||||
<td width="279" valign="top">
|
<td width="279" valign="top">
|
||||||
<div class="destacado_tipo azul"><?php echo $arrayOferta['nombre']; ?></div>
|
<div class="tit azul"><a href="oferta_ficha.php?id=<?php echo $arrayOferta['id']; ?>" class="lmod"><?php echo $arrayOferta['nombre']; ?></a></div>
|
||||||
<div class="destacado_modelo"><a href="oferta_ficha.php?id=<?php echo $arrayOferta['id']; ?>" class="lmod"><?php echo $arrayOferta['nombre']; ?></a></div>
|
|
||||||
<div class="oferta_texto"><?php if(strlen($arrayOferta['descripcion'])) { echo substr($arrayOferta['descripcion'], 0, 150) . '...'; } ?></div>
|
|
||||||
|
|
||||||
<div class="producto_ocasion1"><br />Precio PVP: <?php echo $arrayOferta['pvp'];?> €</div>
|
|
||||||
|
|
||||||
<?php
|
|
||||||
//FOLLETO PDF
|
|
||||||
$path = '_ofr/' . $arrayOferta['id'] . '.pdf';
|
|
||||||
if (file_exists($path)) {
|
|
||||||
echo "<br/><a href='". $path ."'>Ver folleto PDF </a>";
|
|
||||||
}
|
|
||||||
?>
|
|
||||||
|
|
||||||
|
<?php $longitud=150;
|
||||||
|
if (($arrayOferta['pvp']=="") || ($arrayOferta['pvp']==0)) {
|
||||||
|
$longitud=200;
|
||||||
|
}
|
||||||
|
else {?>
|
||||||
|
<div class="oferta_precio"><?php echo ($arrayOferta['pvp'] == '-1' ? 'Consultar' : miNumberFormat($arrayOferta['pvp']) . '<span class="euro">€</span>'); ?></div>
|
||||||
|
<?php } ?>
|
||||||
|
<div class="oferta_texto"><?php if(strlen($arrayOferta['descripcion'])) { echo substr($arrayOferta['descripcion'], 0, $longitud); } ?><a href="oferta_ficha.php?id=<?php echo $arrayOferta['id']; ?>" class="mas">[+]</a>
|
||||||
|
</div>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
|
|
||||||
|
|||||||
@ -4,23 +4,43 @@
|
|||||||
<div class="oferta_foto">
|
<div class="oferta_foto">
|
||||||
<table width="100%" height="100%" border="0" cellpadding="0" cellspacing="0">
|
<table width="100%" height="100%" border="0" cellpadding="0" cellspacing="0">
|
||||||
<tr><td valign="middle" align="center">
|
<tr><td valign="middle" align="center">
|
||||||
<a href="oferta_ficha.php?id=<?php echo $arrayOfertas['id']; ?>"><img src="_ofr/<?php echo $arrayOfertas['id']; ?>_168.jpg" width="160" border="0"></a>
|
<?php
|
||||||
|
//SI TIENE PDF la imagen irá al pdf si no a la ficha
|
||||||
|
$path_pdf = '_ofr/' . $arrayOfertas['id'] . '.pdf';
|
||||||
|
$path_jpg = '_ofr/' . $arrayOfertas['id'] . '_168.jpg';
|
||||||
|
if (!file_exists($path_pdf))
|
||||||
|
$path_pdf = "";
|
||||||
|
if (!file_exists($path_jpg))
|
||||||
|
$path_jpg = "";
|
||||||
|
|
||||||
|
if ($path_pdf != "") {
|
||||||
|
$enlace = $path_pdf;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
$enlace = "oferta_ficha.php?id=". $arrayOfertas['id'];
|
||||||
|
?>
|
||||||
|
|
||||||
|
<a href="<?php echo $enlace; ?>">
|
||||||
|
<?php
|
||||||
|
if ($path_jpg != "") {
|
||||||
|
?>
|
||||||
|
<img src="<?php echo $path_jpg; ?>" width="160" border="0">
|
||||||
|
<?php } ?>
|
||||||
|
</a>
|
||||||
</td></tr></table>
|
</td></tr></table>
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
<td width="8"></td>
|
<td width="8"></td>
|
||||||
<td width="152" valign="top">
|
<td width="152" valign="top">
|
||||||
<div class="oferta_marca"><?php echo $arrayOfertas['fab_nombre']; ?><br><span class="azul"><?php echo $arrayOfertas['nombre']; ?></span></div>
|
<div class="tit azul"><?php echo $arrayOfertas['nombre']; ?></div>
|
||||||
|
<?php $longitud=50;
|
||||||
|
if (($arrayOfertas['pvp']=="") || ($arrayOfertas['pvp']==0)) {
|
||||||
|
$longitud=70;
|
||||||
|
}
|
||||||
|
else {?>
|
||||||
<div class="oferta_precio"><?php echo ($arrayOfertas['pvp'] == '-1' ? 'Consultar' : miNumberFormat($arrayOfertas['pvp']) . '<span class="euro">€</span>'); ?></div>
|
<div class="oferta_precio"><?php echo ($arrayOfertas['pvp'] == '-1' ? 'Consultar' : miNumberFormat($arrayOfertas['pvp']) . '<span class="euro">€</span>'); ?></div>
|
||||||
<div class="oferta_texto"><?php if(strlen($arrayOfertas['descripcion'])) { echo substr($arrayOfertas['descripcion'], 0, 150) . '...'; } ?></div>
|
<?php } ?>
|
||||||
<!--div class="producto_ocasion1"><br />Precio PVP: <?php echo $arrayOfertas['pvp'];?> €</div-->
|
<div class="oferta_texto"><?php if(strlen($arrayOfertas['descripcion'])) { echo substr($arrayOfertas['descripcion'], 0, $longitud); } ?><a href="oferta_ficha.php?id=<?php echo $arrayOfertas['id']; ?>" class="mas">[+]</a>
|
||||||
<?php
|
</div>
|
||||||
//FOLLETO PDF
|
|
||||||
$path = '_ofr/' . $arrayOfertas['id'] . '.pdf';
|
|
||||||
if (file_exists($path)) {
|
|
||||||
echo "<br/><a href='". $path ."'>Ver folleto PDF </a>";
|
|
||||||
}
|
|
||||||
?>
|
|
||||||
|
|
||||||
</td></tr>
|
</td></tr>
|
||||||
</table>
|
</table>
|
||||||
|
|||||||
@ -126,20 +126,10 @@ switch($oferta_categoria_id) {
|
|||||||
|
|
||||||
<tr>
|
<tr>
|
||||||
<td width="170" valign="top" class="producto_texto">
|
<td width="170" valign="top" class="producto_texto">
|
||||||
<span class="producto_tipo azul"><?php echo $oferta_categoria_nombre; ?></span><br>
|
|
||||||
<span class="producto_modelo"><?php echo $oferta_nombre; ?></span><br>
|
<span class="producto_modelo"><?php echo $oferta_nombre; ?></span><br>
|
||||||
<span class="producto_tipo azul"><?php echo $oferta_estado; ?></span><!--span class="producto_tipo rojo"> <?php //echo $oferta_unidades; ?> Unidades</span--><br>
|
<span class="producto_precio_ocasion2">PVP: <?php echo $oferta_pvp; ?></span><span class="euro">€</span><br>
|
||||||
<span class="producto_modelo">Oferta PVP:</span> <span class="producto_precio_ocasion2"><?php echo $oferta_pvp; ?><span class="euro">€</span><br>
|
|
||||||
<img src="_imgs/d.gif" width="170" height="6"><br>
|
<img src="_imgs/d.gif" width="170" height="6"><br>
|
||||||
|
|
||||||
<?php
|
|
||||||
//FOLLETO PDF
|
|
||||||
$path = '_ofr/' . $oferta_id . '.pdf';
|
|
||||||
if (file_exists($path)) {
|
|
||||||
echo "<a href='". $path ."'>Ver folleto PDF </a>";
|
|
||||||
}
|
|
||||||
?>
|
|
||||||
|
|
||||||
<a href="oferta_add.php?id=<?= $oferta_id; ?>&precio=<?= $oferta_pvp; ?>&modelo=<?= $oferta_nombre; ?>" onMouseOver="MM_swapImage('comprar','','_imgs/comprb.gif',1)" onMouseOut="MM_swapImgRestore()"><img src="_imgs/compra.gif" name="comprar" width="61" height="13" border="0" id="comprar"></a>
|
<a href="oferta_add.php?id=<?= $oferta_id; ?>&precio=<?= $oferta_pvp; ?>&modelo=<?= $oferta_nombre; ?>" onMouseOver="MM_swapImage('comprar','','_imgs/comprb.gif',1)" onMouseOut="MM_swapImgRestore()"><img src="_imgs/compra.gif" name="comprar" width="61" height="13" border="0" id="comprar"></a>
|
||||||
</td>
|
</td>
|
||||||
|
|
||||||
@ -148,23 +138,30 @@ switch($oferta_categoria_id) {
|
|||||||
|
|
||||||
<td></td>
|
<td></td>
|
||||||
<td width="170" valign="top" align="center">
|
<td width="170" valign="top" align="center">
|
||||||
|
<?php
|
||||||
|
//SI TIENE PDF la imagen irá al pdf si no a la ficha
|
||||||
|
$path_pdf = '_ofr/' . $oferta_id . '.pdf';
|
||||||
|
$path_jpg = '_ofr/' . $oferta_id . '_168.jpg';
|
||||||
|
if (!file_exists($path_pdf))
|
||||||
|
$path_pdf = "";
|
||||||
|
if (!file_exists($path_jpg))
|
||||||
|
$path_jpg = "";
|
||||||
|
|
||||||
<?php
|
if ($path_pdf != "") {
|
||||||
//LOGOTIPO FABRICANTE
|
$enlace = $path_pdf;
|
||||||
$path = '_logos/c/' . $oferta_fab_id . '.gif';
|
|
||||||
if (file_exists($path)) {
|
|
||||||
echo '<img src="'.$path.'"><br>';
|
|
||||||
}
|
}
|
||||||
?>
|
else
|
||||||
<img src="_imgs/d.gif" width="170" height="6"><br>
|
$enlace = "oferta_ficha.php?id=". $oferta_id;
|
||||||
|
?>
|
||||||
|
|
||||||
|
<a href="<?php echo $enlace; ?>">
|
||||||
|
<?php
|
||||||
|
if ($path_jpg != "") {
|
||||||
|
?>
|
||||||
|
<img src="<?php echo $path_jpg; ?>" width="160" border="0">
|
||||||
|
<?php } ?>
|
||||||
|
</a>
|
||||||
|
|
||||||
<?php
|
|
||||||
//IMAGEN ARTICULO OCASION
|
|
||||||
$path = '_ofr/' . $oferta_id . '_168.jpg';
|
|
||||||
if (file_exists($path)) {
|
|
||||||
echo '<img src="'.$path.'"></td></tr>';
|
|
||||||
}
|
|
||||||
?>
|
|
||||||
<tr>
|
<tr>
|
||||||
<td width="170"><img src="_imgs/d.gif" width="170" height="12"></td><td width="8"><img src="_imgs/d.gif" width="8" height="1"></td><td width="170"><img src="_imgs/d.gif" width="170" height="1"></td></tr>
|
<td width="170"><img src="_imgs/d.gif" width="170" height="12"></td><td width="8"><img src="_imgs/d.gif" width="8" height="1"></td><td width="170"><img src="_imgs/d.gif" width="170" height="1"></td></tr>
|
||||||
|
|
||||||
|
|||||||
22
ofertas.php
22
ofertas.php
@ -143,6 +143,12 @@ include('top.htm');
|
|||||||
if($result && $numProductos) {
|
if($result && $numProductos) {
|
||||||
?>
|
?>
|
||||||
<table border="0" cellspacing="0" cellpadding="0" width="528">
|
<table border="0" cellspacing="0" cellpadding="0" width="528">
|
||||||
|
<tr>
|
||||||
|
<td colspan="2" class="lbl">OFERTA<img src="_imgs/d.gif" width="15" height="18"></td>
|
||||||
|
<td width="70" class="lbl" align="right" valign="bottom">PVP Oferta</td>
|
||||||
|
<td width="30"></td>
|
||||||
|
</tr>
|
||||||
|
|
||||||
<?php
|
<?php
|
||||||
$secciones = array('', 'Altavoces', 'Electrónicas', 'Reproductores de CD, convertidores D/A, etc.', 'Varios');
|
$secciones = array('', 'Altavoces', 'Electrónicas', 'Reproductores de CD, convertidores D/A, etc.', 'Varios');
|
||||||
$curSeccion='';
|
$curSeccion='';
|
||||||
@ -157,20 +163,20 @@ include('top.htm');
|
|||||||
$fab_nombre = $row['fab_nombre'];
|
$fab_nombre = $row['fab_nombre'];
|
||||||
$oferta_descripcion = $row['oferta_descripcion'];
|
$oferta_descripcion = $row['oferta_descripcion'];
|
||||||
|
|
||||||
if($oferta_categoria != $curSeccion){
|
// if($oferta_categoria != $curSeccion){
|
||||||
$curSeccion = $oferta_categoria;
|
// $curSeccion = $oferta_categoria;
|
||||||
?>
|
?>
|
||||||
<tr>
|
|
||||||
<td colspan="2" class="lbl"><?= $secciones[$oferta_categoria]; ?><img src="_imgs/d.gif" width="15" height="18"></td>
|
|
||||||
<td width="70" class="lbl" align="right" valign="bottom">PVP Oferta</td>
|
|
||||||
<td width="30"></td></tr>
|
|
||||||
<?php
|
<?php
|
||||||
}
|
// }
|
||||||
?>
|
?>
|
||||||
<tr onMouseOver="overRow(this);return false;" onMouseOut="outRow(this);return false;">
|
<tr onMouseOver="overRow(this);return false;" onMouseOut="outRow(this);return false;">
|
||||||
<td width="10"></td>
|
<td width="10"></td>
|
||||||
<td width="335" valign="top" class="data">
|
<td width="335" valign="top" class="data">
|
||||||
<a href="oferta_ficha.php?id=<?= $oferta_id; ?> " class="pielink"> <b><?=$fab_nombre;?></b> <?= $oferta_nombre . (strlen($oferta_estado) ? '</span>': "") ; ?></a></td>
|
<span class="tit azul"><a href="oferta_ficha.php?id=<?= $oferta_id; ?> " class="pielink"> <?= $oferta_nombre . (strlen($oferta_estado) ? '</span>': "") ; ?></a></span><br/>
|
||||||
|
|
||||||
|
<?php if(strlen($oferta_descripcion)) { echo substr($oferta_descripcion, 0, 150); } ?><a href="oferta_ficha.php?id=<?php echo $oferta_id; ?>" class="mas">[+]</a>
|
||||||
|
|
||||||
|
</td>
|
||||||
<td width="70" valign="top" align="right" class="data"><?= miNumberFormat($oferta_pvp); ?> €</td>
|
<td width="70" valign="top" align="right" class="data"><?= miNumberFormat($oferta_pvp); ?> €</td>
|
||||||
<td width="30" align="right" valign="top"><a href="oferta_add.php?id=<?= $oferta_id; ?>&precio=<?= $oferta_pvp; ?>&modelo=<?= $oferta_nombre; ?>" onMouseOver="MM_swapImage('comprar<?= $oferta_id; ?>','','_imgs/comprbm.gif',1)" onMouseOut="MM_swapImgRestore()"><img src="_imgs/compram.gif" name="comprar<?= $oferta_id; ?>" width="16" height="13" border="0" id="comprar<?= $oferta_id; ?>"></a></td></tr>
|
<td width="30" align="right" valign="top"><a href="oferta_add.php?id=<?= $oferta_id; ?>&precio=<?= $oferta_pvp; ?>&modelo=<?= $oferta_nombre; ?>" onMouseOver="MM_swapImage('comprar<?= $oferta_id; ?>','','_imgs/comprbm.gif',1)" onMouseOut="MM_swapImgRestore()"><img src="_imgs/compram.gif" name="comprar<?= $oferta_id; ?>" width="16" height="13" border="0" id="comprar<?= $oferta_id; ?>"></a></td></tr>
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user