Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - SunnyUK

Pages: [1] 2 3
1
Cool! Thanks Nicky! :)

2
Hi all,

I have had a browse and done some searches, but have not been able to find a solution, so I'm hoping that someone here might know....

I would like to know how people use the "search" function on my 4images website. If I were to create a mod for it, I would break it into three separate activities

1) log all search criteria
2) analyse the content of that log
3) display the results of the analysis

Does anyone know of an existing mod that will do some or all of this?

Thanks in advance for any help or pointers.

3
Nice mod. Thank you very much.

4
Mods & Plugins (Requests & Discussions) / Re: Multi-word keywords
« on: October 21, 2008, 09:50:59 AM »
Anita,

if you open the file admin\checkimages.php and look at lines 50-60. They look something like this.....:

Code: [Select]
{
  $annotate_default = (isset($config['annotation_use'])) ? $config['annotation_use'] : 0; //add annotation to the images (require "Annotation MOD" by SLL)
  $big_default = 1; //save original image (0 or 1)
  $iptc_date_default = 1; //auto insert date from IPTC (0 or 1)  UPDATED TO 1 TRP
  $iptc_keywords_default = 1; //auto insert keyword from IPTC (0 or 1) UPDATED TO 1 TRP
  $iptc_description_default = 1; //auto insert captions from IPTC (0 or 1) UPDATED TO 1 TRP
  $iptc_name_default = 1; //auto insert name from IPTC (0 or 1) UPDATED TO 1 TRP
  $detailed_default = 0; //detailed view (0 or 1)
  $auto_resize_default = 1; //resize images (0 or 1)
  $auto_thumbs_default = 1; //create thumbs (0 or 1)
  $subcats_default = 0; //include subcategories (0 or 1)
}

This is where you set the default behaviour of the checkimages routine. The ones that says "updated to 1 trp" are the ones I have flicked from 0 to 1 in order to get the behaviour you're looking for.

Hope this helps.

5
Mods & Plugins (Requests & Discussions) / Re: Multi-word keywords
« on: October 16, 2008, 11:10:07 PM »
I mean that the code I have written above only deals with the multi-word keywords.

The real clever stuff, the stuff that makes sure that keywords entered into the IPTC tags (via Photoshop or Lightroom or other programs) are stored in 4images keywords is explained in the link http://www.4homepages.de/forum/index.php?topic=21141.0 .

6
Mods & Plugins (Requests & Discussions) / Re: Multi-word keywords
« on: October 16, 2008, 09:12:56 PM »
Yes, it really is that easy.

Don't forget to also implement http://www.4homepages.de/forum/index.php?topic=21141.0, though

7
d'oh!  :oops:

Thanks V@no

8
If I successfully prevent anyone from uploading executables to the relevant directories..... how do I then subsequently upload an executable myself (e.g. when I need to implement a fix to 4images) ?

9
Mods & Plugins (Releases & Support) / Re: [MOD] Exif V.1.7.6
« on: August 16, 2008, 05:56:28 PM »
There's a bug (looks just like a simple cut and paste error) in functions.php where the GPSLongitude is calculated - this causes images taken east of Greenwhich and North of Equator to be stored (and hence shown on e.g. google maps) as if they were taken West of Greenwich.

To correct it:

In \includes\functions\php, find

Code: [Select]
          elseif ($key == "GPSLongitude") {
          $GPSLongitude_h = explode("/", $exif_info[0]);
          $GPSLongitude_m = explode("/", $exif_info[1]);
          $GPSLongitude_s = explode("/", $exif_info[2]);
       
          $GPSLong_h = $GPSLongitude_h[0] / $GPSLongitude_h[1];
          $GPSLong_m = $GPSLongitude_m[0] / $GPSLongitude_m[1];
          $GPSLong_s = $GPSLongitude_s[0] / $GPSLongitude_s[1];
       
          $GPSLongGrad = $GPSLatfaktor * ($GPSLong_h + ($GPSLong_m + ($GPSLong_s / 60))/60);
       
          $exif_array[$exif_match[$key]] =  $GPSLongitudeRef . " " . $GPSLong_h . "° ". $GPSLong_m . "' " . $GPSLong_s . "'' ($GPSLongGrad)";

Replace this with

Code: [Select]
          elseif ($key == "GPSLongitude") {
          $GPSLongitude_h = explode("/", $exif_info[0]);
          $GPSLongitude_m = explode("/", $exif_info[1]);
          $GPSLongitude_s = explode("/", $exif_info[2]);
       
          $GPSLong_h = $GPSLongitude_h[0] / $GPSLongitude_h[1];
          $GPSLong_m = $GPSLongitude_m[0] / $GPSLongitude_m[1];
          $GPSLong_s = $GPSLongitude_s[0] / $GPSLongitude_s[1];
       
          $GPSLongGrad = $GPSLongfaktor * ($GPSLong_h + ($GPSLong_m + ($GPSLong_s / 60))/60);
       
          $exif_array[$exif_match[$key]] =  $GPSLongitudeRef . " " . $GPSLong_h . "° ". $GPSLong_m . "' " . $GPSLong_s . "'' ($GPSLongGrad)";

(I can't figure out how to colour the code, but the important bit is the 2nd to last line where the original code references $GPSLatfaktor which should have been $GPSLongfaktor.

10
Chit Chat / Re: In memory of manurom
« on: July 28, 2008, 08:48:05 PM »
My condolences to the family. Manuel was always helpful and very friendly.

I'm so very sorry.

11
Discussion & Troubleshooting / What is $show_result used for?
« on: July 19, 2008, 04:16:28 PM »
I'm trying to create an advanced search function (enabling the user to search by multiple fields... e.g. "show me the pictures taken with my macro lens during summer where fill flash was used"), so I'm amending search.php.

It seems that most of the existing functionality in search.php is controlled by a variable called $show_result. This variable gets set in global.php.

Can I safely add code similar to this to global.php or will that cause troubles in the way 4images works ?

Code: [Select]
if (isset($HTTP_POST_VARS['search_date']) || isset($HTTP_GET_VARS['search_date'])) {
  $search_date = (isset($HTTP_POST_VARS['search_date'])) ? trim($HTTP_POST_VARS['search_date']) : trim($HTTP_GET_VARS['search_date']);
  if ($search_date != "") {
    $show_result = 1;
  }
}
else {
  $search_date = "";
}

The code snippet is a slight tweak to the existing code for search_user in global.php

Thanks in advance for any guidance.

12
*bump*

I'm bumping this just to make people aware that this problem still exists. And as said in the thread, there's apparently nothing we can do about it other than accept that Norton is a bit to strict when it determines what constitutes an add. So if anyone has problems with "missing thumbnails", do check whether disabling Norton (or adding your domain to the white list) solves the problem before spending hours and hours going crazy over the code (as I just did :( )

13
Right, my mistake for not understanding the error message. But rather than delete the cry for help, let me post the solution here so that if anyone else encounters the same problem they know what to do...

The images that 4images couldn't import were all very large (straight from camera without any re-sizing). This caused the script to use more memory than had been allocated to PHP. So by going into the PHP ini file and increase the amount of memory from 32 Mb to 64 Mb, the error went away:

1) right click on the 4images mobile icon in the task bar
2) select advanced / php configuration. This will open the php.ini file in edit mode
3) search for memory_limit = 32M (in a section called resource limits)
4) change the 32M to 64M and save the ini file
5) shut down mobile server and restart

If you are nervous about undertaking this without having a backup, the ini file is placed in a directory under 4mobile called server\diskw\usr\local\php - so it might be an idea to make a backup copy of the file before editing it. And actually if you bother making a backup, you might as well edit it directly while you're in the right directory.

14
I'm not sure if this has anything to do with Mobile Server or if it's an error in core 4images. But here goes...

When I

1) copy a new image to \data\media\3
2) run checkimages in order to import the image

I get this error message from checkimages

Warning: rename(./../data/media/3/DSC_1187.JPG,./../data/media/3/DSC_1187.JPG.bak) [function.rename]: File exists in W:\www\4images\includes\image_utils.php on line 180

Fatal error: Allowed memory size of 33554432 bytes exhausted (tried to allocate 3872 bytes) in W:\www\4images\includes\image_utils.php on line 80


After this, I can not import images using checkimages.

The way I read it, there is a memory leak and a 32Mb area which have been exhausted. The only way I can make things work again is to reboot my machine.

Now I can live with rebooting my local PC every now and then during development (even if it's a bit inconvenient), but if this error is NOT caused by 4mobile, then it must be a leak in the core 4images, meaning that my server (I'm on a shared hosted plan) will also eventually encounter it. I suspect that my hosting supplier isn't going to be thrilled if I cause stability problems for the server.

Any ideas? Clues?

I'm using the PHP-5 version of 4Mobile. What other information should I provide?

15
What a great idea! I had been thinking about getting mySQL, php and Apache installed locally to be able to mess about with 4images without having to test things out on my live site. So this all-in-one package is absolutely the ticket!

I run vista. And like mentioned a couple of times before (by others), I get an error message from Vista (program crashed... investigating causes... cannot find a reason). However, after I click "cancel" to the error message, the 4images icon appears in my status bar and it seems I can run it from there. I just wonder which bits are not running as a result of the crash.

After copying my copies of the modded code and re-creating modded tables, it just seems to work. Wonderful!!! Thank you so much! :) :) :)

Oh, and as V@no says, why hijacking drive W?  I had a network drive mapped to W but had to disable that :(

Pages: [1] 2 3