我使用下面的命令在我的ubuntu服务器上安装了ImageMagick php库: apt-get install php5-gd php5-idn php-pear php5-imagick 我可以findphp.info文件中显示的ImageMagick模块,但是当我尝试在我的php程序中使用它的function时,它似乎不工作,甚至没有任何错误。 请帮助,我是一个新用户。 提前致谢
我想只允许访问我的index.php文件,并阻止所有其他的PHP文件。 但是,我的窗口框有什么作用,给我在Debian麻烦。 # Route all requests for non-existent files to index.php if (!-e $request_filename) { rewrite ^/(.*)$ /index.php/$1 last; } # Hide all PHP scripts location ~ \.php { rewrite ^/(.*)$ /index.php/$1 last; } # Forward index.php requests to php-fastcgi location ~ ^/index.php { include fastcgi_params; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; fastcgi_pass 127.0.0.1:9000; } 目标是确保一切都通过索引,所以没有人可以加载任何碰巧可以访问的PHP类。
当试图在Ubuntu 8.04上configurationPHP 5.3.3时,出现以下错误: checking for libevent >= 1.4.11 install prefix… configure: error: Could not find libevent >= 1.4.11 in /usr/local/ 我尝试安装libevent-dev和libevent1软件包,但同样的错误。 然后我删除了包,从源代码下载和编译libevent。 同样的错误。 findlibevent安装到/usr/local/lib/libevent.so与其所有朋友在/ usr / local / lib /中的显示。 我尝试使用以下选项进行configuration: –with-libevent-dir=/usr/local/lib/ 基本上同样的错误: checking for libevent >= 1.4.11 install prefix… configure: error: Could not find libevent >= 1.4.11 in /usr/local/lib/ 有什么build议么??
这个脚本工作完美,强制尾随斜线和隐藏.php扩展名 但! 它不会直接转到.php扩展名。 我怎么也强迫人们直接去file.php到/文件/ RewriteEngine On RewriteRule ^(.*)/$ /$1.php [L] RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_URI} !(.*)/$ RewriteRule ^(.*)$ http://www.mysite.com/$1/ [R=301,L]
我试图找出一种集中pipe理组织的员工分配名单的方法。 有很多人希望发送电子邮件到这些名单,我们目前都在维护我们自己的版本。 这是一个没有预算的创业慈善机构,所以我想知道是否有可用的东西可以运行在他们的networking服务器(cPanel)。 谷歌foo几个小时没有明显的变化。 谢谢!
我需要将网站迁移到其他主机。 我只有FTP服务器访问和MySQL名称+传递(我提供的MySQL服务器的IP是127.0.0.1,并没有PhpMyAdmin和SSHell使用)。 运行在那里的Web应用程序可以使用我认识的凭据和本地主机服务器来访问数据库。 所以我需要一个PHP脚本,它将正确转储MySQL服务器的所有可用数据库,以便它们可以在新服务器上导入。 你能推荐一个好的吗?
我使用webfaction的共享托pipe服务为我的python / php应用程序。 有一件事我不明白。 每次我安装一个新的PHP应用程序,都不会创build新的进程。 但是安装一个新的Python应用程序会在服务器上创build至less3个新进程。 为什么每个Python应用程序需要多个进程,而PHP应用程序却不需要? 编辑:python应用程序与Apache上的WSGI运行。
我为客户build立了一个表单,并意识到我在FROM字段中使用了一个无效的地址。 (501无效地址(回复MAIL FROM命令))。 有没有什么办法可以恢复这些提交给我的客户的电子邮件? 目前看来,postfix只是删除它们。 运行Debian。 想法?
在PHP中,我写了一个相对简单的邮件传递脚本。 这是实际交付部分: private function SendMail($to, $subj) { if(!$this->smtp) { $this->OpenSMTPSock(); } fwrite($this->smtp, "MAIL FROM:<[email protected]>\r\n"); fwrite($this->smtp, "RCPT TO:<$to>\r\n"); fwrite($this->smtp, "DATA\r\n"); fwrite($this->smtp, "Received: from email.com by domain.com ; ".date("r")."\r\n"); fwrite($this->smtp, "Date: ".date("r")."\r\n"); fwrite($this->smtp, "From: ".$this->message["display_name"]." <[email protected]>\r\n"); fwrite($this->smtp, "Reply-to: ".$this->message["reply"]."\r\n"); fwrite($this->smtp, "Subject: $subj\r\n"); fwrite($this->smtp, "To: $to\r\n"); if($this->message["type"] == "H") { fwrite($this->smtp, "content-type: text/html; charset=`iso-8859-1`"); fwrite($this->smtp, "\r\n".$this->m_html."\r\n"); } if($this->message["type"] […]
我有一个执行时间很长的脚本。 Apache正在使用php_mod。 我在浏览器中启动进程(打开url)。 我closures了浏览器,进程仍在运行。 如何findApache进程并停止它(Linux操作系统)