I was going to say you could save yourself some time with a SiteMapPath control but I'm not 100% sure the SiteMap will differentiate between parameterised URLs, you could always give it a go though and see. Click Here for the microsoft page on the SiteMapPath control
I'm sure you're storing the name of your sites in a variable called "page" so echo its value. That is the first solution.
The second solution is to get the URL and break it down and get whatever name appears after "name=" then echo it or optionally, store its value in a variable then echo it.
I hope this helps.