Questions tagged as 'pdo'

1
answer

Why does not a query to the database yield results using PDO in PHP OO?

It has a class called student and another call connection, I create an object of connection through the use of an autoload, when I try to make queries to the database, in spite of being well the attributes of the object this does not return any...
asked by 13.06.2017 / 00:47
2
answers

problems showing results in a table

I have a problem when showing records in my table the problem is the following: in the header of the table I show the hours that would be eight in total and below the header the results of the numbers that have come out are shown according to th...
asked by 10.06.2017 / 20:55
1
answer

Update with PHP and PDO

I'm doing a UPDATE with PDO , previously it worked, but now for some strange reason it does not work and I can not find the error This is the BackEnd : <?php session_start(); require 'extras/config.php'; require 'func...
asked by 05.06.2017 / 00:56
1
answer

display data in the header of a table

I would like to show data in the header of a table, but I can not show it to me as I want; since this field to be shown in the header is called from the attached bd an image of how the data should be displayed and my source code. the line to...
asked by 03.06.2017 / 06:14
2
answers

Problems with keypress

I have a problem when inserting rows in the table with the enter key event: it works fine if I put the function with the button, but I do not want to add rows when the button is clicked, if I do not want to add the rows in the table when filling...
asked by 25.05.2017 / 20:38
2
answers

Why does "Constant expression contains invalid operations" error appear in connection class using PDO in PHP?

I have the following object-oriented connection class with PDO: Conexion.php: <?php namespace Models; $archivo = 'config.ini.php'; $configurar = parse_ini_file($archivo, true); $host= $configurar['basedatos']['host']; $user = $config...
asked by 08.06.2017 / 21:44
0
answers

Problems with PDO in Hostinger

How about, can someone help me with the following problem? I have a web page which at the time of registering through a form, this sends the data to another page so that it creates a database of the user (creates a database, not a table on a...
asked by 16.05.2017 / 20:30
0
answers

How to capture the data of a select to update it?

The drawback I have is when I want to update a select of a specific id but when I give it to edit it always shows me the data of the select of the first id inserted but the other fields if the samples correctly minus the one of the select. Th...
asked by 05.05.2017 / 23:08
0
answers

Change the query to PDO

I have the following code that generates a JSON file, it works fine, but I must change it to send the data between the controller and the model. include "conex.php"; $sql= "select * from timetables"; $query = $con->query($sql); // Fetch t...
asked by 30.04.2017 / 01:25
1
answer

Problems with PDO and PHP

I need to connect to a db oracle, for that I'm using the following code! <?php class ConnectionDBTOAD{ private static $conn=null; private static $server = "mi host"; private static $db_username = "mi usuario"; private static $db_password =...
asked by 27.04.2017 / 15:14