1. This website uses cookies. By continuing to use this website you are giving consent to cookies being used.
    For information on cookies and how you can disable them visit our Cookie Usage page.
    Dismiss Notice

PHP PHP/MySQL problem

Discussion in 'Web Development' started by gilbertsavier, Aug 4, 2009.

  1. gilbertsavier

    gilbertsavier New Member

    Hi

    I have just had a site transferred to me that has [Removed false authorship of website: this is a joke I assume, no such authorship exists in the real world, techAdmin] - and I cannot, for the life of me, understand why it will not properly connect to the MySQL database.
    I have done many before - so it is not likely to be a just basic error.

    When selecting on the search button bottom left I end up with the following message:

    "Error en la Base de Datos al ejecutar
    select * from fichas where
    tipo=''
    and precio>= and precio<= and terretam <= and casatam <= order by puntos descYou have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'and precio<= and terretam <= and casatam <= order by puntos desc' at line 3"


    The site is [link] - my server "experts" have tried everything and confess to being "flumoxxed !!

    Bizarrely - the images that have downloaded (and there are a number genuinely missing) - show in Opera and Firefox - but not in IE !!

    Can anyone help or advise me? I can provide all FTP details etc.


    Thanks & regards
    Lokananth
     
  2. wilmec

    wilmec New Member

    Just at a quick look your error is
    "Error en la Base de Datos al ejecutar
    select * from fichas where
    tipo=''<- should be
    "Error en la Base de Datos al ejecutar
    select * from fichas where
    tipo=''''
    an extra 2 single quotes after the = and before the " double quote.
    so that it wraps anything you have in it IE
    ("SELECT * FROM blah WHERE this = '$whatever' ")