<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html><head><meta content="text/html; charset=utf-8" http-equiv="Content-Type"></head><div class="gmail_quote"><br>
sosogh <sosogh@126.com> a écrit :<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<div style="line-height:1.7;color:#000000;font-size:14px;font-family:arial"><DIV>HI list</DIV>
<DIV>I want to redirect <BR><A href="http://www.mysite.com/bbs/viewthread.php?tid=8123&extra">http://www.mysite.com/bbs/viewthread.php?tid=8123&extra</A>=<BR>to<BR><A href="http://www.mysite.com/forum.php?mod=viewthread&tid=8123">http://www.mysite.com/forum.php?mod=viewthread&tid=8123</A></DIV>
<DIV> </DIV>
<DIV>This is what I  place in the "server" block in the nginx.conf<BR>rewrite  ^/bbs/viewthread.php?tid=([0-9]+).*$   /forum.php?mod=viewthread&tid=$1 last;</DIV>
<DIV> </DIV>
<DIV>but when visit <A href="http://www.mysite.com/bbs/viewthread.php?tid=8123&extra">http://www.mysite.com/bbs/viewthread.php?tid=8123&extra</A>=.<BR>It shows 404 error.</DIV>
<DIV> </DIV>
<DIV>Could anyone point me out what is wrong?<BR>Thank you!<BR></DIV></div><br><br><span title="neteasefooter"><span id="netease_mail_footer"></span></span></blockquote></div><br clear="all">Take a look at your error log, it's write which file nginx can't find and you could see what's wrong with your regex.<br>
Regards,<br>
-- <br>
Envoyé de mon téléphone. Excusez la brièveté.</html>