zettberlin
Forum Replies Created
-
Thanks again for the advice.
I’ll see to keep my hack as separated as possible from your code…I’ll try it on a demo-page, where you could have a look into it and how it works, so you may take into consideration to involve something similar…
So it looks like we have the catch… very well then. I have already informed my clients staff. that pics with less than 1600px resolution should be safe.
Do you think it would be feasible, to insert some reject-mechanism for too large pics that would exit the whole process of inserting a new entry to wp_ngg_pictures and wp_ngg_gallery?
What file/s would I need to hack for that?
Thanks for the advice, it reads like this:
SunOS (32 Bit)
PHP Version : 5.3.29
PHP Memory Limit : 128
PHP Max Upload Gr??e : 32MGD Version : bundled (2.1.0 compatible)
I made some experiments and now I suspect, that the memory-limit could play a part. Gallery imports and processes pictures correctly, when I first reduce their resolution to 1600px horizontal.
Could it be, that the bitmaps are just too big for the memory limit, when I try to feed the system pictures with resolutions like 5000px?
I would never upload pictures of such ridiculous proportions to a website but my client does. As in: grab the pic from the 16MP-camera and upload it as is.
If the picture size is the problem I dare to propose some mechanism, that finds out (with something like getimagesize() ) about the resolution and stops processing the pic throwing a message such as: “Ufortunately pictures of that size may cause fatal memory consumtion on your stupid el-cheapo server, cut it down to $estimated_safe_resolution and try again.”
You know: the trouble is, that the picture is imported to the gallery anyway but without a picture file, wich breaks the page showing the gallery…
I see the same behaviour in 2.1 with several actions such as rebuilding thumbs and others.
Forum: Reviews
In reply to: [IntheDistance] some way to goThanks for the reply.
Yes, I get no title and some other basic problems.
I essence I like your approach to go for strictly modern HTML5 with header/footer tags instead of divs etc but anyway, there may be some problems caused by control structures yielding unforseen output?
Interesting. Is this in the recent WP 3.6?
I was searching for an alternative anyway, have you found one?
Forum: Fixing WordPress
In reply to: password protected directories on a wordpress site> Easy on html site but not so easy on wordpress.
If you are ready to do it from scratch (which I think is a good idea…) you can do that with WP as well by using a page and a php-file you write yourself.
Write a file downloads.php holding the code to ask for a password and then show the files in a directory of your choice.
Create a Page named “Downloads” to have a pointer to you download-page in WPs menus.
Find out the page_id – lets say it would be page_id=23
In your theme-dir open the file index.php and write something like this in an appropriate place:if ($_GET[page_id]==23){
include “downloads.php”;
}This works if downloads.php is in the root-dir of WP.
Whatever you do in downlodas.php is under your control, remember that you need to point to index.php?page_id=23 whenever you use links or forms in your code.best of luck ??