ASP.NET 3.5 웹 응용 프로그램의 기본 "일반 처리기"코드가 클래스에 특성을 추가하지만 올바른 네임 스페이스 참조를 추가하지 않는 이유는 무엇입니까?ASP.NET 3.5의 처리기 (ASHX)에 대한 설명
using System.Web.Services;
는 Microsoft의 기본 템플릿의 버그 :
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
namespace Handler1
{
/// <summary>
/// Summary description for $codebehindclassname$
/// </summary>
[WebService(Namespace = "http://tempuri.org/")]
[WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
public class People : IHttpHandler
{
public void ProcessRequest(HttpContext context)
{
context.Response.ContentType = "text/plain";
context.Response.Write("Hello World");
}
public bool IsReusable
{
get
{
return false;
}
}
}
}
그들은 왜 상단에 라인이없는 : 이것은 그들이 밖으로의 상자를주는 템플릿입니다? 내가 놓친 게 있니?
\ 내가 9.0 이상 이동 해요 MVC에. 하지만 3.5로 업그레이드 된 일부 구형 앱에는 여전히 ASHX 파일이 필요합니다. 난 그냥 내 템플릿을 수정합니다. +1과 대답 모두 도와 주셔서 감사합니다. – BuddyJoe