Jump to content


Photo

database access


  • Please log in to reply
3 replies to this topic

#1 KinmaJinti

KinmaJinti

    Newbie

  • Members
  • 1 posts

Posted 14 August 2019 - 07:55 AM


When I try to access my database, it return the message:


Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in /home1/dtt22299/public_html/online_trading/processemail.php on line 10


I do not understand what it mean


I use {$con = mysql_connect("localhost","dtt22299_bill","[redacted]"); in my processemai.php


Are there anything wrong?

Edited by wolstech, 14 August 2019 - 10:13 AM.
Password


#2 Luigi123

Luigi123

    Rank X Member

  • Moderators
  • 1,635 posts
  • Gender:Male
  • Location:Winnipeg, Manitoba, Canada

Posted 14 August 2019 - 02:28 PM

Moved to Customer Service.
Posted ImagePosted ImagePosted Image
Posted ImagePosted ImagePosted Image

#3 flazepe

flazepe

    Rank VII Member

  • Moderators
  • 520 posts
  • Gender:Male

Posted 14 August 2019 - 02:49 PM

Try:

$con = mysqli_connect("localhost","dtt22299_bill","password","database");


#4 wolstech

wolstech

    Rank X Member

  • Root Admin
  • 10,620 posts
  • Gender:Male
  • Location:Pennsylvania

Posted 14 August 2019 - 04:46 PM

The old mysql_***() functions are obsolete. As flazepe said, use mysqli instead.

 

They work nearly identically, the only main difference is that they all require you pass the connection handle into them (with the old mysql ones it was optional and assumed the most recent connection if you didn't specify).


Please do not PM me for support. Posting on our forums lets all of us learn.
Do you play Minecraft? | Server Monitors | And the Dumbass of the Decade award goes to...





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users