Use custom php files

Im trying to create a file that makes a PDF copy of an item when an press download, i uploaded my custom file for this purpose to the server and when i try to load it on the browser omeka gives me a 404 error i tried to mess with the httacces to give acces to my file but it not working, my file is located in the items dir of the template and the only file that correctly shows there is show.php is there a code or something that redirects on omeka that only allows certain php files to me executed? and if so how can i add my custom php file to be executed to? thanks

The htaccess shipped with Omeka directs all “.php” requests to the Omeka application, by design. The system doesn’t support just adding .php files for direct access, instead new accessible URLs are added by plugins using the Zend Framework MVC system.

You could do something like disabling rewrites (RewriteEngine Off) with an .htaccess in the folder where your custom file is stored, or using something like RewriteCond to exclude your file if you really wanted to work around this.

1 Like

Thanks i have been trying different methods but nothing with the httaccess i will try

This topic was automatically closed 250 days after the last reply. New replies are no longer allowed.