Jump to content

Search the Community

Showing results for tags 'mysql php html'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Welcome to PHP Freaks
    • Announcements
    • Introductions
  • PHP Coding
    • PHP Coding Help
    • Regex Help
    • Third Party Scripts
    • FAQ/Code Snippet Repository
  • SQL / Database
    • MySQL Help
    • PostgreSQL
    • Microsoft SQL - MSSQL
    • Other RDBMS and SQL dialects
  • Client Side
    • HTML Help
    • CSS Help
    • Javascript Help
    • Other
  • Applications and Frameworks
    • Applications
    • Frameworks
    • Other Libraries
  • Web Server Administration
    • PHP Installation and Configuration
    • Linux
    • Apache HTTP Server
    • Microsoft IIS
    • Other Web Server Software
  • Other
    • Application Design
    • Other Programming Languages
    • Editor Help (PhpStorm, VS Code, etc)
    • Website Critique
    • Beta Test Your Stuff!
  • Freelance, Contracts, Employment, etc.
    • Services Offered
    • Job Offerings
  • General Discussion
    • PHPFreaks.com Website Feedback
    • Miscellaneous

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


AIM


MSN


Website URL


ICQ


Yahoo


Jabber


Skype


Location


Interests


Age


Donation Link

Found 1 result

  1. Hello everyone, this is a quick question. Im trying to look for input that the user made and validate if there's a duplicate or not. so: Steps: 1.check user input. 2.Check database for duplicate. 3.Return false/true. Here's what I tried to do... include 'db_connect.php' $username = $_POST['username']; $result = mysql_query("SELECT 1 FROM members WHERE username = " . mysql_real_escape_string($username)); if ($result && mysql_num_rows($result) > 0) { $ready = false; } else { $ready = true; } Here's what Im getting: Warning: mysql_real_escape_string() [function.mysql-real-escape-string]: Access denied for user 'adminUser'@'localhost' (using password: NO) in/home1/../../../../sec_reg.php on line 9 Warning: mysql_real_escape_string() [function.mysql-real-escape-string]: A link to the server could not be established in /home1/../../../../sec_reg.php on line 9 $result=my.... is line 9. Now, what I find weird is that in the SAME file I've got this: if ($insert_stmt = $mysqli->prepare("INSERT INTO members (username, email) VALUES (?, ?)")) { ..Some code here } And before I added the code with the warning the mysqli->prepare didn't have any problems. What could be happening? **Yes...I checked that db_connect.php was correct.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.