Ecommerce software home
Shopping Cart Software Forum for Ecommerce Templates
 
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

Find us on Facebook Follow us on Twitter View our YouTube channel
Search our site
Forum Search
Google Site Search
 All Forums
 Technical
 PHP (Unix / Linux / Apache) versions
 Deprecated Error after PHP Update
Author « Topic »  

markaricnewsom
Advanced Member

USA
223 Posts

Pre-sales questions only
(More Details...)

Posted - 05/21/2019 :  07:20:36  
I updated Word and it said I needed a newer version of PHP. So, I updated php and get the following error:

PHP Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in...

How do I go about fixing this?

Mark Newsom
Web Consultant
P.O. Box 852
Kimberling City, MO 65686

dbdave
ECT Moderator

USA
10408 Posts

Posted - 05/21/2019 :  07:30:06  
Hi, check this thread.
https://www.ecommercetemplates.com/support/topic.asp?TOPIC_ID=106924
The issue is likely you need to make changes in the db_conn_open.php file.

markaricnewsom
Advanced Member

USA
223 Posts

Pre-sales questions only
(More Details...)

Posted - 05/21/2019 :  07:50:40  
That's not quite the same scenario. I am using 5.2.

Mark Newsom
Web Consultant
P.O. Box 852
Kimberling City, MO 65686

dbdave
ECT Moderator

USA
10408 Posts

Posted - 05/21/2019 :  09:43:32  
quote:
I updated Word and it said I needed a newer version of PHP. So, I updated php


So I understand correctly, you "updated" to php 5.2?
If so, have you tried 7.0+?

markaricnewsom
Advanced Member

USA
223 Posts

Pre-sales questions only
(More Details...)

Posted - 05/21/2019 :  13:56:23  
Yes, and when I do, it says I need to connect to the database

Mark Newsom
Web Consultant
P.O. Box 852
Kimberling City, MO 65686

dbdave
ECT Moderator

USA
10408 Posts

Posted - 05/21/2019 :  14:22:40  
Ok, I would go to the link I originally posted, make the changes to the database connection, and try that with the PHP 7.0+
If you still have trouble, perhaps post up the contents of your db_conn_open.php file (with the username/password removed).

Andy
ECT Moderator

95440 Posts

Posted - 05/22/2019 :  00:07:02  
Hi Mark

I think David is perfectly correct there - you need to check and change the syntax in vsadmin/db_conn_open.php and maybe in vsadmin/includes.php as per the examples here https://www.ecommercetemplates.com/support/topic.asp?TOPIC_ID=106924

Andy

Please feel free to review / rate our software

markaricnewsom
Advanced Member

USA
223 Posts

Pre-sales questions only
(More Details...)

Posted - 05/22/2019 :  12:38:33  
Okay, this is what mine looks like:

<?php

// You host should be able to provide you with these settings if you do not know them already

$db_username = "*************"; // Your database login username
$db_password = "*************"; // Your database login password
$db_name = "sumday10_ecomm"; // The name of the database you wish to use
$db_host = "localhost"; // The address of the database. Often this is localhost, but may be for example db.yoursite.com

//////////////////////////////////////////////////
// Please do not edit anything below this line. //
//////////////////////////////////////////////////

$dbh=mysql_connect($db_host, $db_username, $db_password) or die ('You need to set your database connection in vsadmin/db_conn_open.php.</td></tr></table></body></html>');
mysql_select_db($db_name) or die ('You need to set your database connection in vsadmin/db_conn_open.php.</td></tr></table></body></html>');
if(mysqli_connect_error()){
ob_clean();
print '<html><head><title>Database connect error</title></head><body><div style="margin:20px;clear:both">Database Connect Error (' . mysqli_connect_errno() . ') ' . mysqli_connect_error() . '</div>';
print('<div style="margin:20px;clear:both">You need to set your database connection in vsadmin/db_conn_open.php</div>');
print '<div style="margin:20px;clear:both">For help setting your database connection please see...<br />';
print '<a href="https://www.ecommercetemplates.com/phphelp/ecommplus/instructions.asp#dbconn" target="_blank">https://www.ecommercetemplates.com/phphelp/ecommplus/instructions.asp#dbconn</a></div>';
print '<div style="margin:20px;clear:both">We also have a support forum here...<br />';
print '<a href="https://www.ecommercetemplates.com/support/" target="_blank">https://www.ecommercetemplates.com/support/</a></div>';
die('</body></html>');
}
?>

Mark Newsom
Web Consultant
P.O. Box 852
Kimberling City, MO 65686

markaricnewsom
Advanced Member

USA
223 Posts

Pre-sales questions only
(More Details...)

Posted - 05/22/2019 :  12:44:34  
I changed everything below that line that said do not edit anything below this line and it worked. Amazing what happens when you ignore messages like that. :-)

Mark Newsom
Web Consultant
P.O. Box 852
Kimberling City, MO 65686

Andy
ECT Moderator

95440 Posts

Posted - 05/22/2019 :  12:47:43  
Is everything working as it should now, Mark?

Andy

Please feel free to review / rate our software

markaricnewsom
Advanced Member

USA
223 Posts

Pre-sales questions only
(More Details...)

Posted - 05/30/2019 :  06:27:34  
Yes, everything seems to be working fine.

Mark Newsom
Web Consultant
P.O. Box 852
Kimberling City, MO 65686
  « Topic »  
Jump To:
Shopping Cart Software Forum for Ecommerce Templates © 2002-2022 ecommercetemplates.com
This page was generated in 0.03 seconds. Snitz Forums 2000