mssql not loaded


DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 6 of 6

Thread: mssql not loaded

  1. #1
    Join Date
    Sep 2010
    Posts
    10

    mssql not loaded

    Good day!

    I try a lot of configuration to work my connection from php to mssql but still I cannot connect. And I got a code to check if the mssql was loaded.

    Here is the code:
    PHP Code:
    <?php
    if (function_exists('mssql_connect')){
    echo 
    "Okay, fn is there<br>------------------<br>";
    } else {
    echo 
    "Hmmm .. fn is not even there<br>------------------<br>";
    }

    if(
    extension_loaded("mssql")) {
    echo 
    "MSSQL is Loaded<br>";
    }
    else {
    echo 
    "MSSQL not loaded<br>";


    if(
    extension_loaded("msql")) {
    echo 
    "MSQL is Loaded<br>";
    }
    else {
    echo 
    "MSQL not loaded<br>";

    echo 
    '<br><br>';

    $ext get_loaded_extensions();
    if(
    in_array('mssql'$ext))
    echo 
    'u have mssql installed<br><br>';
    else
    echo 
    'u do NOT have mssql installed<br><br>';

    phpinfo();
    ?>
    And when I run this code the result is:

    Hmmm….fn is not even there
    ----------------------
    MSSQL not loaded
    MSQL not loaded
    You do NOT have mssql installed
    And the list of phpinfo() appear.

    Actually I run this code when my php version is php 5.2.4 and now I try it to php 5.1.4 and the result is still the same.

    Web server is IIS 6.0
    OS is Windows Server 2003 R2 Standard Edition
    PHP version is php 5.1.4
    MS SQL Server 2005 Express Edition –Windows Authentication.

    I need to solved this problem because my connection in mssql is not working because call to undefined the function mssql_connect().

    I hope somebody can help me. Almost three weeks I configure this connection and still I cannot connect.

    Any help is highly appreciated.
    Thank you.

  2. #2
    Join Date
    Apr 2007
    Location
    Sterling Heights, Michigan
    Posts
    8,666
    What connection string are you using?
    I don't answer coding questions via PM or Email. Please post a thread in the appropriate forum section.
    Please use [Code]your code goes in here[/Code] tags when posting code.
    Before posting your question, did you look here?
    Got a question on Linux? Visit our Linux sister site.
    Modifications Required For VB6 Apps To Work On Vista

  3. #3
    Join Date
    Sep 2010
    Posts
    10
    Quote Originally Posted by Hack View Post
    What connection string are you using?
    mssql_connect()

  4. #4
    Join Date
    Oct 2010
    Posts
    3
    Not sure if this helps at all, but a few years back I converted my website from using PHP/MySQL to PHP/MSSQL and noticed a severe problem with memory leaks. With MSSQL better for what we needed it to do, I then switched PHP to ASP.NET which then elminated the memory leak issue.

    My point being, I suspect that the two technologies do not function well together (unless I just had poor code).

  5. #5
    Join Date
    Oct 2008
    Posts
    142
    hi there,

    look at this page http://php.net/manual/en/function.mssql-connect.php
    and search for version and find your answer.
    what i am trying to tell you is that you need a sql server connect method which matches your php version.

    best regards,

    tonci.

  6. #6
    Join Date
    Sep 2010
    Posts
    10
    Quote Originally Posted by tkorsano View Post
    hi there,

    look at this page http://php.net/manual/en/function.mssql-connect.php
    and search for version and find your answer.
    what i am trying to tell you is that you need a sql server connect method which matches your php version.

    best regards,

    tonci.
    when I used mssql_connect() it works but my only problem is connect to database. I think i need to configure my sql server but I don't what I need to configure.

Similar Threads

  1. VC++ - updating .dsp file?
    By jimlau in forum C++
    Replies: 13
    Last Post: 05-26-2010, 09:38 AM
  2. loaded page can not run javascript :-(
    By maileen in forum AJAX
    Replies: 6
    Last Post: 10-20-2008, 05:42 PM
  3. Columns in MSSQL filled, with Gridview empty
    By ensingg in forum ASP.NET
    Replies: 0
    Last Post: 09-04-2006, 10:49 AM
  4. "HTTP GET" won't display - PLEASE HELP!
    By realmscape in forum .NET
    Replies: 0
    Last Post: 03-19-2005, 04:27 PM
  5. .NET and DLL ****
    By Willy Van den Driessche in forum .NET
    Replies: 2
    Last Post: 10-28-2001, 05:25 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center