cclear Posted April 21, 2015 Share Posted April 21, 2015 Ok so at first I couldn't get the index.php page to show up but after adding the mod -rewrite, then after adding the subdirectory to the css link, img src and href everything displayed fine and almost every link works. The only links that are not working are the ones that go to coffee, goodies, and sales, along with all the links that are a product. in my htdocs folder i have site2/index.php so I was putting site2 in front of references like the book mentioned but those pages wont load. the links are like this /site2/shop/goodies and the last one changes depending on link. I hope you guys understand my problem. Any insights on how to get these links working would be stupendous. Link to comment Share on other sites More sharing options...
Larry Posted April 22, 2015 Share Posted April 22, 2015 So the problem seems to be in your mod_rewrite, the rules for which are in your .htaccess file. You should be using a RewriteBase in those rules with a value of /site2/ (not sure about the slashes). If you can't get this to work playing around with it, please post the contents of your .htaccess. Link to comment Share on other sites More sharing options...
johannsnr Posted May 7, 2015 Share Posted May 7, 2015 Hi Larry, I have a similar problem as Cclear wrote. My problem though starts with the sales link and I have checked my .htaccess file which is correct(or so it seems). The link to Sales just don't want to link up for some reason. I have tried to simplify the linking files only to include a header and that doesn't work either. So I am stuck with that the problem lies within the .htaccess file, but why would browse and shop work fine and not sales. Link to comment Share on other sites More sharing options...
johannsnr Posted May 7, 2015 Share Posted May 7, 2015 Hi Larry I have found an error in the .htaccess file of /ex2/html in the 2nd ecommerce site. There is a added slash in the code. RewriteRule ^shop/sales/?$ /sales.php Correct me if I'm wrong, so the extra slash is added in the URL and obviously the file then does not exist. Removing the slash in the code resolved the issue. Link to comment Share on other sites More sharing options...
Larry Posted May 8, 2015 Share Posted May 8, 2015 It will depend upon your setup, but I'm glad you've got it working for your case. Link to comment Share on other sites More sharing options...
Recommended Posts