0
am having problems connecting the database of my website. The following error happens:
Fatal error: Uncaught Error: Call to undefined function mysql_connect() in /home/cardgamming/www/configuracao.php:10 Stack trace: #0 /home/cardgamming/www/Painel/inicio.php(2): include() #1 {main} thrown in /home/cardgamming/www/configuracao.php on line 10
Follow the code below:
<?php
error_reporting (E_ALL & ~ E_NOTICE & ~ E_DEPRECATED);
$link_fake = "http://cardgaming.net/"; // SUA URL
$config['host'] = 'mysql04-farm62.kinghost.net'; // HOST DO BANCO DE DADOS
$config['user'] = 'card_add1'; // LOGIN DO BANCO DE DADOS
$config['pass'] = 'senha123'; // SENHA DO BANCO DE DADOS
$config['db'] = 'cardgaming'; // NOME DO BANCO DE DADOS
$selecao = mysql_connect($config['host'],$config['user'],$config['pass'])or die("erro dados");
$conexao = mysql_select_db($config['db'],$selecao);
mysql_query("SET NAMES 'mysql'");
mysql_query('SET character_set_connection=mysql');
mysql_query('SET character_set_client=mysql');
mysql_query('SET character_set_results=mysql');
$seuemail = "[email protected]"; //CONFIGURE SEU EMAIL
$assunto_email = "cardgamming"; //ASSUNTO QUE CHEGARA O EMAIL
Since thanks!