Is there a way I can exclude certain filetypes from the amazing effects of Attachment Store? I have a custom plugin for displaying maps from GPX & KML files. I need for these files to be stored locally. Thanks.
Hmm, yeah. I can add a new field for you to configure some extension to ignore I guess. Will that work for you?
That would be great!!! I'm looking at it right now and this is what is happening... With my custom plugin, when I upload a GPX file for example, it doesnt go into the attachments directory. It goes into a directory called 'filedemo' but now with Attachment Store installed, the GPX file still goes into 'filedemo' but the file has no data.
xfrocks @Russoroni Hmm, I'm a bit worried that even with the extension ignore option, it will not work since your add-on doesn't seem to work with default XenForo attachment system anyway...
But it worked fine until I installed attachment store. It still uses the attachment system but it dumps gpx, kml, kmz & tpo files into a different directory. I'm not exactly sure if it goes into the attachments directory first and then to filedemo but something is messing with it now.
I dont know if this helps but here is some of one of the plugin files... $file = $_SERVER['DOCUMENT_ROOT']."/internal_data/attachments/0/".$att_id."-".$hash_code.".data"; // Open the file to get existing content $current = file_get_contents($file); // Append a new person to the file // Write the contents back to the file $ourFileName = $_SERVER['DOCUMENT_ROOT']."/library/filedemo/".$att_id."-".$hash_code.".".$ext; $ourFileHandle = fopen($ourFileName, 'w') or die("can't open file");
You can try with v1.1.3 now https://xfrocks.com/resources/bd-attachment-store.3/update?update=47 [bd] Attachment Store for XenForo 1 Store attachment differently and more effectively. xfrocks.com
Well... I like how fast you cooked this up and it IS working but I'm still having the problem lol... If I show you my plugin files do you think you could see what the problem is? They are not large or complex. I will PM them to you.