https://github.com/thinkphp/rotate
A simple function JavaScript that allows you to rotate images by the given angle (radians or degrees).
https://github.com/thinkphp/rotate
Last synced: 3 months ago
JSON representation
A simple function JavaScript that allows you to rotate images by the given angle (radians or degrees).
- Host: GitHub
- URL: https://github.com/thinkphp/rotate
- Owner: thinkphp
- Created: 2010-09-22T19:32:14.000Z (over 15 years ago)
- Default Branch: master
- Last Pushed: 2010-09-22T19:49:49.000Z (over 15 years ago)
- Last Synced: 2024-04-14T14:54:28.818Z (almost 2 years ago)
- Language: JavaScript
- Homepage: http://thinkphp.ro/apps/js-hacks/rotate/
- Size: 101 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
Rotate
======
A simple function JavaScript that allows you to rotate images.
Syntax
======
1.Rotate(HTMLImageElement image, String angle)
@param image (HTMLImageElement) an image element.
@param angle (String) angle either radians or degrees ('45deg' or '40rad')
2.Rotate(HTMLImageElement image, Number angle)
@param image (HTMLImageElement) an image element.
@param angle (Number) angle in radians.
Usage
=====
Rotate(document.getElementById('rotate_me'),'45deg');
Rotate(document.getElementById('rotate_me'),Math.PI/2);
Rotate(document.getElementById('rotate_me'),Math.PI/2);
Browser Support
===============
Firefox 1.5+
IE 6+
Opera 9.5+
Google Chrome
Safari 2+