imperium2335 Posted November 13, 2011 Share Posted November 13, 2011 Hi, I have the following in my HTACCESS file: Options +FollowSymlinks RewriteEngine On RewriteRule wedding-cakes/(.*)\.html$ cakes.php?target=$1 RewriteRule chocolate-cups-towers/(.*)\.html$ cakes.php?target=$1 RewriteRule corporate-cakes/(.*)\.html$ cakes.php?target=$1 RewriteRule adult-birthday-cakes/(.*)\.html$ cakes.php?target=$1 RewriteRule childrens-birthday-cakes/(.*)\.html$ cakes.php?target=$1 RewriteRule saucy-cakes/(.*)\.html$ cakes.php?target=$1 RewriteRule christmas-cakes/(.*)\.html$ cakes.php?target=$1 RewriteRule christening-cakes/(.*)\.html$ cakes.php?target=$1 Now, if I go to a link such as: saucy-cakes/bum-shaped-cake.html I get a 404 that says: The requested URL /saucy-cakes.jpg/bum-shaped-cake.html was not found on this server. Where is this .jpg coming from??? Link to comment https://forums.phpfreaks.com/topic/251062-annoying-redirect-problem/ Share on other sites More sharing options...
danbopes Posted November 13, 2011 Share Posted November 13, 2011 Do you have any other .htaccess files, such as in a "saucy-cakes" folder? The .jpg would have to be from another rewrite somewhere. I would suggest turning on rewritelog, and see how things are being rewritten. Link to comment https://forums.phpfreaks.com/topic/251062-annoying-redirect-problem/#findComment-1287851 Share on other sites More sharing options...
imperium2335 Posted November 13, 2011 Author Share Posted November 13, 2011 Hi Dan, I have another htaccess file in the root of the site. The full url if ur interested in looking is: http://www.sweetart.co.uk/2012/cake-gallery.php From there u go into a gallery and then click on images to enlarge them. Strangely enough, putting in: 2012/saucy-cakes/saucy-cakes/bum-shaped-cake.html Works, so I am now totally confused! Link to comment https://forums.phpfreaks.com/topic/251062-annoying-redirect-problem/#findComment-1287852 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.