{
"data": {
"app_id": "0000000",
"scopes": [
"public_profile"
],
"user_id": "00000000"
}
}
I want to get the USER ID with json_decode.
How do I get it?
<?php$con=mysql_connect("localhost","root","") or die("Failed to connect with database!!!!");
mysql_select_db("bancoteste", $con);
$sth = mysql_query("SELECT * FROM pessoa");
?>
<!DOCTYPE html>
<html>
<hea...
I'm starting my studies in PHP. I need to make a logical exclusion and although I have already found enough content on the topic, I can not find exactly how to do logical exclusion in PHP. Mine I did so (physical):
function remove( $table = nu...
I have following code:
<script>
$.post('http://localhost/app/user.php', {acao: acao}, function(retorna){
$("#demo").html(retorna);
if(retorna == "sucesso") {faça x}
});
</script>
However, in user.php...
I have an array of object I want to add a field in each item I make a foreach for this, but the field some after exiting the loop
foreach ($this->questions as $question) {
var_dump($question); // aqui é apresentado o array no est...
I created this code to add products to my database, but an error occurs in the image, says that I did not define it.
The code is this:
<?php
ob_start();
session_start();
require 'ligarDb.php';
$error = false;
$nameError ="";
$imagem...
My code is this:
<?php
$buscarusuario=$pdo->prepare("SELECT * FROM top5 WHERE status = 'ativo' ORDER BY colocacao ASC");
$buscarusuario->execute();
// Exibir com Fetch_Obj
$linha=$buscarusuario->fetchAll(PDO::FETCH_OBJ);
foreach (...
I have some tables in my db between them are
post_has_categoria
post
categoria
In My Models I have the Category.php and the Contest.php
where should sql be responsible for post_has_category?
Good morning!
I have a problem and I can not resolve the issue.
I need a buttom to appear or not according to the PHP condition.
Making the buttom appear I'm getting, the point is that inside it has a javascript call that does not work inside PH...
Regardless of what time it is, I need to find out if a time is in the range of an initial and final time, given the 24-hour format. The logic can be in both PHP and MYSQL, since in any case you should stop a Stored Procedure.
Ex:
Inicio...