Questions tagged as 'php'

1
answer

What sublime plugin name 2/3 that indicates syntax error in the php language?

I need to know some sublime text 3 plugin that it indicates error in real-time debugger type code syntax same as what it has in phpStorm ... does anyone know?     
asked by 15.02.2016 / 13:47
1
answer

What extension of PHP should I use with SQL Server 2000?

I am trying to connect to the SQL Server 2000 database using PHP PDO SQLSRV, but when access to index returns me the catch() with the following error    SQLSTATE [08001]: [Microsoft] [SQL Server Native Client 11.0] SQL Server Native...
asked by 16.02.2016 / 00:32
1
answer

Format hours and minutes presentation of variable read from SQL

I'm starting PHP. I want to display the hours and minutes stored in a field but when I read it what it presents is something like: 01:00:00.0000000 . The SQL field is of type time (7) and the variable where I am reading is: $row["hor...
asked by 08.03.2016 / 16:07
1
answer

How to create a json from my object?

I have a Product object that I can not transform into json using json_encode : <?php class Produto { public $nome; public $preco; public $descricao; function transformarJson(){ } } ?> How can I do this?  ...
asked by 03.03.2016 / 16:55
1
answer

how to get the key in a while loop?

Let's say I have an associative array $array=array( "teste" => "1". "teste2" => "2" ); foreach($array AS $key=>$arr){ echo $key; } How do you loop? Do you have any way?     
asked by 04.03.2016 / 22:40
1
answer

Progress bar follow execution of mysql query

I need a bootstrap progress bar to follow the execution of a mysql query. $limite='200'; // limita $i=1; // para gerar o looping da barra de progresso $y = mysql_query("SELECT * FROM $tabela WHERE x='y' ORDER BY rand() limit $limite"); while(...
asked by 29.12.2016 / 15:11
1
answer

How to display data registered in another page

Hello friends how could I get the data to appear on another page in a table? Thisisthecode<formmethod="post" action="index.php" onSubmit=""> <fieldset> <legend>Sistema de Inventário</legend><br /&g...
asked by 23.12.2016 / 12:52
1
answer

Array PHP for Array JS

I have the following array in PHP Array ( [0] => Array ( [Funcionarios] => Array ( [id] => 3 [nome] => Funcionario Teste [assistmed] => 10...
asked by 28.12.2016 / 14:15
1
answer

Passing an array from a form to PHP via AJAX

I have this form:                                                        jQuery (function($) { AddTableRow = function() { var newRow = $("<tr>"); var cols = ""; cols += '<td><input type="text" name="dados[]...
asked by 26.12.2016 / 17:09
1
answer

Render view through the controller using Slim Framework 3

I'm trying to find a way to render the view using a controller in slim framework but for some reason I'm getting the error: Message: Using $this when not in object context The function is a public function and is inside a class norma...
asked by 24.12.2016 / 21:20