Chad Posted June 19, 2012 Share Posted June 19, 2012 Hello again, ProcessWire forums. I have run into another snag in our small shockwave/flash project that uses ProcessWire for its login and game progress tracking system. The developer of one of the games (no longer with us) has all of the resources linked dynamically within his project using an xml file to catalog where the files are (external flash movies, etc). When I try to put this into processwire, requests to these resources fail with a 404. (it sees the xml file, but fails when it tries to load the next .swf file) Is there a way to point a particular url to a specific file tree outside of processwire's hierarchy? Example of what I'd like to happen: /main.domain.com/the_games: loads a regular processwire template with the log-in information, etc. /main.domain.com/the_games/game1 redirects to a specific area in the server's file heirarchy outside of /site/ (ex. instead of $config->urls->templates->whtever.php, go directly to /games/game1/index.html on the file server ) with full access to the media and flash files using relative urls. I'm guessing that what I will need to do is remap this subdirectory in the .htaccess file, but I'm not sure how exactly to go about doing that or how to do this in a way that does not break ProcessWire. Any advice? If there is another solution that allows pages to see media in relative urls, that would be helpful too. Link to comment Share on other sites More sharing options...
Soma Posted June 19, 2012 Share Posted June 19, 2012 I'm not sure I understand anything after "Example of what I'd like to happen:". I'm no sure what or even why you would want to "redirect" to another non PW page. But I don't see any problems referencing or linking media in your template files as you usually would in any website, PW only protects system files. If a file exists and isn't protected there should be no 404. Hard to really make any assumptions on how to best set it up or help without knowing or understanding your required project structure and needs in the full scope. Link to comment Share on other sites More sharing options...
teppo Posted June 20, 2012 Share Posted June 20, 2012 @Chad, if you want /main.domain.com/the_games/game1 to redirect to another folder somewhere else, you could try using symlinks for that. Though I don't know why you'd need to do this -- couldn't you just move contents of /games/game1/ to correct folder inside /site/? Naturally there could be many reasons that make this difficult, but it might still be worth considering.. this sounds a bit like a setup that might cause many more problems in the future About requests for files mentioned in your XML file failing, this could have something to do with either htaccess rules OR with the way you're requesting those files. What and how does these requests? Is it PHP, Flash or something else? Could it be that it's actually failing the request somehow? What do Apache logs tell about this problem? Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now