luca marletta wrote: > Hi Armin > I've test a bit your beta release for 1.3.0 with window resizing > ported into ver 1. > I like a lot this chance also in ver 1 but I got some problem with a > warning above the main window > "Warning: Invalid argument supplied for foreach() in > /var/www/pmapper-1.3.0/incphp/util.php on line 102" > > and 102 line is > > 102 foreach ($winDimensions as $size => $vals) { > > $html .= " <OPTION value=\"$vals[0]#$vals[1]#$size\""; > > if ($size == $winsize) $html .= " selected "; > > $html .= ">" . _p($vals[2]) . "</OPTION> \n"; > > }
I don't get this error. Seems like $winDimensions is not included in your custom.php (there the array is normally initiated). In any way, the JS for resizing 'changeWinSize' should be modified since it now would not need any more to reload the whole application but just resize the window. > > and also after some normal work on mapfile I was not anymore able to > get the TOC shown and working, I don't know if the the warning is > related. Is there an error in the error log? Or a JS error? > > I like the ver 1 because for me the ver 2 is still full of "previous > image" bug and actually it's not usable. I ran into this problem recently also with version 1, Don't know why it normally mainly appears with version 2. > About this bug that I start to think is not much related to mapserve > bug because is so tided to the ver 2 and not ver 1, can you show me > the line to change for try to use a random number for image files and > not pregressive as it seems now. > If you take a look into the tmp dir you can see that sometimes new > image take the the name of previous (you get it from time changed) > that is the point but WHY? so may be, if it's some counter that > doesn't work, changing the way to make the file name can check if it > is related to that. I have set this for an application at work, I can send you the workaround on Monday. Otherwise it's the line 330 for the map image $this->mapURL = $mapImg->saveWebImage(); it has to change to $mapImg->saveImage($imgTmpName); $imgTmpName needs to be a concat of the absolute path (map file IMAGEPATH) and a unique random name, the $this->mapURL needs to be the same random name concatenated with the IMAGEURL from map file. Don't know, however, if anyone created a bug report on Mapserver's bugzilla and if there is already a bug fix in the latest releases. Armin