Compare commits
10 Commits
63c49a542c
...
00122cf57d
| Author | SHA1 | Date | |
|---|---|---|---|
| 00122cf57d | |||
| 45fc15edf6 | |||
| 5db340bd4e | |||
| ecb6f07835 | |||
| 47f4b14cb4 | |||
| 3b35a49852 | |||
| e6ec77a78c | |||
| dd89620ad7 | |||
| 75bd9cca22 | |||
| 9b70b1e4c4 |
BIN
_imgs/fondo.jpg
Normal file
BIN
_imgs/fondo.jpg
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 59 KiB |
BIN
_imgs/ios-linen.psd
Normal file
BIN
_imgs/ios-linen.psd
Normal file
Binary file not shown.
@ -8,7 +8,7 @@
|
||||
.oferta_foto {
|
||||
overflow: hidden;
|
||||
width: 160px;
|
||||
height: 110px;
|
||||
height: 120px;
|
||||
}
|
||||
|
||||
.oferta_marca {
|
||||
@ -27,7 +27,7 @@
|
||||
.oferta_precio {
|
||||
font-family: "Times New Roman", Times, serif;
|
||||
position: relative;
|
||||
font-size: 36px;
|
||||
font-size: 24px;
|
||||
color: #CB2C54;
|
||||
font-weight: normal;
|
||||
top: 12px;
|
||||
@ -35,6 +35,7 @@
|
||||
|
||||
.oferta_texto {
|
||||
font-family: Verdana, Arial, Helvetica, sans-serif;
|
||||
color: #555555;
|
||||
font-size: 10px;
|
||||
position: relative;
|
||||
top: 14px;
|
||||
@ -71,6 +72,13 @@ a.lmod:hover {
|
||||
height: 95px;
|
||||
}
|
||||
|
||||
.destacado_foto_ofertas {
|
||||
overflow: hidden;
|
||||
position: relative;
|
||||
width: 247px;
|
||||
height: 120px;
|
||||
}
|
||||
|
||||
.destacado_tipo {
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
font-size: 10px;
|
||||
|
||||
@ -5,6 +5,7 @@ body {
|
||||
margin-top: 0px;
|
||||
margin-right: 0px;
|
||||
margin-bottom: 0px;
|
||||
/* background: #36373f url(../_imgs/fondo.jpg) top center repeat-y; */
|
||||
}
|
||||
|
||||
/*
|
||||
@ -159,3 +160,6 @@ a:hover {
|
||||
|
||||
.sombra{background: #FFFFFF url(../_imgs/sombra.gif) repeat-x}
|
||||
|
||||
#menu {font:normal 11px Verdana, Arial, sans-serif;color:#555555;text-align:center;background:url(../_imgs/banda.png) repeat-x;padding-bottom:3px;}
|
||||
#menu a{text-decoration:none;color:#555555;}
|
||||
#menu a:hover{text-decoration:underline;color:blue}
|
||||
|
||||
@ -77,17 +77,13 @@ var $curTipo;
|
||||
$this->contador = 0;
|
||||
$this->result = false;
|
||||
$this->curTipo = $tipo;
|
||||
|
||||
$cuantos = $cuantos * 4;
|
||||
|
||||
|
||||
$conn = db_connect();
|
||||
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
|
||||
LEFT JOIN shoop_fabricantes on (oferta_fab_id=fab_id)
|
||||
WHERE oferta_unidades > 0
|
||||
ORDER BY RAND()';
|
||||
// LIMIT ' . $cuantos;
|
||||
ORDER BY RAND() LIMIT '. $cuantos;
|
||||
|
||||
$this->result = mysql_query($query, $conn);
|
||||
$this->numOfertas = mysql_num_rows($this->result);
|
||||
@ -104,18 +100,17 @@ var $curTipo;
|
||||
if($this->contador < $this->numOfertas) {
|
||||
$row = mysql_fetch_array($this->result);
|
||||
$this->contador ++;
|
||||
if(file_exists('_ofr/' . $row['oferta_id'] . ($this->curTipo != 2 ? '_168.jpg' : '_247.jpg'))) {
|
||||
// if(file_exists('_ofr/' . $row['oferta_id'] . ($this->curTipo != 2 ? '_168.jpg' : '_247.jpg'))) {
|
||||
$oferta = array ( 'categoria_id' => $row['oferta_categoria'],
|
||||
'nombre' => $row['oferta_nombre'],
|
||||
'id' => $row['oferta_id'],
|
||||
'estado' => $row['oferta_estado'],
|
||||
'fab_id' => $row['oferta_fab_id'],
|
||||
'fab_nombre' => $row['fab_nombre'],
|
||||
'pvp' => $row['oferta_pvp'],
|
||||
'descripcion' => $row['oferta_descripcion']);
|
||||
} else {
|
||||
$oferta = $this->getNextOferta();
|
||||
}
|
||||
// } else {
|
||||
// $oferta = $this->getNextOferta();
|
||||
// }
|
||||
}
|
||||
return $oferta; // es un array
|
||||
}
|
||||
@ -133,17 +128,15 @@ var $curTipo;
|
||||
$this->contador = 0;
|
||||
$this->result = false;
|
||||
$this->curTipo = $tipo;
|
||||
|
||||
$cuantos = $cuantos * 4;
|
||||
|
||||
$conn = db_connect();
|
||||
if($conn) {
|
||||
$query = 'SELECT ocasion_id, ocasion_categoria, ocasion_nombre, ocasion_estado, ocasion_pvp, ocasion_precio, ocasion_descripcion, ocasion_fab_id
|
||||
$query = 'SELECT ocasion_id, ocasion_categoria, ocasion_nombre, ocasion_estado, ocasion_pvp, ocasion_precio, ocasion_descripcion, ocasion_fab_id, fab_nombre
|
||||
FROM shoop_ocasion
|
||||
WHERE ocasion_unidades > 0
|
||||
ORDER BY RAND()';
|
||||
// LIMIT ' . $cuantos;
|
||||
|
||||
LEFT JOIN shoop_fabricantes on (ocasion_fab_id=fab_id)
|
||||
WHERE (ocasion_unidades > 0)
|
||||
ORDER BY RAND() LIMIT '. $cuantos;
|
||||
|
||||
$this->result = mysql_query($query, $conn);
|
||||
$this->numOcasiones = mysql_num_rows($this->result);
|
||||
}
|
||||
@ -159,18 +152,19 @@ var $curTipo;
|
||||
if($this->contador < $this->numOcasiones) {
|
||||
$row = mysql_fetch_array($this->result);
|
||||
$this->contador ++;
|
||||
if(file_exists('_ocs/' . $row['ocasion_id'] . ($this->curTipo != 2 ? '_168.jpg' : '_247.jpg'))) {
|
||||
// if(file_exists('_ocs/' . $row['ocasion_id'] . ($this->curTipo != 2 ? '_168.jpg' : '_247.jpg'))) {
|
||||
$ocasion = array ( 'categoria_id' => $row['ocasion_categoria'],
|
||||
'nombre' => $row['ocasion_nombre'],
|
||||
'id' => $row['ocasion_id'],
|
||||
'fab_id' => $row['ocasion_fab_id'],
|
||||
'fab_nombre' => $row['fab_nombre'],
|
||||
'estado' => $row['ocasion_estado'],
|
||||
'precio' => $row['ocasion_precio'],
|
||||
'pvp' => $row['ocasion_pvp'],
|
||||
'descripcion' => $row['ocasion_descripcion']);
|
||||
} else {
|
||||
$ocasion = $this->getNextOcasion();
|
||||
}
|
||||
// } else {
|
||||
// $ocasion = $this->getNextOcasion();
|
||||
// }
|
||||
}
|
||||
return $ocasion; // es un array
|
||||
}
|
||||
|
||||
BIN
_logos/c/197.gif
BIN
_logos/c/197.gif
Binary file not shown.
|
Before Width: | Height: | Size: 3.4 KiB After Width: | Height: | Size: 2.9 KiB |
@ -55,7 +55,8 @@ $result = mysql_query($sql, $conn) or header('Location: ../error.php');
|
||||
|
||||
if ($operacion != "del") {
|
||||
// modifico la imagen.
|
||||
uploadImagenOcasion($id, 247, 95, 168, 102);
|
||||
uploadImagenOcasion($id, 348, 248, 168, 102);
|
||||
uploadImagenOcasion($id, 247, 95, 108, 108);
|
||||
// y vuelvo a la pantalla correspondiente
|
||||
header('Location: ocasion_edit.php?op=edit&id=' . $id);
|
||||
}
|
||||
|
||||
@ -135,14 +135,14 @@ define("MAX_SIZE", $max_size);
|
||||
<td></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<!--tr>
|
||||
<td class="data"><select name="ocasion_fab_id" id="ocasion_fab_id" style="width:200px" class="data">
|
||||
<option value="" selected>Marcas</option>
|
||||
<?php include("menu_marcas.php"); ?>
|
||||
<?php //include("menu_marcas.php"); ?>
|
||||
</select>
|
||||
<script language="JavaScript" type="text/JavaScript"> selectOption('ocasion_fab_id', '<?php echo $ocasion_fab_id; ?>'); </script>
|
||||
</td>
|
||||
</tr>
|
||||
</tr-->
|
||||
|
||||
<tr>
|
||||
<td width="200" class= "lbl">Nombre</td>
|
||||
|
||||
@ -24,19 +24,15 @@ include('../db.php');
|
||||
<?php
|
||||
$conn = db_connect();
|
||||
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
|
||||
LEFT JOIN shoop_fabricantes on (oferta_fab_id=fab_id)
|
||||
/* WHERE oferta_unidades > 0 */
|
||||
ORDER BY oferta_categoria, oferta_id";
|
||||
$result = mysql_query($query, $conn);
|
||||
?>
|
||||
<tr>
|
||||
<td width="100" valign="top" class="hdr" align="left">Marca</td>
|
||||
<td width="355" valign="top" class="hdr">Nombre</td>
|
||||
<td width="40" valign="top" class="hdr" align="right">Uds.</td>
|
||||
<td width="80" valign="top" class="hdr" align="right">PVP</td>
|
||||
<td width="90" valign="top" class="hdr"> </td>
|
||||
<td width="455" valign="top" class="hdr">Nombre</td>
|
||||
<td width="100" valign="top" class="hdr" align="right">PVP</td>
|
||||
<td width="100" valign="top" class="hdr"> </td>
|
||||
</tr>
|
||||
<?php
|
||||
$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_estado = $row['oferta_estado'];
|
||||
$oferta_pvp = $row['oferta_pvp'];
|
||||
$oferta_fab_nombre = $row['fab_nombre'];
|
||||
$oferta_unidades = $row['oferta_unidades'];
|
||||
$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>
|
||||
<td width="100" valign="top" align="left" class="data"><?php echo $oferta_fab_nombre; ?></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 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"> <?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 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>
|
||||
|
||||
@ -54,7 +54,9 @@ $conn = db_connect();
|
||||
|
||||
if ($operacion != "del") {
|
||||
// modifico la imagen.
|
||||
uploadImagenOferta($id, 247, 95, 168, 102);
|
||||
uploadImagenOferta($id, 348, 248, 168, 102);
|
||||
uploadImagenOferta($id, 247, 95, 108, 108);
|
||||
uploadPDFOferta($id);
|
||||
// y vuelvo a la pantalla correspondiente
|
||||
header('Location: oferta_edit.php?op=edit&id=' . $id);
|
||||
}
|
||||
|
||||
@ -70,11 +70,7 @@ define("MAX_SIZE", $max_size);
|
||||
</table>
|
||||
<table border="0" cellspacing="0" cellpadding="0">
|
||||
<tr>
|
||||
<td class= "lbl">Categoría</td>
|
||||
<td class= "lbl"> Imagen</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<!--td><span class="lbl">Categoría</span><br/>
|
||||
<select name="oferta_categoria" id="oferta_categoria" style="width:250px">
|
||||
<option value="1">Altavoces</option>
|
||||
<option value="2">Electrónicas</option>
|
||||
@ -82,21 +78,31 @@ define("MAX_SIZE", $max_size);
|
||||
<option value="4">Varios</option>
|
||||
</select>
|
||||
<script language="JavaScript" type="text/JavaScript"> selectOption('oferta_categoria', '<?= $oferta_categoria; ?>'); </script>
|
||||
</td>
|
||||
</td-->
|
||||
|
||||
<td rowspan="16" valign="top">
|
||||
<table width="250" border="0" cellspacing="0" cellpadding="0">
|
||||
<tr>
|
||||
<td><input name="ofr_imagen" type="file" style="width:250px" class="data"></td>
|
||||
<td><span class="lbl">Folleto PDF</span><br/><input name="ofr_pdf" type="file" style="width:250px" class="data"><br/>
|
||||
<?php
|
||||
if(file_exists('../../_ofr/' . $id . '.pdf')) {
|
||||
echo "<a href='../../_ofr/". $id .".pdf' >Folleto PDF </a>";
|
||||
}
|
||||
?>
|
||||
<br/><br/>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><span class="lbl">Imagen</span><br/><input name="ofr_imagen" type="file" style="width:250px" class="data"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<?php
|
||||
if(file_exists('../../_ofr/' . $id . '_247.jpg')) {
|
||||
if(file_exists('../../_ofr/' . $id . '_348.jpg')) {
|
||||
?>
|
||||
<table width="247" border="1" cellspacing="0" cellpadding="0" bordercolor="#333333" style="margin-top:10px; border-style:solid; border-color:#444444; border:1px; border-padding:1px;">
|
||||
<table width="348" border="1" cellspacing="0" cellpadding="0" bordercolor="#333333" style="margin-top:10px; border-style:solid; border-color:#444444; border:1px; border-padding:1px;">
|
||||
<tr>
|
||||
<td align="center"><img src="../../_ofr/<?php echo $id; ?>_247.jpg"></td>
|
||||
<td align="center"><img src="../../_ofr/<?php echo $id; ?>_348.jpg"></td>
|
||||
</tr>
|
||||
</table>
|
||||
<?php
|
||||
@ -127,19 +133,19 @@ define("MAX_SIZE", $max_size);
|
||||
</tr>
|
||||
|
||||
|
||||
<tr>
|
||||
<!--tr>
|
||||
<td width="200" class= "lbl">Marca</td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</tr-->
|
||||
|
||||
<tr>
|
||||
<!--tr>
|
||||
<td class="data"><select name="oferta_fab_id" id="oferta_fab_id" style="width:200px" class="data">
|
||||
<option value="" selected>Marcas</option>
|
||||
<?php include("menu_marcas.php"); ?>
|
||||
</select>
|
||||
<script language="JavaScript" type="text/JavaScript"> selectOption('oferta_fab_id', '<?php echo $oferta_fab_id; ?>'); </script>
|
||||
</td>
|
||||
</tr>
|
||||
</tr-->
|
||||
|
||||
<tr>
|
||||
<td width="200" class= "lbl">Nombre</td>
|
||||
@ -151,8 +157,8 @@ define("MAX_SIZE", $max_size);
|
||||
<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="200" class= "lbl">Estado</td></tr>
|
||||
<tr><td width="" class="data"><input name="oferta_estado" style="width:px" value="<?= $oferta_estado; ?>">
|
||||
<!--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="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>
|
||||
|
||||
@ -168,4 +168,44 @@
|
||||
}
|
||||
}
|
||||
|
||||
function uploadPDFOferta($prodID) {
|
||||
$path = "../../_ofr/"; // este directorio tiene que tener chmod 777
|
||||
$upload_file_name = "ofr_pdf"; // el nombre del campo tipo file de nuestro formulario
|
||||
$acceptable_file_types = ""; // acepta GIF et JPEG
|
||||
$default_extension = "";
|
||||
$mode = 1; // OPTIONS:
|
||||
// 1 = overwrite mode
|
||||
// 2 = create new with incremental extention
|
||||
// 3 = do nothing if exists, highest protection
|
||||
|
||||
|
||||
// un poco de limpieza previa
|
||||
// este es el temporal
|
||||
$glob = glob($path . $prodID. '_tmp');
|
||||
limpia($glob);
|
||||
limpia($path . '_' . $prodID . '.pdf');
|
||||
// fin de la limpia
|
||||
|
||||
if(strlen($_FILES['ofr_pdf']['name'])) {
|
||||
$my_uploader = new uploader('es'); // Create a new instance of the class
|
||||
$my_uploader->max_filesize(5000000); // OPTIONAL: set the max filesize of uploadable files in bytes
|
||||
// $my_uploader->max_image_size(1600, 1600); // OPTIONAL: if you're uploading images, you can set the max pixel dimensions
|
||||
// UPLOAD the file
|
||||
if ($my_uploader->upload($upload_file_name, $acceptable_file_types, $default_extension)) {
|
||||
$my_uploader->save_file($path, $prodID . '.pdf', $mode);
|
||||
if (!$my_uploader->error) {
|
||||
$my_uploader->delete_file;
|
||||
}
|
||||
}
|
||||
if ($my_uploader->error) {
|
||||
echo $my_uploader->error;
|
||||
}
|
||||
|
||||
$glob = glob($path . $proid. '_tmp');
|
||||
limpia($glob);
|
||||
}
|
||||
// else
|
||||
// limpia($path . $prodID . '.pdf');
|
||||
}
|
||||
|
||||
?>
|
||||
@ -1,4 +1,4 @@
|
||||
<table width="100%" height="100%" border="0" cellpadding="0" cellspacing="0">
|
||||
<table width="100%" height="100%" border="1" cellpadding="0" cellspacing="0">
|
||||
<tr><td width="160">
|
||||
<div class="oferta_foto">
|
||||
<table width="100%" height="100%" border="0" cellpadding="0" cellspacing="0"><tr><td valign="middle" align="center">
|
||||
|
||||
@ -2,8 +2,8 @@
|
||||
<table width="100%" height="100%" border="0" cellpadding="0" cellspacing="0">
|
||||
<tr>
|
||||
<td width="247"><img src="_imgs/d.gif" width="247" height="1" alt=""></td>
|
||||
<td width="12"><img src="_imgs/d.gif" width="12" height="1" alt=""></td>
|
||||
<td width="279"><img src="_imgs/d.gif" width="279" height="1" alt=""></td>
|
||||
<td width="7"><img src="_imgs/d.gif" width="7" height="1" alt=""></td>
|
||||
<td width="270"><img src="_imgs/d.gif" width="270" height="1" alt=""></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
@ -18,16 +18,16 @@
|
||||
?>
|
||||
<img src="_imgs/d.gif" height="6"><br>
|
||||
|
||||
<a href="oferta_ficha.php?id=<?php echo $arrayOcasion['id']; ?>"><img src="_ocs/<?php echo $arrayOcasion['id']; ?>_247.jpg" border="0" alt=""></a>
|
||||
<a href="ocasion_ficha.php?id=<?php echo $arrayOcasion['id']; ?>"><img src="_ocs/<?php echo $arrayOcasion['id']; ?>_247.jpg" border="0" alt=""></a>
|
||||
</div>
|
||||
<div class="destacado_precio"><?php echo ($arrayOcasion['precio'] == '-1' ? 'Consultar' : 'Ocasión ' . miNumberFormat($arrayOcasion['precio']) . '<span class="euro">€</span>'); ?></div>
|
||||
</td>
|
||||
|
||||
<td width="12"><img src="_imgs/d.gif" width="12" alt=""></td>
|
||||
<td width="7"><img src="_imgs/d.gif" width="12" alt=""></td>
|
||||
|
||||
<td width="279" valign="top">
|
||||
<td width="270" valign="top">
|
||||
<div class="destacado_tipo azul"><?php echo $arrayOcasion['nombre']; ?></div>
|
||||
<div class="destacado_modelo"><a href="oferta_ficha.php?id=<?php echo $arrayOcasion['id']; ?>" class="lmod"><?php echo $arrayOcasion['nombre']; ?></a></div>
|
||||
<div class="destacado_modelo"><a href="ocasion_ficha.php?id=<?php echo $arrayOcasion['id']; ?>" class="lmod"><?php echo $arrayOcasion['nombre']; ?></a></div>
|
||||
<div class="oferta_texto"><?php if(strlen($arrayOcasion['descripcion'])) { echo substr($arrayOcasion['descripcion'], 0, 150) . '...'; } ?></div>
|
||||
|
||||
<div class="producto_ocasion1"><br />Precio PVP: <?php echo $arrayOcasion['pvp'];?> €</div>
|
||||
|
||||
@ -2,35 +2,54 @@
|
||||
<table width="100%" height="100%" border="0" cellpadding="0" cellspacing="0">
|
||||
<tr>
|
||||
<td width="247"><img src="_imgs/d.gif" width="247" height="1" alt=""></td>
|
||||
<td width="12"><img src="_imgs/d.gif" width="12" height="1" alt=""></td>
|
||||
<td width="279"><img src="_imgs/d.gif" width="279" height="1" alt=""></td>
|
||||
<td width="7"><img src="_imgs/d.gif" width="7" height="1" alt=""></td>
|
||||
<td width="270"><img src="_imgs/d.gif" width="270" height="1" alt=""></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<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>
|
||||
<td width="247" align="center" valign="top">
|
||||
|
||||
<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_ofertas">
|
||||
<?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"></a><br />
|
||||
<?php } ?>
|
||||
<a href="<?php echo $enlace; ?>">Ver oferta</a>
|
||||
</div>
|
||||
<div class="destacado_precio"><?php echo ($arrayOferta['pvp'] == '-1' ? 'Consultar' : 'Oferta ' . miNumberFormat($arrayOferta['pvp']) . '<span class="euro">€</span>'); ?></div>
|
||||
</td>
|
||||
|
||||
<td width="12"><img src="_imgs/d.gif" width="12" alt=""></td>
|
||||
<td width="7"><img src="_imgs/d.gif" width="12" alt=""></td>
|
||||
|
||||
<td width="279" valign="top">
|
||||
<div class="destacado_tipo azul"><?php echo $arrayOferta['nombre']; ?></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>
|
||||
<td width="270" valign="top">
|
||||
<div class="tit azul"><a href="oferta_ficha.php?id=<?php echo $arrayOferta['id']; ?>" class="lmod"><?php echo $arrayOferta['nombre']; ?></a></div>
|
||||
|
||||
<div class="producto_ocasion1"><br />Precio PVP: <?php echo $arrayOferta['pvp'];?> €</div>
|
||||
<?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>
|
||||
</tr>
|
||||
|
||||
|
||||
41
bann_ocasion_home.php
Normal file
41
bann_ocasion_home.php
Normal file
@ -0,0 +1,41 @@
|
||||
<table width="100%" height="100%" border="0" cellpadding="0" cellspacing="0">
|
||||
<tr>
|
||||
<td width="160">
|
||||
<div class="oferta_foto">
|
||||
<table width="100%" height="100%" border="0" cellpadding="0" cellspacing="0">
|
||||
<tr><td valign="middle" align="center">
|
||||
<?php
|
||||
//SI TIENE PDF la imagen irá al pdf si no a la ficha
|
||||
$path_pdf = '_ocs/' . $arrayOcasion['id'] . '.pdf';
|
||||
$path_jpg = '_ocs/' . $arrayOcasion['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 = "ocasion_ficha.php?id=". $arrayOcasion['id'];
|
||||
?>
|
||||
|
||||
<a href="<?php echo $enlace; ?>">
|
||||
<?php
|
||||
if ($path_jpg != "") {
|
||||
?>
|
||||
<img src="<?php echo $path_jpg; ?>" width="160" border="0"></a><br />
|
||||
<?php } ?>
|
||||
<a href="<?php echo $enlace; ?>">Ver ocasión</a>
|
||||
</td></tr></table>
|
||||
</div>
|
||||
</td>
|
||||
|
||||
<td width="8"></td>
|
||||
<td width="152" valign="top">
|
||||
<div class="oferta_marca"><?php echo $arrayOcasion['fab_nombre']; ?><br><span class="tit azul"><?php echo $arrayOcasion['nombre']; ?></span></div>
|
||||
<div class="oferta_precio"><?php echo ($arrayOcasion['precio'] == '-1' ? 'Consultar' : miNumberFormat($arrayOcasion['precio']) . '<span class="euro">€</span>'); ?></div>
|
||||
<div class="oferta_texto"><?php if(strlen($arrayOcasion['descripcion'])) { echo substr($arrayOcasion['descripcion'], 0, 150) . '...'; } ?></div>
|
||||
<div class="producto_ocasion1"><br />Precio PVP: <?php echo $arrayOcasion['pvp'];?> €</div>
|
||||
</td></tr>
|
||||
</table>
|
||||
46
bann_oferta_home.php
Normal file
46
bann_oferta_home.php
Normal file
@ -0,0 +1,46 @@
|
||||
<table width="100%" height="100%" border="0" cellpadding="0" cellspacing="0">
|
||||
<tr>
|
||||
<td width="160">
|
||||
<div class="oferta_foto">
|
||||
<table width="100%" height="100%" border="0" cellpadding="0" cellspacing="0">
|
||||
<tr><td valign="top" align="center">
|
||||
<?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"></a><br />
|
||||
<?php } ?>
|
||||
<a href="<?php echo $enlace; ?>">Ver oferta</a>
|
||||
</td></tr></table>
|
||||
</div>
|
||||
</td>
|
||||
<td width="8"></td>
|
||||
<td width="152" valign="top">
|
||||
<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>
|
||||
<?php } ?>
|
||||
<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>
|
||||
</div>
|
||||
</td></tr>
|
||||
</table>
|
||||
@ -59,7 +59,7 @@
|
||||
?>
|
||||
</td>
|
||||
<?php
|
||||
if($j == 4) {
|
||||
if($j == 2) {
|
||||
$j = 0;
|
||||
?>
|
||||
</tr>
|
||||
|
||||
@ -1,5 +1,6 @@
|
||||
<ul id="menuTree">
|
||||
<li class="mudo"><a href="clavequien.php" class="parent upper">Quiénes Somos</a></li>
|
||||
<li class="mudo"><a href="clavemarcas.php" class="parent upper">Nuestras Marcas</a></li>
|
||||
<li class="mudo"><a href="articulos2.php?t=2" class="parent upper">e-Learning</a></li>
|
||||
<li class="mudo"><a href="clavefaq.php" class="parent upper">Preguntas Frecuentes</a></li>
|
||||
<li class="mudo"><a href="clavelegal.php" class="parent upper">Información Legal</a></li></ul>
|
||||
125
index.php
125
index.php
@ -64,7 +64,9 @@ ini_set ('display_errors', '0');
|
||||
|
||||
?>
|
||||
<table width="708" border="0" align="center" cellpadding="0" cellspacing="0">
|
||||
<tr>
|
||||
|
||||
<!--Banners cabecera-->
|
||||
<tr>
|
||||
<td colspan="3">
|
||||
<table id="banner" width="708" border="0" cellpadding="0" cellspacing="0">
|
||||
<tr>
|
||||
@ -78,11 +80,17 @@ ini_set ('display_errors', '0');
|
||||
</tr>
|
||||
<tr><td colspan="2" class="sombra" height="10"></td></tr>
|
||||
</table>
|
||||
</td></tr>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<!-- Separacion cuerpo -->
|
||||
<tr>
|
||||
<td><img src="_imgs/d.gif" width="348" height="1"></td>
|
||||
<td><img src="_imgs/d.gif" width="12" height="1"></td>
|
||||
<td><img src="_imgs/d.gif" width="348" height="1"></td></tr>
|
||||
<td><img src="_imgs/d.gif" width="348" height="1"></td>
|
||||
</tr>
|
||||
|
||||
<!-- Cuerpo -->
|
||||
<tr>
|
||||
<td valign="top">
|
||||
|
||||
@ -96,7 +104,62 @@ ini_set ('display_errors', '0');
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<table id="zona" width="348" border="0" cellpadding="0" cellspacing="0">
|
||||
<!--NUEVA ESTRUCTURA-->
|
||||
<table id="zona" width="348" border="1" cellpadding="0" cellspacing="0">
|
||||
<tr><td height="29"><img src="_imgs/zonatit.gif" style="margin-left:8px" /></td></tr>
|
||||
</table>
|
||||
|
||||
<table id="ofertas" width="348" border="0" cellpadding="0" cellspacing="0">
|
||||
<tr><td height="50">OFERTAS</td></tr>
|
||||
<tr><td height="5" colspan="3"><div class="sepa"></div></td></tr>
|
||||
|
||||
<?php
|
||||
$miOfertas = new shoopOfertaNueva(3, '');
|
||||
for ($i=0; $i < $miOfertas->getNum(); $i++){
|
||||
$arrayOfertas = $miOfertas->getNextOferta();
|
||||
if(!empty($arrayOfertas)){
|
||||
?>
|
||||
<tr><td> <?php include('bann_oferta_home.php');?> </td></tr>
|
||||
<tr><td height="5"><div class="sepa"></div></td></tr>
|
||||
<?php
|
||||
}
|
||||
}
|
||||
|
||||
?>
|
||||
</td></tr>
|
||||
<tr><td>
|
||||
<p align="right" style="margin:0;padding:0"><a href="ofertas.php" class="pielink">Ver todo el material de Oferta >></a></p>
|
||||
</td></tr>
|
||||
</table>
|
||||
|
||||
<table id="ocasion" width="348" border="0" cellpadding="0" cellspacing="0">
|
||||
<tr><td height="50">OCASIÓN</td></tr>
|
||||
<tr><td height="5" colspan="3"><div class="sepa"></div></td></tr>
|
||||
|
||||
<?php
|
||||
$miOcasion = new shoopOcasion(3, '');
|
||||
for ($i=0; $i < $miOcasion->getNum(); $i++){
|
||||
$arrayOcasion = $miOcasion->getNextOcasion();
|
||||
if(!empty($arrayOcasion)){
|
||||
?>
|
||||
<tr><td bgcolor="#FFFFFF"><?php include('bann_ocasion_home.php');?></td></tr>
|
||||
<tr><td height="5"><div class="sepa"></div></td></tr>
|
||||
<?php
|
||||
}
|
||||
}
|
||||
|
||||
?>
|
||||
</td></tr>
|
||||
<tr><td>
|
||||
<p align="right" style="margin:0;padding:0"><a href="ocasion.php" class="pielink">Ver todo el material de Ocasión >></a></p>
|
||||
</td></tr>
|
||||
</table>
|
||||
<!--FIN NUEVA ESTRUCTURA-->
|
||||
|
||||
|
||||
|
||||
<!--ZONA-->
|
||||
<!--table id="zona" width="348" border="0" cellpadding="0" cellspacing="0">
|
||||
<tr><td height="29"><img src="_imgs/zonatit.gif" style="margin-left:8px" /></td></tr>
|
||||
<tr>
|
||||
<td>
|
||||
@ -197,34 +260,37 @@ ini_set ('display_errors', '0');
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</table-->
|
||||
|
||||
</td>
|
||||
|
||||
<!--SEPARACION-->
|
||||
<td></td>
|
||||
|
||||
<!--LATERAL DERECHO-->
|
||||
<td valign="top">
|
||||
|
||||
<table id="novedades" width="348" border="0" cellpadding="0" cellspacing="0">
|
||||
|
||||
<!--NOVEDADES-->
|
||||
<table id="novedades" width="348" border="0" cellpadding="0" cellspacing="0">
|
||||
<tr><td colspan="3" height="25"><img src="_imgs/novetit.gif" alt="novedades" width="129" height="13"></td></tr>
|
||||
<?php
|
||||
if($conn) {
|
||||
$query = 'SELECT articulo_id, articulo_titular, articulo_entradilla FROM edito_articulos ORDER BY articulo_id DESC LIMIT 1';
|
||||
$query = 'SELECT articulo_id, articulo_titular, articulo_entradilla FROM edito_articulos ORDER BY articulo_id DESC LIMIT 4';
|
||||
$result = mysql_query($query, $conn);
|
||||
if($result && mysql_num_rows($result)) {
|
||||
$row = mysql_fetch_array($result);
|
||||
if($result && (mysql_num_rows($result)>0)) {
|
||||
while ($row = mysql_fetch_array($result)){
|
||||
?>
|
||||
<tr>
|
||||
<td width="168" valign="top">
|
||||
<span class="tit azul"><?= $row['articulo_titular']; ?></span><br />
|
||||
<?= $row['articulo_entradilla']; ?> <a href="articulos.php?t=1&id=<?= $row['articulo_id']; ?>" class="mas">[+]</a></td>
|
||||
<td><img src="_imgs/d.gif" width="11" height="1" alt=""></td>
|
||||
<td valign="top">
|
||||
<tr>
|
||||
<td width="168" valign="top">
|
||||
<span class="tit azul"><?= $row['articulo_titular']; ?></span><br />
|
||||
<?= $row['articulo_entradilla']; ?> <a href="articulos.php?t=1&id=<?= $row['articulo_id']; ?>" class="mas">[+]</a></td>
|
||||
<td><img src="_imgs/d.gif" width="11" height="1" alt=""></td>
|
||||
<td valign="top">
|
||||
<?php
|
||||
$query = 'SELECT galeria_imagen_name FROM edito_galeria_imagenes WHERE galeria_articulo_id = ' . $row['articulo_id'] . ' ORDER BY galeria_imagen_name';
|
||||
$result = mysql_query($query, $conn);
|
||||
if($result){
|
||||
while($row_img = mysql_fetch_array($result)) {
|
||||
$result2 = mysql_query($query, $conn);
|
||||
if($result2){
|
||||
while($row_img = mysql_fetch_array($result2)) {
|
||||
$path_108 = '_pics/' . $row_img['galeria_imagen_name'] . '_348.jpg';
|
||||
if(file_exists($path_108)) {
|
||||
?>
|
||||
@ -237,15 +303,15 @@ ini_set ('display_errors', '0');
|
||||
?>
|
||||
</td>
|
||||
</tr>
|
||||
<tr><td height="25" colspan="3"><div class="sepa"></div></td></tr>
|
||||
<?php
|
||||
}
|
||||
}
|
||||
}
|
||||
?>
|
||||
|
||||
|
||||
|
||||
</table>
|
||||
</table>
|
||||
|
||||
<!--BANNERS-->
|
||||
<table id="right" width="348" border="0" cellpadding="0" cellspacing="0">
|
||||
<tr>
|
||||
|
||||
@ -265,14 +331,15 @@ ini_set ('display_errors', '0');
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<div class="banner01">
|
||||
<?php
|
||||
// el par‡metro que paso es el nœmero de baners de tipo 1 que quiero
|
||||
$miBanner = new shoopBanners(1, 348);
|
||||
if($miBanner->getNum())
|
||||
echo $miBanner->getNextBanner();
|
||||
?>
|
||||
</div>
|
||||
$miBanner = new shoopBanners(2, 348);
|
||||
for ($i=0; $i < $miBanner->getNum(); $i++){
|
||||
?>
|
||||
<div class="banner01"><?php echo $miBanner->getNextBanner();?></div>
|
||||
<?php
|
||||
}
|
||||
?>
|
||||
|
||||
|
||||
</td></tr></table>
|
||||
|
||||
@ -25,16 +25,16 @@ include('db.php');
|
||||
'acabados'=>''));
|
||||
|
||||
// elimino el producto de la lista
|
||||
$conn = db_connect();
|
||||
if($conn) {
|
||||
$query = 'SELECT ocasion_unidades FROM shoop_ocasion WHERE ocasion_id = ' . $_REQUEST['id'];
|
||||
$result = mysql_query($query);
|
||||
if($result) {
|
||||
$row = mysql_fetch_array($result);
|
||||
$cuantos = $row['ocasion_unidades'] - 1;
|
||||
$query = 'UPDATE shoop_ocasion SET ocasion_unidades="' . $cuantos . '" WHERE ocasion_id = ' . $_REQUEST['id'];
|
||||
$result = mysql_query($query);
|
||||
}
|
||||
}
|
||||
// $conn = db_connect();
|
||||
// if($conn) {
|
||||
// $query = 'SELECT ocasion_unidades FROM shoop_ocasion WHERE ocasion_id = ' . $_REQUEST['id'];
|
||||
// $result = mysql_query($query);
|
||||
// if($result) {
|
||||
// $row = mysql_fetch_array($result);
|
||||
// $cuantos = $row['ocasion_unidades'] - 1;
|
||||
// $query = 'UPDATE shoop_ocasion SET ocasion_unidades="' . $cuantos . '" WHERE ocasion_id = ' . $_REQUEST['id'];
|
||||
// $result = mysql_query($query);
|
||||
// }
|
||||
// }
|
||||
header('Location: ' . $HTTP_SERVER_VARS['HTTP_REFERER']);
|
||||
?>
|
||||
@ -127,7 +127,7 @@ switch($ocasion_categoria_id) {
|
||||
<input name="ocasion_estado" id="ocasion_unidades" type="hidden" value="<?php echo $ocasion_unidades; ?>">
|
||||
|
||||
<tr>
|
||||
<td width="170" valign="top" class="producto_texto">
|
||||
<td colspan="3" width="348" valign="top" class="producto_texto">
|
||||
<span class="producto_tipo azul"><?php echo $ocasion_categoria_nombre; ?></span><br>
|
||||
<span class="producto_modelo"><?php echo $ocasion_nombre; ?></span><br>
|
||||
<span class="producto_tipo azul"><?php echo $ocasion_estado; ?></span><!--span class="producto_tipo rojo"> <?php //echo $ocasion_unidades; ?> Unidades</span--><br>
|
||||
@ -140,25 +140,18 @@ switch($ocasion_categoria_id) {
|
||||
<!--a href="javascript:document.producto.submit();" 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><br>
|
||||
<?php if($cart->find_item($prod_id)) echo $cart->find_item($prod_id) . ' unidad' . ($cart->find_item($prod_id) > 1 ? 'es' : '') . ' en su cesta'; ?>-->
|
||||
</td>
|
||||
<td></td>
|
||||
<!--td></td>
|
||||
<td width="170" valign="top" align="center">
|
||||
|
||||
<?php
|
||||
//LOGOTIPO FABRICANTE
|
||||
$path = '_logos/c/' . $ocasion_fab_id . '.gif';
|
||||
/* $path = '_logos/c/' . $ocasion_fab_id . '.gif';
|
||||
if (file_exists($path)) {
|
||||
echo '<img src="'.$path.'"><br>';
|
||||
}
|
||||
*/
|
||||
?>
|
||||
<img src="_imgs/d.gif" width="170" height="6"><br>
|
||||
|
||||
<?php
|
||||
//IMAGEN ARTICULO OCASION
|
||||
$path = '_ocs/' . $ocasion_id . '_168.jpg';
|
||||
if (file_exists($path)) {
|
||||
echo '<img src="'.$path.'"></td></tr>';
|
||||
}
|
||||
?>
|
||||
<img src="_imgs/d.gif" width="170" height="6"><br></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>
|
||||
|
||||
@ -218,6 +211,41 @@ switch($ocasion_categoria_id) {
|
||||
}
|
||||
}
|
||||
?>
|
||||
|
||||
|
||||
<tr><td align="center">
|
||||
<?php
|
||||
//SI TIENE PDF la imagen irá al pdf si no a la ficha
|
||||
$path_pdf = '_ocs/' . $ocasion_id . '.pdf';
|
||||
$path_jpg = '_ocs/' . $ocasion_id . '_348.jpg';
|
||||
if (!file_exists($path_pdf))
|
||||
$path_pdf = "";
|
||||
if (!file_exists($path_jpg))
|
||||
$path_jpg = "";
|
||||
|
||||
if ($path_pdf != "") {
|
||||
$enlace = $path_pdf;
|
||||
}
|
||||
else
|
||||
$enlace = "ocasion_ficha.php?id=". $ocasion_id;
|
||||
?>
|
||||
|
||||
<a href="<?php echo $enlace; ?>">
|
||||
<?php
|
||||
if ($path_jpg != "") {
|
||||
?>
|
||||
<img src="<?php echo $path_jpg; ?>" width="348" border="0"></a>
|
||||
<?php }
|
||||
|
||||
if ($path_pdf != "") {
|
||||
?>
|
||||
<a href="<?php echo $enlace; ?>">Ver ocasion</a>
|
||||
<?php } ?>
|
||||
|
||||
</td></tr>
|
||||
|
||||
|
||||
|
||||
</table>
|
||||
</td>
|
||||
<td></td>
|
||||
|
||||
@ -125,38 +125,21 @@ switch($oferta_categoria_id) {
|
||||
<input name="oferta_estado" id="oferta_unidades" type="hidden" value="<?php echo $oferta_unidades; ?>">
|
||||
|
||||
<tr>
|
||||
<td width="170" valign="top" class="producto_texto">
|
||||
<span class="producto_tipo azul"><?php echo $oferta_categoria_nombre; ?></span><br>
|
||||
<td colspan="3" width="348" valign="top" class="producto_texto">
|
||||
<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_modelo">Oferta PVP:</span> <span class="producto_precio_ocasion2"><?php echo $oferta_pvp; ?><span class="euro">€</span><br>
|
||||
<?php
|
||||
if (($oferta_pvp!="") && ($oferta_pvp>0)) {
|
||||
?>
|
||||
<span class="producto_precio_ocasion2">PVP: <?php echo $oferta_pvp; ?></span><span class="euro">€</span><br>
|
||||
<?php } ?>
|
||||
|
||||
<img src="_imgs/d.gif" width="170" height="6"><br>
|
||||
|
||||
<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></td>
|
||||
<td width="170" valign="top" align="center">
|
||||
|
||||
<?php
|
||||
//LOGOTIPO FABRICANTE
|
||||
$path = '_logos/c/' . $oferta_fab_id . '.gif';
|
||||
if (file_exists($path)) {
|
||||
echo '<img src="'.$path.'"><br>';
|
||||
}
|
||||
?>
|
||||
<img src="_imgs/d.gif" width="170" height="6"><br>
|
||||
|
||||
<?php
|
||||
//IMAGEN ARTICULO OCASION
|
||||
$path = '_ofr/' . $oferta_id . '_168.jpg';
|
||||
if (file_exists($path)) {
|
||||
echo '<img src="'.$path.'"></td></tr>';
|
||||
}
|
||||
?>
|
||||
<!--td></td>
|
||||
<td width="170" valign="top" align="center"></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>
|
||||
|
||||
@ -216,6 +199,38 @@ switch($oferta_categoria_id) {
|
||||
}
|
||||
}
|
||||
?>
|
||||
<tr><td 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 . '_348.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=". $oferta_id;
|
||||
?>
|
||||
|
||||
<a href="<?php echo $enlace; ?>">
|
||||
<?php
|
||||
if ($path_jpg != "") {
|
||||
?>
|
||||
<img src="<?php echo $path_jpg; ?>" width="348" border="0"></a>
|
||||
<?php }
|
||||
|
||||
if ($path_pdf != "") {
|
||||
?>
|
||||
<a href="<?php echo $enlace; ?>">Ver oferta</a>
|
||||
<?php } ?>
|
||||
|
||||
</td></tr>
|
||||
|
||||
|
||||
</table>
|
||||
</td>
|
||||
<td></td>
|
||||
|
||||
22
ofertas.php
22
ofertas.php
@ -143,6 +143,12 @@ include('top.htm');
|
||||
if($result && $numProductos) {
|
||||
?>
|
||||
<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
|
||||
$secciones = array('', 'Altavoces', 'Electrónicas', 'Reproductores de CD, convertidores D/A, etc.', 'Varios');
|
||||
$curSeccion='';
|
||||
@ -157,20 +163,20 @@ include('top.htm');
|
||||
$fab_nombre = $row['fab_nombre'];
|
||||
$oferta_descripcion = $row['oferta_descripcion'];
|
||||
|
||||
if($oferta_categoria != $curSeccion){
|
||||
$curSeccion = $oferta_categoria;
|
||||
// if($oferta_categoria != $curSeccion){
|
||||
// $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
|
||||
}
|
||||
// }
|
||||
?>
|
||||
<tr onMouseOver="overRow(this);return false;" onMouseOut="outRow(this);return false;">
|
||||
<td width="10"></td>
|
||||
<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="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>
|
||||
|
||||
|
||||
9
top.htm
9
top.htm
@ -1,10 +1,3 @@
|
||||
<style type="text/css">
|
||||
<!--
|
||||
#menu {font:normal 11px Verdana, Arial, sans-serif;color:#555555;text-align:center;background:url(_imgs/banda.png) repeat-x;padding-bottom:3px;}
|
||||
#menu a{text-decoration:none;color:#555555;}
|
||||
#menu a:hover{text-decoration:underline;color:blue}
|
||||
-->
|
||||
</style>
|
||||
<table width="708" border="0" align="center" cellpadding="0" cellspacing="0" id="top">
|
||||
<tr>
|
||||
<td bgcolor="#000000" width="174"><a href="index.php"><img src="_imgs/logo.gif" width="174" height="60" border="0"></a></td>
|
||||
@ -16,6 +9,6 @@
|
||||
<a href="ocasion.php">Ocasión</a> |
|
||||
<a href="ofertas.php">Ofertas</a> |
|
||||
<a href="articulos3.php?t=3">Instalaciones</a> |
|
||||
<a href="articulos2.php?t=2">e-Learning</a>
|
||||
<a href="clavemarcas.php">Marcas</a>
|
||||
</td></tr>
|
||||
</table>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user