Questions tagged as 'pdo'

1
answer

Solution for while in HTML structure

Does anyone have a simple solution to while looping in PHP for the following HTML structure? I basically want every 3 divs to have a <li> separating them so that the slide can work properly, since every <li> works as...
asked by 24.07.2014 / 21:00
1
answer

PDO query error

I have the following code: @$import = $dbconn->prepare("UPDATE t SET"); if(a <> "") { $import .= "teste2= '$a', teste= '$b', "; ... It returns this error: Catchable fatal error: Object of class PDOStatement could not be convert...
asked by 27.11.2018 / 16:25
1
answer

Why, only part of the data, appear in php? [closed]

I'm doing a select, in a table in my database, to get all messages from all users. However, only 1-user messages appear, the others do not! php: <?php ini_set('display_errors', true); error_reporting(E_ALL); header('Access-Control-Allow...
asked by 05.02.2016 / 19:09
1
answer

Error displaying the sum in a SELECT [closed]

I'm not getting the full amount. View    Bank   Valuesthatareinthebank:R$70,88$70.88Valuethatappears  $210Valuethathastoappear  R$212.64Code<?php$numerocontrato=trim($_GET["numerocontrato"]); $consulta = $DB->query("SELECT sum(...
asked by 03.01.2017 / 01:31
1
answer

Update with Multidimensional Array

I have a terrible problem, I can not update mysql via PDO, with array coming from some form fields. I've tried a lot and so far I can not do the update. The array comes in this format. Array ( [id] => Array ( [0] =&g...
asked by 01.06.2015 / 21:09
2
answers

PDO and mysqli are the only options for working with database in PHP? [duplicate]

And if I needed to use a database that was not supported by the PDO, what could I do? After all, what does the PDO do underneath the cloths? Does it use mysqli?     
asked by 11.07.2017 / 00:34
1
answer

(protocol / network address / port) [closed]

When I use the setInterval(getFollow(), 60000); function (1 minute or more or less always the same problem) of javascript I get this error from the PDO:    SQLSTATE [HY000] [2002] Usually only one use is allowed   of each socket...
asked by 14.08.2018 / 17:11
1
answer

Error inserting into DB

Well, I'm having a problem signing up for a client on DB. When I click on the register button, it only refreshes the page and does not insert the client into the database. No error appears and nothing. Just update the form and you're done. When...
asked by 19.12.2017 / 03:19
1
answer

SQLSTATE [08004] [1040] Too many connections

This is my connection class: / **  * Conn.class [CONNECTION]  * Abstract class of connection. Standard SingleTon.  * Returns a PDO object by the static getConn () method;  *  * @copyright (c) 2017, Horácio Pedro INFINITE CONNECTIONS  * / abs...
asked by 19.06.2018 / 13:38
1
answer

Multiple inner join PDO inserts

Hello, I have in the DB the tables categoria and imagens Currently the function (in PHP) to insert in the table category is similar to this (only title itself): public function insere($ttitulo) { try { $stmt =...
asked by 07.03.2016 / 22:06