Solved

RESIZE AND ROTATE IMAGES USING MOUSE

Posted on 2004-04-16
6
1,226 Views
Last Modified: 2013-12-25
i want the mouse to control the image, and so accordingly it should enlarge an image and rotate it.

How can this be achieved? Please provide samples of code if possible.
0
Comment
Question by:zhussai7
6 Comments
 
LVL 30

Expert Comment

by:weed
ID: 10843744
In...Photoshop? What are you trying to do, in what program, and for what purpose?
0
 
LVL 9

Expert Comment

by:j3one
ID: 10844319
I not sure, but I think you mean that you want people to be able to move or rotate images in your website, right?

-> flash or director will do the trick. if you are wanting to do this with code in the html, the only thing I can think of is dhtml or javscript ->http://www.experts-exchange.com/Web/Web_Languages/JavaScript/
0
 
LVL 4

Accepted Solution

by:
monolith_888 earned 250 total points
ID: 10844897
Here's a good start:

-monolith_888

==================

<html>
<head>
<title>T2</title>
<style type="text/css">
span {cursor:hand;color:#666;font-family:tahoma;font-weight:bold;font-size:12px;margin-left:10px;margin-right:10px;border:1px solid #000;padding:2px;width:50px;text-align:center;}
</style>
<script type="text/javascript">
<!--
var imgState =
      {
      zoom  : 1,
      flip  : 'fliph'
      };

function rotate( way )
      {
      var theImg = document.getElementById('myImg');
      var theDiv = document.getElementById('flipper');
      imgState.flip  = (imgState.flip == 'fliph') ? 'flipv' : 'fliph';
      theImg.style.filter = imgState.flip;
      }
      
function zoom( which )
      {
      var theImg = document.getElementById('myImg');
      imgState.zoom = (which == 'in') ? imgState.zoom += .1 : imgState.zoom -= .1;
      theImg.style.zoom = imgState.zoom;
      }
// -->
</script>
</head>
<body>
<span onclick="location.reload();" style="border:0px;">reset</span><P>
<span onclick="rotate('cl');">flip</span>
<span onclick="zoom('in');">+</span>
<span onclick="zoom('out');">-</span>
<P></P>
<img src="http://www.blakeanddawn.com/ee/sunset.jpg" id="myImg">
</body>
</html>
0
 
LVL 10

Assisted Solution

by:Havin_it
Havin_it earned 250 total points
ID: 10858849
Think you'd be better off with a Java applet - a few examples (free) at

http://www.javascriptkit.com/java/

Or this version (very inventive, but requires Perl)

http://www.gifworks.com/

0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Is this responsive table set up right for all browsers 4 64
Hovering effect 9 48
What language/protocol is the Angular Chat? 2 58
Excel Hyperlink Question 4 33
"In order to have an organized way for empathy mapping, we rely on a psychological model and trying to model it in a simple way, so we will split the board to three section for each persona and a scenario and try to see what those personas would Do,…
Get to know the ins and outs of building a web-based ERP system for your enterprise. Development timeline, technology, and costs outlined.
Viewers will get an overview of the benefits and risks of using Bitcoin to accept payments. What Bitcoin is: Legality: Risks: Benefits: Which businesses are best suited?: Other things you should know: How to get started:
Any person in technology especially those working for big companies should at least know about the basics of web accessibility. Believe it or not there are even laws in place that require businesses to provide such means for the disabled and aging p…

863 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

24 Experts available now in Live!

Get 1:1 Help Now