Call to undefined function sqlsrv_connect() with WAMP

后端 未结 4 1440
余生分开走
余生分开走 2021-01-18 23:19

I know that this question has already been asked several times on this website but I\'m seriously starting to wonder wheter I\'m crazy or not.

My configuration : Wam

4条回答
  •  无人共我
    2021-01-18 23:35

    Installing just the PHP extension is not enough, you also need to install Microsoft® ODBC Driver 11 for SQL Server® - Windows

    The ODBC drivers can be found here

    And newer drivers can be found here

    Also the best way to ensure you are editing the correct php.ini file is to use the wampmanager menus. So in future do :-

    wampmanager -> PHP -> php.ini
    

    This will load the correct php.ini into yoru editor.

    C:\wamp\bin\php\php{version}\php.ini is used only by PHP CLI

    C:\wamp\bin\apache\apache{version}\bin\php.ini is used only by PHP when running under Apache

提交回复
热议问题