Fatal error: Call to undefined function mssql_connect() in php












2















I'm running Windows Server, MS Sql and IIS6. I am trying to connect php to ms sql database, and I keep getting the following error from the script




Fatal error: Call to undefined function mssql_connect() in .... on line x




I have install zend studio in C:Program FilesZendZendStudio-5.5.0 directory. Configure IIS server and set the path variable to ;C:Program FilesZendZendStudio-5.5.0binphp5 also.
The zend studio folder contains php4 and php5 inside the bin dir. I have added extension=php_mssql.dll in the php.ini file which is inside the C:Program FilesZendZendStudio-5.5.0binphp5 folder. And added php_mssql.dll in the ext dir. php.ini file is placed in windows path C:WINDOWS also.










share|improve this question

























  • Have you restarted the server since changing the ini file?

    – cwallenpoole
    Jul 13 '11 at 5:08











  • yes, i have and restart system also

    – user99
    Jul 13 '11 at 5:14











  • did you try stackoverflow.com/questions/17103751/…

    – Arpit Gupta
    Jul 24 '13 at 14:41











  • or you can try stackoverflow.com/questions/7402713/…

    – Arpit Gupta
    Jul 24 '13 at 14:48











  • Possible duplicate of PHP Fatal error: Call to undefined function mssql_connect()

    – miken32
    Feb 21 '17 at 18:09
















2















I'm running Windows Server, MS Sql and IIS6. I am trying to connect php to ms sql database, and I keep getting the following error from the script




Fatal error: Call to undefined function mssql_connect() in .... on line x




I have install zend studio in C:Program FilesZendZendStudio-5.5.0 directory. Configure IIS server and set the path variable to ;C:Program FilesZendZendStudio-5.5.0binphp5 also.
The zend studio folder contains php4 and php5 inside the bin dir. I have added extension=php_mssql.dll in the php.ini file which is inside the C:Program FilesZendZendStudio-5.5.0binphp5 folder. And added php_mssql.dll in the ext dir. php.ini file is placed in windows path C:WINDOWS also.










share|improve this question

























  • Have you restarted the server since changing the ini file?

    – cwallenpoole
    Jul 13 '11 at 5:08











  • yes, i have and restart system also

    – user99
    Jul 13 '11 at 5:14











  • did you try stackoverflow.com/questions/17103751/…

    – Arpit Gupta
    Jul 24 '13 at 14:41











  • or you can try stackoverflow.com/questions/7402713/…

    – Arpit Gupta
    Jul 24 '13 at 14:48











  • Possible duplicate of PHP Fatal error: Call to undefined function mssql_connect()

    – miken32
    Feb 21 '17 at 18:09














2












2








2








I'm running Windows Server, MS Sql and IIS6. I am trying to connect php to ms sql database, and I keep getting the following error from the script




Fatal error: Call to undefined function mssql_connect() in .... on line x




I have install zend studio in C:Program FilesZendZendStudio-5.5.0 directory. Configure IIS server and set the path variable to ;C:Program FilesZendZendStudio-5.5.0binphp5 also.
The zend studio folder contains php4 and php5 inside the bin dir. I have added extension=php_mssql.dll in the php.ini file which is inside the C:Program FilesZendZendStudio-5.5.0binphp5 folder. And added php_mssql.dll in the ext dir. php.ini file is placed in windows path C:WINDOWS also.










share|improve this question
















I'm running Windows Server, MS Sql and IIS6. I am trying to connect php to ms sql database, and I keep getting the following error from the script




Fatal error: Call to undefined function mssql_connect() in .... on line x




I have install zend studio in C:Program FilesZendZendStudio-5.5.0 directory. Configure IIS server and set the path variable to ;C:Program FilesZendZendStudio-5.5.0binphp5 also.
The zend studio folder contains php4 and php5 inside the bin dir. I have added extension=php_mssql.dll in the php.ini file which is inside the C:Program FilesZendZendStudio-5.5.0binphp5 folder. And added php_mssql.dll in the ext dir. php.ini file is placed in windows path C:WINDOWS also.







php sql-server






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Jun 16 '15 at 19:52









JackWhiteIII

1,0362922




1,0362922










asked Jul 13 '11 at 5:05









user99user99

1412




1412













  • Have you restarted the server since changing the ini file?

    – cwallenpoole
    Jul 13 '11 at 5:08











  • yes, i have and restart system also

    – user99
    Jul 13 '11 at 5:14











  • did you try stackoverflow.com/questions/17103751/…

    – Arpit Gupta
    Jul 24 '13 at 14:41











  • or you can try stackoverflow.com/questions/7402713/…

    – Arpit Gupta
    Jul 24 '13 at 14:48











  • Possible duplicate of PHP Fatal error: Call to undefined function mssql_connect()

    – miken32
    Feb 21 '17 at 18:09



















  • Have you restarted the server since changing the ini file?

    – cwallenpoole
    Jul 13 '11 at 5:08











  • yes, i have and restart system also

    – user99
    Jul 13 '11 at 5:14











  • did you try stackoverflow.com/questions/17103751/…

    – Arpit Gupta
    Jul 24 '13 at 14:41











  • or you can try stackoverflow.com/questions/7402713/…

    – Arpit Gupta
    Jul 24 '13 at 14:48











  • Possible duplicate of PHP Fatal error: Call to undefined function mssql_connect()

    – miken32
    Feb 21 '17 at 18:09

















Have you restarted the server since changing the ini file?

– cwallenpoole
Jul 13 '11 at 5:08





Have you restarted the server since changing the ini file?

– cwallenpoole
Jul 13 '11 at 5:08













yes, i have and restart system also

– user99
Jul 13 '11 at 5:14





yes, i have and restart system also

– user99
Jul 13 '11 at 5:14













did you try stackoverflow.com/questions/17103751/…

– Arpit Gupta
Jul 24 '13 at 14:41





did you try stackoverflow.com/questions/17103751/…

– Arpit Gupta
Jul 24 '13 at 14:41













or you can try stackoverflow.com/questions/7402713/…

– Arpit Gupta
Jul 24 '13 at 14:48





or you can try stackoverflow.com/questions/7402713/…

– Arpit Gupta
Jul 24 '13 at 14:48













Possible duplicate of PHP Fatal error: Call to undefined function mssql_connect()

– miken32
Feb 21 '17 at 18:09





Possible duplicate of PHP Fatal error: Call to undefined function mssql_connect()

– miken32
Feb 21 '17 at 18:09












2 Answers
2






active

oldest

votes


















0














To get changes made to php.ini to take effect, you must stop and start the IIS web service.



Also, mssql requires: ntwdblib.dll to be available on the Windows PATH. It is better to add the php folder to the Windows PATH instead of moving any files around. Re-logon or reboot your computer to get any changes made to the Windows PATH statement to take effect.






share|improve this answer
























  • I have added php5 folder as it is from C:Program FilesZendZendStudio-5.5.0binphp5 to the Windows path. And ntwdblib.dll is also in the windows path. My php.ini file contains only extension_dir, extension, inlclude_path

    – user99
    Jul 13 '11 at 5:20











  • "And added php_mssql.dll in the ext dir." is it also added to php.ini? like uncommented?

    – Hanky Panky
    Dec 26 '12 at 8:33



















0














mssql_* API are no longer available on recent version of PHP
This extension is not available anymore on Windows with PHP 5.3 or later



you may need fix and compile yourself as it does not included in the open-source package.






share|improve this answer























    Your Answer






    StackExchange.ifUsing("editor", function () {
    StackExchange.using("externalEditor", function () {
    StackExchange.using("snippets", function () {
    StackExchange.snippets.init();
    });
    });
    }, "code-snippets");

    StackExchange.ready(function() {
    var channelOptions = {
    tags: "".split(" "),
    id: "1"
    };
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function() {
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled) {
    StackExchange.using("snippets", function() {
    createEditor();
    });
    }
    else {
    createEditor();
    }
    });

    function createEditor() {
    StackExchange.prepareEditor({
    heartbeatType: 'answer',
    autoActivateHeartbeat: false,
    convertImagesToLinks: true,
    noModals: true,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: 10,
    bindNavPrevention: true,
    postfix: "",
    imageUploader: {
    brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
    contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
    allowUrls: true
    },
    onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    });


    }
    });














    draft saved

    draft discarded


















    StackExchange.ready(
    function () {
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f6674320%2ffatal-error-call-to-undefined-function-mssql-connect-in-php%23new-answer', 'question_page');
    }
    );

    Post as a guest















    Required, but never shown

























    2 Answers
    2






    active

    oldest

    votes








    2 Answers
    2






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes









    0














    To get changes made to php.ini to take effect, you must stop and start the IIS web service.



    Also, mssql requires: ntwdblib.dll to be available on the Windows PATH. It is better to add the php folder to the Windows PATH instead of moving any files around. Re-logon or reboot your computer to get any changes made to the Windows PATH statement to take effect.






    share|improve this answer
























    • I have added php5 folder as it is from C:Program FilesZendZendStudio-5.5.0binphp5 to the Windows path. And ntwdblib.dll is also in the windows path. My php.ini file contains only extension_dir, extension, inlclude_path

      – user99
      Jul 13 '11 at 5:20











    • "And added php_mssql.dll in the ext dir." is it also added to php.ini? like uncommented?

      – Hanky Panky
      Dec 26 '12 at 8:33
















    0














    To get changes made to php.ini to take effect, you must stop and start the IIS web service.



    Also, mssql requires: ntwdblib.dll to be available on the Windows PATH. It is better to add the php folder to the Windows PATH instead of moving any files around. Re-logon or reboot your computer to get any changes made to the Windows PATH statement to take effect.






    share|improve this answer
























    • I have added php5 folder as it is from C:Program FilesZendZendStudio-5.5.0binphp5 to the Windows path. And ntwdblib.dll is also in the windows path. My php.ini file contains only extension_dir, extension, inlclude_path

      – user99
      Jul 13 '11 at 5:20











    • "And added php_mssql.dll in the ext dir." is it also added to php.ini? like uncommented?

      – Hanky Panky
      Dec 26 '12 at 8:33














    0












    0








    0







    To get changes made to php.ini to take effect, you must stop and start the IIS web service.



    Also, mssql requires: ntwdblib.dll to be available on the Windows PATH. It is better to add the php folder to the Windows PATH instead of moving any files around. Re-logon or reboot your computer to get any changes made to the Windows PATH statement to take effect.






    share|improve this answer













    To get changes made to php.ini to take effect, you must stop and start the IIS web service.



    Also, mssql requires: ntwdblib.dll to be available on the Windows PATH. It is better to add the php folder to the Windows PATH instead of moving any files around. Re-logon or reboot your computer to get any changes made to the Windows PATH statement to take effect.







    share|improve this answer












    share|improve this answer



    share|improve this answer










    answered Jul 13 '11 at 5:10









    BalanivashBalanivash

    4,84662747




    4,84662747













    • I have added php5 folder as it is from C:Program FilesZendZendStudio-5.5.0binphp5 to the Windows path. And ntwdblib.dll is also in the windows path. My php.ini file contains only extension_dir, extension, inlclude_path

      – user99
      Jul 13 '11 at 5:20











    • "And added php_mssql.dll in the ext dir." is it also added to php.ini? like uncommented?

      – Hanky Panky
      Dec 26 '12 at 8:33



















    • I have added php5 folder as it is from C:Program FilesZendZendStudio-5.5.0binphp5 to the Windows path. And ntwdblib.dll is also in the windows path. My php.ini file contains only extension_dir, extension, inlclude_path

      – user99
      Jul 13 '11 at 5:20











    • "And added php_mssql.dll in the ext dir." is it also added to php.ini? like uncommented?

      – Hanky Panky
      Dec 26 '12 at 8:33

















    I have added php5 folder as it is from C:Program FilesZendZendStudio-5.5.0binphp5 to the Windows path. And ntwdblib.dll is also in the windows path. My php.ini file contains only extension_dir, extension, inlclude_path

    – user99
    Jul 13 '11 at 5:20





    I have added php5 folder as it is from C:Program FilesZendZendStudio-5.5.0binphp5 to the Windows path. And ntwdblib.dll is also in the windows path. My php.ini file contains only extension_dir, extension, inlclude_path

    – user99
    Jul 13 '11 at 5:20













    "And added php_mssql.dll in the ext dir." is it also added to php.ini? like uncommented?

    – Hanky Panky
    Dec 26 '12 at 8:33





    "And added php_mssql.dll in the ext dir." is it also added to php.ini? like uncommented?

    – Hanky Panky
    Dec 26 '12 at 8:33













    0














    mssql_* API are no longer available on recent version of PHP
    This extension is not available anymore on Windows with PHP 5.3 or later



    you may need fix and compile yourself as it does not included in the open-source package.






    share|improve this answer




























      0














      mssql_* API are no longer available on recent version of PHP
      This extension is not available anymore on Windows with PHP 5.3 or later



      you may need fix and compile yourself as it does not included in the open-source package.






      share|improve this answer


























        0












        0








        0







        mssql_* API are no longer available on recent version of PHP
        This extension is not available anymore on Windows with PHP 5.3 or later



        you may need fix and compile yourself as it does not included in the open-source package.






        share|improve this answer













        mssql_* API are no longer available on recent version of PHP
        This extension is not available anymore on Windows with PHP 5.3 or later



        you may need fix and compile yourself as it does not included in the open-source package.







        share|improve this answer












        share|improve this answer



        share|improve this answer










        answered Sep 30 '13 at 13:02









        Dennis CDennis C

        19.9k126394




        19.9k126394






























            draft saved

            draft discarded




















































            Thanks for contributing an answer to Stack Overflow!


            • Please be sure to answer the question. Provide details and share your research!

            But avoid



            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.


            To learn more, see our tips on writing great answers.




            draft saved


            draft discarded














            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f6674320%2ffatal-error-call-to-undefined-function-mssql-connect-in-php%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown





















































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown

































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown







            Popular posts from this blog

            Monofisismo

            Angular Downloading a file using contenturl with Basic Authentication

            Olmecas