I running a simple mysql query and trying to grab from the src column but I only want to grab the "video#.mp4" part - not the whole value (see picture attached below)
If anyone knows how to achieve this... I really appreciated it! Thank you for any help!
Code:
$con=mysqli_connect("localhost","test","123","test");
// Check connection
if (mysqli_connect_errno())
{
echo "Failed to connect to MySQL: " . mysqli_connect_error();
}
$sql="SELECT id, title, src, type, poster_img FROM TABLE_NAME";
if ($result=mysqli_query($con,$sql))
{
$id = 0;
// Fetch one and one row
while ($row=mysqli_fetch_row($result))
{
// Show video#.mp4 here ///
echo '';
$id++;
}
// Free result set
mysqli_free_result($result);
}
mysqli_close($con);
