<?php
require ('sql_connect.php');
$query = "select * from `products`";
$result = mysql_query($query);
while($row = mysql_fetch_array($result))
{
$imagem = $row['imagem'];
$texto = $row['texto'];
echo "<img src=Images/Products/$imagem> <br> $texto";
}
?>
I have the image and the text of the image that i want to show in my database.
I show the image but i have problems with the text... The text dont show the ENTERS/SPACES. There are some ways to resolve this?
Image of problem: https://i.stack.imgur.com/f51Pp.png
I want this: https://i.stack.imgur.com/f51Pp.png#1
Database: utf8_general_ci
In database text is saving with enters/spaces...