javascript - Canvas implementation on different images -
I am using the next sample in my code:
var lasticon; Click (function () ($ (function (). $ (Function () (if (austicone! = This.id) {$ ('#' + old + 'L') Toggle (); AwwCicon = It is .id;} and {lasticon = null;} $ ('#' + this.id + 'L'). Toggle ();});}); .inonL {display: none; margin-top: 70px; Margin-left: 100px; height: 100 pixel width: 100px; position: full;} var forever; $ (function () {$ ('. Icon'). (Function () (if (aston;! .id) {$ ('#' + old + 'L') Toggle (); AwwCicon = it .id;} and {lasticon = null;} $ ('#' + this.id + 'L'). Toggle ();});});
Whatever I need, next I have to implement the next solution of my first code in the field:
I have done some tests and have tried to apply it to me code, but nothing happens.
I would like to be able to resize and move the second image that appears when clicking on the first image so you can click on the "e-mail icon" for example, and then change the size of the second icon that appears .
This is not really easy but here are some starting points:
- Read the tutorial about image crop and resizing with canvas
- See my example as an implementation, you can copy the code,
& lt; Img class = "resize-image" src = "img / YOURIMAGE.jpg" alt = "image to resize" & gt; You can add an image to the
tag and you can - use the option
Basically you are doing the following:
- Load the original image in the DOM
- Resize and crop your image with javascript to display the result of your image crop.
- Load the original image into a canvas
- Crop & amp;
- Remove the image with the toDataURL function from the canvas
- Send to DataURL for a web service that saves this information on your hard disk on your hard disk.
Comments
Post a Comment