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 6783385
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T16:51:26+00:00 2026-05-26T16:51:26+00:00

I have been using PHP for a long time, but I want to move

  • 0

I have been using PHP for a long time, but I want to move to C#. However, I don’t care much for web controls and the template system. Don’t get me wrong, it is good for many projects, but not all. Sometimes I want to use my own template system

I just want to run my code on every page request and print some HTML, CSS or whatever. Just something like Response.Write() or PHPs “echo” without all the templates and controls. What is the best way to achieve this?

Edit:

This is how I would like it to work:

private void Page_Request(object sender, EventArgs e)
{
    // Do my stuff here

    Response.Write(myhtml);
}
  • 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-26T16:51:27+00:00Added an answer on May 26, 2026 at 4:51 pm

    If you want it to be as bare bones as possible, you could use generic handlers (.ashx).

    You can register routes in your web.config file, to direct the request to the appropriate handler.

    I wouldn’t recommend this approach though. Seems like a lot of extra work (you will need to write everything to the response), and will be prone to errors when you want to make changes.

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

Sidebar

Related Questions

I've been programming PHP for a long time, but not so much PHP 5...
I have been using this PHP script for a long time and this is
I have been using php from some time and I have noticed that it
I've been using SO for a long time but finally had a question I
I know this is very newbyish but I have been using php.net for refernce
I am new to developing in .NET and C#, but have been a long-time
I know namespaces are new in PHP but have been around for a long
I've been working with PHP for a long time, but am now starting to
I have been a long-term .NET developer, but dabble in Java and PHP development
I have been using PHP and JavaScript for building my dad's website. He wants

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.