GetSimple Support Forum

Full Version: How to change upload path/directory ?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Please help me to change the upload path for files from /data/uploads to /media/img
I tried replacing "data/uploads" to "media/img" in /admin/upload.php but in vain.
Quote:admin/inc/common.php

change line 50

Quote:define('GSDATAUPLOADPATH', GSROOTPATH. 'data/uploads/');

to

Quote:define('GSDATAUPLOADPATH', GSROOTPATH. '/media/img/');
as this is not an option, but a hack of the core files, don't forget to redo this hack after the next update ;=)

Cheers, Connie
Yes this is core hack that I do not like, but as I see for now only option. If in some next version developers adds editable configuration file that could solve this limitations.

For security reasons this could be implemented as during installation. Some core directory names encryption.

Wink)
Thanks bogyvet.
I was to change and path with all other benefits like thumbs, file browser etc. In case anyone in future want to hack this feature, you need to update your new path in the following files:

admin\image.php
admin\health-check.php
admin\filebrowser.php
admin\upload.php
admin\inc\common.php
admin\inc\thumb.php
I have a blog that uses a separate domain for the images (e.g.http://sub.domain.com), while my main blog is on the domain.com. I wanted to convert GetSimple to use the sub-domain for an image directory. All was well after the changes show in this thread except for a small oversight. The current image directory includes around 1500 images, all of which GetSimple wants to load every time I want to add an image to a page. I suspect that this will be a limiting factor for site owners in the future, as image directories only get larger and larger, thus increasing load times for adding an image to a page.

The only really bad work-around for this, keeping images in a separate sub-domain/directory, would be to install a web app to download and crop images to the sub-domain, then you could manually copy/paste thumbnails or whatever else into GS.

I would love to convert my WP blog over to GS. The page load times are phenomenal and I love the simplistic nature of the CMS.