<?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: Scaling Images in a Web Viewer</title>
	<atom:link href="http://sixfriedrice.com/wp/scaling-images-in-a-web-viewer/feed/" rel="self" type="application/rss+xml" />
	<link>http://sixfriedrice.com/wp/scaling-images-in-a-web-viewer/</link>
	<description>smart business solutions</description>
	<lastBuildDate>Thu, 22 Mar 2012 11:56:17 -0500</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: David Zizza</title>
		<link>http://sixfriedrice.com/wp/scaling-images-in-a-web-viewer/comment-page-1/#comment-2047</link>
		<dc:creator>David Zizza</dc:creator>
		<pubDate>Wed, 30 Mar 2011 19:06:39 +0000</pubDate>
		<guid isPermaLink="false">http://sixfriedrice.com/wp/scaling-images-in-a-web-viewer/#comment-2047</guid>
		<description>The link to the above sample has change. To prevent insanity, use this link:

http://www.cimbura.com/tech/samplefiles/WebViewerImageResizing.zip</description>
		<content:encoded><![CDATA[<p>The link to the above sample has change. To prevent insanity, use this link:</p>
<p><a href="http://www.cimbura.com/tech/samplefiles/WebViewerImageResizing.zip" rel="nofollow">http://www.cimbura.com/tech/samplefiles/WebViewerImageResizing.zip</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tim Cimbura</title>
		<link>http://sixfriedrice.com/wp/scaling-images-in-a-web-viewer/comment-page-1/#comment-1929</link>
		<dc:creator>Tim Cimbura</dc:creator>
		<pubDate>Sun, 25 Apr 2010 22:07:59 +0000</pubDate>
		<guid isPermaLink="false">http://sixfriedrice.com/wp/scaling-images-in-a-web-viewer/#comment-1929</guid>
		<description>These are some good ideas and solutions to the problem of resizing an image in a web viewer presented here. I think there is a simpler way that is not limited to square images.

The technique uses a data URL to build an image that is resized by the browser. Check out the sample database found here:

http://www.cimbura.com/tech/samplefiles/WebViewerImageResizing.fp7.zip</description>
		<content:encoded><![CDATA[<p>These are some good ideas and solutions to the problem of resizing an image in a web viewer presented here. I think there is a simpler way that is not limited to square images.</p>
<p>The technique uses a data URL to build an image that is resized by the browser. Check out the sample database found here:</p>
<p><a href="http://www.cimbura.com/tech/samplefiles/WebViewerImageResizing.fp7.zip" rel="nofollow">http://www.cimbura.com/tech/samplefiles/WebViewerImageResizing.fp7.zip</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Matthew Richards</title>
		<link>http://sixfriedrice.com/wp/scaling-images-in-a-web-viewer/comment-page-1/#comment-1923</link>
		<dc:creator>Matthew Richards</dc:creator>
		<pubDate>Sun, 21 Mar 2010 06:08:05 +0000</pubDate>
		<guid isPermaLink="false">http://sixfriedrice.com/wp/scaling-images-in-a-web-viewer/#comment-1923</guid>
		<description>Thank you SO much for posting this very useful tutorial and code. It&#039;s been invaluable for my database project. A couple of things I noticed:

As Frank pointed out there are problems on some systems with the height scaling properly, and as Simon pointed out the doctype is to blame. I just removed it entirely leaving only the  header, seemed to fix the problem and not break anything.

My web viewer code looks like this:
&quot;http://yotoen.com/larkfiles/images/scale.html?&quot;&amp;Table::Image

&quot;Table::Image&quot; is actually another entire URL! e.g.
http://yotoen.com/larkfiles/images/sec2798.jpg

So this kind of stacking is possible - very useful when pulling things from other fields / generating URLs from multiple fields or strings.

Thanks again!</description>
		<content:encoded><![CDATA[<p>Thank you SO much for posting this very useful tutorial and code. It&#8217;s been invaluable for my database project. A couple of things I noticed:</p>
<p>As Frank pointed out there are problems on some systems with the height scaling properly, and as Simon pointed out the doctype is to blame. I just removed it entirely leaving only the  header, seemed to fix the problem and not break anything.</p>
<p>My web viewer code looks like this:<br />
&#8220;http://yotoen.com/larkfiles/images/scale.html?&#8221;&amp;Table::Image</p>
<p>&#8220;Table::Image&#8221; is actually another entire URL! e.g.<br />
<a href="http://yotoen.com/larkfiles/images/sec2798.jpg" rel="nofollow">http://yotoen.com/larkfiles/images/sec2798.jpg</a></p>
<p>So this kind of stacking is possible &#8211; very useful when pulling things from other fields / generating URLs from multiple fields or strings.</p>
<p>Thanks again!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Stephen</title>
		<link>http://sixfriedrice.com/wp/scaling-images-in-a-web-viewer/comment-page-1/#comment-1890</link>
		<dc:creator>Stephen</dc:creator>
		<pubDate>Sun, 24 Jan 2010 20:12:25 +0000</pubDate>
		<guid isPermaLink="false">http://sixfriedrice.com/wp/scaling-images-in-a-web-viewer/#comment-1890</guid>
		<description>Thanks for the great info, based on the original Javascript code at the very top and Simons comments on 2/10/08 this is my code I&#039;m using at the moment to display images from a web server in a FileMaker database:
-----------------------


    body { border: 0; margin: 0; } img {display: block; margin: 0 auto;}
    
        function resize_image() {
            var img = document.getElementsByTagName(&#039;img&#039;).item(0);
            if (img.offsetHeight &gt; img.offsetWidth) img.style.height = &#039;100%&#039;;
            else img.style.width = &#039;100%&#039;;
        }
    



    
        document.write(&quot;&quot;);
    
	


-----------------------
The last thing I&#039;d like to achieve it to remove the red cross icon when the image file does not exist.  I have a database which shows a main image and a secondary image of various items.  Not all items have a secondary image.  All the images live on a web server and are accessed by calling the above javascript code via the web viewer in my database using a base URL and then a filename based on a unique identifier (serial number) for each record.  Because all records are looking for a secondary image, when they are found it works great but when the image is not found I&#039;d just like to have a blank white box in the web viewer and not the red cross suggesting file not found.

Hope someone can help.

Thanks very much in advance.</description>
		<content:encoded><![CDATA[<p>Thanks for the great info, based on the original Javascript code at the very top and Simons comments on 2/10/08 this is my code I&#8217;m using at the moment to display images from a web server in a FileMaker database:<br />
&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;</p>
<p>    body { border: 0; margin: 0; } img {display: block; margin: 0 auto;}</p>
<p>        function resize_image() {<br />
            var img = document.getElementsByTagName(&#8217;img&#8217;).item(0);<br />
            if (img.offsetHeight &gt; img.offsetWidth) img.style.height = &#8216;100%&#8217;;<br />
            else img.style.width = &#8216;100%&#8217;;<br />
        }</p>
<p>        document.write(&#8221;");</p>
<p>&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;<br />
The last thing I&#8217;d like to achieve it to remove the red cross icon when the image file does not exist.  I have a database which shows a main image and a secondary image of various items.  Not all items have a secondary image.  All the images live on a web server and are accessed by calling the above javascript code via the web viewer in my database using a base URL and then a filename based on a unique identifier (serial number) for each record.  Because all records are looking for a secondary image, when they are found it works great but when the image is not found I&#8217;d just like to have a blank white box in the web viewer and not the red cross suggesting file not found.</p>
<p>Hope someone can help.</p>
<p>Thanks very much in advance.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Parker</title>
		<link>http://sixfriedrice.com/wp/scaling-images-in-a-web-viewer/comment-page-1/#comment-1843</link>
		<dc:creator>Parker</dc:creator>
		<pubDate>Fri, 16 Oct 2009 16:22:02 +0000</pubDate>
		<guid isPermaLink="false">http://sixfriedrice.com/wp/scaling-images-in-a-web-viewer/#comment-1843</guid>
		<description>This seems like the perfect solution to a problem we have with FMP 10 and web viewer.  We have an FMP db that dynamically accesses images from our website and displays them in an FMP client layout based on data in the layout.  The problem we have is that we can not control the size of the images in the web viewer and the images do not display the way we want them to.

The question I have is this:  Since we are not using an FMP web server, how do I use this code to control the image size in a web viewer on an FMP client layout?

Thanks for posting the info on this website, it&#039;s excellent.</description>
		<content:encoded><![CDATA[<p>This seems like the perfect solution to a problem we have with FMP 10 and web viewer.  We have an FMP db that dynamically accesses images from our website and displays them in an FMP client layout based on data in the layout.  The problem we have is that we can not control the size of the images in the web viewer and the images do not display the way we want them to.</p>
<p>The question I have is this:  Since we are not using an FMP web server, how do I use this code to control the image size in a web viewer on an FMP client layout?</p>
<p>Thanks for posting the info on this website, it&#8217;s excellent.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Edward Souza</title>
		<link>http://sixfriedrice.com/wp/scaling-images-in-a-web-viewer/comment-page-1/#comment-1834</link>
		<dc:creator>Edward Souza</dc:creator>
		<pubDate>Sat, 15 Aug 2009 19:36:11 +0000</pubDate>
		<guid isPermaLink="false">http://sixfriedrice.com/wp/scaling-images-in-a-web-viewer/#comment-1834</guid>
		<description>I&#039;m sorry for the lateness of this post.
I read some of the questions regarding Google Maps, and there are ways to have it embedded in webviewer at any size.
Instead of embedding the map Dynamically, you may choose to have it statically. Using it this way, you are able to specify its size (in pixels), zoom level, and so forth, and it will abide to your given parameters. The only catch is: you need to use the location&#039;s geodesic coordinates (latitude and longitude) with its value in decimal degrees.
For those who want to try it right way, here is a basic code:

http://maps.google.com/staticmap?center=40.714728,-73.998672&amp;zoom=14&amp;size=512x512&amp;key=MAPS_API_KEY&amp;sensor=false

where:

- &quot;center&quot; is the location in decimal degrees
- &quot;size&quot; is the map size (it should fit the dimensions of webviewer window)
- &quot;zoom&quot; is the zoom level desired (from 1 - furthest to 19 - closest)
- MAPS_API_KEY is a Goggle Maps API key you or your client should have. Google measures the maps and static maps traffic through this.

There are several more parameters that can be used and played with -- you may use location points within the map (using decimal degree coordinates), draw lines from one point to another, and so forth.

For a more detailed look, please refer to &quot;http://code.google.com/apis/maps/documentation/staticmaps/&quot;.

On a final note, when using Google static maps, i often disable webviewer&#039;s options, such as &quot;Allow Interaction With WebViewer Content,&quot; &quot;Display Progress Bar,&quot; and &quot;Display Status Messages.&quot; That way I ensure the map will display at its full size.

I hope this may be of any help to you.

E*</description>
		<content:encoded><![CDATA[<p>I&#8217;m sorry for the lateness of this post.<br />
I read some of the questions regarding Google Maps, and there are ways to have it embedded in webviewer at any size.<br />
Instead of embedding the map Dynamically, you may choose to have it statically. Using it this way, you are able to specify its size (in pixels), zoom level, and so forth, and it will abide to your given parameters. The only catch is: you need to use the location&#8217;s geodesic coordinates (latitude and longitude) with its value in decimal degrees.<br />
For those who want to try it right way, here is a basic code:</p>
<p><a href="http://maps.google.com/staticmap?center=40.714728,-73.998672&amp;zoom=14&amp;size=512x512&amp;key=MAPS_API_KEY&amp;sensor=false" rel="nofollow">http://maps.google.com/staticmap?center=40.714728,-73.998672&amp;zoom=14&amp;size=512&#215;512&amp;key=MAPS_API_KEY&amp;sensor=false</a></p>
<p>where:</p>
<p>- &#8220;center&#8221; is the location in decimal degrees<br />
- &#8220;size&#8221; is the map size (it should fit the dimensions of webviewer window)<br />
- &#8220;zoom&#8221; is the zoom level desired (from 1 &#8211; furthest to 19 &#8211; closest)<br />
- MAPS_API_KEY is a Goggle Maps API key you or your client should have. Google measures the maps and static maps traffic through this.</p>
<p>There are several more parameters that can be used and played with &#8212; you may use location points within the map (using decimal degree coordinates), draw lines from one point to another, and so forth.</p>
<p>For a more detailed look, please refer to &#8220;http://code.google.com/apis/maps/documentation/staticmaps/&#8221;.</p>
<p>On a final note, when using Google static maps, i often disable webviewer&#8217;s options, such as &#8220;Allow Interaction With WebViewer Content,&#8221; &#8220;Display Progress Bar,&#8221; and &#8220;Display Status Messages.&#8221; That way I ensure the map will display at its full size.</p>
<p>I hope this may be of any help to you.</p>
<p>E*</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Geoff Coffey</title>
		<link>http://sixfriedrice.com/wp/scaling-images-in-a-web-viewer/comment-page-1/#comment-1824</link>
		<dc:creator>Geoff Coffey</dc:creator>
		<pubDate>Tue, 28 Jul 2009 20:01:39 +0000</pubDate>
		<guid isPermaLink="false">http://sixfriedrice.com/wp/scaling-images-in-a-web-viewer/#comment-1824</guid>
		<description>Edward:

Sorry for the slow response. I was on vacation. I really must confess I know very little about Flash. You might take a look at:

http://fusionplugins.com/reactor/

But I&#039;ve never used it myself. Please post back if you find any good answers!

Thanks,

Geoff</description>
		<content:encoded><![CDATA[<p>Edward:</p>
<p>Sorry for the slow response. I was on vacation. I really must confess I know very little about Flash. You might take a look at:</p>
<p><a href="http://fusionplugins.com/reactor/" rel="nofollow">http://fusionplugins.com/reactor/</a></p>
<p>But I&#8217;ve never used it myself. Please post back if you find any good answers!</p>
<p>Thanks,</p>
<p>Geoff</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Edward Souza</title>
		<link>http://sixfriedrice.com/wp/scaling-images-in-a-web-viewer/comment-page-1/#comment-1819</link>
		<dc:creator>Edward Souza</dc:creator>
		<pubDate>Sat, 18 Jul 2009 20:48:09 +0000</pubDate>
		<guid isPermaLink="false">http://sixfriedrice.com/wp/scaling-images-in-a-web-viewer/#comment-1819</guid>
		<description>Hello, Geoff, and hello all,

First, let me say this is an excellent blog -- the material posted here is precious and allow many to learn the inner mechanics of FileMaker. Mr. Coffey has once helped me personally with an asinine error I made. Although he is an busy person, he was nothing but sheer help to me. Thanks for your posts and assistance, Mr. Coffey. :)
Some questions regarding FMP 10 Advanced, OS X 10.4.11, and Adobe Flash:
1. Is it possible to use Flash movies (.swf) from within [b]local discs[/b] using WebViewer? For example, if I&#039;ve developed a series of buttons and graphics in Flash which are stored in the same folder as my solution (instead of in an URL), is it possible to embed them FileMaker using WebViewer?
2. In case it is possible, does the .swf have to be embed in an HTML page in order to work?
3. Can Flash buttons trigger FMP scripts -- perhaps via XML or an external scripting language (in OS X&#039;s case, AppleScript)?

I know there are some references in the Internet about Flash and FMP interaction; however, the material I could gather does not make any specific reference to WebViewer, and that probably is a logical way to make both &quot;worlds&quot; interact.

Once again, thank you for everything.

E*</description>
		<content:encoded><![CDATA[<p>Hello, Geoff, and hello all,</p>
<p>First, let me say this is an excellent blog &#8212; the material posted here is precious and allow many to learn the inner mechanics of FileMaker. Mr. Coffey has once helped me personally with an asinine error I made. Although he is an busy person, he was nothing but sheer help to me. Thanks for your posts and assistance, Mr. Coffey. <img src='http://sixfriedrice.com/wp/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /><br />
Some questions regarding FMP 10 Advanced, OS X 10.4.11, and Adobe Flash:<br />
1. Is it possible to use Flash movies (.swf) from within [b]local discs[/b] using WebViewer? For example, if I&#8217;ve developed a series of buttons and graphics in Flash which are stored in the same folder as my solution (instead of in an URL), is it possible to embed them FileMaker using WebViewer?<br />
2. In case it is possible, does the .swf have to be embed in an HTML page in order to work?<br />
3. Can Flash buttons trigger FMP scripts &#8212; perhaps via XML or an external scripting language (in OS X&#8217;s case, AppleScript)?</p>
<p>I know there are some references in the Internet about Flash and FMP interaction; however, the material I could gather does not make any specific reference to WebViewer, and that probably is a logical way to make both &#8220;worlds&#8221; interact.</p>
<p>Once again, thank you for everything.</p>
<p>E*</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jeffrey A Grunschel</title>
		<link>http://sixfriedrice.com/wp/scaling-images-in-a-web-viewer/comment-page-1/#comment-1758</link>
		<dc:creator>Jeffrey A Grunschel</dc:creator>
		<pubDate>Thu, 16 Apr 2009 19:53:29 +0000</pubDate>
		<guid isPermaLink="false">http://sixfriedrice.com/wp/scaling-images-in-a-web-viewer/#comment-1758</guid>
		<description>@v and Geoff

When you get a map from google, there is a way to generate a link to the map or embed the map, by pasting the HTML code into your webpage&#039;s code.  If you poke around and play with the embedded html code, and use the trick that Geoff mentioned in another post*, you can accomplish the task you asked about...generating a map that is just a map and nothing else.

*http://sixfriedrice.com/wp/filemaker-9-tip9-web-viewers-without-the-web/

My question is, does anyone know if using this embedded HTML code is the same as using the google map API that was mentioned?  I ask, because I&#039;m working on a solution that embeds a google map into a web viewer, and when I&#039;m finished, the solution will not be free.  Ergo, I don&#039;t want to unknowingly use something that isn&#039;t free, i.e., steal it.</description>
		<content:encoded><![CDATA[<p>@v and Geoff</p>
<p>When you get a map from google, there is a way to generate a link to the map or embed the map, by pasting the HTML code into your webpage&#8217;s code.  If you poke around and play with the embedded html code, and use the trick that Geoff mentioned in another post*, you can accomplish the task you asked about&#8230;generating a map that is just a map and nothing else.</p>
<p>*http://sixfriedrice.com/wp/filemaker-9-tip9-web-viewers-without-the-web/</p>
<p>My question is, does anyone know if using this embedded HTML code is the same as using the google map API that was mentioned?  I ask, because I&#8217;m working on a solution that embeds a google map into a web viewer, and when I&#8217;m finished, the solution will not be free.  Ergo, I don&#8217;t want to unknowingly use something that isn&#8217;t free, i.e., steal it.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: raphael</title>
		<link>http://sixfriedrice.com/wp/scaling-images-in-a-web-viewer/comment-page-1/#comment-1694</link>
		<dc:creator>raphael</dc:creator>
		<pubDate>Thu, 26 Feb 2009 13:36:01 +0000</pubDate>
		<guid isPermaLink="false">http://sixfriedrice.com/wp/scaling-images-in-a-web-viewer/#comment-1694</guid>
		<description>In addition, I tried several things and it seems that img.style.height = ‘100%’ never works (img.style.width = ‘100%’ works perfectly).</description>
		<content:encoded><![CDATA[<p>In addition, I tried several things and it seems that img.style.height = ‘100%’ never works (img.style.width = ‘100%’ works perfectly).</p>
]]></content:encoded>
	</item>
</channel>
</rss>

