Re: [PHP] More include issues

2007-06-06 Thread Dan Shirah
Sorry Stut, I am fairly newb and don't know all the in's and out's of all the functionality. I thought I had a good grasp on th edatabase connection part, but obviously was having a major oversight. Sorry for the confusion and THANK YOU for sticking with me to get this issue resolved. I try not

Re: [PHP] More include issues

2007-06-06 Thread Stut
Dan Shirah wrote: It seems that PHP is getting confused unless I post the $database = mssql_select_db("database", $connection) or die ('DB selection failed'); before the query. This is probably due to the fact that I am pulling information from multiple databases (Two MSSQL and One Informix)

Re: [PHP] More include issues

2007-06-06 Thread Richard Lynch
Use two different $connection variables, say, $mssql and $informix and pass them in as the optional arg to _query or whatever, and then you can avoid flip-flopping like that. On Wed, June 6, 2007 3:53 pm, Dan Shirah wrote: > It seems that PHP is getting confused unless I post the $database = > mss

Re: [PHP] More include issues

2007-06-06 Thread Dan Shirah
It seems that PHP is getting confused unless I post the $database = mssql_select_db("database", $connection) or die ('DB selection failed'); before the query. This is probably due to the fact that I am pulling information from multiple databases (Two MSSQL and One Informix) So if my query just

Re: [PHP] More include issues

2007-06-06 Thread Stut
Dan Shirah wrote: I thought that if you made a connection at the beginning of a page, that you could use that connection throughout the page without having to type it over again as long as you did not explicitly put in code to close the connection?? Which is why I only inserted the include fil

Re: [PHP] More include issues

2007-06-06 Thread Dan Shirah
I thought that if you made a connection at the beginning of a page, that you could use that connection throughout the page without having to type it over again as long as you did not explicitly put in code to close the connection?? Which is why I only inserted the include fil at the beginning of

Re: [PHP] More include issues

2007-06-06 Thread Richard Lynch
On Wed, June 6, 2007 3:24 pm, Dan Shirah wrote: > Yes, I have error_reporting = E_ALL and show_warnings = On. Use phpinfo to confirm that, because... > Here's something interesting...if I put the include directly above the > code > for the dropdown it workslike below: > and then the code sto

Re: [PHP] More include issues

2007-06-06 Thread Stut
Dan Shirah wrote: Yes, I have error_reporting = E_ALL and show_warnings = On. Here's something interesting...if I put the include directly above the code for the dropdown it workslike below: and then the code stops again at the next area of my page where it needs to connect to the dat

Re: [PHP] More include issues

2007-06-06 Thread Dan Shirah
Yes, I have error_reporting = E_ALL and show_warnings = On. Here's something interesting...if I put the include directly above the code for the dropdown it workslike below: '.print_r($credit_card_type_code)); foreach ($credit_card_type_desc as $c) { if ($c['credit_card_type_code'] ==

Re: [PHP] More include issues

2007-06-06 Thread Stut
Dan Shirah wrote: I only added those echo's since we have been trying to figure this out, so I could see how far it was getting before it stopped. When I select "VIew Source", the last line of code is: Do you have display_errors on and error_reporting to show at least errors and warnings

Re: [PHP] More include issues

2007-06-06 Thread Dan Shirah
I only added those echo's since we have been trying to figure this out, so I could see how far it was getting before it stopped. When I select "VIew Source", the last line of code is: On 6/6/07, Stut <[EMAIL PROTECTED]> wrote: Dan Shirah wrote: > > * *** This is the query that uses the

Re: [PHP] More include issues

2007-06-06 Thread Stut
Dan Shirah wrote: * *** This is the query that uses the inlude file database connection info that is currently returning no results * // Query the credit_card_type table and load all of the records // into an array. echo "Pre-SQL"; This does not echo out* $sql = "SELECT * FROM c

Re: [PHP] More include issues

2007-06-06 Thread Dan Shirah
If something was being displayed in there, then we wouldn't be getting to the blank dropdown box. But just for you I put something in there and it doesn't get echo'd out. On 6/6/07, Stut <[EMAIL PROTECTED]> wrote: Dan Shirah wrote: > if(!empty($_POST['max_id'])) { For this test, max_id

Re: [PHP] More include issues

2007-06-06 Thread Stut
Dan Shirah wrote: For sh*ts and giggles, echo something in there - I'm betting it'll get displayed. -Stut -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] More include issues

2007-06-06 Thread Dan Shirah
Okay, here's the entire thing: Submit a New Payment. Credit Card Information Is it a debit card? Yes No Credit

Re: [PHP] More include issues

2007-06-06 Thread Stut
You can't rely on everyone seeing the different colours in your text. Please lay out your replies so they can be read in plain text. Dan Shirah wrote: Ok, I can't see anything wrong with that. Me either Are you absolutely sure it works when you replace the include line with the contents of the

Re: [PHP] More include issues

2007-06-06 Thread Dan Shirah
Using required() it still echoes the text I put in the include file for testing. On 6/6/07, Jim Moseby <[EMAIL PROTECTED]> wrote: > > I have error_reporting set to E_ALL and display_errors is set to On. > > And no errors are displayed As a troubleshooting step, use require() instead if includ

Re: [PHP] More include issues

2007-06-06 Thread Dan Shirah
../../Conn/prpr_mssql.php or ../../Connections/connection.php These are the same file, I was just changing the name to Connections/connection.php for a little added security of my info being on the web is all. On 6/6/07, Jim Lucas <[EMAIL PROTECTED]> wrote: Stut wrote: > Dan Shirah wrote: >

RE: [PHP] More include issues

2007-06-06 Thread Jim Moseby
> > I have error_reporting set to E_ALL and display_errors is set to On. > > And no errors are displayed As a troubleshooting step, use require() instead if include(). It will return an error message if error_reporting() allows it to. JM -- PHP General Mailing List (http://www.php.net/) To

Re: [PHP] More include issues

2007-06-06 Thread Dan Shirah
Ok, I can't see anything wrong with that. Me either Are you absolutely sure it works when you replace the include line with the contents of the include file? Are you sure you're replacing it exactly? Yes, because when I originally made the form I had the connection info hard coded. I "cut" the in

Re: [PHP] More include issues

2007-06-06 Thread Jim Lucas
Stut wrote: Dan Shirah wrote: Ask and you shall recieve!! :) // My include statement at the beginning of the body **Various plain HTML form data here** // My dropdown box that is not getting populated $sql = "SELECT * FROM credit_card_code_types ORDER BY credit_card_type_desc"; $r

Re: [PHP] More include issues

2007-06-06 Thread Stut
Dan Shirah wrote: Ask and you shall recieve!! :) // My include statement at the beginning of the body **Various plain HTML form data here** // My dropdown box that is not getting populated $sql = "SELECT * FROM credit_card_code_types ORDER BY credit_card_type_desc"; $res = mssql_qu

Re: [PHP] More include issues

2007-06-06 Thread Dan Shirah
Ask and you shall recieve!! :) // My include statement at the beginning of the body **Various plain HTML form data here** // My dropdown box that is not getting populated '.print_r($credit_card_type_code)); foreach ($credit_card_type_desc as $c) { if ($c['credit_card_type_code'] == $_POS

Re: [PHP] More include issues

2007-06-06 Thread Stut
Dan Shirah wrote: If I put an echo into my included file, the echo displays on the screen. But no results are returned. However, if I copy the data from my include file and paste it directly into my page, I get the results. Ok, so that's confirmed that the include file is being included p

Re: [PHP] More include issues

2007-06-06 Thread Dan Shirah
If I put an echo into my included file, the echo displays on the screen. But no results are returned. However, if I copy the data from my include file and paste it directly into my page, I get the results. On 6/6/07, Stut <[EMAIL PROTECTED]> wrote: Dan Shirah wrote: > I have error_reporting

Re: [PHP] More include issues

2007-06-06 Thread Stut
Dan Shirah wrote: I have error_reporting set to E_ALL and display_errors is set to On. And no errors are displayed My code run through as it should...passes my include statement...displays part of the form, but when it gets to a dropdown box that is populated by the database (Which the connecti

Re: [PHP] More include issues

2007-06-06 Thread Dan Shirah
I have error_reporting set to E_ALL and display_errors is set to On. And no errors are displayed My code run through as it should...passes my include statement...displays part of the form, but when it gets to a dropdown box that is populated by the database (Which the connection is set in the in

Re: [PHP] More include issues

2007-06-06 Thread Jim Lucas
Dan Shirah wrote: Okay, I'm stumped!!! I have all of my database connection info in a file: connection.php This info is stored in a folder: Connections Example of connection.php: I am trying to include the connection.php file in all of my pages so I don't have to hard code the info into ever

Re: [PHP] More include issues

2007-06-06 Thread Robert Cummings
On Wed, 2007-06-06 at 13:42 -0400, Dan Shirah wrote: > Okay, I'm stumped!!! > > I have all of my database connection info in a file: connection.php > This info is stored in a folder: Connections > Example of connection.php: > $connection = mssql_pconnect('SERVER','user','password') or die ('serve