PHP and MS SQL Server DLL issue

66 views Asked by At

I have PHP 8.3.3 installed and installed the PHP Manager within my IIS 10 environment. I have the following extension in php.ini:

extension=msodbcsql18
extension=bz2
extension=curl
;extension=ffi
;extension=ftp
extension=fileinfo
;extension=gd
extension=gettext
;extension=gmp
;extension=intl
;extension=imap
;extension=ldap
extension=mbstring
extension=exif      ; Must be after mbstring as it depends on it
extension=mysqli
;extension=oci8_12c  ; Use with Oracle Database 12c Instant Client
;extension=oci8_19  ; Use with Oracle Database 19 Instant Client
;extension=odbc
;extension=openssl
;extension=pdo_firebird
extension=pdo_mysql
;extension=pdo_oci
;extension=pdo_odbc
;extension=pdo_pgsql
extension=pdo_sqlite
;extension=pgsql
;extension=shmop
extension=php_pdo_sqlsrv_83_nts_x64
extension=php_sqlsrv_83_nts_x64

Doing a simple connection test runs successfully. I then created a PHP for that has to send an email via the SQL Server Database mail when a record is entered and submitted. There is an error in the log file:

PHP Warning: PHP Startup: Can't load module 'C:\PHP\ext\msodbcsql18.DLL' as it's linked with 14.34, but the core is linked with 14.29 in Unknown on line 0

Even though this message is displayed, the record is added to the SQL Server database and I can see it. The only thing that changed was the SMTP Server address and Port I added to the php.ini. I do not see how there can be any discrepancy between the PHP version and the SQL Server DLL version. What else can I look at to resolve this issue.

I revert back to the php.ini without SMTP settings and this does not created an issue.

0

There are 0 answers