Why Even Bother: Part II

18 March 2010 , ,    8 Comments

Where is part one? Well a few months ago, Brendan wrote part one outlining the frustration we feel about everybody loving the "big boys" in the Twitter client space, never giving the smaller, (seemingly) the non-VC funded, open source clients a chance to shine.

It’s happened again, but this time its worse. Seesmic were yet again presenting at a major Microsoft conference (MIX10), banging on about how they got early access to the WinPhone7 Series hardware and SDK – how wonderful, another platform we simply can’t compete with because come day one, they’ll have not only had the emulator for longer, but physical devices to try everything on. And if we were to move to WP7S, we’d have to break the mindset of everybody who saw MIX/associated articles that "WP7S + Twitter = Seesmic". They are in the phone from before day one.  You just can’t compete against that.

Oh, and something about updated desktop client that will include plugins – turns out via MEF, just like us. The one consolation I have is that all those promised features they keep banging on about – we’ve got them today. Now. 3 months ago. Not "in the near future" (anybody seen their iPhone client they promised? oh wait, doesn’t exist)

However the final crushing blow came when news broke that Silverlight (in beta form?) has now been released on Nokia’s S60 platform – and guess what the two example apps are? Bing and Seesmic.

Unlike Brendan, I’m not venting at the general noisy ‘industry’ and how hard it is to get a break, but how the favourites of PDC will continue being the favourites on every platform Microsoft releases, so long as Microsoft keep handing out early access to the same developer again and again. This isn’t so much about MahTweets, but the frustration that Microsoft pick a favourite and will run forever with them – what about the other, smaller clients in this field? Where is the love for Witty, Blu, Halfwit, Sobees, or Gadfly?

It feels less like "Developers, Developers, Developers" and more like "Developers – those guys, the rest of you don’t matter"

Why even bother?

After MahTweets 3 (which is a very major version/update), I won’t be bothering – I’ll be getting out of the "game". MahTweets will be maintained/major bug fixes, the others may continue working on it, but I have no more interest in creating Twitter clients.

Why is it so personal?

For lack of a better cliché, I am MahTweets. I don’t mean to diminish the role or contributions of others, far from it, when I say I am MahTweets, I mean that I’ve poured a lot of myself into it, I’m the public face, I’m the "overlord", I started the project. For the others, it’s a pet project – for me, I’m disabled and unable to get a ‘real job’ – it’s as close to a job as I’ll have for a long time.


 

How I almost was a Code7 Runner Up

27 November 2009 , , ,    5 Comments

Microsoft ran a programming contest a few months ago called Code7 – the idea is you’d code up an app with specific support for Windows 7 – things like touch, location, taskbar improvements, etc. All you had to do was submit a (up to) 3 minute screencast of your app. The prizes were pretty awesome too, first place is trip to PDC09 + $17,777USD. Regional winners get trip to PDC09 + $7,777USD, and regional runners up get a $1000USD laptop.

Well, I fell into the latter category – that is, I was told I was a regional runner up – awesome eh? My entry was MahTweets, which has support for geocoding photos for Flickr using the Win7 Location platform, as well as taskbar enhancements.

When I say I was told I was a runner up, I mean that I was notified I’d win the prize if I completed certain forms, which I did instantly. Then I was told they’d send out the physical forms, since apparently electronically filling them in isn’t enough. Once the deadlines for submitting those forms came and went without the forms even arriving, I was a little concerned. Turns out Microsoft Legal Counsel decided it was "concerned about the use of the real status feeds from the various social media sites, use of the Flickr website" (emphasis mine – there was more stuff about logos of the various services featured, but that’s relatively minor)

Just to recap, I submitted a screencast of MahTweets, showing some of functions it does with tweets as well as uploading and geotagging a webcam picture (of my ugly mug) to Flickr. Because I featured my Flickr profile, Microsoft Legal Counsel was concerned that I didn’t have permission from Yahoo to use a screenshot of Flickr. Right. To be honest, it wasn’t until I started drafting up this post that I even noticed the Flickr crap – I’ve been more concerned with the "real status feeds".

Firstly, what the hell is a ‘real status feed‘? I asked for clarification on what they meant – and it took twelve days to get a response - turns out that’s just what normal people would call a tweet. I’d say ‘social media network update’, but I only showed off Twitter functionality. MSFT Legal wanted permission from every identifiable twit in the video. "Okay, sure, that’s do-able" I thought, "there is only about eight or nine people who actually have tweets/avatars being shown off".

Turns out that no, I was wrong, they want not only consent from those people, but from any handle visible – so if XYZ wrote "hello @foo", I’d have to get consent from "@foo" as well – as well as all the names visible when I demonstrated building a group/column. Once I got the final bit of clarification, I just gave up, as the number of people I needed consent from was reaching 40+. A big thank you for those who did give me consent when I thought it was still eight or nine people.

The most frustrating bit about this is the way it was set up to be a disappointment – if they had of opened with "hey, if you can clarify XYZ legal situation, we’ll award you a prize" that would have been cool, but the "hey, you’ve won! fill in a form!" then waiting a few days (as it took that long for each email response) to find out there were more concerns just left a bitter taste in my mouth.


 

What Games For Windows Live needs to do to become relevant

25 October 2009 , ,    No Comments

It is undeniable that Microsoft’s Xbox Live Gaming service is regarded as pretty damn good – it has something like 17 million members, and all games on the Xbox 360 integrate into with it.

In the PC world, the bastard cousin of Xbox Live, Games For Windows Live (GFWL), has not fared so well. Only a handful of games make use of the service, and those that do usually suffer because of it. Original adoption of GFWL was always going to be poor – the service launched as a paid subscription service for both the developers and the end user – and in the PC world known for free gaming, that just wasn’t going to cut it. Thankfully late last year with the release of GFW v2, it was made free for both developers and end users – who now get access to all features (like the theoretical-but-in-reality-non-existent Xbox360 <-> PC gaming).

So why has GFWL still fared so poorly despite now being free? Because there is no value to it. I should clarify that. There are features offered by GFWL, but they don’t equate to much because of how poorly implemented or supported they are. The features offered by GFWL are:

In the desktop (or "out of game") client all you can do is connect to the marketplace – it is a glorified web browser. However there is so little content there is no reason you’d use the GFWL marketplace – seven demos, videos of games, and a few addons (although five of those are for Fallout!) You can’t purchase full games – there is no reason to use this over Steam!

gfwlsigning

The above screenshot is the login screen for the desktop GFWL client – look familiar? It should, it looks like the Windows Live Mesesnger login screen with a different skin applied to it. Surely this desktop client lets you talk to your LIVE friends? Nope! What about at least add/remove friends? Nope! The only way you can manage your friends is through a webpage (www.xbox.com) or through an XBox or XBox 360.

The isolated nature of LIVE friends and Live Messenger contacts lets far inferior chat networks/clients such as Steam or Xfire take over (inferior in terms of people on the networks and chat client features such as logging and less uglyness)

What Microsoft needs to do so that this is no longer taken as a joke is

  1. Turn the desktop client into more than a glorified browser – make it a chat client too.
    Until you can talk to your LIVE friends at the desktop, the benefits of GFWL in game are also reduced.
  2. Make the desktop client also talk to Messenger network and Messenger network talk to the "LIVE" network
    If the two clients talked to the same networks, you could choose what IM client you wanted to use (ie, a gamer-centric client, or a general chat client). Perhaps the gamer-centric client could do in game overlays ala XFire/Steam (but not require them to be GFW/GFWL titles)
  3. Get some content
    Chicken and egg situation – not going to get the content there until it has the userbase, but the userbase is never going to move from Steam or other systems unless the content is there (which is why Steam had such a hard time when it started up).

 

Zune sums up everything I hate about Microsoft

16 September 2009 , ,    9 Comments

image

With yesterdays launch of the Zune HD’s and the new Zune Software (4.0), it didn’t take me long to realise everything I hate about Microsoft can be summed up by using Zune examples.

1. Stupid region restrictions

Neither Zune HD or regular Zunes are for sale outside North America. Likewise, the Zune Pass isn’t available outside of NA. I know plenty of people who would drop their iPod for a Zune and the Zune pass, the music subscription model is an awesome idea, and the Zune HD is some awesome looking hardware.

america-sees-world

I know the above is the factually correct representation of the world, but I really wish us dragons could give them money on a monthly basis so we could listen to various monster rock songs.

2. Bloatware

iTunes, 89meg; Songbird, 13.3meg, WinAmp, 9.8meg… Zune Player? 131meg – and it comes in x86 and x64 separate downloads. In typical fashion, Microsoft just have to have the largest program available. Why is it so big when most of it is visualisations and data pulled from the web? That brings me to my next gripe..

3. Custom UI framework – not WPF

Why is the Zune Player 131meg? Probably because they’ve implemented their own private UI framework based on Media Center rather than using Windows Presentation Foundation (WPF), the framework we are constantly reminded of being "good" for media and the like.

WPF is supposed to be the successor to WinForms in .NET. It can use vectors for the interface, has hardware accelerated support, pixel shader support for effects… but where has Microsoft used it? Well, there is Expression Studio (a suite of applications for… making WPF/Silverlight apps) and the unreleased Visual Studio 2010 (…a program for developing WPF/Silverlight apps amongst other things)… I can’t think of any other examples.

The apparent lack of faith in their own framework leaves us WPF developers scratching our heads and wondering if we should be calling it quits on WPF, or striving on when they finally iron out a considerable number of the show stopper bugs (virtualisation problems, resize performance problems, text blurry problems) in .NET 4.0 (or possibly later!)

4. Overlapping Products

Instead of being content with just one media/music playing application, Microsoft have decided to reinvent the wheel and have two separate programs. Zune Player and Windows Media Player (WMP). It’s be great if the features in Zune Player were a super-set of those found in Windows Media Player 12, but it lacks a host of features found in the latest (and even some found in the previous) version of WMP.

  Zune Player Windows Media Player 12
Handles multi-disc albums Yes No
Has DNLA Support No Yes
Has Windows 7 Support Yes Yes
No, really, Win7 support including Libraries No Yes
DVD Support No Yes
Detects Folder.jpg Sort of Yes
Detects folder.jpg hidden by WMP No Yes
Syncs Zune Yes No
Syncs other mp3 devices using MTP No Yes
Has "similar song/artist" playlist Yes (Smart DJ) No
Has "autoplaylist/smart playlist" Yes Yes
Plays Internet Radio playlists No Yes
Has taskbar mode Yes No (But WMP11 did)
Search-as-you-type No Yes
Podcast support Yes No

The above shows that unless you really want the pretties or the few features WMP is lacking, there isn’t much in the way to convince me to use the Zune player.


 

Deakin MSP Blog live

8 March 2009 , , ,    No Comments

The Deakin MSP blog is now live, although still a work in progress as we get everything going. "We" being me, and the two other Deakin Microsoft Student Partners, Elmar and Rob.

Some of the content I write for the Deakin MSP blog, I’ll repost here (such as the Its A Microsoft Life).


 

DevSta {Challenge 2008} Live!

30 September 2008 , ,    No Comments

Microsoft Australia has a new programming competition, 200 hours (well, 160 hours as of writing this post) called DevSta. It’s open to all Australians – professional programmer or not.

Competition Brief

In a nutshell, you have to make something that is is "old school/new cool", it confuses me somewhat. Read the full brief.

Prizes

First prize:

  • Return economy airfares to Las Vegas for two people (approx. $7,000 RRP- based on flights from your nearest capital city).
  • Five nights’ luxury accommodation, twin share at the Venetian Resort Hotel Casino (valued at $3,190 RRP).
  • Two tickets to the MIX09 Developer Conference from 18-20 March 2009 ($3,000 RRP). MIX09 is an international conference for developers and business strategists. Hear from visionary keynote speakers, expand your technical knowledge at targeted sessions, and put it all to practice in hands-on labs and workshops.
  • One copy of Microsoft® Visual Studio® 2008 Professional Edition with a 1 year MSDN Premium Subscription valued at $4,355 RRP.
  • An Xbox 360 Elite Console package – with Halo® 3, Gears of War® and Saint’s Row games valued at $865 RRP! This premier Xbox 360™ console package includes a huge 120GB hard drive, a high-definition multimedia interface (HDMI) port, a high-definition cable, and a premium black finish. It also includes a black wireless controller and black Xbox Live® headset. It also has enough space for a whole library of Xbox Live Arcade games and downloadable high-definition TV shows, movies, music, and more – available from Xbox Live Marketplace.
  • Samsung Omnia mobile phone valued at $849 RRP.

Second prize:

  • One copy of Visual Studio 2008 Professional Edition with a 1 year MSDN Premium Subscription valued at $4,355 RRP.
  • An Xbox 360 Elite Console package – with Halo 3, Gears of War and Saints Row games valued at $865 RRP.
  • A Wireless Entertainment Desktop 8000 valued at $449.95 RRP. Including the ultimate rechargeable keyboard and mouse for Windows Vista and PC entertainment, this great package is designed to make it easier than ever to control PC media from your desk, your lap or even the comfort of your couch!
  • A Xbox Live 12-Month Premium Gold Pack valued at $99.95 RRP.

Third prize:

  • One copy of Visual Studio 2008 Professional Edition with a 1 year MSDN Premium Subscription valued at $4,355 RRP.
  • An Xbox 360 Elite Console package – with Halo 3, Gears of War and Saints Row games valued at $865 RRP .

Fourth prize:

  • An Xbox 360 Elite Console package – with Halo 3, Gears of War and Saints Row games valued at $865 RRP.
  • One user licensed copy of Microsoft Visual Studio 2008 Professional Edition valued at $1,387 RRP.

Fifth prize:

  • One user licensed copy of Microsoft Visual Studio 2008 Professional Edition valued at $1,387 RRP.
  • A Wireless Entertainment Desktop 8000 valued at $449.95 RRP. Including the ultimate rechargeable keyboard and mouse for Windows Vista and PC entertainment, this great package is designed to make it easier than ever to control PC media from your desk, your lap or even the comfort of your couch!

Best Windows Mobile application prize:

  • Two Samsung Omnia mobile phones valued at $849 RRP each.
  • A Samsung 40" series 6LCD TV valued at $3,099 RRP.

It looks interesting, but the site scares me with all the "bling"


 

Remix Melbourne 2008

remix_logo1 With Remix over, I thought I’d sum up my thoughts on the event. Last year’s Remix was my first Microsoft event, but now I have a few more under my belt. This year I hung around Stephen Price, whose Quokka cartoons were featured all over the Remix blog. Stephen’s a very cool bloke, even if he gets lost too easily.

 

Keynote

While Mark Pesce‘s keynote speech was fantastic, I’m not sure how much relevance there was to most of Remix. The content of Remix’s sessions were always going to be about about XAML (Silverlight/WPF), IE8/ASP.NET, and Expression Studio – that is technically focused, rather than the social implications. The Live Platform session (the third session) certainly did expand on "hyper-connectivity"  (social) and the technological side of things, but the rest of the Remix "conversation" was perhaps a bit too focused on the technical or product side of things. That aside, I will repeat, it was a fantastic presentation. Get yourself on Twitter now!

If you weren’t at Remix, watch the video above (text version)

Session 1 – What’s New in Windows Presentation Foundation 3.5 and beyond

Speaker: Joseph Cooney

I quite like WPF, but I haven’t really seen the need to move to .NET 3.5….until Joseph’s presentation.

.NET 3.5 cool things are:

IMG_2870

The WPF cool things are:

Ugly things:

Joseph’s slides and demos are up on his blog already!

Session 2 – Introducing Microsoft Expression Studio 2

Speaker: Tim Aidlin

This was a fairly run-of-the-mill "I have a new application, let me show you it" presentation, covering Expression Studio 2 (except Expression Encoder 2) as well as Deep Zoom Composer. Unfortunately, for any attendees of Remix 07 or Mix On Campus, this sort of stuff (albeit for xStudio1) was pretty much what the events were all about last time, and it felt like the audience knew a bit more (about their favourite specific application) than Tim did.

While the list of new features to xMedia2 are neat (RAW image handling, batch renaming, metadata browsing, voice annotations, gallery generation), I still don’t really know what its purpose is in the Expression Studio suite. If it was a free app I could probably find a use for it, but for photo/image management Live Gallery is "good enough", and I manage all my music in Media Player…maybe its great for video management?

Contrasting with statements from Lee Brimelow from last year (that "everything you can do in Design, you can do in Blend, so I don’t see the point of xDesign"), Tim showed off xDesign2 and some of the reasons why you’d use it over xBlend. Yes, you can probably do everything in xBlend, just like everything you can do in Photoshop can be done in Paint. Being a developer, I think I’ll still be sticking to Blend, but I could see how the more artistic parts of XAML would be easier in xDesign.

Despite the improvements to xWeb2, as a developer and somebody who has been generated CSS/(X)HTML for years, I will not get any value out of xWeb2. VS2008 does all the stuff I need to do, or Notepad++ steps in when I need to go kung fu on my CSS. PHP IntelliSense/support has made it in, but this should have been a feature in xWeb2.

Session 3 – Windows Live Platform: Take the best of Windows Live and make it yours

Speakers: Angus Logan, Bronwen Zande, John O’Brien

I didn’t really know what to expect from this session, the Live Platform session sounded like it would be pretty boring, but I wasn’t overly interested in the other session which was upstairs, so the Live Platform session it was! I was pleasantly surprised, as this was a very cool session, possibly my favourite for the day! My laziness paid off!

The key things were how you can use Microsoft’s Live Platform to create incredibly interactive websites by making use of the Live services such as Virtual Earth, Live Messenger (/Hotmail) contacts/presence, Spaces, Storage (FolderShare/SkyDrive), Notifications (via email, SMS for North America, or via WLM through the alerts service).

For a few projects I have in mind, the Live ID login system looks appealing, although I’m wondering if a service like OpenID is more ‘acceptable’ (by end users, since Microsoft is so evil and all, apparently). I’d be very interested in the Live Platform Team’s view on OpenID vs LiveID, or if they can coexist.

IMG_2937

Angus left Twhirl running while giving his presentation, so I managed to get a few tweets popping up on the screen!

Session 4 – Building an Immersive, Integrated Media Experience in Silverlight

This session showed off the new ABC Silverlight Store, which while cool, is all Silverlight v1 stuff. It just seemed to lack the "wow", going over very similar things that were covered at Remix 07, without the edge the original presentations on Silverlight v1 had because it wasn’t new. I walked out (I needed a break/fresh air, not because I was bored) before it finished, so the last 15 minutes may have been awesome, its hard to tell.

The Silverlight Store also had a matching desktop client…written in Silverlight? I think (as a demonstration of the power of Silverlight and WPF), it would have been mucho cooler to do that in WPF. The technical reasons for not doing so are more than understandable – WPF weighs in at 20meg, and Silverlight at about 4meg. Both clients being Silverlight means just one framework download/install, which is much more friendly for the target audience.

The presentation was done using DeepZoom, zooming into each slide or diagram to show more detail, such as exploding a file overview into the actual code behind that file. That bit was cool.

Session 5 – Skipped

I skipped session five, not because of the content available, but because I ran into Long Zheng, and we got to chatting. Long has a new Zune ("Long Zhune"). He’s a cool guy, with or without the Zune!

Session 6 – Using Microsoft Silverlight for Creating Rich Mobile User Experiences

Speakers: Shane Morris, Michael Kordahi and David Lemphers. Originally meant to be presented by Leslie Nassar

I’ve been looking at creating a mobile version of MahTweets, using .NET CF. The three problems I have with .NET CF are limited controls available, it’s all WinForms crap, and only available on Windows Mobile phones. Silverlight, however, will be on Windows Mobile phones and Nokia’s S60 and S40 OS’ phones, uses XAML solving both WinForms problem, and amount of controls available!

A good list of S60 phones can be found at the Nokia Gaming Blog – I think the cool thing is that it includes the popular E65, and all (I think) of the powerful N series phones! It is foreseeable that other phones (or browsers) will eventually be able to play Silverlight as well!

Shane talked about how Mobile is already big, but is already accelerating faster than PC/laptop markets, and the ways designs will have to change not just for the limited capability or screen real estate, but the way the mobile user "snacks" on content.

IMG_2961

Michael demo’d Silverlight on a HTC WinMo phone, but unfortunately its "pre-pre-pre-beta", so we aren’t able to play with anything yet. Apparently some of the other Remix events around the world pulled the Silverlight mobile content! The goal of the Silverlight mobile project is to use the exact same Silverlight tools, and allow all existing Silverlight stuff to just work – you wont have to compile to "Silverlight Mobile", ala .NET and .NET CF.

Imagine Cup

During Session 5, I had Long talk me through what his teams project was all about. It is very cool, but rather than fumbling around to describe what it is, he’s already blogged about the team SOAK entry.

IMG_2990

Congratulations again to Long, David Burela, Edward Hooper, and Dimaz Pramudya! Good luck in France guys.

Overall

It was fantastic to see that some of the feedback from last year made the event change this year, such as including free wifi and ‘recharge’ stations. Unfortunately, the wifi/net connection weren’t too stable up until ~3pm, and other suggestions such as including pens for the feedback forms didn’t make it through, so Stephen and I pinched one of the vendor’s pens.

I can’t remember if I wrote down "better food", but this year had a lot less salmon and cold wedges! There were even TimTams! (’cause, you know, this it totally the most important part of the day).

This year the event was split across Melbourne and Sydney, and cut down to one day (each). This year’s venue (Melbourne Town Hall) was both better and worse than last year. More room to move between sessions and chairs to sit on, but higher ceilings (which created echo’s and "lost the vibe"), consistently bad lighting and uncomfortable chairs during the sessions all worked against the Town Hall. A few others agreed on the venue being ‘so-so’, and Ed Hooper suggested that the Melbourne Convention Centre, which is where Heroes Happened was held, would have been a better choice – which I agree with.

Remix is still in an infant state, its still learning about itself, but it is developing, experimenting and evolving. While not everything was perfect, I still will be attending next year because despite all my complaints it was still a great (albeit exhausting) day. Next year, however I think I’ll just take my camera and a notepad, rather than laptop + camera, which is fairly weighty. I’ll also sit a bit closer so that some more of my photos turn out. Argh!

Just like last year, Nick Hodge has a summary post of activity on the blogosphere about Remix.


 

Win a ticket to Remix 08, Silverlight Skateboard or Zune!

microsoft_silverlight_c

Shane Morris has just posted an exciting looking competition to make your own Silverlight Music Video to "Step Back" by Sydney/NY musician Matt Broadfoot.

First prize:

  • A Silverlight skateboard!!!
  • A ticket to Remix 08 Australia Event in either Melbourne or Sydney

Second prize:

  • A generation 1 Microsoft Zune® Scotty had lying around – which will be lovely once upgraded to the latest software :-)
  • A ticket to Remix 08 Australia Event in either Melbourne or Sydney

Third prize:

  • A Microsoft Wireless Presenter Mouse
  • A ticket to Remix 08 Australia Event in either Melbourne or Sydney

There is a very limited number of those Silverlight Skateboards in the world, would be very cool to win one.

Competition closes at 10am (Sydney time), Monday, May 12, 2008. Only a couple of weeks, so get cracking!
Terms and conditions


 

Exploiting Live Gallery to upload to custom gallery

19 March 2008 , ,    1 Comment

My photo management tool of choice is Live Gallery (WLG): it’s fast, free, and fairly featuresome.

One feature that is lacking however, is to upload to your own ‘custom’ gallery. Oh, sure, you can upload to Flickr, or Live Spaces, but honestly, who uses either of those services, pfft! Unfortunately, there doesn’t seem to be a plugin API (yet?) for Live Gallery so it isn’t possible to add your own image gallery service to upload – well, not as neatly as Flickr/Live Spaces.

Step 1: Add Your Gallery

To add your own custom gallery uploading to Live Gallery, we need to exploit the Online Printing functionality. Each printing service is actually defined in the registry, and the default “Print@Kodak” is a great starting point to seeing what data we need.

It is located at:

HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\PublishingWizard\InternetPho
toPrinting\DownloadedProviders\Print@Kodak

The registry values look like:

“displayname”=”Print@Kodak”
“description”=”Get Kodak photo quality prints from your digital camera!”
“href”=”http://print.fotowire.com/webprint/xp/start.asp?WID=25900″
“icon”=”fwPrint.ico”

To add your own, it is as simple as creating your own key inside of DownloadedProviders, however either Windows or WLG seems to delete the registry key after closing WLG. Instead of inside DownloadedProviders, create a Providers key (inside InternetPhotoPrinting), and then create your own Provider key, with the same sorts of values (displayname, href, description and icon) as the Kodak Provider.

It should look something like this image when you’re done

image

There is another benefit to doing it this way, under the printing menu, you will now have ‘Print’, ‘Order prints’, and ‘Order prints from foo

image

Step 2: Prepare your gallery

While it is great we’ve thrown it a random URL, how do we know what data is actually being sent?

Thankfully Elmar Putz had figured out the XP Web Publishing Wizard (which is very, very similar), so that was most of the leg work done.

First, the page set in the Href in Registry. I’m going to cut to the chase and just list the HTML/Javascript, if you want more of an explanation, see Elmar’s article (linked above). All you need to do is change the UploadURL and EndUrl

<html>
    <
head>
        <
script language=”JavaScript”>
            var
UploadURL = “http://mydomain/upload/”;
            var EndURL = “http://mydomain/aftertheupload.html”;
            function window.onload()
            {
                window.external.SetWizardButtons(0,1,0);   
            }

            function window.onback()
            {
                window.external.FinalBack();
            }
           
            function window.onnext()
            {
                var xml = window.external.Property(“TransferManifest”);
                var files = xml.selectNodes(“transfermanifest/filelist/file”);

                for (i = 0; i < files.length; i++)
                {           
                    var postTag = xml.createNode(1, “post”, “”);
                    postTag.setAttribute(“href”, UploadURL);
                    postTag.setAttribute(“name”, “myfile”);

                    var dataTag = xml.createNode(1, “formdata”, “”);
                    dataTag.setAttribute(“name”, “MAX_FILE_SIZE”);
                    dataTag.text = “2000000″;
                    postTag.appendChild(dataTag);

                    var dataTag = xml.createNode(1, “formdata”, “”);
                    dataTag.setAttribute(“name”, “action”);
                    dataTag.text = “Save”;
                    postTag.appendChild(dataTag);

                    files.item(i).appendChild(postTag);
                }

                var uploadTag = xml.createNode(1, “uploadinfo”, “”);
                var htmluiTag = xml.createNode(1, “htmlui”, “”);
                htmluiTag.text = EndURL;
                uploadTag.appendChild(htmluiTag);

                xml.documentElement.appendChild(uploadTag);
               
                window.external.FinalNext();
            }
           
            function document.oncontextmenu()
            {
                return false;
            }
        </script>
    </
head>
<
body>
    <
h2>Click Next to upload</h2>
</
body>
</
html>

image

The code for the page at UploadURL would look something like…

ASP.NET

String uploadDir = "Images/";
HttpFileCollection hpC = System.Web.HttpContext.Current.Request.Files;
for (int i = 0; i < hpC.Count; i++)
{
    HttpPostedFile file = hpC[i];
    if (file.FileName != string.Empty)
    {
        file.SaveAs(Server.MapPath(uploadDir + file.FileName));
    }
}

PHP

<?php foreach ($_FILES["pictures"]["error"] as $key => $error) { if ($error == UPLOAD_ERR_OK) { $tmp_name = $_FILES["pictures"]["tmp_name"][$key]; $name = $_FILES["pictures"]["name"][$key]; move_uploaded_file($tmp_name, "uploadDirectory/$name"); } } ?>

Step 3: Reading the file (optional)

If you’re writing your own gallery, or simply just want a way to avoid having to FTP in to upload files, it may look as if you’ve lost the meta-data (specifically I mean tags)  from your photos. Fear not, however, as there is a way!

All the tags are stored in ‘XMP’ format, which is essentially just embedded XML.

.NET 2.0
In .NET 2.0, there is no native way to read in XMP Information, so we need to use some XML parsing to get it. Microsoft blogger Omir Shahine, has a great post on accessing XMP data in .NET 2, including the code/general discussion on the matter.

.NET 3.x+
In .NET 3 and above, inside the Windows Imaging Component, there is the BitmapMetaClass. However this is both more and less complex than using regular expressions (above), in that you nave to use the proper ‘paths’ for accessing specific data. I won’t cover it here, but WIC/BitmapMetaClass is what you should look into if you want the .NET 3+ method of accessing XMP/EXIF data.

PHP
Like .NET 2, there is no native way to read in XMP information. The below code will return an array of XMP Tags.

<?php function GetTags($filename) { $handle = fopen($filename, "r"); $image = fread($handle, filesize($filename)); fclose($handle); preg_match("/LastKeywordXMP>([\w\W\t\f\s]*)LastKeywordXMP>/i", $image, $matches); $tags =split("</rdf:li>",$matches[1]); for ($i=0;$i<count($tags);$i++) { $tags[$i] = trim(strip_tags($tags[$i])); } return $tags; }?>

Final Notes

Since there isn’t an authentication option in the printing wizard, security is a concern, particularly in a multiuser environment. You could implement any/all of the following however

 



 

Vista Service Pack 1 Out Now

19 March 2008 ,    No Comments

If you haven’t been lucky enough to have had access to Vista SP1 through Technet or MSDN, Microsoft have released SP1 to the general public today. Wondering why you’d bother upgrading? Apart from security roll ups and whatnot, APC discovered that Vista with SP1 is up to 86% faster in certain tasks than without SP1 (metrics via Nick Hodge) – very very cool.

Vista SP1 32bit (434.5 MB)
Vista SP1 64bit (726.5 MB)


 
Previous Posts →