HTML eementer i websider gir feil

by tesagen 26. april 2010 19:10

Hvis HTML elementer skrives i tekstfelt til ASPX sider så kommer det feilmelding.
Dette kan endres ved å stte følgende side deklarasjon:

 ValidateRequest="false"

<%@ Page Language="vb" AutoEventWireup="false"  ValidateRequest="false" CodeBehind="Results.aspx.vb" Inherits="If_Skade.Results" %>

Disabling request validation for your application

To disable request validation for your application, you must modify or create a Web.config file for your application and set the validateRequest attribute of the <pages /> section to false:

<configuration> <system.web> <pages validateRequest="false" /> </system.web> </configuration>

If you wish to disable request validation for all applications on your server, you can make this modification to your Machine.config file.

Caution: When request validation is disabled, content can be submitted to your application; it is the responsibility of the application developer to ensure that content is properly encoded or processed.

The code below is modified to turn off request validation:

Tags: , ,

ASPX

Legg inn kommentar




  Country flag

  • Kommentar
  • Forhåndsvisning
Loading


Velkommen

Hei

Denen siden inneholder private programerings snutter

Været

Månedsliste

Nyeste Innlegg

Kalender

<<  mai 2012  >>
mationtofr
30123456
78910111213
14151617181920
21222324252627
28293031123
45678910

View posts in large calendar