nginx&laravel:内部重定向到“/index.php”时重写或内部重定向循环

I am trying to upload my laravel app to my Digital Ocean droplet.

I followed this tutorial and now I am getting 500 server error.

here is my nginx error.log:

2016/11/22 02:21:30 [error] 7733#7733: *1 rewrite or internal redirection cycle while internally redirecting to "/index.php", client: 198.7.58.98, server: antique.samiemad.me, request: "GET / HTTP/1.1", host: "antique.samiemad.me"
2016/11/22 02:25:05 [error] 7733#7733: *2 rewrite or internal redirection cycle while internally redirecting to "/index.php", client: 52.71.155.178, server: antique.samiemad.me, request: "GET /robots.txt HTTP/1.1", host: "antique.samiemad.me"
2016/11/22 02:25:05 [error] 7733#7733: *3 rewrite or internal redirection cycle while internally redirecting to "/index.php", client: 52.71.155.178, server: antique.samiemad.me, request: "GET /info.php HTTP/1.1", host: "antique.samiemad.me"
2016/11/22 02:30:53 [error] 7733#7733: *4 rewrite or internal redirection cycle while internally redirecting to "/index.php", client: 198.7.58.98, server: antique.samiemad.me, request: "GET / HTTP/1.1", host: "antique.samiemad.me"
2016/11/22 02:32:30 [error] 7733#7733: *5 rewrite or internal redirection cycle while internally redirecting to "/index.php", client: 52.71.155.178, server: antique.samiemad.me, request: "GET /info.php HTTP/1.1", host: "antique.samiemad.me"
2016/11/22 02:35:52 [error] 7733#7733: *13 rewrite or internal redirection cycle while internally redirecting to "/index.php", client: 188.227.78.184, server: antique.samiemad.me, request: "GET / HTTP/1.1", host: "antique.samiemad.me"
2016/11/22 02:35:52 [error] 7733#7733: *14 rewrite or internal redirection cycle while internally redirecting to "/index.php", client: 188.227.78.184, server: antique.samiemad.me, request: "GET /favicon.ico HTTP/1.1", host: "antique.samiemad.me", referrer: "http://antique.samiemad.me/"
2016/11/22 02:44:56 [error] 7733#7733: *15 rewrite or internal redirection cycle while internally redirecting to "/index.php", client: 198.7.58.98, server: antique.samiemad.me, request: "GET / HTTP/1.1", host: "antique.samiemad.me"
2016/11/22 02:57:59 [error] 7733#7733: *17 rewrite or internal redirection cycle while internally redirecting to "/index.php", client: 198.7.58.98, server: antique.samiemad.me, request: "GET / HTTP/1.1", host: "antique.samiemad.me"
2016/11/22 03:02:30 [error] 7733#7733: *18 rewrite or internal redirection cycle while internally redirecting to "/index.php", client: 198.7.58.98, server: antique.samiemad.me, request: "GET / HTTP/1.1", host: "antique.samiemad.me"

I searched around for this error and I think there must be something wrong with my 'sites-available' files. I tried to play around with some values there but I couldn't get it to work yet.

here are the current contents of my 'sites-available/antique.samiemad.me':

server {
    listen 80 ;
    listen [::]:80 ;

    root /var/www/antique.samiemad.me/public;
    index index.php index.html index.htm;

    server_name antique.samiemad.me;
    charset   utf-8;

    gzip on;
    gzip_vary on;
    gzip_disable "msie6";
    gzip_comp_level 6;
    gzip_min_length 1100;
    gzip_buffers 16 8k;
    gzip_proxied any;
    gzip_types
        text/plain
        text/css
        text/js
        text/xml
        text/javascript
        application/javascript
        application/x-javascript
        application/json
        application/xml
        application/xml+rss;

    location / {
        try_files \$uri \$uri/ /index.php?\$query_string;
    }

    location ~ \.php\$ {
        try_files \$uri /index.php =404; # tried to comment-out this line.. no luck :(
        fastcgi_split_path_info ^(.+\.php)(/.+)\$;
        fastcgi_pass unix:/run/php/php7.0-fpm.sock;
        fastcgi_index index.php;
        fastcgi_param SCRIPT_FILENAME \$document_root\$fastcgi_script_name;
        include fastcgi_params;
    }

    location ~* \.(?:jpg|jpeg|gif|png|ico|cur|gz|svg|svgz|mp4|ogg|ogv|webm|htc|svg|woff|woff2|ttf)\$ {
      expires 1M;
      access_log off;
      add_header Cache-Control "public";
    }

    location ~* \.(?:css|js)\$ {
      expires 7d;
      access_log off;
      add_header Cache-Control "public";
    }

    location ~ /\.ht {
        deny  all;
    }

}

I think maybe the problem is in one of the try_files commands? I tried to comment-out the line pointed out in the code but I still have the same error. So it must be something else causing this.

1个回答



原来问题是我在'$'符号前有'\'.. </ p>

< p>我删除了它们,它就像一个魅力。</ p>

我将联系教程作者来纠正他的代码。</ p>
</ div>

展开原文

原文

Turns out the problem was that I had '\' before some '$' signs..

I removed them and it worked like a charm.

I will contact the tutorial author to correct his code.

dongquming3255
dongquming3255 我有一个类似的问题,虽然我的不一样(我有try_files $ uri $ uri / /index.php?$args;,但我仍然得到这个讨厌的循环!)。 另外,很高兴看到该文章的作者仍然没有修复它=)
大约 3 年之前 回复
Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
其他相关推荐
nginx 重定向跳转 http://xxxxx.xxx.com/aa/bbbb/cccc/dddd.htm到http://xxxxx.xxx.com/ee/

当访问 http://xxxxx.xxx.com/aa/bbbb/cccc/dddd.htm 时重定向到http://xxxxx.xxx.com/ee/ 其中原nginx配置 server { listen 80; server_name xxxxx.xxx.com; access_log /applogs/xxx.access.log main; error_log /applogs/xxx.test.error.log; root html; index index.html index.htm; location / { proxy_pass http://192.168.0.1; } } 请写清楚配置添加到什么位置

简单的nginx重定向.php到主页

<div class="post-text" itemprop="text"> <p>My old website had urls like:</p> <p>domain.com/search.php?query=query<br> domain.com/product.php?id=id</p> <p>I need to redirect requests to these files (and only these files) to:</p> <p>domain.com</p> <p>I'm using the Laravel framework that uses a single index.php file.</p> <p>I've tried:</p> <p>-Placing files named "search.php" and "product.php" in my root directory that redirects the user.</p> <p>-Adding to Nginx conf:</p> <pre><code>location /search.php { return 301 http://domain.com; ) </code></pre> </div>

无法连接到ssl://smtp.gmail.com:465名称或服务未知(0)

<div class="post-text" itemprop="text"> <p>I have some strange problem here, socket connection to smtp.gmail.com fails when I try to execute script on site with <code>Warning: stream_socket_client(): unable to connect to ssl://smtp.gmail.com:465 (php_network_getaddresses: getaddrinfo failed: Name or service not known) in /var/www/test/test.php on line 2 php_network_getaddresses: getaddrinfo failed: Name or service not known (0)</code> , but work fine if i run it in shell like <code>php test.php</code>, telnet works fine too and openssl connection as well, but web script just fail. I looked a lot of similar issues and didn't found an answer for that, any suggestions? I run nginx + php-fpm if, openssl enabled</p> <p>UPD: here is my test script:</p> <pre><code>$fp = fsockopen("ssl://smtp.gmail.com", 465, $errno, $errstr, 10); if (!$fp) { echo "$errstr ($errno)&lt;br /&gt; "; } else { echo "opened"; } </code></pre> </div>

安装nginx,添加它为系统服务,nano /etc/init.d/nginx添加的配置代码看不懂

#!/bin/sh # # nginx - this script starts and stops the nginx daemon # # chkconfig: - 85 15 # description: Nginx is an HTTP(S) server, HTTP(S) reverse \ # proxy and IMAP/POP3 proxy server # processname: nginx # config: /data/nginx/nginx.conf # config: /etc/sysconfig/nginx # pidfile: /var/run/nginx.pid # Source function library. . /etc/rc.d/init.d/functions # Source networking configuration. . /etc/sysconfig/network # Check that networking is up. [ "$NETWORKING" = "no" ] && exit 0 nginx="/data/nginx/sbin/nginx" prog=$(basename $nginx) NGINX_CONF_FILE="/data/nginx/conf/nginx.conf" [ -f /etc/sysconfig/nginx ] && . /etc/sysconfig/nginx lockfile=/var/lock/subsys/nginx start() { [ -x $nginx ] || exit 5 [ -f $NGINX_CONF_FILE ] || exit 6 echo -n $"Starting $prog: " daemon $nginx -c $NGINX_CONF_FILE retval=$? echo [ $retval -eq 0 ] && touch $lockfile return $retval } stop() { echo -n $"Stopping $prog: " killproc $prog -QUIT retval=$? echo [ $retval -eq 0 ] && rm -f $lockfile return $retval killall -9 nginx } restart() { configtest || return $? stop sleep 1 start } reload() { configtest || return $? echo -n $"Reloading $prog: " killproc $nginx -HUP RETVAL=$? echo } force_reload() { restart } configtest() { $nginx -t -c $NGINX_CONF_FILE } rh_status() { status $prog } rh_status_q() { rh_status >/dev/null 2>&1 } case "$1" in start) rh_status_q && exit 0 $1 ;; stop) rh_status_q || exit 0 $1 ;; restart|configtest) $1 ;; reload) rh_status_q || exit 7 $1 ;; force-reload) force_reload ;; status) rh_status ;; condrestart|try-restart) rh_status_q || exit 0 ;; *) echo $"Usage: $0 {start|stop|status|restart|condrestart|try-restart|reload|force-reload|configtest}" exit 2 esac 请有空的大神指导下几个主要步骤的作用(详细的当然更好),先谢过啦!本人是纯新手,只知道一点简单命令,对着文档知其然而不知其所以然,真心很苦恼。。。。。。

使用PHP模拟“假”目录,不使用.htaccess,mod_rewrite或404重定向

<div class="post-text" itemprop="text"> <h2>Situation</h2> <p>Hello, I'm confused as to PHP's expected/default behavior regarding extensionless PHP files, and/or URL requests that "go past" the actual file that (I want to) processes the request (i.e., PHP's default "fallback" actions before it resorts to completely 404-ing). Here's my situation:</p> <p>My directory structure on my local server (running nginx 1.5.3 with very basic PHP 5.5.1 setup) looks like the following:</p> <pre><code>/index /index.php /other /other.php /rootdir/index /rootdir/index.php /rootdir/other /rootdir/other.php </code></pre> <p>The contents of all eight files are the same:</p> <pre><code>&lt;?php echo $_SERVER['PHP_SELF'] . ', ' . $_SERVER['REQUEST_URI']; ?&gt; </code></pre> <p>BUT, hitting the respective endpoint produces some strange (to me) results.</p> <h2>Research</h2> <pre><code>GET /index.php '/index.php, /index.php' # Makes sense... GET /index.php/something_else '/index.php, /index.php/something_else' # Also makes sense... GET /index/something_else '/index.php, /index/something_else' # Let's call this ANOMALY 1... (see below) GET /something_else '/index.php, /something_else' # ANOMALY 2 GET /other.php '/other.php, /other.php' # Expected... GET /other.php/something_else '/index.php, /other.php/something_else' # ANOMALY 3 GET /rootdir/index.php '/rootdir/index.php, /rootdir/index.php' # Expected... GET /rootdir/index.php/something_else '/index.php, /rootdir/index.php/something_else' # ANOMALY 4 GET /rootdir/other.php '/rootdir/other.php, /rootdir/other.php' # Expected... GET /rootdir/other.php/something_else '/index.php, /rootdir/other.php/something_else' # ANOMALY 5 </code></pre> <p>My understanding is that the server redirects to <code>/index.php</code> when it is unable to find what the user is looking for at the request URI; that much makes sense... <strong>what I don't understand</strong> is:</p> <ol> <li>Why it will do this <em>despite</em> my not having a dedicated 404 page set up (I didn't tell it to try <code>/index.php</code> before 404-ing; I <em>want</em> it to display a legit, non-custom 404 page if something isn't found and/or can't be processed. I figured it should display the default server 404 page when it couldn't find something... apparently that's not always the case...?)</li> <li>Why it doesn't try <code>/rootdir/index.php</code> when it can't find something within the <code>/rootdir/</code> subdirectory.</li> </ol> <h2>Questions</h2> <ol> <li><p>Would somebody be able to shed some light on what PHP's logic is (or maybe it's nginx's doing; I haven't been able to figure that out yet) with regards to addresses that are not found? Why am I seeing what I am seeing? (Specifically with respect to Anomalies #4 and #5. I expected it to use <code>/rootdir/index.php</code> for handling it's "404," <strong><em>or</em></strong> I expected a real 404 page; the fallback to <code>/index.php</code> was unexpected.)</p></li> <li><p>As a direct corollary (corollical?) question, <strong>how can I go about simulating extensionless PHP files that will handle hits that occur "below" them</strong> (e.g. in the Anomaly #1 case; that's actually exactly what I want, though it wasn't quite what I expected) <strong><em>without</em></strong> relying on <code>.htaccess</code>, mod_rewriting, or redirects? Or is that a silly question? :-)</p></li> </ol> <h2>References</h2> <p>I'm trying to roll out a custom implementation for handling requests like <code>/some_dir/index.php/fake_subdir</code> and <code>/some_other_dir/index.php/fake_subdir</code> (i.e., different "fallback handlers") without relying on Apache, but the logic behind PHP's (or nginx's?) default fallback behavior is eluding me. These pages are primarily where this question stems from:</p> <ul> <li><a href="https://stackoverflow.com/questions/975262/pretty-urls-without-mod-rewrite-without-htaccess">Pretty URLs without mod_rewrite, without .htaccess</a></li> <li><a href="https://stackoverflow.com/a/975343/2420847">https://stackoverflow.com/a/975343/2420847</a></li> </ul> </div>

Nginx如何直接访问index.php时返回404

<div class="post-text" itemprop="text"> <p>For security purpose, I am attempting to hide almost all the fingerprint info of my web application. The most important thing is to hide <code>PHP</code> from any visitors. So I try to modify my <code>Nginx</code>'s configuration file. The configuration will show as follows.</p> <pre><code>location / { root /data/site/public; index index.html index.htm index.php; try_files $uri /index.php; location /index.php { fastcgi_pass unix:/var/run/php5-fpm.sock; include fastcgi.conf; } } </code></pre> <p>By this way, I successfully hide <code>index.php</code> from URL. However, Hackers could also directly access my website by using some URL such as <code>http://example.com/index.php</code>, which shows that my website is written by <code>PHP</code>. Sometimes it maybe dangerous. So, I modify the <code>Nginx</code>'s config second time, longing for <code>404</code> when access <code>index.php</code> directly, and it looks like</p> <pre><code>location / { root /data/site/public; if ( $request_uri ~ /index\.php ) { return 404; } index index.html index.htm index.php; try_files $uri /index.php; location /index.php { fastcgi_pass unix:/var/run/php5-fpm.sock; include fastcgi.conf; } } </code></pre> <p>However..., it seems that <code>Nginx</code> acts nothing different from the previous one.</p> <p>Could anyone tell me the reason ? or any other solutions...</p> </div>

curl命令无法从api.github获取内容,但网络没问题

<div class="post-text" itemprop="text"> <p>I was trying use command <code>composer create-project laravel/laravel Laravel</code>, to create a new laravel project.</p> <p>But I got this in the terminal:</p> <pre><code>Failed to download jakub-onderka/php-console-color from dist: The "https://api.github.com/repos/JakubOnderka/PHP-Console-Color/zipball/e0b393dacf7703fc36a4efc3df1435485197e6c1" file could not be downloaded: failed to open stream: Connection timed out Now trying to download from source </code></pre> <p>Then, I tried this command:</p> <pre><code>curl https://api.github.com/repos/JakubOnderka/PHP-Console-Color/zipball/e0b393dacf7703fc36a4efc3df1435485197e6c1 </code></pre> <p>It cannot work.</p> <p>However, when I entered the address in the browser(FireFox), It works!</p> <p>What's wrong with that? Have suffered from this couple of days.</p> </div>

简单的Docker / Nginx错误 - PHP / Laravel

<div class="post-text" itemprop="text"> <p>I'm building a PHP and Laravel docker multi-container application by following <a href="https://medium.com/@shakyShane/laravel-docker-part-1-setup-for-development-e3daaefaf3c" rel="nofollow noreferrer">this tutorial</a>.</p> <p>It's straight forward and I followed it accurately but I'm running into the following error when running <code>docker-compose up</code>:</p> <pre><code>database_1 | 2018-07-08 16:51:11 1 [Note] mysqld: ready for connections. database_1 | Version: '5.6.40' socket: '/var/run/mysqld/mysqld.sock' port: 3306 MySQL Community Server (GPL) app_1 | [08-Jul-2018 15:02:52] NOTICE: fpm is running, pid 1 app_1 | [08-Jul-2018 16:51:10] NOTICE: ready to handle connections web_1 | 2018/07/08 16:52:24 [emerg] 1#1: unknown directive "listen:" in /etc/nginx/conf.d/default.conf:2 web_1 | nginx: [emerg] unknown directive "listen:" in /etc/nginx/conf.d/default.conf:2 see-number_web_1 exited with code 1 </code></pre> <p>The following is my <code>web.dockerfile</code> that handles the web/nginx service:</p> <pre><code>FROM nginx:1.10 ADD vhost.conf /etc/nginx/conf.d/default.conf </code></pre> <p>And this is the <code>vhost.conf</code> file which I'm using: </p> <pre><code>server { listen 80; index index.php index.html; root /var/www/public; location / { try_files $uri /index.php?$args; } location ~ \.php$ { fastcgi_split_path_info ^(.+\.php)(/.+)$; fastcgi_pass app:9000; fastcgi_index index.php; include fastcgi_params; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; fastcgi_param PATH_INFO $fastcgi_path_info; } } </code></pre> <hr> <p>Here's the entire <code>docker-compose.yml</code> file holding it all together:</p> <pre><code>version: '2' services: # The Application app: build: context: ./ dockerfile: app.dockerfile working_dir: /var/www volumes: - ./:/var/www environment: - "DB_PORT=3306" - "DB_HOST=database" # The Web Server web: build: context: ./ dockerfile: web.dockerfile working_dir: /var/www volumes_from: - app ports: - 8080:80 # The Database database: image: mysql:5.6 volumes: - dbdata:/var/lib/mysql environment: - "MYSQL_DATABASE=homestead" - "MYSQL_USER=homestead" - "MYSQL_PASSWORD=secret" - "MYSQL_ROOT_PASSWORD=secret" ports: - "33061:3306" volumes: dbdata: </code></pre> <hr> <p>I found <a href="https://stackoverflow.com/a/21960803/6365534">this StackOverflow answer</a> that talks about hidden EOL characters but I've tried typing it out myself, and running it through <a href="https://www.textfixer.com/tools/remove-line-breaks.php" rel="nofollow noreferrer">this tool</a> in the same thread. </p> <p>Any suggestions as to why I might be getting this error?</p> <hr> <p><strong>Update 1</strong><br> As requested, I'm including the <code>docker history</code> for the web service image that's causing issues:</p> <pre><code>&lt;user&gt;:&lt;project&gt; &lt;user&gt;$ docker history see-number_web IMAGE CREATED CREATED BY SIZE COMMENT 5c0285cb9dd2 6 hours ago /bin/sh -c #(nop) ADD file:4387275b028088cf9… 453B 0346349a1a64 15 months ago /bin/sh -c #(nop) CMD ["nginx" "-g" "daemon… 0B &lt;missing&gt; 15 months ago /bin/sh -c #(nop) EXPOSE 443/tcp 80/tcp 0B &lt;missing&gt; 15 months ago /bin/sh -c ln -sf /dev/stdout /var/log/nginx… 22B &lt;missing&gt; 15 months ago /bin/sh -c apt-key adv --keyserver hkp://pgp… 58.2MB &lt;missing&gt; 15 months ago /bin/sh -c #(nop) ENV NGINX_VERSION=1.10.3-… 0B &lt;missing&gt; 15 months ago /bin/sh -c #(nop) MAINTAINER NGINX Docker M… 0B &lt;missing&gt; 15 months ago /bin/sh -c #(nop) CMD ["/bin/bash"] 0B &lt;missing&gt; 15 months ago /bin/sh -c #(nop) ADD file:4eedf861fb567fffb… 123MB </code></pre> </div>

Nginx Centos7 Laravel 5无法写入日志文件[关闭]

<div class="post-text" itemprop="text"> <p>I got a brand new Centos 7 server and would like to install laravel + nginx</p> <p>I added Remi repo for PHP5.6 Also added epel</p> <pre><code>yum update yum install nmap rsync nano wget curl yum install epel-release rpm -Uvh http://rpms.famillecollet.com/enterprise/remi-release-7.rpm nano /etc/yum.repos.d/remi.repo yum install nginx systemctl start nginx systemctl enable nginx sudo firewall-cmd --permanent --zone=public --add-service=http sudo firewall-cmd --permanent --zone=public --add-service=https sudo firewall-cmd --reload #PHP yum install php php-mysql php-fpm php-dom php-mcrypt php-mbstring nano /etc/php.ini cgi.fix_pathinfo=0 nano /etc/php-php.d/www.conf listen = /var/run/php-fpm/php-fpm.sock listen.owner = nobody listen.group = nobody user = nginx group = nginx systemctl start php-fpm systemctl enable php-fpm </code></pre> <p>The NGINX server is working, and phpinfo(); is looking good too.</p> <p>inside /etc/nginx/nginx.conf:</p> <pre><code># For more information on configuration, see: # * Official English Documentation: http://nginx.org/en/docs/ # * Official Russian Documentation: http://nginx.org/ru/docs/ user nginx; worker_processes auto; error_log /var/log/nginx/error.log; pid /run/nginx.pid; events { worker_connections 1024; } http { log_format main '$remote_addr - $remote_user [$time_local] "$request" ' '$status $body_bytes_sent "$http_referer" ' '"$http_user_agent" "$http_x_forwarded_for"'; access_log /var/log/nginx/access.log main; sendfile on; tcp_nopush on; tcp_nodelay on; keepalive_timeout 65; types_hash_max_size 2048; include /etc/nginx/mime.types; default_type application/octet-stream; # Load modular configuration files from the /etc/nginx/conf.d directory. # See http://nginx.org/en/docs/ngx_core_module.html#include # for more information. include /etc/nginx/conf.d/*.conf; server { listen 80 default_server; listen [::]:80 default_server; server_name _; #root /usr/share/nginx/html; root /usr/share/nginx/html/lv/public; index index.php index.html index.htm # Load configuration files for the default server block. include /etc/nginx/default.d/*.conf; location / { try_files $uri $uri/ /index.php$is_args$args; } location ~ \.php$ { try_files $uri /index.php =404; fastcgi_pass unix:/var/run/php-fpm/php-fpm.sock; fastcgi_index index.php; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; include fastcgi_params; } error_page 404 /404.html; location = /40x.html { } error_page 500 502 503 504 /50x.html; location = /50x.html { } } } </code></pre> <p>Inside /usr/share/nginx/html/lv I have installed alaravel 5 project via git.</p> <pre><code>[root@213 lv]# ls -la total 164 drwxr-xr-x. 11 nginx nginx 4096 Jan 28 02:19 . drwxr-xr-x. 3 root root 4096 Jan 28 02:17 .. drwxrwxr-x. 15 nginx nginx 4096 Oct 21 10:44 app -rw-rw-r--. 1 nginx nginx 1635 Aug 19 08:57 artisan drwxrwxr-x. 2 nginx nginx 39 Nov 28 01:22 bootstrap -rw-rw-r--. 1 nginx nginx 1007 Aug 19 08:57 composer.json -rw-rw-r--. 1 nginx nginx 107281 Aug 19 08:57 composer.lock drwxrwxr-x. 2 nginx nginx 4096 Aug 19 08:57 config drwxrwxr-x. 4 nginx nginx 52 Aug 19 08:57 database -rw-rw-r--. 1 nginx nginx 503 Aug 19 08:57 gulpfile.js -rw-rw-r--. 1 nginx nginx 79 Aug 19 08:57 package.json -rw-rw-r--. 1 nginx nginx 87 Aug 19 08:57 phpspec.yml -rw-rw-r--. 1 nginx nginx 729 Aug 19 08:57 phpunit.xml drwxrwxr-x. 4 nginx nginx 4096 Nov 28 01:03 public -rw-rw-r--. 1 nginx nginx 1724 Aug 19 08:57 readme.md drwxrwxr-x. 5 nginx nginx 42 Aug 19 08:57 resources -rw-rw-r--. 1 nginx nginx 561 Aug 19 08:57 server.php drwxrwxrwx. 6 nginx nginx 76 Aug 19 08:57 storage drwxrwxr-x. 2 nginx nginx 47 Aug 19 08:57 tests drwxrwxr-x. 29 nginx nginx 4096 Aug 19 08:57 vendor [root@213 lv]# cd storage [root@213 storage]# ls -la total 12 drwxrwxr-x. 6 nginx nginx 76 Aug 19 08:57 . drwxr-xr-x. 11 nginx nginx 4096 Jan 28 02:19 .. drwxrwxr-x. 2 nginx nginx 23 Aug 19 08:57 app drwxrwxr-x. 3 nginx nginx 21 Aug 19 08:57 documents drwxrwxr-x. 5 nginx nginx 62 Aug 19 08:57 framework -rwxrwxr-x. 1 nginx nginx 11 Aug 19 08:57 .gitignore drwxrwxrwx. 2 nginx nginx 4096 Jan 27 14:01 logs </code></pre> <p>logs is empty.</p> <p>I still get the following the error:</p> <pre><code>PHP message: PHP Fatal error: Uncaught exception 'UnexpectedValueException' with message 'The stream or file "/usr/share/nginx/html/lv/storage/logs/laravel-2016-01-28.log" could not be opened: failed to open stream: Permission denied' in /usr/share/nginx/html/lv/vendor/monolog/monolog/src/Monolog/Handler/StreamHandler.php:95 Stack trace: #0 /usr/share/nginx/html/lv/vendor/monolog/monolog/src/Monolog/Handler/RotatingFileHandler.php(88): Monolog\Handler\StreamHandler-&gt;write(Array) #1 /usr/share/nginx/html/lv/vendor/monolog/monolog/src/Monolog/Handler/AbstractProcessingHandler.php(37): Monolog\Handler\RotatingFileHandler-&gt;write(Array) #2 /usr/share/nginx/html/lv/vendor/monolog/monolog/src/Monolog/Logger.php(269): Monolog\Handler\AbstractProcessingHandler-&gt;handle(Array) #3 /usr/share/nginx/html/lv/vendor/monolog/monolog/src/Monolog/Logger.php(545): Monolog\Logger-&gt;addRecord(400, 'exception 'Symf...', Array) #4 /usr/share/nginx/html/lv/vendor/larav </code></pre> <p>So I ran whoami.php which has `echo shell_exec('whoami');' in it, and the user is nginx.</p> <p>So I don't get the problem</p> </div>

nginx无法重启 “/var/run/nginx/nginx.pid”failed

我第一次启动是可以成功访问的,之后我重启了电脑,再次启动的时候报错了 ![图片说明](https://img-ask.csdn.net/upload/201701/09/1483947199_123063.png) 我看网上说要用-c参数,我也试了,还是不行 ![图片说明](https://img-ask.csdn.net/upload/201701/09/1483947276_874597.png) 还有一个疑问是,我看别人的目录结构里都有logs这个文件,但我的找不到logs这个目录,只有conf,html ,sbin 三个文件夹 有没有知道怎么解决的帮下小弟,万分感谢。

Laravel Nginx重定向旧网址

<div class="post-text" itemprop="text"> <p>I have redeveloped a php site using the laravel framework. I now want to redirect the old urls like <code>/products.php?id_categ=1&amp;id_brand=4&amp;id_products=5</code> to <code>/products/product_name</code></p> <p>I have alreay made a route that will accept any url with product.php <code>Route::get('products.php','ProductController@oldLinks');</code></p> <p>The function <code>oldLinks</code> in <code>ProductController</code> finds the product slug based on the id and displays the appropriate product.</p> <p>This all works in the local environment when I do <code>php artisan serve</code> but it will not work in the production server which uses nginx.</p> <p>How do I get about solving this issue?</p> <p>Here is the nginx conf</p> <pre><code>server { listen 80 default_server; listen [::]:80 default_server; # SSL configuration # # listen 443 ssl default_server; # listen [::]:443 ssl default_server; # # Note: You should disable gzip for SSL traffic. # See: https://bugs.debian.org/773332 # # Read up on ssl_ciphers to ensure a secure configuration. # See: https://bugs.debian.org/765782 # # Self signed certs generated by the ssl-cert package # Don't use them in a production server! # # include snippets/snakeoil.conf; root /var/www/laravel/public; # Add index.php to the list if you are using PHP index index.php index.html index.htm index.nginx-debian.html; server_name laravel.com www.laravel.com; location / { # First attempt to serve request as file, then # as directory, then fall back to displaying a 404. try_files $uri $uri/ /index.php?$query_string; } # pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000 # location ~ \.php$ { include snippets/fastcgi-php.conf; # # # With php7.0-cgi alone: # fastcgi_pass 127.0.0.1:9000; # With php7.0-fpm: fastcgi_pass unix:/run/php/php7.0-fpm.sock; } # deny access to .htaccess files, if Apache's document root # concurs with nginx's one # location ~ /\.ht { deny all; } </code></pre> <p>}</p> </div>

Linux下nginx配置问题;

nginx -t 然后下面出现这个问题: nginx: [emerg] a duplicate listen 0.0.0.0:443 in /etc/nginx/nginx.conf:43 nginx: configuration file /etc/nginx/nginx.conf test failed 这是我的nginx.conf文件; # For more information on configuration, see: # * Official English Documentation: http://nginx.org/en/docs/ # * Official Russian Documentation: http://nginx.org/ru/docs/ user root; worker_processes auto; error_log /var/log/nginx/error.log; pid /run/nginx.pid; # Load dynamic modules. See /usr/share/doc/nginx/README.dynamic. include /usr/share/nginx/modules/*.conf; events { worker_connections 1024; } http { log_format main '$remote_addr - $remote_user [$time_local] "$request" ' '$status $body_bytes_sent "$http_referer" ' '"$http_user_agent" "$http_x_forwarded_for"'; access_log /var/log/nginx/access.log main; sendfile on; tcp_nopush on; tcp_nodelay on; keepalive_timeout 65; types_hash_max_size 2048; include /etc/nginx/mime.types; default_type application/octet-stream; # Load modular configuration files from the /etc/nginx/conf.d directory. # See http://nginx.org/en/docs/ngx_core_module.html#include # for more information. include /etc/nginx/conf.d/*.conf; server { listen 443 default_server; listen [::]:443 default_server; server_name 192.168.80.30; root /usr/pajc/PAJC/Source/public; listen 443 ssl; ssl_certificate /etc/ssl/server.pem; ssl_certificate_key /etc/ssl/privkey.pem; # Load configuration files for the default server block. include /etc/nginx/default.d/*.conf; location / { } error_page 404 /404.html; location = /40x.html { } error_page 500 502 503 504 /50x.html; location = /50x.html { } } # Settings for a TLS enabled server. # # server { # listen 443 ssl http2 default_server; # listen [::]:443 ssl http2 default_server; 顺便问下有没有大佬能教下Linux搭建laravel项目教程。详细点的

Laravel on nginx显示403,但我的路径是正确的

<div class="post-text" itemprop="text"> <p>I have a digitalocean droplet and I want to run a laravel project. I used this tutorial <a href="https://www.digitalocean.com/community/tutorials/how-to-deploy-a-laravel-application-with-nginx-on-ubuntu-16-04" rel="nofollow noreferrer">https://www.digitalocean.com/community/tutorials/how-to-deploy-a-laravel-application-with-nginx-on-ubuntu-16-04</a></p> <p>The thing is that it displays a 403. I saw on other questions that they missed the public directory or they had the path wrong, but in my case I got a 403 when I have the public dir correct, and a 500 when I have it wrong.</p> <p>My nginx error log says</p> <pre><code>2017/09/29 13:58:16 [error] 15176#15176: *2 directory index of "/var/www/laravel/public/" is forbidden </code></pre> <p>My nginx sites-available/my-site.com</p> <pre><code>server { listen 80; listen [::]:80; # SSL configuration # # listen 443 ssl default_server; # listen [::]:443 ssl default_server; # # Note: You should disable gzip for SSL traffic. # See: https://bugs.debian.org/773332 # # Read up on ssl_ciphers to ensure a secure configuration. # See: https://bugs.debian.org/765782 # # Self signed certs generated by the ssl-cert package # Don't use them in a production server! # # include snippets/snakeoil.conf; root /var/www/laravel/public; # Add index.php to the list if you are using PHP index index.html index.htm index.nginx-debian.html; server_name my-site.com www.my-site.com; location / { # First attempt to serve request as file, then # as directory, then fall back to displaying a 404. try_files $uri $uri/ /index.php?$query_string; } </code></pre> </div>

nginx下部署默认laravel返回404

# 问题描述 laravel项目在Apache下能正常访问,nginx下反向代理Apache服务器做php处理就返回404, 应该是index.php中执行错误,是权限问题吗? https://laravel.lscsfs.cn/ 返回404 https://laravel.lscsfs.cn/host.php 和 https://laravel.lscsfs.cn/info.php 正常 #apache errorlog [Wed Jul 03 16:09:02.523181 2019] [:error] [pid 3342] [client 127.0.0.1:58666] script '/var/www/html/index.php' not found or unable to stat 为什么Apache会去找html下的index.php? ### 相关代码 #nginx的conf server { listen 443; server_name laravel.lscsfs.cn; root /var/www/laravel/public; index index.html index.php; ssl on; ssl_certificate ssl/laravel.lscsfs.cn/1_laravel.lscsfs.cn_bundle.crt; ssl_certificate_key ssl/laravel.lscsfs.cn/2_laravel.lscsfs.cn.key; ssl_session_cache shared:SSL:1m; ssl_session_timeout 5m; ssl_ciphers HIGH:!aNULL:ECDHE-RSA-AES128-GCM-SHA256:HIGH:!aNULL:!MD5:!RC4:!DHE; ssl_prefer_server_ciphers on; #Load configuration files for the default server block. include /etc/nginx/default.d/*.conf; location / { try_files $uri $uri/ /index.php?$query_string; } location ~ \.php$ { proxy_pass http://localhost:8080; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header X-Request-URI $request_uri; proxy_connect_timeout 30; proxy_send_timeout 30; proxy_read_timeout 30; client_max_body_size 10m; client_body_buffer_size 128k; proxy_buffer_size 4k; proxy_buffers 4 32k; proxy_busy_buffers_size 64k; proxy_temp_file_write_size 64k; } error_page 404 /404.html; location = /40x.html { } error_page 500 502 503 504 /50x.html; location = /50x.html { }

nginx: [emerg] unknown directive "ngx_fastdfs_module" in /usr/local/nginx/conf/nginx.conf:50

安装fastdfs 整合 nginx ; nginx: [emerg] unknown directive "ngx_fastdfs_module" in /usr/local/nginx/conf/nginx.conf:50![图片说明](https://img-ask.csdn.net/upload/201905/22/1558504219_473998.png) 请问这种情况怎么解决

win8用nginx怎么设置http://127.0.0.1/images图片服务器

win8用nginx怎么设置http://127.0.0.1/images图片服务器

nginx1.6 rewrite正则表达式 如何更改

我自己写了一个正则 rewrite /music_content/([0-9]+).html$ /music_content.do?articleID=$1 last; 就是说music_content下的目录任意数字的html 都重写为 music_content.do?articleID=数字 比如: http://www.XXX.com.cn/music_content/521.html 则重写为http://www.XXX.com.cn/music_content.do?articeID=521 可是发现了一个问题 如果网站为 http://XXX.com.cn/music_content/521.html 时(去掉www) 点开时 nginx提示没有当前页 然后我就把Url更改成正常的do 就是:http://XXX.com.cn/music_content.do?articeID=521时 页面也可正常显示 为什么会出现这样的问题,应该如何解决

nginx1.17.4中编译openssl报错

nginx1.17.4中编译openssl报错 file included from /usr/include/openssl/ssl.h:149:0, from src/event/ngx_event_openssl.h:15, from src/core/ngx_core.h:83, from src/core/nginx.c:9: /usr/include/openssl/comp.h:36:5: 错误:未知的类型名‘COMP_METHOD’ COMP_METHOD *meth; ^ /usr/include/openssl/comp.h:44:24: 错误:未知的类型名‘COMP_METHOD’ COMP_CTX *COMP_CTX_new(COMP_METHOD *meth); ^ /usr/include/openssl/comp.h:50:1: 错误:未知的类型名‘COMP_METHOD’ COMP_METHOD *COMP_rle(void); ^ /usr/include/openssl/comp.h:51:1: 错误:未知的类型名‘COMP_METHOD’ COMP_METHOD *COMP_zlib(void); ^ In file included from src/event/ngx_event_openssl.h:15:0, from src/core/ngx_core.h:83, from src/core/nginx.c:9: /usr/include/openssl/ssl.h:879:5: 错误:未知的类型名‘COMP_METHOD’ COMP_METHOD *method; ^ In file included from /usr/include/openssl/ssl.h:1655:0, from src/event/ngx_event_openssl.h:15, from src/core/ngx_core.h:83, from src/core/nginx.c:9: /usr/include/openssl/dtls1.h:257:35: 错误:字段‘recordinfo’的类型不完全 struct bio_dgram_sctp_rcvinfo recordinfo; ^ In file included from src/event/ngx_event_openssl.h:15:0, from src/core/ngx_core.h:83, from src/core/nginx.c:9: /usr/include/openssl/ssl.h:2468:1: 错误:未知的类型名‘COMP_METHOD’ const COMP_METHOD *SSL_get_current_compression(SSL *s); ^ /usr/include/openssl/ssl.h:2469:1: 错误:未知的类型名‘COMP_METHOD’ const COMP_METHOD *SSL_get_current_expansion(SSL *s); ^ /usr/include/openssl/ssl.h:2470:1: 错误:未知的类型名‘COMP_METHOD’ const char *SSL_COMP_get_name(const COMP_METHOD *comp); ^ /usr/include/openssl/ssl.h:2475:45: 错误:未知的类型名‘COMP_METHOD’ int SSL_COMP_add_compression_method(int id, COMP_METHOD *cm);

ubuntu安装nginx进行到进入nginx-1.8.1的目录执行sudo ./make的时候报错:sudo: ./make:找不到命令

环境:ubuntu虚拟机16.04 问题:在网上找了一个FASTDFS的安装教程,链接是https://blog.csdn.net/michael_xwb/article/details/90267890 前面几步进行得都没有问题,但是到了安装Nginx + fastdfs-nginx-module时出现了问题,行到进入nginx-1.8.1的目录执行sudo ./make的时候报错:sudo: ./make:找不到命令 ![图片说明](https://img-ask.csdn.net/upload/201910/12/1570845361_573257.png) 他文章里要求的前置组件 ``` sudo apt-get install zlib1g-dev sudo apt-get install libpcre3 libpcre3-dev sudo apt-get install openssl libssl-dev ``` 这些我都安装了,但是依然没有成功,后面的步骤我一直没进行,在nginx1.8.1下也找不到make文件 ![图片说明](https://img-ask.csdn.net/upload/201910/12/1570845687_926181.png) 后来我又试了试nginx1.12.1版本,也是同样的问题,依旧是找不到make命令。 请问一下有没有大手子知道是怎么回事的?万分感谢!

4小时玩转微信小程序——基础入门与微信支付实战

这是一个门针对零基础学员学习微信小程序开发的视频教学课程。课程采用腾讯官方文档作为教程的唯一技术资料来源。杜绝网络上质量良莠不齐的资料给学员学习带来的障碍。 视频课程按照开发工具的下载、安装、使用、程序结构、视图层、逻辑层、微信小程序等几个部分组织课程,详细讲解整个小程序的开发过程

Python可以这样学(第四季:数据分析与科学计算可视化)

董付国老师系列教材《Python程序设计(第2版)》(ISBN:9787302436515)、《Python可以这样学》(ISBN:9787302456469)配套视频,在教材基础上又增加了大量内容,通过实例讲解numpy、scipy、pandas、statistics、matplotlib等标准库和扩展库用法。

组成原理课程设计(实现机器数的真值还原等功能)

实现机器数的真值还原(定点小数)、定点小数的单符号位补码加减运算、定点小数的补码乘法运算和浮点数的加减运算。

javaWeb图书馆管理系统源码mysql版本

系统介绍 图书馆管理系统主要的目的是实现图书馆的信息化管理。图书馆的主要业务就是新书的借阅和归还,因此系统最核心的功能便是实现图书的借阅和归还。此外,还需要提供图书的信息查询、读者图书借阅情况的查询等

土豆浏览器

土豆浏览器可以用来看各种搞笑、电影、电视剧视频

Java面试题大全(2020版)

发现网上很多Java面试题都没有答案,所以花了很长时间搜集整理出来了这套Java面试题大全,希望对大家有帮助哈~ 本套Java面试题大全,全的不能再全,哈哈~ 一、Java 基础 1. JDK 和 JRE 有什么区别? JDK:Java Development Kit 的简称,java 开发工具包,提供了 java 的开发环境和运行环境。 JRE:Java Runtime Environ...

Java8零基础入门视频教程

这门课程基于主流的java8平台,由浅入深的详细讲解了java SE的开发技术,可以使java方向的入门学员,快速扎实的掌握java开发技术!

Java基础知识面试题(2020最新版)

文章目录Java概述何为编程什么是Javajdk1.5之后的三大版本JVM、JRE和JDK的关系什么是跨平台性?原理是什么Java语言有哪些特点什么是字节码?采用字节码的最大好处是什么什么是Java程序的主类?应用程序和小程序的主类有何不同?Java应用程序与小程序之间有那些差别?Java和C++的区别Oracle JDK 和 OpenJDK 的对比基础语法数据类型Java有哪些数据类型switc...

TTP229触摸代码以及触摸返回值处理

自己总结的ttp229触摸代码,触摸代码以及触摸按键处理

网络工程师小白入门--【思科CCNA、华为HCNA等网络工程师认证】

本课程适合CCNA或HCNA网络小白同志,高手请绕道,可以直接学习进价课程。通过本预科课程的学习,为学习网络工程师、思科CCNA、华为HCNA这些认证打下坚实的基础! 重要!思科认证2020年2月24日起,已启用新版认证和考试,包括题库都会更新,由于疫情原因,请关注官网和本地考点信息。题库网络上很容易下载到。

深度学习原理+项目实战+算法详解+主流框架(套餐)

深度学习系列课程从深度学习基础知识点开始讲解一步步进入神经网络的世界再到卷积和递归神经网络,详解各大经典网络架构。实战部分选择当下最火爆深度学习框架PyTorch与Tensorflow/Keras,全程实战演示框架核心使用与建模方法。项目实战部分选择计算机视觉与自然语言处理领域经典项目,从零开始详解算法原理,debug模式逐行代码解读。适合准备就业和转行的同学们加入学习! 建议按照下列课程顺序来进行学习 (1)掌握深度学习必备经典网络架构 (2)深度框架实战方法 (3)计算机视觉与自然语言处理项目实战。(按照课程排列顺序即可)

java jdk 8 帮助文档 中文 文档 chm 谷歌翻译

JDK1.8 API 中文谷歌翻译版 java帮助文档 JDK API java 帮助文档 谷歌翻译 JDK1.8 API 中文 谷歌翻译版 java帮助文档 Java最新帮助文档 本帮助文档是使用谷

Ubuntu18.04安装教程

Ubuntu18.04.1安装一、准备工作1.下载Ubuntu18.04.1 LTS2.制作U盘启动盘3.准备 Ubuntu18.04.1 的硬盘空间二、安装Ubuntu18.04.1三、安装后的一些工作1.安装输入法2.更换软件源四、双系统如何卸载Ubuntu18.04.1新的改变功能快捷键合理的创建标题,有助于目录的生成如何改变文本的样式插入链接与图片如何插入一段漂亮的代码片生成一个适合你的列...

快速排序---(面试碰到过好几次)

原理:    快速排序,说白了就是给基准数据找其正确索引位置的过程.    如下图所示,假设最开始的基准数据为数组第一个元素23,则首先用一个临时变量去存储基准数据,即tmp=23;然后分别从数组的两端扫描数组,设两个指示标志:low指向起始位置,high指向末尾.    首先从后半部分开始,如果扫描到的值大于基准数据就让high减1,如果发现有元素比该基准数据的值小(如上图中18&amp;lt...

手把手实现Java图书管理系统(附源码)

【超实用课程内容】 本课程演示的是一套基于Java的SSM框架实现的图书管理系统,主要针对计算机相关专业的正在做毕设的学生与需要项目实战练习的java人群。详细介绍了图书管理系统的实现,包括:环境搭建、系统业务、技术实现、项目运行、功能演示、系统扩展等,以通俗易懂的方式,手把手的带你从零开始运行本套图书管理系统,该项目附带全部源码可作为毕设使用。 【课程如何观看?】 PC端:https://edu.csdn.net/course/detail/27513 移动端:CSDN 学院APP(注意不是CSDN APP哦) 本课程为录播课,课程2年有效观看时长,大家可以抓紧时间学习后一起讨论哦~ 【学员专享增值服务】 源码开放 课件、课程案例代码完全开放给你,你可以根据所学知识,自行修改、优化 下载方式:电脑登录https://edu.csdn.net/course/detail/27513,点击右下方课程资料、代码、课件等打包下载

HTML期末大作业

这是我自己做的HTML期末大作业,花了很多时间,稍加修改就可以作为自己的作业了,而且也可以作为学习参考

Python数据挖掘简易入门

&nbsp; &nbsp; &nbsp; &nbsp; 本课程为Python数据挖掘方向的入门课程,课程主要以真实数据为基础,详细介绍数据挖掘入门的流程和使用Python实现pandas与numpy在数据挖掘方向的运用,并深入学习如何运用scikit-learn调用常用的数据挖掘算法解决数据挖掘问题,为进一步深入学习数据挖掘打下扎实的基础。

极简JAVA学习营第四期(报名以后加助教微信:eduxy-1)

想学好JAVA必须要报两万的培训班吗? Java大神勿入 如果你: 零基础想学JAVA却不知道从何入手 看了一堆书和视频却还是连JAVA的环境都搭建不起来 囊中羞涩面对两万起的JAVA培训班不忍直视 在职没有每天大块的时间专门学习JAVA 那么恭喜你找到组织了,在这里有: 1. 一群志同道合立志学好JAVA的同学一起学习讨论JAVA 2. 灵活机动的学习时间完成特定学习任务+每日编程实战练习 3. 热心助人的助教和讲师及时帮你解决问题,不按时完成作业小心助教老师的家访哦 上一张图看看前辈的感悟: &nbsp; &nbsp; 大家一定迫不及待想知道什么是极简JAVA学习营了吧,下面就来给大家说道说道: 什么是极简JAVA学习营? 1. 针对Java小白或者初级Java学习者; 2. 利用9天时间,每天1个小时时间; 3.通过 每日作业 / 组队PK / 助教答疑 / 实战编程 / 项目答辩 / 社群讨论 / 趣味知识抢答等方式让学员爱上学习编程 , 最终实现能独立开发一个基于控制台的‘库存管理系统’ 的学习模式 极简JAVA学习营是怎么学习的? &nbsp; 如何报名? 只要购买了极简JAVA一:JAVA入门就算报名成功! &nbsp;本期为第四期极简JAVA学习营,我们来看看往期学员的学习状态: 作业看这里~ &nbsp; 助教的作业报告是不是很专业 不交作业打屁屁 助教答疑是不是很用心 &nbsp; 有奖抢答大家玩的很嗨啊 &nbsp; &nbsp; 项目答辩终于开始啦 &nbsp; 优秀者的获奖感言 &nbsp; 这是答辩项目的效果 &nbsp; &nbsp; 这么细致的服务,这么好的氛围,这样的学习效果,需要多少钱呢? 不要1999,不要199,不要99,只要9.9 是的你没听错,只要9.9以上所有就都属于你了 如果你: 1、&nbsp;想学JAVA没有基础 2、&nbsp;想学JAVA没有整块的时间 3、&nbsp;想学JAVA没有足够的预算 还等什么?赶紧报名吧,抓紧抢位,本期只招300人,错过只有等时间待定的下一期了 &nbsp; 报名请加小助手微信:eduxy-1 &nbsp; &nbsp;

C++语言基础视频教程

C++语言基础视频培训课程:本课与主讲者在大学开出的程序设计课程直接对接,准确把握知识点,注重教学视频与实践体系的结合,帮助初学者有效学习。本教程详细介绍C++语言中的封装、数据隐藏、继承、多态的实现等入门知识;主要包括类的声明、对象定义、构造函数和析构函数、运算符重载、继承和派生、多态性实现等。 课程需要有C语言程序设计的基础(可以利用本人开出的《C语言与程序设计》系列课学习)。学习者能够通过实践的方式,学会利用C++语言解决问题,具备进一步学习利用C++开发应用程序的基础。

UnityLicence

UnityLicence

软件测试2小时入门

本课程内容系统、全面、简洁、通俗易懂,通过2个多小时的介绍,让大家对软件测试有个系统的理解和认识,具备基本的软件测试理论基础。 主要内容分为5个部分: 1 软件测试概述,了解测试是什么、测试的对象、原则、流程、方法、模型;&nbsp; 2.常用的黑盒测试用例设计方法及示例演示;&nbsp; 3 常用白盒测试用例设计方法及示例演示;&nbsp; 4.自动化测试优缺点、使用范围及示例‘;&nbsp; 5.测试经验谈。

YOLOv3目标检测实战:训练自己的数据集

YOLOv3是一种基于深度学习的端到端实时目标检测方法,以速度快见长。本课程将手把手地教大家使用labelImg标注和使用YOLOv3训练自己的数据集。课程分为三个小项目:足球目标检测(单目标检测)、梅西目标检测(单目标检测)、足球和梅西同时目标检测(两目标检测)。 本课程的YOLOv3使用Darknet,在Ubuntu系统上做项目演示。包括:安装Darknet、给自己的数据集打标签、整理自己的数据集、修改配置文件、训练自己的数据集、测试训练出的网络模型、性能统计(mAP计算和画出PR曲线)和先验框聚类。 Darknet是使用C语言实现的轻型开源深度学习框架,依赖少,可移植性好,值得深入探究。 除本课程《YOLOv3目标检测实战:训练自己的数据集》外,本人推出了有关YOLOv3目标检测的系列课程,请持续关注该系列的其它课程视频,包括: 《YOLOv3目标检测实战:交通标志识别》 《YOLOv3目标检测:原理与源码解析》 《YOLOv3目标检测:网络模型改进方法》 敬请关注并选择学习!

Python数据分析师-实战系列

系列课程主要包括Python数据分析必备工具包,数据分析案例实战,核心算法实战与企业级数据分析与建模解决方案实战,建议大家按照系列课程阶段顺序进行学习。所有数据集均为企业收集的真实数据集,整体风格以实战为导向,通俗讲解Python数据分析核心技巧与实战解决方案。

YOLOv3目标检测实战系列课程

《YOLOv3目标检测实战系列课程》旨在帮助大家掌握YOLOv3目标检测的训练、原理、源码与网络模型改进方法。 本课程的YOLOv3使用原作darknet(c语言编写),在Ubuntu系统上做项目演示。 本系列课程包括三门课: (1)《YOLOv3目标检测实战:训练自己的数据集》 包括:安装darknet、给自己的数据集打标签、整理自己的数据集、修改配置文件、训练自己的数据集、测试训练出的网络模型、性能统计(mAP计算和画出PR曲线)和先验框聚类。 (2)《YOLOv3目标检测:原理与源码解析》讲解YOLOv1、YOLOv2、YOLOv3的原理、程序流程并解析各层的源码。 (3)《YOLOv3目标检测:网络模型改进方法》讲解YOLOv3的改进方法,包括改进1:不显示指定类别目标的方法 (增加功能) ;改进2:合并BN层到卷积层 (加快推理速度) ; 改进3:使用GIoU指标和损失函数 (提高检测精度) ;改进4:tiny YOLOv3 (简化网络模型)并介绍 AlexeyAB/darknet项目。

超详细MySQL安装及基本使用教程

一、下载MySQL 首先,去数据库的官网http://www.mysql.com下载MySQL。 点击进入后的首页如下:  然后点击downloads,community,选择MySQL Community Server。如下图:  滑到下面,找到Recommended Download,然后点击go to download page。如下图:  点击download进入下载页面选择No...

一学即懂的计算机视觉(第一季)

图像处理和计算机视觉的课程大家已经看过很多,但总有“听不透”,“用不了”的感觉。课程致力于创建人人都能听的懂的计算机视觉,通过生动、细腻的讲解配合实战演练,让学生真正学懂、用会。 【超实用课程内容】 课程内容分为三篇,包括视觉系统构成,图像处理基础,特征提取与描述,运动跟踪,位姿估计,三维重构等内容。课程理论与实战结合,注重教学内容的可视化和工程实践,为人工智能视觉研发及算法工程师等相关高薪职位就业打下坚实基础。 【课程如何观看?】 PC端:https://edu.csdn.net/course/detail/26281 移动端:CSDN 学院APP(注意不是CSDN APP哦) 本课程为录播课,课程2年有效观看时长,但是大家可以抓紧时间学习后一起讨论哦~ 【学员专享增值服务】 源码开放 课件、课程案例代码完全开放给你,你可以根据所学知识,自行修改、优化 下载方式:电脑登录https://edu.csdn.net/course/detail/26281,点击右下方课程资料、代码、课件等打包下载

董付国老师Python全栈学习优惠套餐

购买套餐的朋友可以关注微信公众号“Python小屋”,上传付款截图,然后领取董老师任意图书1本。

爬取妹子图片(简单入门)

安装第三方请求库 requests 被网站禁止了访问 原因是我们是Python过来的 重新给一段 可能还是存在用不了,使用网页的 编写代码 上面注意看匹配内容 User-Agent:请求对象 AppleWebKit:请求内核 Chrome浏览器 //请求网页 import requests import re //正则表达式 就是去不规则的网页里面提取有规律的信息 headers = { 'User-Agent':'存放浏览器里面的' } response = requests.get

web网页制作期末大作业

分享思维,改变世界. web网页制作,期末大作业. 所用技术:html css javascript 分享所学所得

技术大佬:我去,你写的 switch 语句也太老土了吧

昨天早上通过远程的方式 review 了两名新来同事的代码,大部分代码都写得很漂亮,严谨的同时注释也很到位,这令我非常满意。但当我看到他们当中有一个人写的 switch 语句时,还是忍不住破口大骂:“我擦,小王,你丫写的 switch 语句也太老土了吧!” 来看看小王写的代码吧,看完不要骂我装逼啊。 private static String createPlayer(PlayerTypes p...

相关热词 c#跨线程停止timer c#批量写入sql数据库 c# 自动安装浏览器 c#语言基础考试题 c# 偏移量打印是什么 c# 绘制曲线图 c#框体中的退出函数 c# 按钮透明背景 c# idl 混编出错 c#在位置0处没有任何行
立即提问