i m trying to compare 2 price
for example when person enters min price as 3000$ and max price as $10000.and press search .it has to search all the price bewtween 3000$ to 10000$.i think the select option for price in cars.com best describe my problem
i dont know how to proceed. i m new to php.i hope u guide me
thanks

What is it that you are searching: database, files, some other type of data collection?

i m searching the price from the database within particular range.
suppose i want to search between 1 to 10. search should display all information between the price range 1 to 10.
in cars.com price search is there. i want to search taht type

SQL does the actual searching. PHP connects to the database, executes the queries, and formats the results. What part of the process do you not understand?

i m trying to compare 2 price
for example when person enters min price as 3000$ and max price as $10000.and press search .it has to search all the price bewtween 3000$ to 10000$.i think the select option for price in cars.com best describe my problem
i dont know how to proceed. i m new to php.i hope u guide me
thanks

aarya,
The database will select the db listings in the price range for you if you specify in the sql query.

eg:

$sql = "SELECT * FROM table WHERE price > '$price1' AND price < '$price2';

in teh example $price1 is the min price and $price2 is the max price.

;)

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.