Hi All,
Today we've launched a site that tries to helps you get rid of the traffic from IE6 by advising them to upgrade.
The people that are still running IE6 probably need a little help in upgrading (or they would have done so already) so we encourage them by making a donation to Visio which is a NGO that helps visually handicapped.
The please visit http://www.microsoft.com/netherlands/vanie6naarie8/ and send everyone you know who uses IE6 there.
If you have a website or a blog please use the following banners to actively send traffic of IE6 users to the site:
Please help the poor people still experiencing the internet in IE6 and the visually impaired.
Thanks
Bram
Thanks to Nitasha we learned that it is possible to create a custom WebPlatformInstaller feed she describes it in her post:
Is there a way to get WebPI to install Products in an offline way?
This is not really a supported scenario but when you are about to go to a convention and have to demo WebPI and you only have convention WIFI you better be prepped for the worsed.
So now we know how to be prepped for the worsed and I started to look at the WebPI feed but it is a HUGE file and I had to download all the packages manual and then set the installerURL etc etc.
To speed up this process I've created the following Powershell file to do this for you.
#Get the WebPL feed (this could be improved by downloading it[xml]$xd = Get-Content "D:\OfflineWebPI\WebProductList.xml"foreach($entry in $xd.feed.entry){ Write-Host $entry.productid
foreach($installer in $entry.installers.installer) { if($installer.installerFile.installerURL) { if($installer.languageId -eq "en") { [string]$url = $installer.installerFile.installerURL $lastslash = $url.LastIndexOf("/")+1 $filenamelen = $url.Length-$lastslash $filename = $url.Substring($lastslash,$filenamelen) $filename = "D:\OfflineWebPI\$filename" Write-Host "Downloading $filename" $clnt = New-Object System.Net.WebClient $clnt.DownloadFile($url,$filename) $installer.installerFile.installerURL = $filename } } }}$xd.Save("D:\OfflineWebPI\WebProductListNew.xml")
I'm blogging this now mainly for my own reference. Will comment the code later.
If you are a hoster you "could" use this to create an in network cache of the web platform packages.
I was building the Virtual PC that will be used in the “Wordpress on Windows Install Challenge” next Saturday on the Dutch Wordcamp event when I had to figure out if I could get this working.
My setup is a single laptop running Windows 7 native booted from a VHD as is described here. Unfortunately or great (Depends who you are talking to) Windows Server 2008 R2 only exists in 64bit so I couldn’t run it in Virtual PC as it currently only supports 32bit operating systems. So I started to create a VPC with Windows Server 2008 so I could use Hyper-V as a hypervisor which does support 64bit OSses.
I really love native boot VHDs they make live so easy and clear. I was working in WS2008R2 and build a Virtual Machine which the people will use on Saturday but all my tools of course were on my other VHD which runs Win7.
I thought I might be able to boot my main install in Hyper-V. I tried that and got a bootloader not found error message which makes sense as the bootloader of my laptop is on my system partition. After a little research I figured out how to make the VHD bootable by putting a bootloader on it.
From a command prompt run:
After this you can boot your VHD from Hyper-V it will install the drivers required and after a reboot it feels just like my main install. Only a bit slower as I have to reserve memory for the base os and my other VMs. If I want my power back I can boot native from the VHD and work from there.
On my physical disk there are only 3 files now windows7.vhd, hyperv.vhd and wordcamp.vhd (I like it).
See you all soon
Those of you who follow me on Twitter might have noticed I’ve been working towards PICNIC09 on 23-25 September. For the first time Microsoft is a premium sponsor of this event and we’ll be showing some really cool stuff.
As PICNIC is not your every day event we’ll be at PICNIC with a participation that is not what you expect and or know of Microsoft.
We’re inviting everyone to come have a PICNIC @ the Microsoft Creative Park! The great thing is that for 95% of the Microsoft activities you only need a Festival Ticket which costs only €90 a day compared to €300 for a conference ticket.
This park will be created in the Gashouder on the PICNIC festival ground and in the Creative park you can have a refreshment and chill out like you would in a normal park. There will be Microsoft people in the park with who you can have a conversation and tell them what you think of Microsoft.
Besides a PICNIC festival ticket you need to register for the lab that’s why I list it first.
Microsoft Social Network Design Camp On Thursday and Friday Morning Antoni Dol of Macaw will lead a lab to prototype the ideas for the next social network. We’ll be prototyping using Sketchflow. We are collecting ideas for the camp so if you have an idea about the next social network please send me a DM on twitter @bramveen or leave a comment here. If you want to participate in the Design Camp please go here.
Visit one of our silent announcements We’ll be revealing something at PICNIC which I can’t talk about yet but we’ll be doing this at the park using a “Silent Disco” system. Seating is limited so make sure you don’t miss it.
Upgrade your digital identity You know those people who have a great personalized twitter page? A good example is the twitter page of my friend, founder of Het Nieuwe Werken Blog and former Microsoft colleague Alex Vermeule.
. In the Microsoft Creative Park you can have your picture taken and you can create a great twitter background or image to use in your personal marketing.
Learn to know the Expression Suite If you are interested in getting started with Silverlight or any other MSFT web technology you can try them out in our Creative outlook. We’ll have labs building a twitter client, a game, troubleshooting browser layout problems and rapid prototyping.
Catch up on the rest of the festival We are working together with Inholland to bring you all the video and pictures they created in a Media Half Pipe (don’t ask) you’ll be able to check out all you’ve missed during the festival.
Drop of your Pictures to have them put into the PICNIC Photosynth If you shoot pictures during PICNIC and upload them to Flicr or drop them off at the Creative Park we will photosynth them a 4 times a day to create a photosynth of the festival.
Participate in the Microsoft Logica Marble Competition Across the festival terrain there will be several Surface units build into PICNIC tables that will display the backchannel of PICNIC on Flicr and Twitter. More important is that if you put your PICNIC badge on the table you will be able to plarticipate in the Marble competition.
And there is more I’ll probably drop some tidbits every day we have left in the road to PICNIC.
Come have a PICNIC in the Microsoft Creative Park get your PICNIC tickets here.
See you there (I’ll be the guy looking really tired) ;-).
This is also a post from my old blog which I have to migrate as it will be deactivated next friday. (BTW why isn’t twitterfeed crossposting my blog to twitter).
I’ve downloaded the Azure SDK from Azure.com http://www.microsoft.com/azure/register.mspx. This allows you to get started with the development fabric while you wait for getting enrolled in the CTP.
Getting started an building a hello world (Or actually Hello Arie as I was sitting next to Arie Leeuwestein) kept breaking.I was running SQL server Standard edition in stead of the SQL Server Express edition which the fabric expected. I’m sure I’m not the only one that will run into this problem. To fix this you need to change the settings in C:\Program Files\Windows Azure SDK\v1.0\bin\DevelopmentStorage.exe.config in this file the SQL server instance is configured.
Once I changed this from .\SQLEXPRESS to . the dev fabric started and I’m now able to build Azure applications and debug them on my laptop.
I just recieved my password for Azure .NET services (the service bus and Identity) and Azure SQL Services (relational data) so I’ll be playing with them today and tomorrow.
I’m on PDC this week and the amount of technology that is being announced is really amazing and really fire my enthousiasm for our platform.
Other stuff I really enjoyed:
- Windows 7 in the keynote (this is looking good and at the expo I was able to play around with it and it really is as responsive as it looked on stage).
- Geneva the identity framework www.microsoft.com/geneva a identity framework that takes most the ID heavy lifiting (Authentication) out of the application and really makes it easy to setup federation
- Visual Studio Team System for Database Developers (My collegue knows Gert Drapers the Engineering Manager) really cool stuf in SQL Schema deployment check out the Release Candidate
- Oslo and the “M” language. This is really cool stuff a modeling language.
This is a repost of a post of my blog on the Dutch Microsoft Blog page. Since I moved my blog to the msdn domain they will delete my blog sooner or later and there are some posts I like to keep.
This is once again a posting in English. Yesterday and today I must have spend over 3 hours figuring out how to call an ASP.NET 2.0 webservice using PHP 5.0. Of course I tried to find some sample code somewhere and finally found some but the reasons why it took so long were trivial and not very well documented. So here is my gotchas of calling an ASP.NET webservice using a php script.
Lets start with the sample script and then I'll tell you what things I encountered before everything worked.
function AddDevice($DeviceName,$MacAddress,$PassWord,$IPAddress, $Mask, $Gateway) { //Beware that IIS authentication can only be done through basic auth. $username = "User"; $password = "Pass@Word!"; $client = new SoapClient("ADSConnector.wsdl", array('login' => $username, 'password' => $password)); //The parameters of the webmethod have to be in an array. And the members of the array have to have the same name (case sensitive) as the Arguments at the webservice and $params->DeviceName = $DeviceName; $params->MacAddress = (string)$MacAddress; $params->PassWord = (string)$PassWord; $params->IPAddress = (string)$IPAddress; $params->Mask = (string)$Mask; $params->Gateway = (string)$Gateway; //The return value of the webservice call is a StdClass $result = $client->AddDevice($params); //To get the good value from the stdClass object get the WebMethodResult member $simpleresult = $result->AddDeviceResult; return($simpleresult); }
First of all I had to call the web service authenticated and I had to figure out that php cannot authenticate using Windows Authentication. The error message that I got was:
"Fatal error: Uncaught SoapFault exception: [HTTP] Unauthorized"
The logs of my IIS server that was running my ASP webservice told me I had an Access Denied but no details at all. After fidling around a bit more I finally figured out you had to change the authentication method to Basic Authentication. As my web server and client are on a management LAN there is no real problem doing that. If you need to do this over the internet make sure you use SSL.
The second step was calling the webmethods. I would expect that if the method takes say 2 parameters that to be called something like this
$client->AddDevice($value1, $value2);
It took me a while to figure out that the proper way is to put the values in an array so it has to be:
$params->$value1 = value; $params->$value2 = value;
$client->AddDevice($params);
The next thing that hit us was that only a few of the parameters arrived at the webmethod. Thank god I was able to attach a debugger at the ASP.NET end or else it would have taken us years to figure this one out.
The reason for this problem was that the names of the members of the parameters array were not properly formatted. The ASP.NET function definition is;
public
string AddDevice(string DeviceName, string MacAddress, string Password, string IPAddress, string Mask, string Gateway)
And our parameters array looked like this
$params->Devicename = $DeviceName; $params->MacAddress = $MacAddress; $params->PassWord = $PassWord; $params->IPAddress = $IPAddress; $params->Mask = $Mask; $params->Gateway = $Gateway;
Maybe you see that Devicename and PassWord are misspelled. Or at least are nog case by case the same as the names of the arguments of the AddDevice function.
After fixing this we had all the funny PHP calling ASP.NET webservice quirks ironed out and were ready to look at functionality.
I hope this post was useful and I also hope it will pop up in live search and other search engines when someone tries to find information on php and webservices and .NET or using the php soapclient.
By the way I was running the php scripts from the IIS7 webserver on my Vista laptop and getting it all to work was really a walk in the park. For more details check out this blog posting.
Have a good one.
To win a Mix Essentials Europe ticket you need to find the words to a sentence. Once you know what the sentence is you must mail it to winamixeuroeticket@live.com the first 5 people to send the right answer get a ticket worth 445 euro which gives access to all Mix Europe and Devdays.
Mark Voermans wrote an article on his blog about the new Training kit for PHP on Windows. The first word of the sentence we are looking for is the second word of the title of this post.
Ruud de Jonge (who is both my and Marks manager) wrote an article about Mix Essentials Europe. The second word of the sentence is the 14 to last word of this post.
On Devdays Pierre Joye (a PHP community member who started the PHP Windows Core team) will give a presentation. The third word of the sentence is the third word of the title of his presentations.
The last word of the sentence is from my blog. I have a post where I announce I’ll be speaking at Devdays and in that post I say somewhere that IIS7 ….! Fill in the …. and you have the last word.
Happy hunting
See you all at DevDays/Mix Essentials
Hi all,
It almost looks like we coordinate things at Microsoft. While we are running the WinPHP Challenge in Europe with the Dutch PHP Conference and Leaseweb massive PHP on Windows content is being published by my friends in the US.
It is great that we have a MSSQL driver for PHP. The next thing is using the really nice SQL features like GeoSpatial Datatypes and the Reporting Services. In the training kits we show how to leverage these kind for SQL features.
PHP & SQL Server Demos
· Integrating SQL Server Geo-Spatial with PHP · SQL Server Reporting Services and PHP
PHP & SQL Server Hands On Labs
· Introduction to Using SQL Server with PHP · Using Full Text Search over Office Documents in PHP
PHP on Windows Hands On Labs (these can be downloaded independent)
· IIS Access Control Features for PHP · Using IIS 7.0 Media Features in a PHP Application · Troubleshooting PHP · Migrating PHP Applications to IIS 7.0
To download all this content download the training kit here this will make the demos for Devdays much more easy to prepare.
In this video we show how to connect to Contacts and Profiles in the live framework using PHP. This makes the social graph of users of Live services accesible for PHP developers.
“Live framework is the uniform way of programming Live Services from any platform, programming language, application or device. As a concrete example, check out a very useful “how do I” screencast - - Access Windows Live Profiles and Contacts from PHP apps - - by Program Manager Nishant Gupta. He also provides a code snippet you can use to step along with the video. “
The video and the code can be downloaded from here.
· TechNet Virtual Lab: Using IIS 7.0 Media Features in a PHP Application – Learn how to deliver media over the Web with IIS 7.0, play a video using the embedded Windows Media Player control, create media playlists with IIS 7.0 Web Playlists, provide an enhanced media player experience with Silverlight 2.0, reduce bandwidth costs with IIS 7.0 Bit-rate Throttling, leverage Silverlight 2.0 Seek, and protect media
· Running PHP on Microsoft Servers and Services – Learn how to run PHP on various Microsoft platforms including Internet Information Services (IIS), Microsoft SQL Server, Windows, Azure Service Platform, and more
Integration between VS.Php and Silverlight – Learn how to develop Silverlight on PHP, how to debug PHP and Silverlight (integrated together
Happy coding
With the WinPHP challenge in its second week I think all participants have created their PHP Dev/Test environment. Now @juokaz asked me how to deploy bits to a Windows Server 2008 machine.
To do this we’ll use the Web Deployment tool we’ll also use the IIS Managemt service to deploy to a remote service without RDP-ing into it.
First of all we of course need to install the Web Deployment tool. To do this we of course use the Web Platform Installer (WebPI).
On the dev and the production machine we install the Web Deployment Tool 1.0RC.
I’ve installed Wordpress on my dev machine and will be deploying that as a sample to also show you can deploy MySQL Databases.
To deploy an MySQL database the web deployment tool needs a snapshot of your DB. To get this run the mysqldump command in the bin directory of your mysql install.
mysqldump –uusersname –ppassword database > filename.sql (replace bold stuff with
Now we can make the actual export. In the IIS manager we navigate to the application we want to deploy and we click on the export application button.
Now we get the create application package dialogue.
We click Add Component and in the Provider name we select dbMySQL path field we enter the exportfile we created with mysqldump. There are a whole lot of providers there is of course a provider for MSSql but also for GAC Assemblies, registry keys, application host config files and a lot more.
After that we click Ok and we click next until we have to give in a name of the export package. This is a zipfile.
Now move your package to your production server using your protocol of choice.
On the production server we open IIS manager and select the site where we want to import the application. And we select Import application.
Now we browse to the application package we just copied to the server.
The Web Deployment tool shows you what is in the package and you can change some parameters.
We must do that so we can specify a different username and DB name.
If you have configured all parameters and import the package you have deployed you application to the production server.
You can find all this information on the IIS site on http://www.iis.net/extensions/WebDeploymentTool.
Enjoy.
For those of participants in the WinPHP challenge that are looking at Windows Server 2008 for the first time and haven’t looked at Windows for I write this article to make a flying start coding.
The Server that Leaseweb has sponsored are running Windows Server 2008 web edition and need to be configured from scratch. To have an test / dev environment you are able to run either Windows Vista SP1 (as it has the same version of IIS7 build in).
If you are however not running Windows Vista but are running Windows XP or Windows Server 2003 on your dev machine you can use Virtual PC to create a VPC with Windows Server 2008. You can download Virtual PC from here.
If you are running OSX as your main OS there are solutions from VMWare, Parallels and probably others to create virtual machines on a Mac if you are running Linux on your dev/test machine you will probably go with Xen - UPDATE - @stuherbert pointed out that Virtualbox would be the VM technology of choice for the linuxdevs out there.
Anyway in this post I’ll show how to run with VirtualPC as “I’m a PC and running Windows (7)”
Once you have installed VirtualPC you will be asked to create a new VirtualPC. Everything is pretty self explanatory. When I create a VPC I always move the files out of the default location or it will store the VPCs in your documents folder. Next to that the only thing I change is that I increase the memory for the machine to 1024MB (I have 4GB in my dev machine) and that normally works ok.
Now we need the bits. You can download any version of Windows Server 2008 from here for a 60 day evaluation trial and if you register you can extend it to 240 days. The participants of the WinPHP Challenge will recieve a copy of the Windows Web Server 2008 software so lets run with that this is the direct link to the Windows Web Server 2008 edition.
So now I have a virtual machine which settings look something like this.
I’ve downloaded the ISO for Windows Server 2008 web edition which I mount to the Virtual Machine and then I boot. To do that start the VPC and right click on the CD icon in the bottom of the VPC screen.
Installing windows is pretty straight forward. With Windows Server 2008 you just select all default options and you have a running machine in Virtual PC. All roles will be configured after installation.
After Windows Started for the first time you get the Initial Configuration Tasks.
The only thing I do here is enabling Remote desktop so I can use Terminal Services to connect to my dev/test server. This works smoother then the VPC client. The rest of the server we configure with the Web Platform Installer so we can click the “do not show this window at logon” checkbox.
After that you need to install the VM additions. This will give you a smoother ride in VPC. You install them by selecting Action – Install VM Additions
Ok so now we have a clean install of Windows Server 2008 with no roles at all. Let’s change it into a Web Server that can run PHP and has a Database installed.
Make sure your machine is connected to the internet and go to this URL. And select the Web Platform Installer 2 Beta.
The web platform installer (WebPI) will launch and allow you to select exactly how you would like to configure your webserver. It will download all required bits and install and configure them.
It also has the posibilities to install common web applications like Drupal, Wordpress, Gallery. We’ll be extending this list as we go along.
For now I only want PHP to run. We’ll talk a bit more about different IIS features in future posts.
If I press the install button the WebPI will add all the dependencies for PHP and when I accept them it will install and configure IIS7 to run PHP applications.
You can now take a quick cup of coffee and when you return your machine is able to run. To prove it we’ll create a website to run phpinfo();
To do that click the start button and type iis in the search box. This will get you the IIS manager. In the IIS manager create a new Virtual Directory under the default site.
In the directory in my case c:\test create a file with phpinfo();
Et voila you have a running Windows Server 2008 dev environment in a Virtual Machine.
In this WinPHP series I’ll create the following follow up posts:
- Managing Sites and deploying to a hosted server - Databases - Audio / Video
If we still have time maybe I’ll do a bit more. This will also by the way be the basis of my DevDays 2009 talk.
The WinPHP Competition registration will close end of business on Friday April 17th want to go to Vegas register NOW!
On the March 23 we announced the WinPHP Challenge the competition for PH P programmer to create the app they always wanted to write and have the opportunity to win a trip to the MIX 2010 conference in Las Vegas. This competition is run by the Dutch PHP Conference, Microsoft and Leaseweb.
When Cal Evans and myself were discussing this competition it soon became clear that we needed to faciltiate the competitiors with a server running Windows Server 2008 so they are able to deploy their application. I didn’t have to think long and immediately called our friends at Leaseweb.
Leaseweb being one of the biggest hosters in Europs has the expertise and scale to host the competition and give all the competitiors their own Virtual Machine running Windows Server 2008. They are providing this on their premium storage solution from the Evoswitch datacenter. Leaseweb is one of the fastest growing hosters and they were a TAP customer for Windows Server 2008. They have been selling Windows Server 2008 dedicated servers one day after the release date of Windows Server 2008 which make them one of the most experienced Windows Server 2008 hosters.
Because Leaseweb always wants to be the first with new technologies they were also part of the Hyper-V technical adoption program and will launch a very competitive Virtual Dedicated Server offer based on Hyper-V very soon again as one of the first in the Netherlands.
This expertise made Leaseweb the obvious partner to work with for the WinPHP Challenge and they were happy to join DPCon and Microsoft in making this contest happen.
I am very happy to send out the login codes to the Virtual Dedicated servers on Monday when the competition kicks of.
I’m very proud to say I’ll be speaking at DevDays 2009. For the first time this year DevDays will have non MS technologies. We’ve created a very cool track for PHP.
Pierre Joye will be talking to the work the PHP community has done to make PHP better on Windows and will address why PHP 5.3 will absolutely ROCK on Winodows.
Stefan Koopmanschap will talk about 5 Essential PHP community applications that work fine on Windows.
Maarten Balliauw and Kevin Dockx will talk about PHP and Silverlight.
I’ll be talking about PHP on Windows. What Windows features will you like in you PHP Application and why IIS7 ROCKS! :-)
I think it is really cool we are featuring PHP on Devdays.
I’ll be introducing the speakers and their talks later and will be posting my notes about prepping for my own talks as well.
The registration for the WinPHP challenge will be extended until Friday. We need a bit more time to get all the things in place. We’ll kick of the competition by sending out the welcome e-mails next monday.
Details can be found here on the DPC09 Wiki
Registration opens April 2nd and you must register before April 17th to participate. Winners will be announced during the closing keynote at DPC09.
Check out the wiki for full details and contest rules and please help us spread the word.
I can’t wait for registrations to open the prices are GREAT the winner takes away:
Looking forward to the competition.
Build your next Open Source project on IIS7/PHP and win prizes.
First prize is airfare, hotel and a ticket to MIX10 in Las Vegas, NV-US!
Come help us celebrate the great progress that the PHP Windows team has made in making PHP a First Class citizen on Windows.
Registration opens April 2nd and you must register before April 15th to participate. Winners will be announced during the closing keynote at DPC09.
In the last couple of days a lot of Azure materials are released.
First big kudos to David Aiken for building a brilliant training kit which can be downloaded here.
I’m half way now and this is by far the best training kit I did in ages. No crashes or bugs in the sample code. Good scenarios and clear explanations.
Besides that 9 out of 40 how do I videos were posted yesterday. They are very comprehensive and short enough to get up to speed on your own pace.
The topics are:
More and more information is getting available and it is looking better and better :-D
Enjoy the viewing and doing the labs.
There are some free e-books I’d like you point out.
This 15MB E-Book is over 400 pages long, so it is quite comprehensive. It covers all current Microsoft Virtualization technologies even the newest, such as the Microsoft Enterprise Desktop Virtualization (MED-V), and VDI. Definitely a worthwhile addition to your library.
Synopsys
This guide will teach you about the benefits of the latest virtualization technologies and how to plan, implement, and manage virtual infrastructure solutions. The technologies covered include: Windows Server 2008 Hyper-V, System Center Virtual Machine Manager 2009, Microsoft Application Virtualization 4.5, Microsoft Enterprise Desktop Virtualization, and Microsoft Virtual Desktop Infrastructure.
The book also provides insight into the Core Infrastructure Optimization model, and how implementing virtualization technologies can help move a company further along toward the goal of building an efficient, reliable Dynamic IT infrastructure.
Here’s how to get it: Simply register at http://csna01.libredigital.com/?urmvs17u33
NOTE: Once you’ve authenticated using your Passport/Live ID the only required fields for registration are: name, country, role, and an email address. You’re taken directly to the download from there (you will need to temporarily allow Pop-Ups for the download window).
Some more free e-books:
· Writing Secure Code for Vista, Michael Howard and David LeBlanc. http://csna01.libredigital.com/?urrs4gt63d
· Understanding IPv6 2nd Edition, Joseph Davies. http://csna01.libredigital.com/?urws8un4p7
Enjoy
Of course everyone has been extremely busy installing Windows 7 on all their test machines and not so test machines. During all this hard work we might have overlooked the fact that yesterday also Windows Server 2008 R2 beta 1 got released.
Everyone who has a Technet or MSDN subscription can download it from there and for those who don’t have a subscription this link will be available at 9AM PST tomorrow morning.
The thing that I’ve been waiting for are the Hyper-V features which include Live Migration and a VDI broker for more information keep an eye on the official Hyper-V blog http://blogs.technet.com/virtualization/
Happy testing
I’m using a lot of twitter lately and was looking for a nice twitter client in WPF which I found in Witty Twitter. The only feature that was missing was automatically converting a URL to tinyurl.
I downloaded the source of wittytwitter to see if it was easy to add this functionality.
It took me more time to donwloand and install TortoiseSVN than to add the feature.
Here is the code which can be used to parse any string for urls formatted as http://www.xyz.com
protected string ToTinyURLS(string txt) { Regex regx = new Regex("http://([\\w+?\\.\\w+])+([a-zA-Z0-9\\~\\!\\@\\#\\$\\%\\^\\&\\*\\(\\)_\\-\\=\\+\\\\\\/\\?\\.\\:\\;\\'\\,]*)?", RegexOptions.IgnoreCase); MatchCollection mactches = regx.Matches(txt); foreach (Match match in mactches) { string tURL = MakeTinyUrl(match.Value); txt = txt.Replace(match.Value, tURL); } return txt; } public static string MakeTinyUrl(string Url) { try { if (Url.Length <= 12) { return Url; } if (!Url.ToLower().StartsWith("http") && !Url.ToLower().StartsWith("ftp")) { Url = "http://" + Url; } var request = WebRequest.Create("http://tinyurl.com/api-create.php?url=" + Url); var res = request.GetResponse(); string text; using (var reader = new StreamReader(res.GetResponseStream())) { text = reader.ReadToEnd(); } return text; } catch (Exception) { return Url; } }
Thanks to Faraz Shah Khan and Emad Ibrahim
I’ll be sending the update to the witty team ASAP.
I’ve been looking for a good and free control panel for Windows Server for a while now and I think I’ve finally found it.
Dotnet panel has an Express version which is deal for managing your dedicated server. There is no maximum domains that can be managed and it runs on Windows Server 2008 Web edition.
I’ve installed it on my dedicated server and made different profiles (ASP.NET with MSSSQL, PHP with MySQL etc).
Now I can automate the site/FTP/database creation (just what you expect from a control panel).
The cool thing is that first of all it is a free control panel and it allows you to manage three servers under the express license.
Another cool feature that dotnetpanel has is that it supports Hyper-V. Look at www.dotnetpanel.com/vps for the details.
I think this is a great free control panel for windows.
You need a place to store your photo’s, video’s, dll’s (PDC keynote visitors ;-).
Check out skydrive.live.com login with your live ID (no provisioning required).
It has been upgraded to 25GB.
Ever since PDC I’ve been asked to redeliver a lot of content that was presented there.
I’ve noticed that I’ve been using a lot of content that was presented at PDC as all the presentations are available on demand and even better they also offer the pptx as download which makes it very easy to redeliver.
The only problem with all this great content is that they have decided to hide it on the PDC website.
All the content can be found on this site sessions.microsoftpdc.com/public/sessions.aspx all the info on Azure our S+S strategy Oslo the future of C#.
Enjoy the content.
Ik heb mijn blog verhuisd naar blogs.msdn.com/bramveen.
Ik zal voorlopig nog crossposten maar op den duur verhuis ik voorgoed naar blogs.msdn.com.
Om dit blog te blijven volgen moet je de RSS feed veranderen naar feeds.feedburner.com/bramveen.
Op het msdn platform heb ik wat meer mogelijkheden en is het makkelijker occasionally een internationaal publiek te bereiken.
Ik hoop dat jullie me zullen volgen.
Groet