473,468 Members | 4,640 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

HtmlForm Help...Again

Hi,

I have a control that derives from the HtmlForm control. The difference is that I can set the action attribute to whatever I
desire. This works fine. :-)

What I can't seem to do is prevent the form from mangling the ID and Name attributes of the controls I'm using. I see them
in the url and it makes me sick. Also, I notice that the _VIEWSTATE and _EVENTVALIDATION hidden controls are sent in the url
as well. The changing of attributes and the unwanted controls are only in the url when I set the method attribute to "GET."
Is there any way to prevent these things from happening? (I don't need the viewstate stuff, in case you're wondering)

Thanks,
Roshawn
Feb 2 '07 #1
3 1480
an action of get tells the browser to send all form element pairs on the
url instead of after the headers (postdata), this includes all hidden
fields. if you don't need any form data then use link instead.

-- bruce (sqlwork.com)

Roshawn wrote:
Hi,

I have a control that derives from the HtmlForm control. The difference
is that I can set the action attribute to whatever I desire. This works
fine. :-)

What I can't seem to do is prevent the form from mangling the ID and
Name attributes of the controls I'm using. I see them in the url and it
makes me sick. Also, I notice that the _VIEWSTATE and _EVENTVALIDATION
hidden controls are sent in the url as well. The changing of attributes
and the unwanted controls are only in the url when I set the method
attribute to "GET." Is there any way to prevent these things from
happening? (I don't need the viewstate stuff, in case you're wondering)

Thanks,
Roshawn
Feb 2 '07 #2
Thanks for the tip. :-)

bruce barker wrote:
an action of get tells the browser to send all form element pairs on the
url instead of after the headers (postdata), this includes all hidden
fields. if you don't need any form data then use link instead.

-- bruce (sqlwork.com)
Feb 2 '07 #3
I do need the form data; I just don't need the __VIEWSTATE or __EVENTVALIDATION functionality. I can maintain the state of
the web control without these things.

bruce barker wrote:
an action of get tells the browser to send all form element pairs on the
url instead of after the headers (postdata), this includes all hidden
fields. if you don't need any form data then use link instead.

-- bruce (sqlwork.com)
Feb 2 '07 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

9
by: Dom Boyce | last post by:
Hi First up, I am using MS Access 2002. I have a database which records analyst rating changes for a list of companies on a daily basis. Unfortunately, the database has been set up (by my...
0
by: Jeff Dockman | last post by:
Background: We needed the ability to create a templated web site that may change in layout from installation to installation. To accomplish this, we created a base Page class that all pages in...
2
by: Jiho Han | last post by:
In CreateChildControls method of my Page, I am trying to see if a hidden input field is present (by id) and if not, add it to a predefined form (by id). protected override void...
0
by: VB Programmer | last post by:
I have 2 webforms. When I print out the page.Controls(1).tostring variable one says "HtmlForm", the other "HtmlGenericControl". How can I change the first one to "HtmlForm"? ?...
2
by: Shawn | last post by:
Hi. I'm trying to loop through all webcontrols in my System.Web.UI.HtmlControls.HtmlForm. This is my code: Dim form As HtmlForm Dim control As Control form = Me.FindControl("completion")...
0
by: Wouter vanEck | last post by:
Hi All, I have the following problem, I have a string for example "<table><tr></td><MyTextBox /></td></tr></table>" which is created by a user typing in a textbox. Now I like to take that...
14
by: Laser Lu | last post by:
Hello, All, I just want to know that generally how to get the HtmlForm element in an ASP.NET Page? Can anybody help? Please:) Best regards, Laser Lu
0
by: Bruno | last post by:
Hello guys, I'm having problem using tagMapping with HtmlForm, I have this in web.config: <tagMapping> <add tagType="System.Web.UI.HtmlControls.HtmlForm" mappedTagType="CustomForm" />...
1
by: mwalts | last post by:
Hello all, I have to write a web part for a SharePoint 2003 server. We only have one SharePoint server, so developing directly on it isn't really viable. So I've planned to do the majority of...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.