<?php
// random row mysql query example
$sql = "SELECT * FROM tablename
WHERE somefield='something'
ORDER BY RAND() LIMIT 5";
// or, something like this
$sql = "SELECT * FROM tablename
ORDER BY RAND()";
?>
// random row mysql query example
$sql = "SELECT * FROM tablename
WHERE somefield='something'
ORDER BY RAND() LIMIT 5";
// or, something like this
$sql = "SELECT * FROM tablename
ORDER BY RAND()";
?>
반응형