RE: finder (I AM REALLY SORRY)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Jajajajaja no Yves... really I dont want you for do my job... for that I
said "I'm really sorry" because I understand what do yo think. I reading and
writing code testing all... I ask for you because not undertand something
complicated like this multifinder... I see a lot of finder tutorials
searching all without selecting data search... I'm thinking I must write
more than 100 lines for particular search, but with the hel of he list I see
not... I do a code with the help of a web... and help from you, list.

Sorry if you think that... but itsnt...
Thanks a lot...

+                                                                          _
   // Emiliano Boragina _
   // Diseño & Comunicación //////////////////
+                                                                          _
   // emiliano.boragina@xxxxxxxxx  /
   // 15 40 58 60 02 ///////////////////////////
+                                                                          _

-----Mensaje original-----
De: Yves Sucaet [mailto:yves.sucaet@xxxxxxx] 
Enviado el: Viernes, 17 de Julio de 2009 10:08 a.m.
Para: php-db@xxxxxxxxxxxxx
Asunto: Re:  finder (I AM REALLY SORRY)

Hi List,

Am I the only one who's getting the feeling that we're doing Emiliano's JOB 
here? Maybe he should try posting a job opening at his company to this list,

instead of letting us solve all his problems and write his entire 
application for him.

I'm all for helping each other out, but this has just been a stepwise 
build-up of how to write his real-estate application.

Just my two cents,

----- Original Message ----- 
From: "Emiliano Boragina" <emiliano.boragina@xxxxxxxxx>
To: <php-db@xxxxxxxxxxxxx>
Sent: Friday, July 17, 2009 12:16 AM
Subject:  finder (I AM REALLY SORRY)


Sorry a lot of times!!!

Please... tell me (and help me) to know if this is right:



<?

include "conn.php";



$sql = "SELECT * FROM principal FULL JOIN detalles FULL JOIN aestrenar FULL
JOIN fotos ON principal.id=detalles.id=aestrenar.id=fotos.id ORDER BY id
ASC";

$result=mysql_query($sql,$conn);

$row=mysql_fetch_row($result);



$f_codigo = $_REQUEST['codigo'];

$f_inmueble = $_REQUEST['inmueble'];

$f_operacion = $_REQUEST['operacion'];

$f_desde = $_REQUEST['fpreciodesde'];

$f_hasta = $_REQUEST['fpreciohasta'];

$f_moneda = $_REQUEST['moneda'];

$f_region = $_REQUEST['region'];

$f_barrio = $_REQUEST['barrio'];

$f_ambientes = $_REQUEST['ambientes'];

$f_dependencia = $_REQUEST['dependencia'];

$f_cochera = $_REQUEST['cochera'];

$f_ubicacion = $_REQUEST['ubicacion'];

$f_apto = $_REQUEST['apto'];



if(($f_desde <= 0) || ($f_desde == "")) { $f_desde = 0; }

if(($f_hasta <= 0) || ($f_hasta == "")) { $f_hasta = 0; }

if(($f_ambientes <= 0) || ($f_ambientes == "")) { $f_ambientes = 0; }

$f_precio = $f_desde >= $row['precio'] <= $f_hasta;



if($f_codigo == "")

{

         $sql_BUSQUEDA = "SELECT * FROM principal FULL JOIN detalles WHERE
'";

         if ($f_inmueble > 0) { $sql_BUSQUEDA .= " inmueble LIKE
'%$f_inmueble%' "; }

         if ($f_operacion > 0) { $sql_BUSQUEDA .= "AND operacion LIKE
'%$f_operacion%' "; }

         if ($f_precio) { $sql_BUSQUEDA .= "AND precio = '$f_precio' "; }

         if ($f_moneda == 1) { $sql_BUSQUEDA .= "AND moneda = '$f_moneda' ";
}

         if ($f_moneda == 2) { $sql_BUSQUEDA .= "AND moneda = '$f_moneda' ";
}

         if ($f_region > 0) { $sql_BUSQUEDA .= "AND region LIKE
'%$f_region%' "; }

         if ($f_barrio > 0) { $sql_BUSQUEDA .= "AND barrio LIKE
'%$f_barrio%' "; }

         if ($f_ambientes > 0) { $sql_BUSQUEDA .= "AND ambientes LIKE
'%$f_ambientes%' "; }

         if ($f_dependencia > 0) { $sql_BUSQUEDA .= "AND dependencia LIKE
'%$f_dependencia%' "; }

         if ($f_cochera > 0) { $sql_BUSQUEDA .= "AND cochera LIKE
'%$f_cochera%' "; }

         if ($f_ubicacion > 0) { $sql_BUSQUEDA .= "AND ubicacion LIKE
'%$f_ubicacion%' "; }

         if ($f_apto > 0) { $sql_BUSQUEDA .= "AND apto LIKE '%$f_apto%' "; }

         $sql_BUSQUEDA .= " ORDER BY principal.id DESC";

         $result = mysql_query($sql_BUSQUEDA,$conn);

}

else

{

         $sql_BUSQUEDA = "SELECT * FROM principal FULL JOIN detalles WHERE
codigo = '$f_codigo'";

         $result=mysql_query($sql_BUSQUEDA,$conn);

         $row=mysql_fetch_row($result);

}

?>



Thanks a lot!



+                                                                          _
   // Emiliano Boragina _
   // Diseño & Comunicación //////////////////
+                                                                          _
   // emiliano.boragina@xxxxxxxxx  /
   // 15 40 58 60 02 ///////////////////////////
+                                                                          _






-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[Index of Archives]     [PHP Home]     [PHP Users]     [Postgresql Discussion]     [Kernel Newbies]     [Postgresql]     [Yosemite News]

  Powered by Linux