ASP.NET 4.0 C# WebForms
I have route.Ignore("{resource}.axd/{*pathInfo}");
in my global.asax for my ajax to work correctly.
The control is a "MSCaptcha".
It shows the path in sourcefile http://localhost:666/Project/CaptchaImage.axd?guid=96f830ee-6fb9-42ad-9ff4-d6484ffdcbe4
but does not show the "image".
Can I add something to my global.asax to get the captcha control to work? Any suggestions?
It looks like you want to be able to ignore your captchaImage.axd at different depths in your virtual folder hierarchy? This would require handling multiple segments via routing which isn't convenient in your case. It would be better to "fix" the location of the CaptchaImage.axd to a certain path, ignore that path via routing, and always reference the CaptchaImage.axd at that one location.
Details on asp.net routing. http://msdn.microsoft.com/en-us/library/cc668201.aspx
You do need to set it to ignore at the different levels as mentioned by Kenneth. In my app, we only dealt with one level deep. However, you can use the following code and set multiple levels.
routes.Ignore("{parent}/{sub}/{resource}.axd");
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With