zoukankan      html  css  js  c++  java
  • windows 2008 R2操作系统上使用iis服务运行php和mysql数据库的网站遇到的验证码不显示问题?

    1,本地运行正常,路径没问题。

    2,GD2.dll开启

    3,IIS服务正常开启,并启用父路径为True

    4,检查是否IIS服务中FSO权限问题

        开始 -》 程序 -》 管理工具 -》 Internet服务管理器 -》 主目录 勾选“写入” 即可

    5,检查是否ADODB.Stream组件禁用
        重新开启ADODB.Stream组件的办法:开始 -》 运行 -》
        regsvr32 "C:Program FilesCommon FilesSystemadomsado15.dll

    6 , 本网站使用thinkphp内核,检查是否Dom问题,摘抄thinkphp官网论坛中ijisong的代码

    <?php
    if (isset($_GET['dir'])){ //设置文件目录
    $basedir=$_GET['dir'];
    }else{
    $basedir = '.';
    }
    $auto = 1;
    checkdir($basedir);
    function checkdir($basedir){
    if ($dh = opendir($basedir)) {
    while (($file = readdir($dh)) !== false) {
    if ($file != '.' && $file != '..'){
    if (!is_dir($basedir."/".$file)) {
    echo "filename: $basedir/$file ".checkBOM("$basedir/$file")." <br>";
    }else{
    $dirname = $basedir."/".$file;
    checkdir($dirname);
    }
    }
    }
    closedir($dh);
    }
    }
    function checkBOM ($filename) {
    global $auto;
    $contents = file_get_contents($filename);
    $charset[1] = substr($contents, 0, 1);
    $charset[2] = substr($contents, 1, 1);
    $charset[3] = substr($contents, 2, 1);
    if (ord($charset[1]) == 239 && ord($charset[2]) == 187 && ord($charset[3]) == 191) {
    if ($auto == 1) {
    $rest = substr($contents, 3);
    rewrite ($filename, $rest);
    return ("<font color=red>BOM found, automatically removed.</font>");
    } else {
    return ("<font color=red>BOM found.</font>");
    }
    }
    else return ("BOM Not Found.");
    }
    function rewrite ($filename, $data) {
    $filenum = fopen($filename, "w");
    flock($filenum, LOCK_EX);
    fwrite($filenum, $data);
    fclose($filenum);
    }
    ?>

    7,还在测试中。。。

  • 相关阅读:
    asp.net textbox 控件如何清除缓存
    extjs Accordion 怎样把展开符号:加号(+)放在左边?
    ORACLE 调试输出,字符串执行函数
    Oracle中table函数的应用
    Oracle LAST_DAY(d)
    Oracle 管道化表函数(Pipelined Table)[转载]
    ext中fieldLabel文本太宽的问题,以及Panel居中显示
    什么是泛型(C#)
    设置Ext tab的宽度自动适应
    js选择日期即时把两个日期相差天数显示出来?
  • 原文地址:https://www.cnblogs.com/sxiangyues/p/6512772.html
Copyright © 2011-2022 走看看