Today's Question:  What are you most afraid of as a programmer?        GIVE A SHOUT



  Meta tag in HTML header

In server response, we can use response.setHeader() to set the meta information in header of a HTML page. The usage is response.setHeader(name,context); meta is used to simulate the response header of HTTP protocol in HTML page. It should be put between the <head> and </head> tag. 1. <meta name="Generator" content="" > <!--This is to specify the tool which generates this page such as Microsoft FrontPage 4.0 etc --> 2. <meta name="keywords" content=""> <!-- To tel...

56,064 0 0          HTML HTTP META HEAD

  Some useful Linux commands for teamwork

A small development team in the intranet will frequently transfer codes, share files. Here are some command we use frequently to release some of our work. They are not applicable to Windows users. 1. Output program execution output through GTalk. Sometimes we may need to send the program execution result and log to teammates for debugging using IM. These outputs are very troublesome to copy and send while in command line mode. So we could have a program called which can put GTalk as a p...

1,198 0 0          LINUX HTTP NFS GTALK

  Output a file with HTTP range header in PHP

When downloading a large file, we may encounter some network issues which causes download termination and only part of the file is downloaded. When the network connection resumes next time, we may need to redownload the file again from the beginning. In order to save bandwidth, http provides a Range parameter in its header which can control the file transfer flow. With the range parameter in the header, we can resume the download from where we stop. Here is a piece of PHP code snippet which uses...

15,123 2 6          PHP HTTP RANGE FILE TRANSFER

  HTTP is not a transport protocol, HTTP is not RPC

Recently there was a question on the forums asking why we encourage usage of HttpRequestMessage<T> / HttpResponseMessage<T> in the signature of a web api implementation. The point made in the post is that if you have an ICalculator contract which your API implements, then it’s violating SOC / inappropriate to have those messages as params and in the contract. The argument is valid when looking at HTTP from the standpoint of an RPC mechanism, which is actually a quite common ...


  Circumventing browser connection limits for fun and profit

A few days ago, this video hosted by metacafe popped up on digg, explaining how to increase site download times by tweaking your browser settings to increase connection parallelism. To explain why this works, let’s step back a bit to discuss how browsers manage server connections. In building any application, developers are often required to make ‘utilitarian’ choices. Pretentiously paraphrasing Jeremy Bentham, ‘utilitarian’ describes an approach that ‘does the greatest good f...


  IE ActiveX(”htmlfile”) Transport, Part II

In my last post I discussed using the ActiveX(”htmlfile”) technique to provide a usable streaming transport in Internet Explorer. The solution I provided will work, but since writing the last article I’ve made significant progress in understanding why IE behaves the way it does with respect to the streaming transport. The previous solution amounted to creating an array of messages, pushing messages on that array from the htmlfile iframe, and popping messages off of the array in the parent ...