0

I'm sorry for this newbie question... Could someone help me with the following:

How can I insert my $test variable into the Mysql statement?

Below my code:

$sql = "SELECT * FROM linkbuilding WHERE branche= '[here I want to insert $test]'"

$test = zakelijk
brombeer
  • 8,716
  • 5
  • 21
  • 27
Mark T
  • 1
  • This question has already been asked here is the link :) https://stackoverflow.com/questions/7537377/how-to-include-a-php-variable-inside-a-mysql-statement#:~:text=The%20rules%20of%20adding%20a,No%20exceptions. – David Nov 15 '20 at 08:34
  • 2
    Fairly sure the duplicate also talks about using prepared statements as well. But - https://stackoverflow.com/questions/60174/how-can-i-prevent-sql-injection-in-php. – Nigel Ren Nov 15 '20 at 08:35

0 Answers0