asp.net & grabbing a code from url
-
I have a domain where queries will be in form www.domain.com/demo12345 demo12345 being a code I need to grab & process. I need to have a single page to process these requests and the only thing this domain does, is that it reads the code and processes it. Can I do this on that domain itself or do I need to configure a redirection in IIS and grab the code from the referrer url?
-
I have a domain where queries will be in form www.domain.com/demo12345 demo12345 being a code I need to grab & process. I need to have a single page to process these requests and the only thing this domain does, is that it reads the code and processes it. Can I do this on that domain itself or do I need to configure a redirection in IIS and grab the code from the referrer url?
-
use this function Request.RawUrl() it returns a string so u do string manipulation to get the part u want from it hope this would help ...
Best Regards 3ala2 :)
-
The only problem being that how do I pass the request to the asp.net without having .aspx in the url and how do I prevent the server considering the code as folder and returning HTTP 404 when the URI is requested? Any references?
Now if u keep the class name the same and change the aspx page name to "Default" if u have a folder called "ABC123" and the "Default.aspx" page is saved in it this link will work http://localhost/YourProject/ABC123 and will redirect u to the "Default.aspx" page if this isn't helpful please post more detailed scenario ...
Best Regards 3ala2 :)
-
Now if u keep the class name the same and change the aspx page name to "Default" if u have a folder called "ABC123" and the "Default.aspx" page is saved in it this link will work http://localhost/YourProject/ABC123 and will redirect u to the "Default.aspx" page if this isn't helpful please post more detailed scenario ...
Best Regards 3ala2 :)
I'll answer this myself: Installing Wildcard Application Mappings (IIS 6.0) will configure a Web site or virtual directory to run an Internet Server API (ISAPI) application at the beginning of every request to that Web site or virtual directory, regardless of the extension of the requested file. This effectively means that no matter what was requested, it's first handled by aspnet_isapi.dll (as I configured it) After this, it's only a matter of Url Rewriting with ASP.NET Thanks for attention :)
-
I'll answer this myself: Installing Wildcard Application Mappings (IIS 6.0) will configure a Web site or virtual directory to run an Internet Server API (ISAPI) application at the beginning of every request to that Web site or virtual directory, regardless of the extension of the requested file. This effectively means that no matter what was requested, it's first handled by aspnet_isapi.dll (as I configured it) After this, it's only a matter of Url Rewriting with ASP.NET Thanks for attention :)