php - How to select only 1 row from a query result? like the 4th row -


I have this code and I want to create a type of "citation area" on my website. I want it to be my Select 3 random quotes from the database. I know about the function rand (minimum, max) , but how do I use the query to select that exact line?

  requires 'DBPPP'; $ Link = mysql_connect ('localhost', 'root', '430123'); $ Db = mysql_select_db ('bakery', $ link); $ Result = mysql_query (select 'with quotes');  

I can use for loop and how much was the number from rand () to use mysql_fetch_row () But could that be a little disabled?

To use only 4 lines, offset limit, number_of_records

  quote from SELECT * sequence by rand () range 3, 1  

Comments

Popular posts from this blog

apache - 504 Gateway Time-out The server didn't respond in time. How to fix it? -

c# - .net WebSocket: CloseOutputAsync vs CloseAsync -

c++ - How to properly scale qgroupbox title with stylesheet for high resolution display? -