<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Cropping Images using DHTML (Prototype) and symfony</title>
	<atom:link href="http://spindrop.us/2006/09/16/cropping-images-using-dhtml-prototype-and-symfony/feed/" rel="self" type="application/rss+xml" />
	<link>http://spindrop.us/2006/09/16/cropping-images-using-dhtml-prototype-and-symfony/</link>
	<description>look at all this code you don't have to write</description>
	<lastBuildDate>Thu, 04 Mar 2010 08:43:44 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Steve Conley</title>
		<link>http://spindrop.us/2006/09/16/cropping-images-using-dhtml-prototype-and-symfony/comment-page-1/#comment-291469</link>
		<dc:creator>Steve Conley</dc:creator>
		<pubDate>Sun, 14 Jun 2009 22:34:49 +0000</pubDate>
		<guid isPermaLink="false">http://spindrop.us/2006/09/16/cropping-images-using-dhtml-prototype-and-symfony/#comment-291469</guid>
		<description>&lt;p&gt;Because there&#039;s some demand out there for a packaged version of this, I&#039;ve made one!  My package wraps this in a class that isn&#039;t symfony dependent.&lt;/p&gt;

&lt;p&gt;http://www.tanabi.com/projects/cropper&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>Because there&#8217;s some demand out there for a packaged version of this, I&#8217;ve made one!  My package wraps this in a class that isn&#8217;t symfony dependent.</p>

<p><a href="http://www.tanabi.com/projects/cropper" rel="nofollow">http://www.tanabi.com/projects/cropper</a></p>]]></content:encoded>
	</item>
	<item>
		<title>By: Aleksey</title>
		<link>http://spindrop.us/2006/09/16/cropping-images-using-dhtml-prototype-and-symfony/comment-page-1/#comment-107866</link>
		<dc:creator>Aleksey</dc:creator>
		<pubDate>Wed, 28 May 2008 23:31:07 +0000</pubDate>
		<guid isPermaLink="false">http://spindrop.us/2006/09/16/cropping-images-using-dhtml-prototype-and-symfony/#comment-107866</guid>
		<description>&lt;p&gt;Problem in transparency for “ava_overlay”&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>Problem in transparency for “ava_overlay”</p>]]></content:encoded>
	</item>
	<item>
		<title>By: Aleksey</title>
		<link>http://spindrop.us/2006/09/16/cropping-images-using-dhtml-prototype-and-symfony/comment-page-1/#comment-107865</link>
		<dc:creator>Aleksey</dc:creator>
		<pubDate>Wed, 28 May 2008 23:30:05 +0000</pubDate>
		<guid isPermaLink="false">http://spindrop.us/2006/09/16/cropping-images-using-dhtml-prototype-and-symfony/#comment-107865</guid>
		<description>&lt;p&gt;Hi, thank you very much autor for this work. Very introsting. But this havn&#039;t been working in IE6. :-(. Problem in transparency for &quot;&quot;. Maybe somebody solved this proble.&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>Hi, thank you very much autor for this work. Very introsting. But this havn&#8217;t been working in IE6. <img src='http://spindrop.us/wp-includes/images/smilies/icon_sad.gif' alt=':-(' class='wp-smiley' /> . Problem in transparency for &#8220;&#8221;. Maybe somebody solved this proble.</p>]]></content:encoded>
	</item>
	<item>
		<title>By: Simbiotica :: Cropping Images using DHTML (Prototype) and symfony at Spindrop</title>
		<link>http://spindrop.us/2006/09/16/cropping-images-using-dhtml-prototype-and-symfony/comment-page-1/#comment-55867</link>
		<dc:creator>Simbiotica :: Cropping Images using DHTML (Prototype) and symfony at Spindrop</dc:creator>
		<pubDate>Wed, 24 Oct 2007 08:39:30 +0000</pubDate>
		<guid isPermaLink="false">http://spindrop.us/2006/09/16/cropping-images-using-dhtml-prototype-and-symfony/#comment-55867</guid>
		<description>&lt;p&gt;[...] Read more :: http://spindrop.us/2006/09/16/cropping-images-using-dhtml-prototype-and-symfony/ [...]&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>[...] Read more :: <a href="http://spindrop.us/2006/09/16/cropping-images-using-dhtml-prototype-and-symfony/" rel="nofollow">http://spindrop.us/2006/09/16/cropping-images-using-dhtml-prototype-and-symfony/</a> [...]</p>]]></content:encoded>
	</item>
	<item>
		<title>By: léonie</title>
		<link>http://spindrop.us/2006/09/16/cropping-images-using-dhtml-prototype-and-symfony/comment-page-1/#comment-48029</link>
		<dc:creator>léonie</dc:creator>
		<pubDate>Thu, 30 Aug 2007 10:17:34 +0000</pubDate>
		<guid isPermaLink="false">http://spindrop.us/2006/09/16/cropping-images-using-dhtml-prototype-and-symfony/#comment-48029</guid>
		<description>&lt;p&gt;Can you please upload the corresponding php file(s)? Or am I missing something? I really digg your script. There are a couple others around, but I like the idea of the interface.&lt;/p&gt;

&lt;p&gt;Just for others to be up to date of what is around and works in most browsers:&lt;/p&gt;

&lt;p&gt;http://199.199.212.26/demo/
http://mondaybynoon.com/examples/image&lt;em&gt;crop&lt;/em&gt;resize/&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>Can you please upload the corresponding php file(s)? Or am I missing something? I really digg your script. There are a couple others around, but I like the idea of the interface.</p>

<p>Just for others to be up to date of what is around and works in most browsers:</p>

<p><a href="http://199.199.212.26/demo/" rel="nofollow">http://199.199.212.26/demo/</a>
<a href="http://mondaybynoon.com/examples/image" rel="nofollow">http://mondaybynoon.com/examples/image</a><em>crop</em>resize/</p>]]></content:encoded>
	</item>
	<item>
		<title>By: NP</title>
		<link>http://spindrop.us/2006/09/16/cropping-images-using-dhtml-prototype-and-symfony/comment-page-1/#comment-45782</link>
		<dc:creator>NP</dc:creator>
		<pubDate>Mon, 20 Aug 2007 15:03:16 +0000</pubDate>
		<guid isPermaLink="false">http://spindrop.us/2006/09/16/cropping-images-using-dhtml-prototype-and-symfony/#comment-45782</guid>
		<description>&lt;p&gt;Could you please make a archive with the full functional code? I&#039;m really having a hard time setting this up.&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>Could you please make a archive with the full functional code? I&#8217;m really having a hard time setting this up.</p>]]></content:encoded>
	</item>
	<item>
		<title>By: Ignacio</title>
		<link>http://spindrop.us/2006/09/16/cropping-images-using-dhtml-prototype-and-symfony/comment-page-1/#comment-44071</link>
		<dc:creator>Ignacio</dc:creator>
		<pubDate>Wed, 08 Aug 2007 05:04:15 +0000</pubDate>
		<guid isPermaLink="false">http://spindrop.us/2006/09/16/cropping-images-using-dhtml-prototype-and-symfony/#comment-44071</guid>
		<description>&lt;p&gt;I did it!
imagecopyresampled ( $final, $im, 0, 0, 17, 17, 160, 160, 160, 160 );
17 = Margin of the overlay, sure!&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>I did it!
imagecopyresampled ( $final, $im, 0, 0, 17, 17, 160, 160, 160, 160 );
17 = Margin of the overlay, sure!</p>]]></content:encoded>
	</item>
	<item>
		<title>By: Ignacio</title>
		<link>http://spindrop.us/2006/09/16/cropping-images-using-dhtml-prototype-and-symfony/comment-page-1/#comment-44064</link>
		<dc:creator>Ignacio</dc:creator>
		<pubDate>Wed, 08 Aug 2007 04:30:14 +0000</pubDate>
		<guid isPermaLink="false">http://spindrop.us/2006/09/16/cropping-images-using-dhtml-prototype-and-symfony/#comment-44064</guid>
		<description>&lt;p&gt;I passed 2 days trying to change this... I don&#039;t want 80x80, I want 160x160, nothing happen... :(&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>I passed 2 days trying to change this&#8230; I don&#8217;t want 80&#215;80, I want 160&#215;160, nothing happen&#8230; <img src='http://spindrop.us/wp-includes/images/smilies/icon_sad.gif' alt=':(' class='wp-smiley' /> </p>]]></content:encoded>
	</item>
	<item>
		<title>By: dungpt</title>
		<link>http://spindrop.us/2006/09/16/cropping-images-using-dhtml-prototype-and-symfony/comment-page-1/#comment-40025</link>
		<dc:creator>dungpt</dc:creator>
		<pubDate>Mon, 02 Jul 2007 12:12:59 +0000</pubDate>
		<guid isPermaLink="false">http://spindrop.us/2006/09/16/cropping-images-using-dhtml-prototype-and-symfony/#comment-40025</guid>
		<description>&lt;p&gt;omg, i&#039;m crazing with it :(&lt;/p&gt;

&lt;p&gt;here&#039;s my problem&lt;/p&gt;

&lt;p&gt;http://www.sitepoint.com/forums/showthread.php?t=475618&lt;/p&gt;

&lt;p&gt;i can&#039;t create image ok with 48x48 pixels&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>omg, i&#8217;m crazing with it <img src='http://spindrop.us/wp-includes/images/smilies/icon_sad.gif' alt=':(' class='wp-smiley' /> </p>

<p>here&#8217;s my problem</p>

<p><a href="http://www.sitepoint.com/forums/showthread.php?t=475618" rel="nofollow">http://www.sitepoint.com/forums/showthread.php?t=475618</a></p>

<p>i can&#8217;t create image ok with 48&#215;48 pixels</p>]]></content:encoded>
	</item>
	<item>
		<title>By: Developerz</title>
		<link>http://spindrop.us/2006/09/16/cropping-images-using-dhtml-prototype-and-symfony/comment-page-1/#comment-35484</link>
		<dc:creator>Developerz</dc:creator>
		<pubDate>Thu, 14 Jun 2007 06:10:49 +0000</pubDate>
		<guid isPermaLink="false">http://spindrop.us/2006/09/16/cropping-images-using-dhtml-prototype-and-symfony/#comment-35484</guid>
		<description>&lt;p&gt;Hi Dave,&lt;/p&gt;

&lt;p&gt;Thanks so much for sharing this example.  I just got done implementing it in C#. Let&#039;s just say I&#039;m pretty stoked for figure it all out.&lt;/p&gt;

&lt;p&gt;I did find one bug in the javascript &quot;function setupAva&quot;&lt;/p&gt;

&lt;p&gt;The problem occurs when a user uploads a landscape image (width is greater than height), and does not use the handle.onDrag .  If they don&#039;t the ava_width returns 80, which will throw off the proportion.&lt;/p&gt;

&lt;p&gt;So what I did to fix this bug was set the was to set: ava&lt;em&gt;width.value = new&lt;/em&gt;w;&lt;/p&gt;

&lt;p&gt;Here&#039;s a portion of the function setupAva that shows where I&#039;ve added &quot;ava&lt;em&gt;width.value = new&lt;/em&gt;w;&quot;&lt;/p&gt;

&lt;p&gt;var ratio = (start&lt;em&gt;h / start&lt;/em&gt;w);
            var new&lt;em&gt;h;
            var new&lt;/em&gt;w;
            if (ratio &gt; 1) {
                new&lt;em&gt;w = 80;
                new&lt;/em&gt;h = (80&lt;em&gt;start&lt;em&gt;h)/start&lt;/em&gt;w;
            } else {
                new&lt;em&gt;h = 80;
                new&lt;/em&gt;w = (80&lt;/em&gt;start&lt;em&gt;w)/start&lt;/em&gt;h;
            }&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;        // set the ava_width.value here in case the user does not use the handle.onDrag function, if you don&#039;t landscape images get cropped with a small height
        ava_width.value = new_w;

        // these need to be set after we init
        avatarImg.style.top = &#039;100px&#039;;
        avatarImg.style.left = &#039;100px&#039;;
        avatarImg.style.width = new_w   &#039;px&#039;;
        avatarImg.style.height = new_h   &#039;px&#039;;
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;Anyway, thanks again and hopefully this helps someone.&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>Hi Dave,</p>

<p>Thanks so much for sharing this example.  I just got done implementing it in C#. Let&#8217;s just say I&#8217;m pretty stoked for figure it all out.</p>

<p>I did find one bug in the javascript &#8220;function setupAva&#8221;</p>

<p>The problem occurs when a user uploads a landscape image (width is greater than height), and does not use the handle.onDrag .  If they don&#8217;t the ava_width returns 80, which will throw off the proportion.</p>

<p>So what I did to fix this bug was set the was to set: ava<em>width.value = new</em>w;</p>

<p>Here&#8217;s a portion of the function setupAva that shows where I&#8217;ve added &#8220;ava<em>width.value = new</em>w;&#8221;</p>

<p>var ratio = (start<em>h / start</em>w);
            var new<em>h;
            var new</em>w;
            if (ratio &gt; 1) {
                new<em>w = 80;
                new</em>h = (80<em>start</em><em>h)/start</em>w;
            } else {
                new<em>h = 80;
                new</em>w = (80start<em>w)/start</em>h;
            }</p>

<pre><code>        // set the ava_width.value here in case the user does not use the handle.onDrag function, if you don't landscape images get cropped with a small height
        ava_width.value = new_w;

        // these need to be set after we init
        avatarImg.style.top = '100px';
        avatarImg.style.left = '100px';
        avatarImg.style.width = new_w   'px';
        avatarImg.style.height = new_h   'px';
</code></pre>

<p>Anyway, thanks again and hopefully this helps someone.</p>]]></content:encoded>
	</item>
</channel>
</rss>
