Hi Tony,
The menu knows what the current page is by the pageid=x param in the query string, however with url re-writing you don't really see the query string on content system pages. The content system pages are all virtual, they don't correspond to physical pages, they are really all server by Default.aspx.
Really, I think where you are going wrong is trying to develop a page in the first place, you should develop a UserControl inheriting from SiteModuleControl as discussed here:
http://www.mojoportal.com/overviewofcontentfeaturedevelopment.aspx
Then you can plug your feature into a content system page like any of the other features and you don't have to worry about the menu, it will just work as it should. For complex features you may need to link from your modulecontrol to external physical pages. For example on this site the Forums ModuleControl plugs into a content page but from there it links to a number of supporting physical pages like ForumThreadView.aspx etc, you can notice in the urls the reason the menu stays highlighted correctly is because the pageid is passed to the external pages in the query string.
Hope it helps,
Joe