Click here to Skip to main content
15,891,006 members
Home / Discussions / ASP.NET
   

ASP.NET

 
AnswerRe: zoom the image size and display in the center of the page Pin
Brij26-Apr-10 3:37
mentorBrij26-Apr-10 3:37 
AnswerRe: zoom the image size and display in the center of the page [modified] Pin
daveyerwin26-Apr-10 5:17
daveyerwin26-Apr-10 5:17 
GeneralRe: zoom the image size and display in the center of the page Pin
developerit27-Apr-10 1:49
developerit27-Apr-10 1:49 
GeneralRe: zoom the image size and display in the center of the page Pin
daveyerwin27-Apr-10 2:56
daveyerwin27-Apr-10 2:56 
AnswerRe: zoom the image size and display in the center of the page Pin
Tej Aj26-Apr-10 8:03
Tej Aj26-Apr-10 8:03 
QuestionHow to Get FTP username and password Pin
sjs4u26-Apr-10 0:44
sjs4u26-Apr-10 0:44 
AnswerRe: How to Get FTP username and password Pin
Not Active26-Apr-10 2:23
mentorNot Active26-Apr-10 2:23 
QuestionJcrop a jquery plug-in, has anybody used it ? Pin
jason_mf25-Apr-10 23:58
jason_mf25-Apr-10 23:58 
I try to use it.
I know how to set up, how to initialize,etc.
but I encountered a strange problem.
I can't drag the selection of the code of i writed in the html file.
In the another html file,I copy code from Jcrop's demo, the drag is ok.

the code of I writed and the code of copied are same, I checked several times.

And the resize box Of the Crop selection is not display.

the "Jcrop.css" is referenced right.

Very strange. Why?

Here is the code:
<br />
<HTML><br />
<HEAD><br />
<br />
<TITLE> New Document </TITLE><br />
<br />
    <br />
    <script type="text/javascript" src="js/jquery.min.js"></script><br />
    <script type="text/javascript" src="js/jquery.Jcrop.js"></script><br />
	<link type="text/css" href="css/jquery.Jcrop.css" /><br />
<br />
	<script type="text/javascript"><br />
        <br />
        jQuery(window).load(function() {<br />
           <br />
			var api = $.Jcrop('#cropbox', {<br />
				onChange: showPreview,<br />
				onSelect: showPreview,<br />
				<br />
<br />
				setSelect: [0, 0, 120, 120],<br />
				<br />
				aspectRatio: 1<br />
			});<br />
<br />
			<br />
			api.setOptions({ minSize: [40, 40], maxSize: [120, 120] });<br />
        });<br />
<br />
        function showPreview(coords) {<br />
<br />
            if (parseInt(coords.w) > 0) {<br />
                var rx = 100 / coords.w;<br />
                var ry = 100 / coords.h;<br />
                var realHeight = $("#cropbox").attr("height");<br />
<br />
                jQuery('#preview').css({<br />
                    width: Math.round(rx * 500) + 'px',<br />
                    height: Math.round(ry * realHeight) + 'px',<br />
                    marginLeft: '-' + Math.round(rx * coords.x) + 'px',<br />
                    marginTop: '-' + Math.round(ry * coords.y) + 'px'<br />
                });<br />
            }<br />
        <br />
<br />
        }<br />
<br />
		function initCut(){<br />
				//var api = $.Jcrop('#cropbox',{<br />
					//onChange: showPreview,<br />
					//onSelect: showPreview,<br />
					//init selection<br />
					//setSelect: [ 0, 0, 120, 120 ],<br />
					//Rate<br />
					//aspectRatio: 1<br />
				//});<br />
				<br />
				<br />
				//api.setOptions( {minSize: [ 40, 40],	maxSize: [ 120, 120]});alert("begin crop");<br />
<br />
				//api.setOptions({ allowResize: true });<br />
			}<br />
    </script><br />
</HEAD><br />
<br />
<BODY><br />
	<input id="btnBegin" type="button" value="Begin Crop" onclick="initCut();"/><br />
<br />
	<div class="article" style="border:thin #FF0000 solid;"><br />
        <br />
		<div style=" float:left;  border:thin; background-color:#FF0000;"><br />
            <img id="cropbox" src="images/jane.jpg" style=" width:500px;" /><br />
        </div><br />
<br />
        <div style=" width:120px; height:120px; overflow:hidden; float:left; margin-left:10px;"><br />
			<img id="preview" src="images/jane.jpg" /><br />
        </div><br />
            <br />
        <div style=" clear:both"></div><br />
    </div><br />
<br />
</BODY><br />
</HTML><br />

AnswerRe: Jcrop a jquery plug-in, has anybody used it ? Pin
Peace ON26-Apr-10 3:13
Peace ON26-Apr-10 3:13 
Questiontxt file template for Email Pin
FEMDEV25-Apr-10 23:48
FEMDEV25-Apr-10 23:48 
AnswerRe: txt file template for Email Pin
Jamil Hallal26-Apr-10 0:07
professionalJamil Hallal26-Apr-10 0:07 
GeneralRe: txt file template for Email Pin
FEMDEV26-Apr-10 1:04
FEMDEV26-Apr-10 1:04 
AnswerRe: txt file template for Email Pin
Sandesh M Patil26-Apr-10 0:45
Sandesh M Patil26-Apr-10 0:45 
QuestionTables in Web Site. Pin
Syasyaaa25-Apr-10 22:39
Syasyaaa25-Apr-10 22:39 
AnswerRe: Tables in Web Site. Pin
Ashfield25-Apr-10 22:43
Ashfield25-Apr-10 22:43 
AnswerRe: Tables in Web Site. Pin
Rijz25-Apr-10 22:46
Rijz25-Apr-10 22:46 
AnswerRe: Tables in Web Site. Pin
Tej Aj25-Apr-10 23:54
Tej Aj25-Apr-10 23:54 
AnswerRe: Tables in Web Site. Pin
Sandesh M Patil26-Apr-10 0:36
Sandesh M Patil26-Apr-10 0:36 
QuestionAsp to asp.net 2.0 migration Pin
Rijz25-Apr-10 22:37
Rijz25-Apr-10 22:37 
AnswerRe: Asp to asp.net 2.0 migration Pin
Vimalsoft(Pty) Ltd25-Apr-10 23:32
professionalVimalsoft(Pty) Ltd25-Apr-10 23:32 
GeneralRe: Asp to asp.net 2.0 migration Pin
Rijz26-Apr-10 0:21
Rijz26-Apr-10 0:21 
AnswerRe: Asp to asp.net 2.0 migration Pin
Jamil Hallal26-Apr-10 0:20
professionalJamil Hallal26-Apr-10 0:20 
AnswerRe: Asp to asp.net 2.0 migration Pin
Ankur\m/26-Apr-10 2:09
professionalAnkur\m/26-Apr-10 2:09 
GeneralRe: Asp to asp.net 2.0 migration Pin
Rijz29-Apr-10 0:07
Rijz29-Apr-10 0:07 
GeneralRe: Asp to asp.net 2.0 migration Pin
Ankur\m/29-Apr-10 0:12
professionalAnkur\m/29-Apr-10 0:12 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.