Azure PHP错误500

Azure PHP错误500,php,mysql,azure,Php,Mysql,Azure,我创建了一个简单的PHP注册表单,并通过FTP将其上传到我的azure目录。 当我填写表格详细信息并单击“提交”时,它会自动转到错误500页。他们在我的脚本中没有错误,所以这对我来说毫无意义 我确保登录已打开,当我阅读错误报告时,它就是这么说的 HTTP Error 500.0 - Internal Server Error The page cannot be displayed because an internal server error has occurred. Most l

我创建了一个简单的PHP注册表单,并通过FTP将其上传到我的azure目录。 当我填写表格详细信息并单击“提交”时,它会自动转到错误500页。他们在我的脚本中没有错误,所以这对我来说毫无意义

我确保登录已打开,当我阅读错误报告时,它就是这么说的

HTTP Error 500.0 - Internal Server Error

The page cannot be displayed because an internal server error has occurred.



Most likely causes:
•IIS received the request; however, an internal error occurred during the processing of the request. The root cause of this error depends on which module handles the request and what was happening in the worker process when this error occurred.
•IIS was not able to access the web.config file for the Web site or application. This can occur if the NTFS permissions are set incorrectly.
•IIS was not able to process configuration for the Web site or application.
•The authenticated user does not have permission to use this DLL.
•The request is mapped to a managed handler but the .NET Extensibility Feature is not installed.

Things you can try:
•Ensure that the NTFS permissions for the web.config file are correct and allow access to the Web server's machine account.
•Check the event logs to see if any additional information was logged.
•Verify the permissions for the DLL.
•Install the .NET Extensibility feature if the request is mapped to a managed handler.
•Create a tracing rule to track failed requests for this HTTP status code. For more information about creating a tracing rule for failed requests, click here. 



Detailed Error Information:



Module
   FastCgiModule 

Notification
   ExecuteRequestHandler 

Handler
   PHP54_via_FastCGI 

Error Code
   0x00000000 



Requested URL
   http://MyTestSite:80/register.php 

Physical Path
   D:\home\site\wwwroot\register.php 

Logon Method
   Anonymous 

Logon User
   Anonymous 
#
这是我的实际代码

<?php
    require_once 'processor/dbconfig.php';



    if(isset($_POST['submit']))
    {
       $uname = trim($_POST['user']);
       $umail = trim($_POST['email']);
       $upass = trim($_POST['pwd']); 
       $fname = trim($_POST['first']); 
       $lname = trim($_POST['last']); 
       $ubranch = trim($_POST['branch']); 


                if($user->register($fname,$lname,$uname,$umail,$upass,$ubranch)) 
                {
                    echo 'Success';
                }


    }
    ?>
    <html>
    <head>
          <!-- Latest compiled and minified CSS -->
    <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap.min.css">

    <!-- jQuery library -->
    <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script>

    <!-- Latest compiled JavaScript -->
    <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/js/bootstrap.min.js"></script>
    <style type="text/css">
        .container {
            margin-right: auto;
            margin-left: auto;
            margin-top: 15px;
            margin-bottom: auto;
            width: 200px;
            clear: both;
            padding: 20px 50px 20px;
            width: 400px;
            background: white;
            border-radius: 3px;
            -webkit-box-shadow: 0 0 200px rgba(255, 255, 255, 0.5), 0 1px 2px rgba(0, 0, 0, 0.3);
            box-shadow: 0 0 200px rgba(255, 255, 255, 0.5), 0 1px 2px rgba(0, 0, 0, 0.3);
        }
    </style>
    </head>
    <body>
    <div class="container">
    <form role="form" method="POST">

      <div class="form-group">
        <label for="user">Username:</label>
        <input type="text" name="user" class="form-control" id="user">
      </div>
      <div class="form-group">
        <label for="pwd">Password:</label>
        <input type="password" name="pwd" class="form-control" id="pwd">
      </div>
      <div class="form-group">
        <label for="email">Email:</label>
        <input type="email" name="email" class="form-control" id="email">
      </div>
      <div class="form-group">
        <label for="first">First Name:</label>
        <input type="text" name="first" class="form-control" id="first">
      </div>
      <div class="form-group">
        <label for="last">Last Name:</label>
        <input type="text" name="last" class="form-control" id="last">
      </div>
      <div class="form-group">
        <label for="branch">Branch:</label>
        <input type="text" name="branch" class="form-control" id="branch">
      </div>
      <input type="submit" name="submit" class="btn btn-default"/>
    </form>
    </div>
    </body>
    </html>

.集装箱{
右边距:自动;
左边距:自动;
边缘顶部:15px;
页边距底部:自动;
宽度:200px;
明确:两者皆有;
填充:20px 50px 20px;
宽度:400px;
背景:白色;
边界半径:3px;
-webkit盒阴影:0 0 200px rgba(255,255,0.5),0 1px 2px rgba(0,0,0,0.3);
框阴影:0 0 200px rgba(255,255,255,0.5),0 1px 2px rgba(0,0,0.3);
}
用户名:
密码:
电邮:
名字:
姓氏:
分支机构:

启用显示错误,以获取详细错误,从而简化调试。 将这行代码放在PHP脚本的顶部:

ini_set('display_errors', 1);

然后用新的错误更新您的问题。

启用显示错误,以获得详细错误,从而简化调试。 将这行代码放在PHP脚本的顶部:

ini_set('display_errors', 1);

然后用新错误更新您的问题。

可能是脚本中的语法错误或发出的警告。您必须查看错误日志以了解详细信息。@MarcB我发布了错误日志,里面没有有用的东西。你得开始挖了,这就是我来这里的原因。我不知道还有什么地方需要挖掘。可能是脚本中的语法错误或发出警告之类的简单问题。您必须查看错误日志以了解详细信息。@MarcB我发布了错误日志,里面没有有用的东西。你得开始挖了,这就是我来这里的原因。我不知道还有什么地方可以挖。谢谢你!我补充说,然后出现了一个错误,说未定义的函数密码\u散列,密码散列出现在php版本5.5中。我检查了我的azure php版本,它设置为5.4。我将php版本更新为5.5和VIOLA!它起作用了。再次感谢你,伙计!!我的朋友,我会接受这个答案,一旦它让我简化了事情,这是令人惊讶的,它不是自动启用的任何人谁真正开始PHP。很高兴你成功了!谢谢你,伙计!我补充说,然后出现了一个错误,说未定义的函数密码\u散列,密码散列出现在php版本5.5中。我检查了我的azure php版本,它设置为5.4。我将php版本更新为5.5和VIOLA!它起作用了。再次感谢你,伙计!!我的朋友,我会接受这个答案,一旦它让我简化了事情,这是令人惊讶的,它不是自动启用的任何人谁真正开始PHP。很高兴你成功了!