Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 1040355
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T15:12:49+00:00 2026-05-16T15:12:49+00:00

I am using jQuery within a server side control to post back to a

  • 0

I am using jQuery within a server side control to post back to a common handler.

For instance, I have “/handler.ashx” which services pages all over my application.

How I want some code within handler.ashx to be able to get the class which created the page that the control is on. In handler.ashx I can see the referer (for example Referer:http://localhost/Playground/form2.aspx). However, I don’t know how to use that URL to get the class Playground.Form2.

Ideas:

  1. I could obviously parse the URL and assume that is the class name, but that isn’t safe.

  2. I could use reflection to iterate through all classes which extend from Page, and check the TemplateSourceDirectory and/or AppRelativeVirtualPath to see if it is the correct object.

However, I was wondering if there is some method available I can use, or if anyone recommends not going down this road in the first place.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-16T15:12:50+00:00Added an answer on May 16, 2026 at 3:12 pm

    Rather than trying to get the type object from the Request, it might be better to pass some kind of unique identifier from the page calling the handler which identifies the requesting type. To simplify this process, you can make a static class with a method that accepts the unique identifier and returns a Type object.

    Depending on the frequency of retrieving these Type objects, it might be prudent to cache the result of the type reflection.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a page that is using jQuery tabs. Within one of my tabs
I am using jQuery.post() to send data to the server, when the server sends
I have an update panel within a div that I modal using the JQuery
Using Jquery preferably, how do I detect if an element is within the viewable
I'm using JQuery to find certain div classes within DOM & If they found
I am using the jQuery nyroModal plugin within ASP.Net. I love nyroModal, and overall
I am using JQuery to execute an operation within a web service. After writing
-- Running within ASP.NET MVC alongside jQuery -- I'm using jQuery to render a
I am using jQuery to parse an RSS feed. Within each <item> is a
Is it possible to get all div's within a page using jQuery including nested

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.