473,651 Members | 2,546 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

What's the use of hidden form?

Hi, guys:
I am trying debug other people(who has left company)'s ASP code, and had
difficulty understanding the use of a hidden asp page.

The application has an index page, like MyIndex.asp which has nothing but
a couple of other asp files, like
<frameset COLS="0,0,52%, *">
<frame NAME="hidden" SRC="MyHidden.a sp">
<frame NAME="content" SRC="MyContent. asp">
</frameset>

MyHidden.asp is like this:
<!-- #include file="MyHidden. js" -->
<SCRIPT LANGUAGE=VBScri pt RUNAT=Server>
' a LOT of server code retrieving data from database, and populate to
local variables.
Response.Write( "<HTML><HEAD><T ITLE></TITLE>")
Response.Write( "<meta http-equiv='Content-Type' content='text/html'>")

Response.Write( "</HEAD><BODY onBeforeUnLoad= 'unLoadForm()'> ")
Response.Write( "<FORM name='MyForm' ACTION='MyHidde n.asp' METHOD=POST>")

Response.Write( "<TEXTAREA NAME='txtStatus '>" & sStatus & "</TEXTAREA>")
Response.Write( "<INPUT TYPE='text' NAME='txtComman d' VALUE=" & sCmd & ">")
Response.Write( "<INPUT TYPE='text' NAME='txtSubmit ToManager' VALUE=0>")
Response.Write( "<INPUT TYPE='text' NAME='txtReadOn ly' VALUE=" & bReadOnly
& ">")
Response.Write( "<INPUT TYPE='text' NAME='txtCount' VALUE=" & iCnt & ">")
Response.Write( "<INPUT TYPE='text' NAME='txtUserId ' VALUE=" & nTimeTrackId
& ">")

Response.Write( "</FORM>")
Response.Write( "</BODY></HTML>")

My question is: with all these "response.write " in MyHidden.asp, I don't
actually see them anywhere on the web page, nor do I know what this hidden
form is for.

What if I want to check the values of some variables? When I added one
more Response.Write( "iCnt=" & iCnt ), the page gives me error.

So... can somebody help me interpret the code? Thanks!
Jul 22 '05 #1
6 1897
people use them to "store" things, like variable values, etc, for later use.
You write things to them. Since they are in a frameset they dont get
lost/wiped unless the parent does. It's a way around using sessions or
passing values to every form all the time.
--
Curt Christianson
Site & Scripts: http://www.Darkfalz.com
Blog: http://blog.Darkfalz.com
"GoCMS" <Go***@discussi ons.microsoft.c om> wrote in message
news:0D******** *************** ***********@mic rosoft.com...
Hi, guys:
I am trying debug other people(who has left company)'s ASP code, and had
difficulty understanding the use of a hidden asp page.

The application has an index page, like MyIndex.asp which has nothing but
a couple of other asp files, like
<frameset COLS="0,0,52%, *">
<frame NAME="hidden" SRC="MyHidden.a sp">
<frame NAME="content" SRC="MyContent. asp">
</frameset>

MyHidden.asp is like this:
<!-- #include file="MyHidden. js" -->
<SCRIPT LANGUAGE=VBScri pt RUNAT=Server>
' a LOT of server code retrieving data from database, and populate to
local variables.
Response.Write( "<HTML><HEAD><T ITLE></TITLE>")
Response.Write( "<meta http-equiv='Content-Type' content='text/html'>")

Response.Write( "</HEAD><BODY onBeforeUnLoad= 'unLoadForm()'> ")
Response.Write( "<FORM name='MyForm' ACTION='MyHidde n.asp' METHOD=POST>")

Response.Write( "<TEXTAREA NAME='txtStatus '>" & sStatus & "</TEXTAREA>")
Response.Write( "<INPUT TYPE='text' NAME='txtComman d' VALUE=" & sCmd &
">")
Response.Write( "<INPUT TYPE='text' NAME='txtSubmit ToManager' VALUE=0>")
Response.Write( "<INPUT TYPE='text' NAME='txtReadOn ly' VALUE=" & bReadOnly
& ">")
Response.Write( "<INPUT TYPE='text' NAME='txtCount' VALUE=" & iCnt & ">")
Response.Write( "<INPUT TYPE='text' NAME='txtUserId ' VALUE=" &
nTimeTrackId
& ">")

Response.Write( "</FORM>")
Response.Write( "</BODY></HTML>")

My question is: with all these "response.write " in MyHidden.asp, I don't
actually see them anywhere on the web page, nor do I know what this hidden
form is for.

What if I want to check the values of some variables? When I added one
more Response.Write( "iCnt=" & iCnt ), the page gives me error.

So... can somebody help me interpret the code? Thanks!

Jul 22 '05 #2
It looks like it posts to itself. Do you see in myhidden.asp some code that
handles the post. It would allow to see what it does server side with this
information. My guess would be some kind of navigation tracking system ???

What is the error you have if you add some code tho this page ? You could
also likely just change the frameset to reveal those hidden fields allowing
to see how it evolves as you goes through pages...

Good luck.

Patrice

--

"GoCMS" <Go***@discussi ons.microsoft.c om> a écrit dans le message de
news:0D******** *************** ***********@mic rosoft.com...
Hi, guys:
I am trying debug other people(who has left company)'s ASP code, and had
difficulty understanding the use of a hidden asp page.

The application has an index page, like MyIndex.asp which has nothing but a couple of other asp files, like
<frameset COLS="0,0,52%, *">
<frame NAME="hidden" SRC="MyHidden.a sp">
<frame NAME="content" SRC="MyContent. asp">
</frameset>

MyHidden.asp is like this:
<!-- #include file="MyHidden. js" -->
<SCRIPT LANGUAGE=VBScri pt RUNAT=Server>
' a LOT of server code retrieving data from database, and populate to
local variables.
Response.Write( "<HTML><HEAD><T ITLE></TITLE>")
Response.Write( "<meta http-equiv='Content-Type' content='text/html'>")

Response.Write( "</HEAD><BODY onBeforeUnLoad= 'unLoadForm()'> ")
Response.Write( "<FORM name='MyForm' ACTION='MyHidde n.asp' METHOD=POST>")

Response.Write( "<TEXTAREA NAME='txtStatus '>" & sStatus & "</TEXTAREA>")
Response.Write( "<INPUT TYPE='text' NAME='txtComman d' VALUE=" & sCmd & ">") Response.Write( "<INPUT TYPE='text' NAME='txtSubmit ToManager' VALUE=0>")
Response.Write( "<INPUT TYPE='text' NAME='txtReadOn ly' VALUE=" & bReadOnly & ">")
Response.Write( "<INPUT TYPE='text' NAME='txtCount' VALUE=" & iCnt & ">")
Response.Write( "<INPUT TYPE='text' NAME='txtUserId ' VALUE=" & nTimeTrackId & ">")

Response.Write( "</FORM>")
Response.Write( "</BODY></HTML>")

My question is: with all these "response.write " in MyHidden.asp, I don't actually see them anywhere on the web page, nor do I know what this hidden
form is for.

What if I want to check the values of some variables? When I added one
more Response.Write( "iCnt=" & iCnt ), the page gives me error.

So... can somebody help me interpret the code? Thanks!

Jul 22 '05 #3
Thanks for the reply. I still wonder why this form is not visible from the
web page, and how to check the values to be right.

"Patrice" wrote:
It looks like it posts to itself. Do you see in myhidden.asp some code that
handles the post. It would allow to see what it does server side with this
information. My guess would be some kind of navigation tracking system ???

What is the error you have if you add some code tho this page ? You could
also likely just change the frameset to reveal those hidden fields allowing
to see how it evolves as you goes through pages...

Good luck.

Patrice

--

"GoCMS" <Go***@discussi ons.microsoft.c om> a écrit dans le message de
news:0D******** *************** ***********@mic rosoft.com...
Hi, guys:
I am trying debug other people(who has left company)'s ASP code, and had
difficulty understanding the use of a hidden asp page.

The application has an index page, like MyIndex.asp which has nothing

but
a couple of other asp files, like
<frameset COLS="0,0,52%, *">
<frame NAME="hidden" SRC="MyHidden.a sp">
<frame NAME="content" SRC="MyContent. asp">
</frameset>

MyHidden.asp is like this:
<!-- #include file="MyHidden. js" -->
<SCRIPT LANGUAGE=VBScri pt RUNAT=Server>
' a LOT of server code retrieving data from database, and populate to
local variables.
Response.Write( "<HTML><HEAD><T ITLE></TITLE>")
Response.Write( "<meta http-equiv='Content-Type' content='text/html'>")

Response.Write( "</HEAD><BODY onBeforeUnLoad= 'unLoadForm()'> ")
Response.Write( "<FORM name='MyForm' ACTION='MyHidde n.asp' METHOD=POST>")

Response.Write( "<TEXTAREA NAME='txtStatus '>" & sStatus & "

Jul 22 '05 #4
Unless I misundersttod it looks like it is in a 0 sized frame. If You change
this you should see the form...

Patrice

--

"GoCMS" <Go***@discussi ons.microsoft.c om> a écrit dans le message de
news:63******** *************** ***********@mic rosoft.com...
Thanks for the reply. I still wonder why this form is not visible from the
web page, and how to check the values to be right.

"Patrice" wrote:
It looks like it posts to itself. Do you see in myhidden.asp some code that handles the post. It would allow to see what it does server side with this information. My guess would be some kind of navigation tracking system ???
What is the error you have if you add some code tho this page ? You could also likely just change the frameset to reveal those hidden fields allowing to see how it evolves as you goes through pages...

Good luck.

Patrice

--

"GoCMS" <Go***@discussi ons.microsoft.c om> a écrit dans le message de
news:0D******** *************** ***********@mic rosoft.com...
Hi, guys:
I am trying debug other people(who has left company)'s ASP code, and had difficulty understanding the use of a hidden asp page.

The application has an index page, like MyIndex.asp which has nothing
but
a couple of other asp files, like
<frameset COLS="0,0,52%, *">
<frame NAME="hidden" SRC="MyHidden.a sp">
<frame NAME="content" SRC="MyContent. asp">
</frameset>

MyHidden.asp is like this:
<!-- #include file="MyHidden. js" -->
<SCRIPT LANGUAGE=VBScri pt RUNAT=Server>
' a LOT of server code retrieving data from database, and populate

to local variables.
Response.Write( "<HTML><HEAD><T ITLE></TITLE>")
Response.Write( "<meta http-equiv='Content-Type' content='text/html'>")
Response.Write( "</HEAD><BODY onBeforeUnLoad= 'unLoadForm()'> ")
Response.Write( "<FORM name='MyForm' ACTION='MyHidde n.asp' METHOD=POST>")
Response.Write( "<TEXTAREA NAME='txtStatus '>" & sStatus & "

Jul 22 '05 #5
Yeah...I was so careless. Thanks! Both the server and client side are using
this hidden information. Client side uses it in javascript function to
manipulate other items in other form, and server side uses it to update
database. Now it makes more sense. :)

"Patrice" wrote:
Unless I misundersttod it looks like it is in a 0 sized frame. If You change
this you should see the form...

Patrice

--

"GoCMS" <Go***@discussi ons.microsoft.c om> a écrit dans le message de
news:63******** *************** ***********@mic rosoft.com...
Thanks for the reply. I still wonder why this form is not visible from the
web page, and how to check the values to be right.

"Patrice" wrote:
It looks like it posts to itself. Do you see in myhidden.asp some code that handles the post. It would allow to see what it does server side with this information. My guess would be some kind of navigation tracking system ???
What is the error you have if you add some code tho this page ? You could also likely just change the frameset to reveal those hidden fields allowing to see how it evolves as you goes through pages...

Good luck.

Patrice

--

"GoCMS" <Go***@discussi ons.microsoft.c om> a écrit dans le message de
news:0D******** *************** ***********@mic rosoft.com...
> Hi, guys:
> I am trying debug other people(who has left company)'s ASP code, and had > difficulty understanding the use of a hidden asp page.
>
> The application has an index page, like MyIndex.asp which has nothing but
> a couple of other asp files, like
> <frameset COLS="0,0,52%, *">
> <frame NAME="hidden" SRC="MyHidden.a sp">
> <frame NAME="content" SRC="MyContent. asp">
> </frameset>
>
> MyHidden.asp is like this:
> <!-- #include file="MyHidden. js" -->
> <SCRIPT LANGUAGE=VBScri pt RUNAT=Server>
> ' a LOT of server code retrieving data from database, and populate to > local variables.
> Response.Write( "<HTML><HEAD><T ITLE></TITLE>")
> Response.Write( "<meta http-equiv='Content-Type' content='text/html'>") >
> Response.Write( "</HEAD><BODY onBeforeUnLoad= 'unLoadForm()'> ")
> Response.Write( "<FORM name='MyForm' ACTION='MyHidde n.asp' METHOD=POST>") >
> Response.Write( "<TEXTAREA NAME='txtStatus '>" & sStatus & "


Jul 22 '05 #6
> <frameset COLS="0,0,52%, *">
<frame NAME="hidden" SRC="MyHidden.a sp">
<frame NAME="content" SRC="MyContent. asp">
</frameset>


This frameset declares 4 "columns" - the first and second being 0 wide, the
third column uses 52% of the window width and the forth column takes up the
remainer - in this case 48%

You can view the "myhidden.a sp" page by modifying the first column to be
something other than zero. From the above example, it looks like
"MyContent. asp" page is also zero width.

Anyway, the values stored on this hidden page are available to any client-side
code which can be addressed in any other page using code like this:

window.parent.f rames(0).myForm .txtUserId.valu e

The hidden window is designed to hold common values on the client that any
other HTML page might want to use or reference.

Brian

Jul 22 '05 #7

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

Similar topics

8
17297
by: Matt Herson | last post by:
I have been trying to find a way to use JavaScript to change the value of a hidden field on submit. I am already invoking a JavaScript to handle the validation on submit. The reason I need to change this field is some of the forms have two buttons on them, each needs to process the form differently. If I can change the value of the hidden field dynamically it will solve my issue as I can run each against a diffent cgi. Currently my...
1
3487
by: Sam Wuebben | last post by:
I would like to add a few hidden field values to a form as it is submited via JavaScript. I have a static page shopping site that uses MIVA shopping cart. Some of the pages are getting quite large and I want to start reducing the amount of code on each page. Replacing tables with divs are helping some but not as much as I would like. Some pages may have up to 100 different items on it and each one has its own form for submitting the...
2
1347
by: francisco lopez | last post by:
Yesterday I had a problem with a javascript to validate my form, but you helped my out yesterday and it works now perfectly!!! so thank you!!! the problem I have now is the following: I put my form now on the server and I changed following lines: I changed: form action="mailto:fran@gmx.net"
5
2282
by: Werner Partner | last post by:
On my testpage http://www.sonoptikon.de/test.php I have this <table><tr> <td valign="top" align="center" style="width:150px;"> <form action=test.php method="get">
1
1840
by: Madame Blablavatsky | last post by:
hello, i am trying to build a kind of very, very simple ritch text editor for people to use with a very simple cms. at the moment i am working on the basic structure. the text is put in an iframe. then a hidden textfield gets the value from the content of that iframe. then the hidden textfield is sent to a php-page so it can be put in a
12
7433
by: Alan Silver | last post by:
Hello, I have a page that gets passed an ID in the query string. It then uses this ID to pull info out of a database and populate controls on the page. When the page is posted back, the query string is not going to be there any more, so I need some way of storing the ID. What's the best way of doing this? The obvious thought is a hidden form field, but there doesn't seem to be a web control for this. Do I just use an ordinary HTML...
4
1902
by: _Raven | last post by:
Okay, I am playing with submitting forms with Ajax. I am trying to adapt this script to my forms: http://www.captain.at/howto-ajax-form-post-get.php I have included my code at the bottom of this post. Basically, this will work correctly if I remove all non-form related tags from the form =eg span, div, but I want to format the form all pretty like so??? Right now, it only collects 2 parts of the form fields =sites &
2
2567
by: Tarik Monem | last post by:
OK! I've gone through a few tutorials and I cannot understand what I'm doing wrong casting_registration.php <table> <tr> <td> <form enctype="multipart/form-data" action="thankyou.php" method="post" name="registrationform"> Choose a shows:
0
1524
by: stefcollect | last post by:
Hi all, I am pretty new to PHP and am stuck on - what I think - is a generic string handling problem. I need to read and manipulate some HTML files and have a problem in getting some substrings found even when - it is clear - strings are there. (see a HTML chunk I need to edit at the end of this email). In particular, the following functions are "randomly" working for me:
0
8347
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8275
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
1
8457
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8571
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6157
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 presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5605
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 then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4143
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
2696
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 we have to send another system
1
1905
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.