Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Connecting to a DB on the Frameset page for a frame child

Status
Not open for further replies.

morsagmon

Programmer
Jan 5, 2001
9
0
0
US
Hi.

I have a Frameset page that calls two Frames.

On that Frameset page I run many ASP processings.

I need to query a SQL 7 DB in one of the childs (frames), but I cannot Open the connection in that child, as username & password info are available to the father (Frameset page) only and I cannot pass these as URL parameters to the child page.

Can you show me the way (If there is any) to define the connection object and to open the connection to the DB in the Father and yet pass a handle parameter or something to a frame's SRC for using that connection ?

Thanks,

Mor.
 
try to use session variables!
you store in session variables like this:

session("Username") = "Blabla"

in any asp page on the site you can then:
<%=Session(&quot;Username&quot;)%>

rgrds Silvers5
As seen on EE
 
why don't you do what the microsoft page says to do and use cookies? ray
rheindl@bju.edu

 
This application can't rely on thick clients enabling cookies. If I'll have no choice I might consider it later.

Mor.
 
then pass the values in the querystring of the frame! (my.asp?var1=blabla&amp;var2=blabla.. it's a solution! Silvers5
As seen on EE
 
I can't.
1. There are username and password fields among those parameters.
2. The called asp file may be called directly from another source, with a regular FORM, passing these parameters in POST and I prefer not to modify the code in such a way that will enable it to handle both POSTed and GETed parameters.

Mor.
 
have u tried to establish the connection string in a separate file on the server then link it to the framed page using SSI (server side include)???
 
.. You can encrypt the query string, you can pass an encrypted date stamp with the string.. but since it's a frame..? Silvers5
As seen on EE
 
i have my senior project using asp technology my sp was an online checking of internet bills (only for those subscribers) the problem is how can i connect to the account of the subscribers in the internet. Is it possible to make a temporary account just to test only those who are logging. The account i preferring is the internet account of the subscribers.
what is remote dial in user service?
 
hi.. i just try the suggestion silvers5 said by using session.. but it's still don't work.. the id cannot be trace to another id(in form/file).. eg: ID from file try1 to try2 connecting with ID. password only login once u enter it (the 1st page).. then it just carried to another pages. do u hava any ideas how should i do...
i'm a begginner programmer online...
thanks
 
Microsoft OLE DB Provider for ODBC Drivers error '80040e14'
[Microsoft][ODBC SQL Server Driver][SQL Server]INSERT statement conflicted with COLUMN FOREIGN KEY constraint 'FK_TerimaA_CiptaA'. The conflict occurred in database 'ewk', table 'CiptaA', column 'IDBantuan'.
/e-bantuan/e-bantuan_try/TMPw7bwmbvr8.asp, line 115
line 115 MM_editCmd.Execute

this is error that happend when i submit data to SQL.. i don't know how to improve it.. i try hardly but still same problem occur.. i'm using Macromedia dreamweaver MX as tools for built my system online(asp)..
hopefully can somebody answer my question..

tengku
thanks.
 
Your INSERT statement violates a referential constraint.
You try to insert a row with a foreign key colummn with no corresponding value in the reference table.
See your DBA for more explanation.

Hope This Help
PH.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top