  | |  | mod_rewrite help | mod_rewrite help 2005-01-19 - By Jorge Schrauwen
No, still doesnt work, i still get a 404. I tried from .htaccess and httpd.conf, same result --- error.log --- [Wed Jan 19 20:34:10 2005] [error] [client 192.168.2.4] File does not exist: S:/wwwroot/imageview5/view thanx for the help though Jorge
_____
From: PMilanese@(protected) [mailto:PMilanese@(protected)] Sent: Wednesday, January 19, 2005 20:30 To: users@(protected); jorge@(protected) Subject: RE: [users@(protected)] Mod_rewrite help
That should do it, but. I don't know if absolutely necessary, however I put the entire URL in the Rewrite. -
RewriteRule ^/view/(.*)/(.*)$ http://www.blah.com/?album=$1$file=$2
Let me know if it helps-
P
_____
From: Jorge Schrauwen [mailto:jorge@(protected)] Sent: Wednesday, January 19, 2005 9:35 AM To: users@(protected) Subject: [users@(protected)] Mod_rewrite help
hi all,
I'm new to mod_rewrite and regex for that mather...
and i'm stuk. here is what i'm trying to do: i want to rewrite
/view/vacation/1.jpg
to
/index.php?album=vacation&file=1.jpg
this is what i have sofar:
---
RewriteEngine on RewriteRule ^/view/(.*)/(.*) /index.php?album=$1&file=$2
--
thanx in advance
Jorge Schrauwen
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <HTML xmlns="http://www.w3.org/TR/REC-html40" xmlns:v = "urn:schemas-microsoft-com:vml" xmlns:o = "urn:schemas-microsoft-com:office:office" xmlns:w = "urn:schemas-microsoft-com:office:word"><HEAD> <META http-equiv=Content-Type content="text/html; charset=us-ascii"> <META content="MSHTML 6.00.2900.2523" name=GENERATOR><!--[if !mso]> <STYLE>v\:* { BEHAVIOR: url(#default#VML) } o\:* { BEHAVIOR: url(#default#VML) } w\:* { BEHAVIOR: url(#default#VML) } .shape { BEHAVIOR: url(#default#VML) } </STYLE> <![endif]--> <STYLE>@(protected) { font-family: Tahoma; } @(protected) Section1 {size: 8.5in 11.0in; margin: 1.0in 1.25in 1.0in 1.25in; } P.MsoNormal { FONT-SIZE: 12pt; MARGIN: 0in 0in 0pt; FONT-FAMILY: "Times New Roman" } LI.MsoNormal { FONT-SIZE: 12pt; MARGIN: 0in 0in 0pt; FONT-FAMILY: "Times New Roman" } DIV.MsoNormal { FONT-SIZE: 12pt; MARGIN: 0in 0in 0pt; FONT-FAMILY: "Times New Roman" } A:link { COLOR: blue; TEXT-DECORATION: underline } SPAN.MsoHyperlink { COLOR: blue; TEXT-DECORATION: underline } A:visited { COLOR: purple; TEXT-DECORATION: underline } SPAN.MsoHyperlinkFollowed { COLOR: purple; TEXT-DECORATION: underline } SPAN.EmailStyle17 { COLOR: navy; FONT-FAMILY: Arial; mso-style-type: personal-reply } DIV.Section1 { page: Section1 } </STYLE> </HEAD> <BODY lang=EN-US vLink=purple link=blue> <DIV dir=ltr align=left><SPAN class=123213419-19012005><FONT face=Arial color=#0000ff size=2>No, still doesnt work, i still get a 404.</FONT></SPAN></DIV> <DIV dir=ltr align=left><SPAN class=123213419-19012005><FONT face=Arial color=#0000ff size=2></FONT></SPAN> </DIV> <DIV dir=ltr align=left><SPAN class=123213419-19012005><FONT face=Arial color=#0000ff size=2>I tried from .htaccess and httpd.conf, same result</FONT></SPAN></DIV> <DIV dir=ltr align=left><SPAN class=123213419-19012005><FONT face=Arial color=#0000ff size=2></FONT></SPAN> </DIV> <DIV dir=ltr align=left><SPAN class=123213419-19012005><FONT face=Arial color=#0000ff size=2>--- error.log ---</FONT></SPAN></DIV> <DIV dir=ltr align=left><SPAN class=123213419-19012005><FONT face=Arial color=#0000ff size=2>[Wed Jan 19 20:34:10 2005] [error] [client 192.168.2.4] File does not exist: S:/wwwroot/imageview5/view</FONT></SPAN></DIV> <DIV dir=ltr align=left><SPAN class=123213419-19012005><FONT face=Arial color=#0000ff size=2></FONT></SPAN> </DIV> <DIV dir=ltr align=left><SPAN class=123213419-19012005><FONT face=Arial color=#0000ff size=2>thanx for the help though</FONT></SPAN></DIV> <DIV dir=ltr align=left><SPAN class=123213419-19012005><FONT face=Arial color=#0000ff size=2></FONT></SPAN> </DIV> <DIV dir=ltr align=left><SPAN class=123213419-19012005><FONT face=Arial color=#0000ff size=2>Jorge</FONT></SPAN></DIV><BR> <DIV class=OutlookMessageHeader lang=en-us dir=ltr align=left> <HR tabIndex=-1> <FONT face=Tahoma size=2><B>From:</B> PMilanese@(protected) [mailto:PMilanese@(protected)] <BR><B>Sent:</B> Wednesday, January 19, 2005 20:30<BR><B>To:</B> users@(protected); jorge@(protected)<BR><B>Subject:</B > RE: [users@(protected)] Mod_rewrite help<BR></FONT><BR></DIV> <DIV></DIV> <DIV class=Section1> <P class=MsoNormal><FONT face=Arial color=navy size=2><SPAN style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: Arial">That should do it, but … I don’t know if absolutely necessary, however I put the entire URL in the Rewrite. –<o:p></o:p></SPAN></FONT></P> <P class=MsoNormal><FONT face=Arial color=navy size=2><SPAN style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: Arial"><o:p> </o:p>< /SPAN></FONT></P> <P class=MsoNormal><FONT face=Arial color=navy size=2><SPAN style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: Arial">RewriteRule ^/view/(.*)/(.*)$ <A href="http://www.blah.com/?album=$1$file=$2">http://www.blah.com/?album=$1$file =$2</A><o:p></o:p></SPAN></FONT></P> <P class=MsoNormal><FONT face=Arial color=navy size=2><SPAN style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: Arial"><o:p> </o:p>< /SPAN></FONT></P> <P class=MsoNormal><FONT face=Arial color=navy size=2><SPAN style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: Arial">Let me know if it helps-<o:p></o:p></SPAN></FONT></P> <P class=MsoNormal><FONT face=Arial color=navy size=2><SPAN style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: Arial"><o:p> </o:p>< /SPAN></FONT></P> <P class=MsoNormal><FONT face=Arial color=navy size=2><SPAN style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: Arial">P<o:p></o:p></SPAN>< /FONT></P> <P class=MsoNormal><FONT face=Arial color=navy size=2><SPAN style="FONT-SIZE: 10pt; COLOR: navy; FONT-FAMILY: Arial"><o:p> </o:p>< /SPAN></FONT></P> <DIV style="BORDER-RIGHT: medium none; PADDING-RIGHT: 0in; BORDER-TOP: medium none; PADDING-LEFT: 4pt; PADDING-BOTTOM: 0in; BORDER-LEFT: blue 1.5pt solid; PADDING -TOP: 0in; BORDER-BOTTOM: medium none"> <DIV> <DIV class=MsoNormal style="TEXT-ALIGN: center" align=center><FONT face="Times New Roman" size=3><SPAN style="FONT-SIZE: 12pt"> <HR tabIndex=-1 align=center width="100%" SIZE=2> </SPAN></FONT></DIV> <P class=MsoNormal><B><FONT face=Tahoma size=2><SPAN style="FONT-WEIGHT: bold; FONT-SIZE: 10pt; FONT-FAMILY: Tahoma">From:</SPAN>< /FONT></B><FONT face=Tahoma size=2><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Tahoma"> Jorge Schrauwen [mailto:jorge@(protected)] <BR><B><SPAN style="FONT-WEIGHT: bold">Sent:</SPAN></B> Wednesday, January 19, 2005 9:35 AM<BR><B><SPAN style="FONT-WEIGHT: bold">To:</SPAN></B> users@(protected)<BR><B><SPAN style="FONT-WEIGHT: bold">Subject:</SPAN></B > [users@(protected)] Mod_rewrite help</SPAN></FONT><o:p></o:p></P></DIV> <P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN style="FONT-SIZE: 12pt"><o:p> </o:p></SPAN></FONT></P> <DIV> <P class=MsoNormal><FONT face=Arial size=2><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Arial">hi all,</SPAN></FONT><o:p></o:p></P></DIV> <DIV> <P class=MsoNormal><FONT face=Arial size=2><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Arial">I'm new to mod_rewrite and regex for that mather...</SPAN></FONT><o:p></o:p></P></DIV> <DIV> <P class=MsoNormal><FONT face=Arial size=2><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Arial">and i'm stuk. here is what i'm trying to do:<BR>i want to rewrite</SPAN></FONT><o:p></o:p></P></DIV> <DIV> <P class=MsoNormal><FONT face=Arial size=2><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Arial">/view/vacation/1.jpg</SPAN></FONT> <o:p></o:p></P></DIV> <DIV> <P class=MsoNormal><FONT face=Arial size=2><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Arial">to</SPAN></FONT><o:p></o:p></P>< /DIV> <DIV> <P class=MsoNormal><FONT face=Arial size=2><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Arial">/index.php?album=vacation&file =1.jpg</SPAN></FONT><o:p></o:p></P></DIV> <DIV> <P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN style="FONT-SIZE: 12pt"> <o:p></o:p></SPAN></FONT></P></DIV> <DIV> <P class=MsoNormal><FONT face=Arial size=2><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Arial">this is what i have sofar:</SPAN></FONT><o:p></o:p></P></DIV> <DIV> <P class=MsoNormal><FONT face=Arial size=2><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Arial">---</SPAN></FONT><o:p></o:p></P>< /DIV> <DIV> <P class=MsoNormal><FONT face=Arial size=2><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Arial">RewriteEngine on<BR>RewriteRule ^/view/(.*)/(.*) /index.php?album=$1&file=$2</SPAN></FONT><o:p></o:p></P></DIV> <DIV> <P class=MsoNormal><FONT face=Arial size=2><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Arial">--</SPAN></FONT><o:p></o:p></P>< /DIV> <DIV> <P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN style="FONT-SIZE: 12pt"> <o:p></o:p></SPAN></FONT></P></DIV> <DIV> <P class=MsoNormal><FONT face=Arial size=2><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Arial">thanx in advance</SPAN></FONT><o:p></o:p></P></DIV> <DIV> <P class=MsoNormal><FONT face="Times New Roman" size=3><SPAN style="FONT-SIZE: 12pt"> <o:p></o:p></SPAN></FONT></P></DIV> <DIV> <P class=MsoNormal><FONT face=Arial size=2><SPAN style="FONT-SIZE: 10pt; FONT-FAMILY: Arial">Jorge Schrauwen<o:p></o:p></SPAN></FONT></P></DIV></DIV></DIV></BODY></HTML>
|
|
 |