I developed web form and connected to mysql db. When I tested on local hosting (on my computer) it worked ok, all INSERT queries were done successfully, but when I uploaded on hosting (tried on 2 hosting companies) all Inserts in db are empty.
What problem can be?
My code
$db = mysqli_connect('localhost', 'cy57447_forms', '123456789', 'cy57447_forms');
if(isset($_POST['register'])) {
$email = mysql_real_escape_string($_POST['email']);
$tg_username = mysql_real_escape_string($_POST['tg_username']);
$bitcointalk_username = mysql_real_escape_string($_POST['bitcointalk_username']);
$bitcointalk_profile_link = mysql_real_escape_string($_POST['bitcointalk_profile_link']);
$twitter_account_url = mysql_real_escape_string($_POST['twitter_account_url']);
$number_of_followers = mysql_real_escape_string($_POST['number_of_followers']);
$twitter_audit_link = mysql_real_escape_string($_POST['twitter_audit_link']);
$ethereum_wallet = mysql_real_escape_string($_POST['ethereum_wallet']);
$tokens = '';
}
$sql = "INSERT INTO twitter_form (`tg_username`, `bitcointalk_username`, `bitcointalk_profile_link`, `twitter_account_url`, `number_of_followers`, `twitter_audit_link`, `ethereum_wallet`, `email`, `tokens`) VALUES ('$tg_username', '$bitcointalk_username', '$bitcointalk_profile_link', '$twitter_account_url', '$number_of_followers', '$twitter_audit_link', '$ethereum_wallet','$email', '');";
$result = mysqli_query($db, $sql);