03.29.07

I Should Gamble Today

Posted in Bugs at 11:03 am by Željko Filipin

What is the chance of visiting a page that has a certificate that has expired nine minutes ago? :)

tcom.PNG

tcom1.PNG

03.28.07

Upload

Posted in Software at 5:14 pm by Željko Filipin

Today I had to upload a big file (over 15 MB) and I had some problems with uploading. I tried different applications. Accidentally, I had Windows Task Manager opened while uploading and noticed interesting patterns.

This is how downloading file with Internet Explorer looks like.

ie_download.png

Upload to ASP.NET page with with Internet Explorer.

ie_asp.png

Upload to SharePoint page with with Internet Explorer.

ie_sp.png

Upload to ASP.NET page with with Firefox.

ff.png

Sending e-mail with Outlook Express.

oe.png

Uploading file with FileZilla.

fz.png

03.22.07

First Steps in ASP.NET

Posted in .NET at 2:13 pm by Željko Filipin

asp.png

My developer is using ASP.NET. I decided to learn basics of it. After all, you have to know your enemy. As it usually goes, pretty soon I got into trouble. Internet Information Services (IIS 5.1) at my machine (Windows XP Professional, Service Pack 2) was processing server code of asp pages, but not of aspx. Internet Explorer would show HTML portion of aspx page, but server code was ignored. Firefox was showing asp pages, but for aspx pages I was getting “open with” pop-up.

What went wrong? .NET Framework and IIS are installed.

I started looking at Internet Information Services (Start > All Programs > Administrative Tools > Internet Information Services). At ASP.NET tab of Web Sites Properties window (Internet Information Services > local computer > Web Sites > right click > Properties ) I saw that ASP.NET version is not selected, so I selected 2.0.50727 (1.1.4322 was also available).

No luck. I started getting this error page.

Server Application Unavailable

Time to ask my developer for help. He said I should create virtual directory.

  • at C:\Inetpub\wwwroot\ create directory asp
  • Internet Information Services > local computer > Web Sites > Default Web Site > right click > New > Virtual Directory… > enter alias (”asp” sounds good) > browse to directory > make sure “Read” and “Run scripts (such as ASP)” checkboxes are checked
  • Internet Information Services > local computer > Web Sites > Default Web Site > virtual directory alias (”asp”, remember) > right click > Properties > ASP.NET > ASP.NET version > 2.0.50727

Then I got different error message.

Failed to access IIS metabase.

According to Failed to access IIS metabase blog post from R. Aaron Zupancic, the problem was:

You may have installed IIS after installing the .NET framework.

True. I installed .NET framework immediately after I installed Windows, and I installed IIS later when I needed it. Solution? Open command prompt, go to C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727 and execute

aspnet_regiis -i

Everything works fine now. Firefox needed some time to start recognizing aspx pages (I was still getting “open with” pop-up), but now it works.

03.16.07

WordPress Error: “Cannot modify header information - headers already sent”

Posted in Bugs at 4:06 pm by Željko Filipin

There was important security update of Wordpress recently. In upgrade instructions it is suggested to delete old files on the server, and then upload new files, and I did as they suggested.

A few days ago I wanted to upload an image and got this error message.

The uploaded file could not be moved to [...]/wp-content/uploads/[...].
Warning: Cannot modify header information - headers already sent by (output started at [...]/wp-admin/admin-functions.php:1879) in [...]/wp-includes/functions.php on line 1219

WordPress

94

I searched for that error message, but did not find anything useful. I looked at source files mentioned, but I am not very familiar with PHP, so no luck there too.

Then I remembered that I had problems previously after upgrading because Wordpress did not have permission to write to upload folder. I checked it and yes, that was the problem. I fixed permissions and upload worked again.

I am just surprised how error message did not say that Wordpress does not have permission to write to a folder, but something about headers. I thought that not having permission is one of the common scenarios.

03.15.07

Repeat Feature of Microsoft Excel

Posted in Software at 1:00 pm by Željko Filipin

While I am in “tip mode”… :)

I found out something very useful in Microsoft Excel. There is feature called repeat (Ctrl+Y). It is not only the opposite of undo. With it you can repeat action you have just performed.

Time for an example. I will not go into detail. I had a lot of data in one row, a few hundred cells (if I remember correctly, maybe even over thousand), and I wanted to move some cells to the right.

dog
cat
elephant

I had to visually look at that data and some of it move to the right column. In this example, I would move elephant. (I leave it to you, dear reader, to figure out why.) I could cut elephant and paste it in the cell to the right. Let’s count keyboard actions. (Remember, I had to do it a lot, so every keyboard or mouse click counts.)

  1. Ctrl+X
  2. Right Cursor
  3. Ctrl+V

Three actions. Now table looks like this.

dog
cat
elephant

I could get the same result with inserting cell and moving original cell to the right. Right click “elephant” cell, from context menu select Insert… > Shift cells right > OK. (I used mouse to do that, but there is also “right click” key on your keyboard. It is just to the right of “any” key. Just kidding. It is to the left of right “Ctrl” key on my keyboard. Really.) A lot of clicking. But, after you do it once, Excel remembers that you have just inserted cell and moved previous content to the right. And you can repeat that action on another cell with Ctrl+Y.

So, when you have to repeat some action that requires a lot of clicking (mouse or keyboard), you can do it just once, and that repeat that action with Ctrl+Y. It saved me a lot of time.

03.14.07

Capitalization of Titles

Posted in Software at 4:31 pm by Željko Filipin

capitalization.png

Another very useful feature of Microsoft Word is capitalization of titles. If you need a quick way to correctly capitalize your title, type

capitalization of titles

in Microsoft Word, select it, Format > Change Case… > Title Case > OK.

It will change to

Capitalization Of Titles

Run spell checking and it will tell you that “Of” should be “of”. Change it, and you are done.

Capitalization of Titles

03.13.07

Go To Page Feature in Microsoft Word

Posted in Software at 12:00 pm by Željko Filipin

word.png

Recently I had to visually compare pdf and doc file. There was over one hundred pages of text. I used Adobe Reader for pdf file and Microsoft Word for doc file. I had to jump from page to page a lot (not sequential pages). Adobe Reader has “go to page” feature that I find very useful. I could not find it in Microsoft Word. I knew it had to be there, but it took me some time (and help from my wife) to find it. Here it is: “Edit > Go To…” or Ctrl+G. So simple.

03.12.07

I Do Not Want All My Internet Traffic to Go Over VPN

Posted in Software at 4:58 pm by Željko Filipin

VPN

Few days ago I created another virtual private network (VPN) connection at my machine. All of my Internet traffic was going over that connection. Because I am connected to a machine located in Switzerland, sites that recognize that were giving me pages translated to German. My German is not so good, so I wanted to disable all my traffic going over VPN. My developer showed me how to do it a few months ago, but I forgot it. I have a really bad memory.

I could not reach him at the moment, so I searched all our instant message and e-mail conversation, but I could not find that information. I looked at VPN’s properties, but nothing looked familiar. I knew it is simple, but I just could not find it. So, I waited until he returned.

Now that I know it again, I just have to write it down. I will forget it.

Go to Network Connections, right click connection, Properties > Networking > This connection uses the following items > Internet Protocol (TCP/IP) > Properties > Advanced… > General > Use default gateway on remote network > uncheck.

03.02.07

Two Years with Ruby and Watir

Posted in Watir at 5:58 pm by Željko Filipin

dw-974859.jpg

According to Watir Users page at Watir wiki I have been using Ruby and Watir for two years. I checked SVN log, and the first entry is dated 11th March 2005. I checked out the code. There is 58 files in three folders. Tests are for two projects, and the biggest file has over 600 lines, so I guess I was writing scripts for month or two before I checked it into SVN.

By the way, the code is horrible. :) I have read somewhere that if you look at your old code and you do not think

What was I thinking when I wrote this?!?!

it means that you have not learned anything since then.

It has been interesting two years.

The picture is from http://www.allaboardtoys.com/assets/product_imagesm/DW-974859.jpg.