I tried to filter some data from a mysql table.
<?php
include ("connection.php");
$name = "cable";
$sql = "SELECT * FROM stock WHERE item LIKE '%$name%'";
?>
<a target="_blank" href="test2.php?link=<?php echo $sql; ?>" >click</a>
I tried to get the sql statement using the $_GET[link] from the next page. (test2.php). Here's the code from TEST2.PHP
<?php
include ("connection.php");
$link = $_GET['link'];
echo $link;
then the echo $link show me a different value. It doesn't display "cable". Instead, it displays
SELECT * FROM stock WHERE item LIKE 'Êble%'
can you tell me why CABLE became Êble ?