FeaturePics API Demo - Silverlight Update

I have previously blogged about how to use Silverlight 2.0 Beta to create a FeaturePics API demo.

FeaturePics API Demo - Part 1
FeaturePics API Demo - Part 2

On 10/14 Silverlight 2.0 was released with various breaking changes from the Beta as documented on this Silverlight Blog.

As you know from FeaturePics API Demo - Part 1, this demo was a modification of Scott Guthrie's eight part tutorial Silverlight 2 End to End Tutorial: Building a Digg Search Client, which has also been updated to Silverlight 2.0. My update has once again followed Scott's lead in that he replaced the discontinued  WatermarkTextBox Control with a simple TextBox control, and I have done the same. This caused the helpful disappearing text in the TextBox to no longer appear, which is the only obvious change.

There are a few additional changes that are documented in Silverlight Blog. The ones I made are as follows:

Breaking Change #1. Your Web Page.

If you have a project already developed for beta-1 or beta-2 you will need to make an adjustment to your web page that hosts the Silverlight control. For an HTML page change you will need to change the MIME type. To do this, open your HTML Page, change “x-silverlight-2-b1” or “application/x-silverlight-2-b2” to “application/x-silverlight-2”.

<object data="data:application/x-silverlight-2," type="application/x-silverlight-2" width="100%" height="100%">

Breaking Change #4. Cross Domain Hosts.

Cross domain hosts of Silverlight must set the right MIME type for XAP (application/x-silverlight-app)

Breaking Change #16. ContentPresenter and ContentControl.

The following properties were removed from ContentPresenter and ContentControl:

  • TextAlignment
  • TextDecorations
  • TextWrapping

The URL remains the same: FeaturePics API Demo. This one does not work on the MAC.

A somewhat simpler page is at: FeaturePics API Demo - Simple Page.  This one does work on the MAC. The only difference is in the html page containing the control.

19. October 2008 01:30 by Kal | Comments (0) | Permalink

MAC Woes - FeaturePics API Demo

I did a couple of posts about creating a Silverlight demo of the FeaturePics API.

The final sample is at : http://enermeter.com/fpDemo/apidemo.html.

Reports soon came in that the page would not run on either Safari nor FireFox on the MAC. So I put the same control on a page with less HTML and CSS, and I have been told that it works this way. Go figure. But hey, I am sure people who prepare pages for the MAC can work out how to embed this control on their page if they are so inclined. Here is the simplified version: http://enermeter.com/fpDemo/apidemo-MAC.html

5. September 2008 12:17 by Kal | Comments (0) | Permalink

FeaturePics API Demo

FeaturePics has released an api (application programming interface) that allows images on the FeaturePics web site to be used on your web site. There are various api options available that you can see described at http://www.featurepics.com/API/Search.aspx. I was aware of the api, but had not seen it in action. < /p>

I have also been hearing a lot about Microsoft Silverlight that is in the second beta release, but really knew nothing about it. Reports have  it that it will work on any browser and has only about a 4k download to install on the client computer, and the download only needs to be installed once,  the first time a Silverlight app is run. So when I found a small tutorial demonstrating how to use Silverlight in a client application, I decided to take the plunge. < /p>

The tutorial was pretty straightforward and the result was impressive. No problem at all until I tried to run the code and it did not work. It turned out to be a difference between beta 1 and beta 2. I wrote a blog post about how to resolve that issue. < /p>

http://enermeter.com/post/2008/08/16/Simple-Silverlight-2-app-APIDemo-Part-1-Building-the-DiggSample.aspx < /p>

While working out the Digg example in the tutorial I thought it might be modified a bit to show how the recently released FeaturePics api could be used in a web application. I made the changes and wrote a second blog post about doing so, including the source code I used to make the application. < /p>

http://enermeter.com/post/2008/08/28/Simple-Silverlight-2-app-APIDemo-Part-2-Building-the-FeaturePics-API-Demo.aspx < /p>

If you are not a programmer and have little or no interest in this type of technology, you might still be interested to see the page as it turned out. It allows you to search all of the FeaturePics images by keyword, and returns a set of thirty image thumbnails that result. Please note that the set of thumbs in my demo can range from zero to thirty, while the actual number at FeaturPics may be much greater than thirty. When you click on one of them you get a brief summary of the image and a link back to FeaturePics. < /p>

You can see the completed demo application here: http://enermeter.com/fpDemo/apidemo.html. < /p>

1. September 2008 16:49 by kal | Comments (0) | Permalink

Calendar

<<  July 2010  >>
MoTuWeThFrSaSu
2829301234
567891011
12131415161718
19202122232425
2627282930311
2345678

View posts in large calendar