andy's php projects
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister   ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
Script and site usage:
All of the scripts on this site are provided free for non-commerical, personal or non-profit use. If you find these scripts useful to you, appreciate the free support, or are just an all round nice person, then why not donate a little dosh? If you wish to use any of these in a commercial system, please refer to the payment plan.


IE problem on Mac

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    php.amnuts.com Forum Index -> Crop Canvas
View previous topic :: View next topic  
Author Message
Londonsnapper
Newbie


Joined: 31 Jan 2006
Posts: 3

PostPosted: Tue Jan 31, 2006 6:22 am    Post subject: IE problem on Mac Reply with quote

Hi there - I'm a newbie and have been playing around with your code which is perfect for what I'm looking for - nice one! I have got it working perfectly in Safari and Firefox on a Mac but in Explorer the image appears but no cropping square so I am unable to crop it. I have tried your hints about making sure there is no html after the javascript but it hasn't helped. If you have any ideas I'd be grateful - I can't find anything on the forum about this.

regards, Andy.
Back to top
View user's profile Send private message
amnuts
Site Admin


Joined: 01 Sep 2002
Posts: 662
Location: East Sussex, England

PostPosted: Tue Jan 31, 2006 7:45 am    Post subject: Reply with quote

Hi and welcome to the board!

I've just tried it using IE 5.2 on a MAc and, even though I got the cropping area and was able to make a crop, the whole thing looked a little 'iffy'. The cropping area wasn't transparent, the image was bigger than the contain and overflowed (which might have hidden the cropping area for you).

The cause? Well, IE on the Mac is quite, quite old now and might not understand some things in the CSS or javascript. You might be able to make the interface a bit friendlier for that browser, but then you would be doing an injustice to the newer browsers.

Did you try the demo on this site as-is (ie, running it from this website rather than downloading the files and trying out a local copy) in IE on the Mac?

Andy
Back to top
View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger MSN Messenger
Londonsnapper
Newbie


Joined: 31 Jan 2006
Posts: 3

PostPosted: Tue Jan 31, 2006 9:31 am    Post subject: Reply with quote

Hi - thanks for the very fast reply!

I have just had a look at your example on your site using Explorer 5.2 and get the same result that you did - the crop square is not transparent and the size cannot be changed. Also the image appears slightly offset to the left and up.

I know IE on the Mac isn't used very much anymore, so maybe I should just ignore it - it's always been annoying with the way it treats Javascript.

What would be useful though is to make the crop square a fixed size of 90pixels square - are you able to give me a quick way to do this but still enable to be resized in other browsers? I want the output image to be fixed at this size.

Any help you can give is much appreciated, and if I get this to work, rest assured I'll be donating!

regards

Andy
Back to top
View user's profile Send private message
amnuts
Site Admin


Joined: 01 Sep 2002
Posts: 662
Location: East Sussex, England

PostPosted: Tue Jan 31, 2006 10:03 am    Post subject: Reply with quote

When looking at the $_SERVER['HTTP_USER_AGENT'] information on the Mac, I get something like this:

Mozilla/4.0 (compatible; MSIE 5.23; Mac_PowerPC)

What you could do is use that information to determine the MSIE on a Mac and fix the size of the cropping, such as:

PHP:
<?php require_once(dirname(__FILE__) . '/class.cropinterface.php');
class 
myInterface extends cropInterface
{
    function 
myInterface($debug false)
    {
        
parent:cropInterface($debug);
        if (
stristr($_SERVER['HTTP_USER_AGENT'], 'MSIE') && stristr($_SERVER['HTTP_USER_AGENT'], 'Mac_PowerPC')) {
            
$this->setResizing(false);
            
$this->setCropDefaultSize(9090);
        }
    }
?>


You'd then use the extension class above rather than the cropInterface class (but because it extends the cropInterface you have all the methods and variables available to you that you'd expect).

I haven't tried the above, but it should work.

Andy
Back to top
View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger MSN Messenger
Londonsnapper
Newbie


Joined: 31 Jan 2006
Posts: 3

PostPosted: Tue Jan 31, 2006 10:39 am    Post subject: Reply with quote

Sounds good to me - I won't be able to try it for a couple of weeks due to lack of time, but I'll get back to you when I have done.

Cheers

Andy
Back to top
View user's profile Send private message
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    php.amnuts.com Forum Index -> Crop Canvas All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group