php-windows Digest 2 Mar 2001 02:16:41 -0000 Issue 469 Topics (messages 5768 through 5784): Re: Question on using an array 5768 by: Asendorf, John 5770 by: Asendorf, John pg_cmdtuples support help needed from the gurus. 5769 by: Jess Perez Connecting to access or SQL server 5771 by: Martin Rokicki 5772 by: Michael Rudel 5774 by: Andrian Pervazov Win2k & php 5773 by: Wolfgang Schneider 5775 by: Andreas Lange 5776 by: Andrian Pervazov Re: Connecting to remote databases 5777 by: Mayo, Bill 5778 by: Daniel Furse mssql and odbc functions 5779 by: Martin Rokicki 5780 by: Michael Rudel 5782 by: Martin Rokicki 5783 by: Frank M. Kromann Re: Question on using an array - And after all that... 5781 by: Asendorf, John Web Servers 5784 by: Jim Ray Administrivia: To subscribe to the digest, e-mail: [EMAIL PROTECTED] To unsubscribe from the digest, e-mail: [EMAIL PROTECTED] To post to the list, e-mail: [EMAIL PROTECTED] ----------------------------------------------------------------------
I kind of snipped that out of the sample... sorry... was trying to make the sample as easy to read as possible... --------------------- John Asendorf - [EMAIL PROTECTED] Web Applications Developer http://www.lcounty.com - NEW FEATURES ADDED DAILY! Licking County, Ohio, USA 740-349-3631 Aut insanit homo, aut versus facit > -----Original Message----- > From: Ernest E Vogelsinger [mailto:[EMAIL PROTECTED]] > Sent: Wednesday, February 28, 2001 6:38 PM > To: Asendorf, John > Cc: Php-Windows (E-mail) > Subject: Re: [PHP-WIN] Question on using an array > > > At 16:55 28.02.2001, Asendorf, John said: > --------------------[snip]-------------------- > >I just added the last three entries on the array which all > have the same key > >(could be my obvious problem...) My problem is that the > while loop only hits > >the LAST of the three 'links.php' entry... > > > >Any suggestions on how to force it to hit all of those entries? > >pleasepleasepleaseplease don't tell me I have to rewrite the > whole thing > >with the keys/values reversed... > --------------------[snip]-------------------- > > You've already got excellent answers (you only have _one_ > "links.php" key > in the array). I wanted to add that you should put a "reset($array)" > statement before any "each($array)" loop to make sure the loop will > reliably start at the very first element. > > > ...ebird > > >O Ernest E. Vogelsinger > (\) http://www.1-at-web.at/ > ^ ICQ# 13394035 >
I used Michael's suggestion and came up with something that 'almost' works... I totally forgot an important part... the links were being alphabetized. (I snipped out a bunch of stuff here... so it's easier to see the meat...) You can see the result at http://www.lcounty.com/is/website/revision.php I'm using some dummy includes and the page is inaccessible through the site... $arr_links = array('is/' => 'Information Systems' ,'hr/' => 'Human Resources' ,'planning/' => 'Planning Commission' ,'boe/' => 'Board of Elections' ,'rec/' => 'County Recorder' ,'lchd/' => 'Health Department' ,'treasurer/' => 'County Treasurer' ,'rlc/' => 'Recycling & Litter' ,'ac/' => 'Animal Control' ,'cc/' => 'County Commissioners' ,'auditor/' => 'County Auditor' ,'ww/' => 'Water & Wastewater' ,'mrdd/' => 'MRDD' ,'vsc/' => 'Veterans\' Commission' ,'links.php' => array ('1' => 'Park District ' ,'2' => 'CSEA' ,'3' => 'County Sheriff' ,'4' => 'LCATS' ) ); while ( list($key, $val) = each($arr_links) ) { if ( is_array( $val ) ) { while ( list($key1, $val1) = each($val) ) { echo " <tr>\n <td></td>\n<td nowrap"; $currentlink = $levels.$key; //SNIP echo "><A class=\"sidebar\" href=\"$currentlink\">$val1</A></td>\n<td></td>\n </tr>\n"; } } else { //for the other ones... } } --------------------- John Asendorf - [EMAIL PROTECTED] Web Applications Developer http://www.lcounty.com - NEW FEATURES ADDED DAILY! Licking County, Ohio, USA 740-349-3631 Aut insanit homo, aut versus facit > -----Original Message----- > From: Michael Rudel [mailto:[EMAIL PROTECTED]] > Sent: Thursday, March 01, 2001 7:22 AM > To: 'Asendorf, John' > Subject: RE: [PHP-WIN] Question on using an array > > > Hey John, > > ... have you solved your problem ??? > > Greetinx, > > Michael Rudel > - Web-Development, Systemadministration - > _______________________________________________________________ > > Suchtreffer AG > Bleicherstraße 20 > D-78467 Konstanz > Germany > fon: +49-(0)7531-89207-17 > fax: +49-(0)7531-89207-13 > e-mail: mailto:[EMAIL PROTECTED] > internet: http://www.suchtreffer.de > _______________________________________________________________ > >
Is there anyone here who can tell me where I can get the pgsql.c module for PHP4 that has the cmdtuples support compiled in so that when it is called from PHPlib it does not give the following error message. Warning: This compilation does not support pg_cmdtuples() in ../phplib/php/db_pgsql.inc on line 177 I looked in the source code and the is an constant I think it was HAVE_CMDTUPLES that determined whether that section of the code would be compiled in or excluded. I would appreciate any assistence in getting this module with this compiled in. -- Regards Jess Perez -- Regards Jess Perez
Hi All, I've got PHP running on an NT box with IIS 4.0. I also have an SQL server 6.5 running on another box. Here is my question. I need to make data reports based on a database located on the SQL server. There is an access database that points to this SQL server through linked tables. What should I do? Connect to the acces database or the SQL server? Is one harder than the other? Is there any kind of advantage to using one over the other? I'm going to look at the PHP documentation to figure it all out, but any kind of head start you guys could give me would be appreciated. I have only used PHP to connect to a mysql database and have found it very easy, but have not connected to anything else. Regards, Martin
Hi Martin, I think its faster to connect directly to the SQL-Server. If you use ODBC, then the Sourcecode is equal for Access and MS-SQL-Server. Hope this helps. Greetinx, Michael Rudel - Web-Development, Systemadministration - _______________________________________________________________ Suchtreffer AG Bleicherstraße 20 D-78467 Konstanz Germany fon: +49-(0)7531-89207-17 fax: +49-(0)7531-89207-13 e-mail: mailto:[EMAIL PROTECTED] internet: http://www.suchtreffer.de _______________________________________________________________ -----Original Message----- From: Martin Rokicki [mailto:[EMAIL PROTECTED]] Sent: Thursday, March 01, 2001 3:07 PM To: '[EMAIL PROTECTED]' Subject: [PHP-WIN] Connecting to access or SQL server Hi All, I've got PHP running on an NT box with IIS 4.0. I also have an SQL server 6.5 running on another box. Here is my question. I need to make data reports based on a database located on the SQL server. There is an access database that points to this SQL server through linked tables. What should I do? Connect to the acces database or the SQL server? Is one harder than the other? Is there any kind of advantage to using one over the other? I'm going to look at the PHP documentation to figure it all out, but any kind of head start you guys could give me would be appreciated. I have only used PHP to connect to a mysql database and have found it very easy, but have not connected to anything else. Regards, Martin -- PHP Windows Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
I believe connecting to SQL Server directly is better. Access cannot handle well concurrent users. Using the native SQL Server functions instead of ODBC should be (at least theoretically) faster as well. Andrian Martin Rokicki wrote: > > Hi All, > I've got PHP running on an NT box with IIS 4.0. I also have an SQL > server 6.5 running on another box. Here is my question. I need to make data > reports based on a database located on the SQL server. There is an access > database that points to this SQL server through linked tables. What should I > do? Connect to the acces database or the SQL server? Is one harder than the > other? Is there any kind of advantage to using one over the other? I'm going > to look at the PHP documentation to figure it all out, but any kind of head > start you guys could give me would be appreciated. I have only used PHP to > connect to a mysql database and have found it very easy, but have not > connected to anything else. > > Regards, > Martin > > -- > PHP Windows Mailing List (http://www.php.net/) > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > To contact the list administrators, e-mail: [EMAIL PROTECTED]
Hi everyone, I am new to this list ... and new to a few other things relating to what I would like to ask about ... :) At times, I would like to test some websites which I have developed with php, and currently I have a PC with Win98 and xitami webserver and php3 running, and everything is fine ... so what's the question? Well ... Now I received a notbook with Win2k on it and I would like to set up the same or similar configuration as mentioned above ... but Win2k seems quite different, have its own webserver already built in (?), doesn't seem to have a "hosts" file where the host names are listed for the localhost 127.0.0.1 etc... Does anyone have a suggestion / instructions on how I can fix up this notebook to provide me again with a webserver, and especially (!) how to implement a php module with the Win2k "webserver" and being able to assign a directory with files to a host name to be used with local host? Any help is appreciated! God bless you with His grace and peace Wolfgang Schneider Looking for Biblical information? We have studies, articles, bookshop and other interesting pages. COME AND SEE! Check it out NOW! -- BibelCenter: http://www.bibelcenter.de -- Bookstore: http://www.worthy.net/BibelCenter/ - "Great offers! Check it out!" -- Christian eBooks: http://www.christian-ebooks.de
> -----Original Message----- > From: Wolfgang Schneider [mailto:[EMAIL PROTECTED]] > Sent: Thursday, March 01, 2001 3:13 PM > To: php-windows > Subject: [PHP-WIN] Win2k & php > > > Hi everyone, > > I am new to this list ... and new to a few other things relating to > what I would like to ask about ... :) > > At times, I would like to test some websites which I have developed > with php, and currently I have a PC with Win98 and xitami webserver and > php3 running, and everything is fine ... so what's the question? Well > ... > > Now I received a notbook with Win2k on it and I would like to set up > the same or similar configuration as mentioned above ... but Win2k > seems quite different, have its own webserver already built in (?), the build in is the Internet Information Server Version ? ;) you can uninstall it via the "Control-Panel"-"Software"-"Windows components" > doesn't seem to have a "hosts" file where the host names are listed for > the localhost 127.0.0.1 etc... the file can be found under: C:\WINNT\system32\drivers\etc\hosts > Does anyone have a suggestion / instructions on how I can fix up this > notebook to provide me again with a webserver, and especially (!) how > to implement a php module with the Win2k "webserver" and being able to > assign a directory with files to a host name to be used with local > host? Any help is appreciated! Hmm, try out the Apache Webserver ;) it is free and not from the evil-empire ;) > God bless you with His grace and peace > Wolfgang Schneider CodeDuck
You can also setup your websites with the IIS that comes with Winows 2000. Go to Control Panel, Administrative Tools. Internet Services Manager. You can change the directory for the default website, set up new websites, configure them etc. - it might do the job you need. Andrian Andreas Lange wrote: > > > -----Original Message----- > > From: Wolfgang Schneider [mailto:[EMAIL PROTECTED]] > > Sent: Thursday, March 01, 2001 3:13 PM > > To: php-windows > > Subject: [PHP-WIN] Win2k & php > > > > > > Hi everyone, > > > > I am new to this list ... and new to a few other things relating to > > what I would like to ask about ... :) > > > > At times, I would like to test some websites which I have developed > > with php, and currently I have a PC with Win98 and xitami webserver and > > php3 running, and everything is fine ... so what's the question? Well > > ... > > > > Now I received a notbook with Win2k on it and I would like to set up > > the same or similar configuration as mentioned above ... but Win2k > > seems quite different, have its own webserver already built in (?), > > the build in is the Internet Information Server Version ? ;) > > you can uninstall it via the "Control-Panel"-"Software"-"Windows components" > > > doesn't seem to have a "hosts" file where the host names are listed for > > the localhost 127.0.0.1 etc... > > the file can be found under: > > C:\WINNT\system32\drivers\etc\hosts > > > Does anyone have a suggestion / instructions on how I can fix up this > > notebook to provide me again with a webserver, and especially (!) how > > to implement a php module with the Win2k "webserver" and being able to > > assign a directory with files to a host name to be used with local > > host? Any help is appreciated! > > Hmm, try out the Apache Webserver ;) it is free and not from the evil-empire > ;) > > > God bless you with His grace and peace > > Wolfgang Schneider > > CodeDuck > > -- > PHP Windows Mailing List (http://www.php.net/) > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > To contact the list administrators, e-mail: [EMAIL PROTECTED]
I had this exact problem and it took me days of beating my head against the wall to find the solution. First, you do want to make sure that the Access security permissions are correct on the database. For example, "Admin" typically needs to be the owner; it can sometimes get corrupted, causing a problem. Secondly, you need to make sure that the IIS user account has the appropriate NT permissions to the database. I have found that write access is required for it to work. Thirdly, and most likely your problem, is a bug in IIS. Check out Microsoft TechNet article Q189408 (FIX: ASP Fails to Access Network Files Under IIS 4.0 and IIS 5.0). ~~~~~~~~~~~~~~~~~~~ Bill Mayo Network Administrator Pitt County MIS > -----Original Message----- > From: Daniel Furse [SMTP:[EMAIL PROTECTED]] > Sent: Wednesday, February 28, 2001 9:52 AM > To: PHP Windows List (E-mail) > Subject: Connecting to remote databases > > Hi everyone, > > I'm trying to connect an Access database that is not on the same server as > the web server. All the servers are Windows NT 4, the web server is IIS4, > and I'm using PHP4. Whenever I try to query the database, it returns: > > Warning: SQL error: [Microsoft][ODBC Microsoft Access 97 Driver] The > Microsoft Jet database engine cannot open the file 'SIDSC.MDB'. It > is > already opened exclusively by another user, or you need permission > to view > its data., SQL state S1000 inSQLExecDirect > > I've checked that the database is not opened by anyone else. I've also > tried > creating a new database on the web server and creating links to the tables > in Access, but I still get the same error. The remote database has read > permissions for the 'Everyone' group, so does the entire directory path, > and > the share. > > Can anyone help? > > Many thanks, > > Dan
Thank you! Now it works! This problem first popped up over six months ago, and I've been working round it since then. Many thanks, Dan -----Original Message----- From: Mayo, Bill [mailto:[EMAIL PROTECTED]] Sent: 01 March 2001 16:10 To: 'Daniel Furse'; PHP Windows List (E-mail) Subject: [PHP-WIN] RE: Connecting to remote databases I had this exact problem and it took me days of beating my head against the wall to find the solution. First, you do want to make sure that the Access security permissions are correct on the database. For example, "Admin" typically needs to be the owner; it can sometimes get corrupted, causing a problem. Secondly, you need to make sure that the IIS user account has the appropriate NT permissions to the database. I have found that write access is required for it to work. Thirdly, and most likely your problem, is a bug in IIS. Check out Microsoft TechNet article Q189408 (FIX: ASP Fails to Access Network Files Under IIS 4.0 and IIS 5.0). ~~~~~~~~~~~~~~~~~~~ Bill Mayo Network Administrator Pitt County MIS > -----Original Message----- > From: Daniel Furse [SMTP:[EMAIL PROTECTED]] > Sent: Wednesday, February 28, 2001 9:52 AM > To: PHP Windows List (E-mail) > Subject: Connecting to remote databases > > Hi everyone, > > I'm trying to connect an Access database that is not on the same server as > the web server. All the servers are Windows NT 4, the web server is IIS4, > and I'm using PHP4. Whenever I try to query the database, it returns: > > Warning: SQL error: [Microsoft][ODBC Microsoft Access 97 Driver] The > Microsoft Jet database engine cannot open the file 'SIDSC.MDB'. It > is > already opened exclusively by another user, or you need permission > to view > its data., SQL state S1000 inSQLExecDirect > > I've checked that the database is not opened by anyone else. I've also > tried > creating a new database on the web server and creating links to the tables > in Access, but I still get the same error. The remote database has read > permissions for the 'Everyone' group, so does the entire directory path, > and > the share. > > Can anyone help? > > Many thanks, > > Dan -- PHP Windows Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Hi All, Thanks for the advice on database connectivity. I've tried connecting to the mssql server (which is running 2000 not 6.5 as I had thought) with the mssql_connect function as well as the odbc_connect function. When I run the mssql connect I use this code: MSSQL_CONNECT($host,$user,$pass) The variables are all defined with the correct values, but I receive an error message: Fatal error: Call to undefined function: mssql_connect() in c:\inetpub\wwwroot\stpweb\test\mssql.php on line 7 I've looked through the PHP documentation and tried a couple of fixes for this error, but no luck so far. Also when I try to connect to the database using odbc connect and this code: odbc_connect("dsn","uid","pas"); I get this message: Warning: SQL error: [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified, SQL state IM002 in SQLConnect I have the DSN defined as a system dsn, and it works when tested. I know I'm screwing something up, but I'm not sure what. Any help you could give would be appreciated. Regards, Martin
Hey Martin, First Problem (mssql): you don't have the mssql-extension running. Check it out in the php.ini and remove the ; before the appropriate line. Second Problem (odbc): I've never worked with mssql2k, but here a silly question that *might* be the problem: the system-dsn entry, is it set on the Web-Server ??? Hope this helps, at least a bit =8) Greetinx, Michael Rudel - Web-Development, Systemadministration - _______________________________________________________________ Suchtreffer AG Bleicherstraße 20 D-78467 Konstanz Germany fon: +49-(0)7531-89207-17 fax: +49-(0)7531-89207-13 e-mail: mailto:[EMAIL PROTECTED] internet: http://www.suchtreffer.de _______________________________________________________________ -----Original Message----- From: Martin Rokicki [mailto:[EMAIL PROTECTED]] Sent: Thursday, March 01, 2001 7:08 PM To: '[EMAIL PROTECTED]' Subject: [PHP-WIN] mssql and odbc functions Hi All, Thanks for the advice on database connectivity. I've tried connecting to the mssql server (which is running 2000 not 6.5 as I had thought) with the mssql_connect function as well as the odbc_connect function. When I run the mssql connect I use this code: MSSQL_CONNECT($host,$user,$pass) The variables are all defined with the correct values, but I receive an error message: Fatal error: Call to undefined function: mssql_connect() in c:\inetpub\wwwroot\stpweb\test\mssql.php on line 7 I've looked through the PHP documentation and tried a couple of fixes for this error, but no luck so far. Also when I try to connect to the database using odbc connect and this code: odbc_connect("dsn","uid","pas"); I get this message: Warning: SQL error: [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified, SQL state IM002 in SQLConnect I have the DSN defined as a system dsn, and it works when tested. I know I'm screwing something up, but I'm not sure what. Any help you could give would be appreciated. Regards, Martin -- PHP Windows Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Here is what the windows extensions of my php.ini looks like: ;Windows Extensions ;extension=php_mysql.dll ;extension=php_nsmail.dll ;extension=php_calendar.dll ;extension=php_dbase.dll ;extension=php_filepro.dll ;extension=php_gd.dll ;extension=php_dbm.dll extension=php_mssql70.dll ;extension=php_zlib.dll ;extension=php_filepro.dll ;extension=php_imap4r2.dll ;extension=php_ldap.dll ;extension=php_crypt.dll ;extension=php_msql2.dll extension=php_odbc.dll And the mssql portion: [MSSQL] extension=php_mssql70.dll I checked and I do have that dll in c:\winnt\system32. I also have the data source setup on the web serve as a system dsn. Thanks!, Martin -----Original Message----- From: Michael Rudel [mailto:[EMAIL PROTECTED]] Sent: Thursday, March 01, 2001 1:31 PM To: Martin Rokicki; [EMAIL PROTECTED] Subject: RE: [PHP-WIN] mssql and odbc functions Hey Martin, First Problem (mssql): you don't have the mssql-extension running. Check it out in the php.ini and remove the ; before the appropriate line. Second Problem (odbc): I've never worked with mssql2k, but here a silly question that *might* be the problem: the system-dsn entry, is it set on the Web-Server ??? Hope this helps, at least a bit =8) Greetinx, Michael Rudel - Web-Development, Systemadministration - _______________________________________________________________ Suchtreffer AG Bleicherstraße 20 D-78467 Konstanz Germany fon: +49-(0)7531-89207-17 fax: +49-(0)7531-89207-13 e-mail: mailto:[EMAIL PROTECTED] internet: http://www.suchtreffer.de _______________________________________________________________ -----Original Message----- From: Martin Rokicki [mailto:[EMAIL PROTECTED]] Sent: Thursday, March 01, 2001 7:08 PM To: '[EMAIL PROTECTED]' Subject: [PHP-WIN] mssql and odbc functions Hi All, Thanks for the advice on database connectivity. I've tried connecting to the mssql server (which is running 2000 not 6.5 as I had thought) with the mssql_connect function as well as the odbc_connect function. When I run the mssql connect I use this code: MSSQL_CONNECT($host,$user,$pass) The variables are all defined with the correct values, but I receive an error message: Fatal error: Call to undefined function: mssql_connect() in c:\inetpub\wwwroot\stpweb\test\mssql.php on line 7 I've looked through the PHP documentation and tried a couple of fixes for this error, but no luck so far. Also when I try to connect to the database using odbc connect and this code: odbc_connect("dsn","uid","pas"); I get this message: Warning: SQL error: [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified, SQL state IM002 in SQLConnect I have the DSN defined as a system dsn, and it works when tested. I know I'm screwing something up, but I'm not sure what. Any help you could give would be appreciated. Regards, Martin -- PHP Windows Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP Windows Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
If you are using PHP as an ISAPI module, you need to restart the web service after making changes to php.ini. The file is only read on startup. php_mssql70.dll can be in \winnt\system32 or in yoy php directory (c:\php4). It is important that your extension_dir in php.ini points to the right place. default is ./ and that indicates that php_mssql70.dll should be in the sam directory as php.exe (and all other php binaries). In order to use MS SQL server from a web server you also need to install a MS SQL Client (from the cd) or at least copy ntwdblib.dll to \winnt\system32. - Frank > Here is what the windows extensions of my php.ini looks like: > > ;Windows Extensions > ;extension=php_mysql.dll > ;extension=php_nsmail.dll > ;extension=php_calendar.dll > ;extension=php_dbase.dll > ;extension=php_filepro.dll > ;extension=php_gd.dll > ;extension=php_dbm.dll > extension=php_mssql70.dll > ;extension=php_zlib.dll > ;extension=php_filepro.dll > ;extension=php_imap4r2.dll > ;extension=php_ldap.dll > ;extension=php_crypt.dll > ;extension=php_msql2.dll > extension=php_odbc.dll > > And the mssql portion: > [MSSQL] > extension=php_mssql70.dll > > I checked and I do have that dll in c:\winnt\system32. I also have the data > source setup on the web serve as a system dsn. > Thanks!, > Martin > > -----Original Message----- > From: Michael Rudel [mailto:[EMAIL PROTECTED]] > Sent: Thursday, March 01, 2001 1:31 PM > To: Martin Rokicki; [EMAIL PROTECTED] > Subject: RE: [PHP-WIN] mssql and odbc functions > > > Hey Martin, > > First Problem (mssql): you don't have the mssql-extension running. > Check it out in the php.ini and remove the ; before the appropriate line. > > Second Problem (odbc): I've never worked with mssql2k, but here a silly > question that *might* be the problem: the system-dsn entry, is it set on > the Web-Server ??? > > Hope this helps, at least a bit =8) > > Greetinx, > > Michael Rudel > - Web-Development, Systemadministration - > _______________________________________________________________ > > Suchtreffer AG > Bleicherstraße 20 > D-78467 Konstanz > Germany > fon: +49-(0)7531-89207-17 > fax: +49-(0)7531-89207-13 > e-mail: mailto:[EMAIL PROTECTED] > internet: http://www.suchtreffer.de > _______________________________________________________________ > > > > -----Original Message----- > From: Martin Rokicki [mailto:[EMAIL PROTECTED]] > Sent: Thursday, March 01, 2001 7:08 PM > To: '[EMAIL PROTECTED]' > Subject: [PHP-WIN] mssql and odbc functions > > > Hi All, > Thanks for the advice on database connectivity. I've tried > connecting to the mssql server (which is running 2000 not 6.5 as I had > thought) with the mssql_connect function as well as the odbc_connect > function. When I run the mssql connect I use this code: > MSSQL_CONNECT($host,$user,$pass) > The variables are all defined with the correct values, but I receive an > error message: > Fatal error: Call to undefined function: mssql_connect() in > c:\inetpub\wwwroot\stpweb\test\mssql.php on line 7 > I've looked through the PHP documentation and tried a couple of fixes for > this error, but no luck so far. Also when I try to connect to the database > using odbc connect and this code: > odbc_connect("dsn","uid","pas"); > I get this message: > Warning: SQL error: [Microsoft][ODBC Driver Manager] Data source name not > found and no default driver specified, SQL state IM002 in SQLConnect > I have the DSN defined as a system dsn, and it works when tested. I know I'm > screwing something up, but I'm not sure what. Any help you could give would > be appreciated. > > Regards, > Martin > > > -- > PHP Windows Mailing List (http://www.php.net/) > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > To contact the list administrators, e-mail: [EMAIL PROTECTED] > > > -- > PHP Windows Mailing List (http://www.php.net/) > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > To contact the list administrators, e-mail: [EMAIL PROTECTED] > > > > -- > PHP Windows Mailing List (http://www.php.net/) > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > To contact the list administrators, e-mail: [EMAIL PROTECTED] > > >
And after all was said and done... I chickened out and did the following: 1) created a PHP page that would accept the site addresses and put them in a "click here" link and an auto-refresh javascript... 2) add the areas to the array like so: ,'outsite.php?site=http://www.lickingcountysheriff.com' => 'County Sheriff' ,'outsite.php?site=http://www.msmisp.com/lpd/' => 'Park District' ,'outsite.php?site=http://www.state.oh.us/odhs/county/licking/' => 'CSEA' ,'outsite.php?site=http://www.lcats.org/' => 'LCATS' ); which, in turn, fixed my 'overwriting the key' problem 3) Left everything else alone... See it in action at www.lcounty.com Thanks everyone... I had to alert viewers that they were being transfered out of the domain due our/my accessability standards... --------------------- John Asendorf - [EMAIL PROTECTED] Web Applications Developer http://www.lcounty.com - NEW FEATURES ADDED DAILY! Licking County, Ohio, USA 740-349-3631 Aut insanit homo, aut versus facit > -----Original Message----- > From: Asendorf, John [mailto:[EMAIL PROTECTED]] > Sent: Thursday, March 01, 2001 8:52 AM > To: [EMAIL PROTECTED]; Php-Windows (E-mail) > Subject: RE: [PHP-WIN] Question on using an array > > > I used Michael's suggestion and came up with something that 'almost' > works... > > I totally forgot an important part... the links were being > alphabetized. > > (I snipped out a bunch of stuff here... so it's easier to see > the meat...) > > You can see the result at > http://www.lcounty.com/is/website/revision.php > > I'm using some dummy includes and the page is inaccessible through the > site... > > > > $arr_links = array('is/' => 'Information Systems' > ,'hr/' => 'Human Resources' > ,'planning/' => 'Planning Commission' > ,'boe/' => 'Board of Elections' > ,'rec/' => 'County Recorder' > ,'lchd/' => 'Health Department' > ,'treasurer/' => 'County Treasurer' > ,'rlc/' => 'Recycling & Litter' > ,'ac/' => 'Animal Control' > ,'cc/' => 'County Commissioners' > ,'auditor/' => 'County Auditor' > ,'ww/' => 'Water & Wastewater' > ,'mrdd/' => 'MRDD' > ,'vsc/' => 'Veterans\' Commission' > ,'links.php' => array ('1' => 'Park District ' > ,'2' => 'CSEA' > ,'3' => 'County Sheriff' > ,'4' => 'LCATS' > ) > ); > > > while ( list($key, $val) = each($arr_links) ) { > > > > if ( is_array( $val ) ) { > > while ( list($key1, $val1) = each($val) ) { > > echo " <tr>\n > <td></td>\n<td nowrap"; > $currentlink = $levels.$key; > //SNIP > echo "><A class=\"sidebar\" > href=\"$currentlink\">$val1</A></td>\n<td></td>\n </tr>\n"; > > } > } > > else { > //for the other ones... > } > > } > > --------------------- > John Asendorf - [EMAIL PROTECTED] > Web Applications Developer > http://www.lcounty.com - NEW FEATURES ADDED DAILY! > Licking County, Ohio, USA > 740-349-3631 > Aut insanit homo, aut versus facit > > > > -----Original Message----- > > From: Michael Rudel [mailto:[EMAIL PROTECTED]] > > Sent: Thursday, March 01, 2001 7:22 AM > > To: 'Asendorf, John' > > Subject: RE: [PHP-WIN] Question on using an array > > > > > > Hey John, > > > > ... have you solved your problem ??? > > > > Greetinx, > > > > Michael Rudel > > - Web-Development, Systemadministration - > > _______________________________________________________________ > > > > Suchtreffer AG > > Bleicherstraße 20 > > D-78467 Konstanz > > Germany > > fon: +49-(0)7531-89207-17 > > fax: +49-(0)7531-89207-13 > > e-mail: mailto:[EMAIL PROTECTED] > > internet: http://www.suchtreffer.de > > _______________________________________________________________ > > > > > > -- > PHP Windows Mailing List (http://www.php.net/) > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > To contact the list administrators, e-mail: > [EMAIL PROTECTED] >
I am new with PHP and I have a question about Web Servers. I am running Windows ME and PWS is not supported. Will PHP run under Apache for windows? Also, does anyone know will Windows MySQL run under Apache for windows as well? Thank you for the help. Jim Ray