Based on the following url, http://www.domain.com/c-61-page-name.aspx

In the master page, how would I get the value '61'?

In my master page I have the following, but right now I am hard coding the value. I want to dynamically grab the entityid and then pass to xml.config file.
Code:
<asp:Literal ID="ltlTitleName" runat="server" Text="<%$ Tokens:XMLPACKAGE, ProductLanding-GetTitle.xml.config, parametername=61 %>" />
Thanks for any info you can provide.