GET parameter with special characters

1

I have browsed the entire internet behind the solution of my problem and as a last resort, I come to ask you and I hope to find a solution to my problem, as follows:

I am making a query via PHP & MySql with the following parameters passed in the URL ../data/status.php?projeto=108&origem=Sugestão de Melhoria

By "debugging" my code next to the back end (PHP) I realize that it actually mounts the query correctly as below:

string(883) "SELECT mantis_bug_table.version   AS VERSAO, 
   CASE 
     WHEN mantis_bug_table.version <> '' THEN 
     Replace(mantis_bug_table.version, '.', '') 
   END                        AS VERSAOSEMPONTO, 
   CASE 
     WHEN mantis_bug_table.status IN ( 10, 20, 30, 50 ) THEN 'EM EXECUÇÃO' 
     ELSE 'CONCLUÍDO' 
   END                        AS DESCRICAO, 
   Count(mantis_bug_table.id) AS QUANTIDADE FROM   dbmantis_bugs.mantis_bug_table 
   INNER JOIN dbmantis_bugs.mantis_custom_field_string_table 
           ON ( mantis_bug_table.id = mantis_custom_field_string_table.bug_id ) WHERE  ( mantis_custom_field_string_table.value = 'Sugestão de Melhoria' ) 
   AND ( mantis_bug_table.project_id = 108 ) GROUP  BY mantis_bug_table.version, 
      descricao ORDER  BY mantis_bug_table.version ASC, 
      status ASC "

But when I run the query, it simply does not return any of them:

object(mysqli_result)#2 (5) { ["current_field"]=> int(0) ["field_count"]=> int(4) ["lengths"]=> NULL ["num_rows"]=> int(0) ["type"]=> int(0) }

And when I get the same query and execute in the database I get the following results:

  

NULL COMPLETED 13

     

1.0.0.x 100x COMPLETED 2

     

1.0.1.x 101x COMPLETED 7

     

1.0.2.x 102x IMPLEMENTATION 1

     

1.0.2.x 102x COMPLETED 9

     

1.0.3.x 103x IMPLEMENTATION 5

     

1.0.3.x 103x COMPLETED 5

     

1.0.4.x 104x IN PROGRESS 1

     

1.0.4.x 104x CONCLUDED 1

Follow my PHP code: link Here is the connection code: link

PS: When using any other parameter in the source that does not contain special characters, for example GRI, the results are printed on the screen correctly without any problem.

../data/status.php?projeto=108&origem=GRI
    
asked by anonymous 28.11.2016 / 12:46

0 answers