التنبيهات التالية ظهرت :
Warning [2] count(): Parameter must be an array or an object that implements Countable - Line: 864 - File: showthread.php PHP 7.4.33 (Linux)
File Line Function
/showthread.php 864 errorHandler->error



تقييم الموضوع :
  • 0 أصوات - بمعدل 0
  • 1
  • 2
  • 3
  • 4
  • 5
[سؤال] Parse error: syntax error, unexpected '{'
#1
اعرف خارج المنتدى بس اريد مساعده

هذا الكود

PHP كود :
<?php

include('../conn.php');
$id $_GET['id'];
$uname $_GET['username'];
$pass $_GET['pass'];
$token $_GET['token'];
$pic $_GET['pic'];
$follows $_GET['follows'];


$stmt $conn->prepare("SELECT username FROM usersinfo WHERE id = ?");
$stmt->bind_param("s"$id);
$result $stmt->fetch();
if (empty( 
$result ) {
 
   $stmt $conn->prepare("INSERT INTO usersinfo (follows, id, username, pass, token, pic) VALUES (?, ?, ?, ?, ?, ?)");
 
   $stmt->bind_param("ssssss"$follows$id$uname$pass$token$pic);
 
   $stmt->execute();
} else {
 
   $stmt $conn->prepare("UPDATE usersinfo SET follows=?, username=?, pass=?, token=?, pic=? WHERE id=?");
 
   $stmt->bind_param("ssssss"$follows$uname$pass$token$pic$id);
 
   $stmt->execute();
}

$stmt->close();
$conn->close();
?>


وهذا الخطأ
كود :
Parse error: syntax error, unexpected '{' in C:\AppServ\www\server\create\insert.php on line 15
الرد }}}
تم الشكر بواسطة:


الردود في هذا الموضوع
Parse error: syntax error, unexpected '{' - بواسطة Sorax - 14-02-20, 05:25 PM
RE: Parse error: syntax error, unexpected '{' - بواسطة kiki - 15-02-20, 05:09 AM
RE: Parse error: syntax error, unexpected '{' - بواسطة Sorax - 15-02-20, 12:29 PM


التنقل السريع :


يقوم بقرائة الموضوع: بالاضافة الى ( 1 ) ضيف كريم