Questions tagged as 'pdo'

0
answers

PDO - Uncaught exception 'PDOException' with message 'could not find driver'

Hey people! I'm trying to set up a project in a Yosemite Mac environment. The project I plan to run works normally on an Ubuntu. I installed the PDO drive. In phpinfo it looks like this: PDO PDO support => enabled PDO drivers => my...
asked by 03.12.2015 / 13:34
0
answers

Problems adding an array to fetchAll results

private $resultado; public function buscaTodos($query){ $stmt = $this->conn->prepare($query); $stmt->execute(); $this->resultado = $stmt->fetchAll(PDO::FETCH_OBJ); } public function getAllResults(){ $resultados =...
asked by 26.10.2015 / 02:00
2
answers

How to mount query in PDO with items before concatenated

The question is as follows, in mysql we can concatenate a query and then perform the search, as follows: $cidades = '&& (cidade = 100 || cidade = 101 || cidade = 102)'; $order = 'id ASC'; $sql = 'SELECT * FROM tabela WHERE status = 1...
asked by 13.10.2015 / 22:45
1
answer

Is using PDO the safest way to connect to a DB with PHP?

I am a beginner in PHP and would like to know if PDO (PHP Data Objects) is the safest way to connect to a database? I also need an example of how to make this connection and insert / select data.     
asked by 09.06.2015 / 15:26
0
answers

Save image along with form to the database by PHP

Good afternoon people, please help me, I found a tutorial on the internet that teaches to save the image in the database with php and jquery, but it teaches to send only the image already tried in every possible way so I can put with form with n...
asked by 03.10.2015 / 18:33
1
answer

Is using PDO the safest way to connect to a DB with PHP?

I am a beginner in PHP and would like to know if PDO (PHP Data Objects) is the safest way to connect to a database? I also need an example of how to make this connection and insert / select data.     
asked by 09.06.2015 / 15:26
1
answer

List evenly 3 column-count

Well I think this is in css what is not my beach, I would like to be listing the results of the bd and pass the next result to the next column I tried to use (summarized) SELECT * FROM anuncios ORDER BY data DESC .recipiente{ -webkit-colum...
asked by 04.06.2015 / 02:56
1
answer

Insertion with non-standard characters [duplicate]

When I enter MySQL database with PHP and PDO are entering strange and cluttered characters, what could be wrong? Here is an image of a bank table: Mypagehastheparameter:<metaname="viewport" content="width=device-width, initial-scale=1.0"...
asked by 27.04.2015 / 03:29
2
answers

return query as zend string

I have the following code where I need to save $ error_itens the complete query with the parameters to analyze what is happening, my question is, how do I show this query? $sql = new Sql($this->adapter); $query = $sql->in...
asked by 16.06.2016 / 05:59
2
answers

Password encryption in MD5? [duplicate]

What security does MD5 bring if the encryption of a password is only in the database in the password field? if by chance the system were invaded by any other breach would the MD5 influence something? Any internet site that Decrypta this MD5? W...
asked by 24.12.2016 / 01:06