I've created a WP theme, which contains slideshows on different pages. I don't want to use any WP plugins for that specific project, so I tried the following:
- define foldes at the root directory (e.g. /slideshow/folder1)
- get files from folders on specific pages via php and echo the code
Wordpress naturally redirect any links which are not absolute I guess. This method will work at the home page (because the folders for the slideshow are in the root directory), but not in any other pages.
The schema for the pages is "www.mylocation.com/pagename/". When I'm trying to get the files with a relative url like "../slideshow/folder1" Wordpress redirect the link to "../pagename/slideshow/folder1".
Is there a solution which will work for that specific part (maybe without htaccess redirect)?
The temporarily solution is rewrite the urls after loading via JavaScript but this will force loading failures when php is trying to get the files.