RE: [PHP] Speed of loding PHP pages

2001-07-11 Thread Brian S. Dunworth


Are IE and Netscape both set the same as far as caching?

 -
   Brian S. Dunworth
   Sr. Software Development Engineer
   Oracle Database Administrator
   The Printing House, Ltd.

   (850) 875-1500  x225
   [EMAIL PROTECTED]
 -


-Original Message-
From:   Don [SMTP:[EMAIL PROTECTED]]
Sent:   Wednesday, July 11, 2001 12:48 PM
To: php list
Subject:[PHP] Speed of loding PHP pages

Hi,

Has anyone tries any test loading PHP pages into IE 5.x and Netscape
4.7x?

As an experiment, I have a page that issues a phpinfo().  WIth I.E. 5.5,
it takes about 3 seconds.  With Netscape 4.77, it takes almost 20
seconds.

Thanks,
Don


-- 
PHP General 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 General 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]




RE: [PHP] email templates and str_replace

2001-06-20 Thread Brian S. Dunworth



 Richard,
   The problem is with the str_replace()s. Consider the following:
 
 ?php
 $myvar = 'this is a var.';
 $mytext = str_replace('is', 'is not', $myvar);
 ?
 
 At this point $myvar still equals 'this is a var.' but $mytext is 'this is
 not a var.' $myvar hasn't been modfified by the str_replace so any
 additional str_replace()s after it will not have a cumlative effect.

Actually, wouldn't the string then be equal to 'this not is not a var.' ??


- Brian


-- 
PHP General 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]




Re: [PHP] Accesing Oracle

2001-05-21 Thread Brian S. Dunworth


At 03:21 PM 5/21/01 +0100, Kike wrote:
Hi all,
I've just installed Orcale 8.1.7 in a linux server in my lan. I'm trying 
to access to
the server from another computer with apache and i get the next:
Fatal error: Call to undefined function: ora_logon() in
/usr/local/apache/htdocs.
Where can i find docs to configure boths machines to access to the
oracle server?

   First, if you're trying to access an Oracle 8i database, you'll want 
OCILogon() not ora_logon() --  ora_* functions are for Oracle 7.x 
databases, OCI* functions are for Oracle 8.x databases...

   The first thing you need to do is install the Oracle Net8 Client on your 
apache webserver machine and configure it so that you can connect to the 
Oracle 8.1.7 server.

   Be sure to set ORACLE_SID, NLS_LANG, and ORACLE_HOME in your default 
environment (or, specifically in the environment for your apache user) so 
that the Net8 client software can connect to the database when executed as 
the 'nobody' user...

   Next, compile PHP again, including the OCI8 functions, and restart apache.


  -
Brian S. Dunworth
Sr. Software Development Engineer
Oracle Database Administrator
The Printing House, Ltd.

(850) 875-1500  x225
[EMAIL PROTECTED]
  -


-- 
PHP General 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]




RE: [PHP] Netscape 6, What a piece of s$#@ , anyone else had problems with php and Netscape 6?

2001-05-18 Thread Brian S. Dunworth

At 11:37 AM 5/18/01 -0400, scott [gts] wrote:
yes.  netscape is incredibly anal about tables.

   Actually, it's incredibly anal about following the HTML 
specification(s).  An incomplete tag pair (ie: TABLE /TABLE) is to be 
_ignored_ ...similarly, unrecognized parameters inside certain tags are 
ignored and the parameters that *are* recognized are utilized.  This is all 
according to the ideal specification.  Internet Explorer, which will 
attempt to ascertain what the (bad) HTML programmer meant by inserting 
missing tags, etc, is the program that is not doing things correctly.

   All that is to say that Netscape, at least in this instance, is doing 
exactly what it is supposed to do.  Internet Explorer should not display 
anything within malformed or missing tag pairs.

if you miss even one tag, the entire table
will not show...

   this is not necessarily true, unless the one tag you're missing is the 
TABLE or /TABLE tag...


per your subject header:
1) it's a netscape problem -- it affects 4.x, not just 6

   No, it's an Internet Explorer problem.  The HTML specification clearly 
indicates that unrecognized and/or incomplete tags should be IGNORED.   Not 
_interpreted_ or _guessed_at_, but ignored.

2) PHP is server-side.  it's not repsonsible for the rendering
   of HTML by each individual browser.

this part is correct...

   if something looks ok in IE and breaks in Netscape, then it's most
   likely the browser's fault, not PHP.

I think you may mean, if something looks okay in IE and doesn't appear 
in Netscape, then it's most likely the HTML programmers fault for not 
writing clean, legitimate HTML within their PHP program.

   the browser doesn't ever *see* the PHP code...  so there's no way
   that a browser could ever have problems *just* with PHP.

   Agreed...


  -
Brian S. Dunworth
Sr. Software Development Engineer
Oracle Database Administrator
The Printing House, Ltd.

(850) 875-1500  x225
[EMAIL PROTECTED]
  -


-- 
PHP General 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]




Re: [PHP] How to let PHP cgi find oracle TNS?

2001-05-15 Thread Brian S. Dunworth

At 10:09 AM 5/15/01 +0800, Jude Chen wrote:
Warning: Unable to connect to ORACLE (ORA-12154: TNS:could not resolve 
service name) in E:\website\yktest\web\includes\db\dbenv.php on line 4

But I have the correct TNS, through which I can connect to Oracle using 
SQL*PLUS, configured on the machine, using SQL*NET configuration tool.

I don't know why, can anyone help me?

   Can you show us the PHP code that produces this error?

   Are the ORACLE_HOME, NLS_LANG, and ORACLE_SID environment variables set 
for the 'nobody' user (or whichever entity runs apache/php) ?

   How, exactly, are you calling the OCI8 functions?


  -
Brian S. Dunworth
Sr. Software Development Engineer
Oracle Database Administrator
The Printing House, Ltd.

(850) 875-1500  x225
[EMAIL PROTECTED]
  -


-- 
PHP General 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]




Re: [PHP] Wierd error messages

2001-04-25 Thread Brian S. Dunworth


At 03:03 PM 4/25/01 +0100, Euan Greig wrote:
[25-Apr-2001 14:34:48] PHP Warning:  Missing ] in üu variable in Unknown 
on line 0
[25-Apr-2001 14:34:50] PHP Warning:  Missing ] in }´üt variable in Unknown 
on line 0

  [...] etc

   I hate to say it, but this looks suspiciously like a memory leak in 
WindowsNT...  especially if the problem cleared up after rebooting.

  - Brian


  -
Brian S. Dunworth
Sr. Software Development Engineer
Oracle Database Administrator
The Printing House, Ltd.

(850) 875-1500  x225
[EMAIL PROTECTED]
  -


-- 
PHP General 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]




Re: [PHP] link variables space problem in netscape

2001-04-24 Thread Brian S. Dunworth

At 02:23 AM 4/25/01 +0800, Mark Lo wrote:
Hi,

  I am having a problem in link variables in netscape.  etc.
www.domain.com?xx=1xxx=2=mark loxxxee=polol

if the above link contains space, then everyting is faded after the space, 
how to over come this problem in netscape.  In IE5, it is okay to have 
spacein link variables.

   The proper way to phrase In IE5, it is okay to have spaces in link 
variables is

IE5, which doesn't follow the specifications of the language, works with 
spaces embedded in the links.  Netscape, which follows (at least that part 
of) the HTML specification, disallows embedded spaces in links.

   Meanwhile, try the urlencode() and urldecode() functions. :)

Thank you

   Welcome.


  -
Brian S. Dunworth
Sr. Software Development Engineer
Oracle Database Administrator
The Printing House, Ltd.

(850) 875-1500  x225
[EMAIL PROTECTED]
  -


-- 
PHP General 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]




Re: [PHP] MySql / sql help plz!

2001-04-23 Thread Brian S. Dunworth

At 02:33 PM 4/23/01 -0700, elias wrote:
how can i get an SQL statment that when run, i get a query result like that:

Id:  Value count:
---  --
a4 values
b4 values
c2 values


   SELECT ID,COUNT(*) FROM table_name GROUP BY ID;

i feel that it's easy...but i'm not really good at SQL.

   ..and you probably won't get better at it here.  Try an SQL list or any 
number of online tutorials or books on SQL.

  - Brian

  -
Brian S. Dunworth
Sr. Software Development Engineer
Oracle Database Administrator
The Printing House, Ltd.

(850) 875-1500  x225
[EMAIL PROTECTED]
  -


-- 
PHP General 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]




Re: [PHP] show tables in oracle 8-i

2001-04-12 Thread Brian S. Dunworth

At 11:09 AM 4/12/01 -0700, Dennis Gearon wrote:
I've been looking through the book, and so far, I can't find the command 
for 'show tables' in Oracle 8i. Anyone know it? It should be
programmatically available, I would think, as an SQL command.


   SELECT TABLE_NAME FROM ALL_TABLES;

  - Brian

  -
Brian S. Dunworth
Sr. Software Development Engineer
Oracle Database Administrator
The Printing House, Ltd.

(850) 875-1500  x225
[EMAIL PROTECTED]
  -


-- 
PHP General 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]




Re: [PHP] Oracle Connection

2001-04-10 Thread Brian S. Dunworth

At 08:42 AM 4/10/01 -0700, Dunaway, Brian wrote:

I need to access a remote oracle database. What I mean is that the machine 
that is allowed access to the oracle database is not running php...I have 
access to the machine with the oracle access from my machine which is 
running php. Boy that sounds confusing.

   No, not really.

anyway I am setting my environment with putenv(oracle_home=/something) and 
putenv(oracle_sid=database)...what can I do? any ideas?

   I'm assuming that this isn't working for you.  Make sure you set 
NLS_LANG etc, as well in your environment, as specified in the PHP 
documentation.

   Do you have an Oracle client installed on the machine that has PHP 
installed on it?  Did you compile PHP with oci8 support?

   Here, our web server (Linux) has Apache/PHP and Oracle Net8 client 
installed.  The Net8 client talks to our Sun box with Oracle 8i 
installed.  Works with PHP with no hitches.

Brian D.

   yeah, me too.  :)

Running PHP 4

   yeah, me too.  :)

  - Brian

  -
Brian S. Dunworth
Sr. Software Development Engineer
Oracle Database Administrator
The Printing House, Ltd.

(850) 875-1500  x225
[EMAIL PROTECTED]
  -


-- 
PHP General 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]




Re: [PHP] PHP/MySQL Code

2001-04-06 Thread Brian S. Dunworth

At 11:51 AM 4/6/01 -0500, Jeff Oien wrote:

if ($num = 0) {
 print "htmlerror message etc.
 exit;
}

   This "conditional" will always run.  you are assigning $num the value of 
zero within your if() statement, and that assignation actually happens, so 
the result is "true" and the braced statements run.

   Try:

if ($num == 0) {
   print "blah blah blah, etc.\n"
   exit;
}

  - Brian

  ---------
Brian S. Dunworth
Sr. Software Development Engineer
Oracle Database Administrator
The Printing House, Ltd.

(850) 875-1500  x225
[EMAIL PROTECTED]
  -


-- 
PHP General 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]




Re: [PHP] header() vs. no cache, it doesn't work.

2001-03-30 Thread Brian S. Dunworth

At 04:03 PM 3/30/01 -0500, Scott Fletcher wrote:
When I use this script

  header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
  header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT");

### oops, don't forget to escape these!  ^ ^

  header("Cache-Control: no-cache, must-revalidate");
  header("Pragma: no-cache");

Next, I browse around and go back one page, the cache does not expire.
Sometime I get the error messages said that the header had already start 
or something.  So, what is the other way around to fix this 
problem?  Or how can I fix it


  -
Brian S. Dunworth
Sr. Software Development Engineer
Oracle Database Administrator
The Printing House, Ltd.

(850) 875-1500  x225
[EMAIL PROTECTED]
  -


-- 
PHP General 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]




RE: [PHP] RE: Oracle ODBC sql [ORA-00972: identifier is too long]

2001-03-22 Thread Brian S. Dunworth

At 09:52 AM 3/22/01 -0500, Brooks, Ken wrote:
Lets start at the basics.

What is the easiest way to *make sure* that i am connecting to that oracle
db?

Anyway I can just list the tables, or something.
odbc_tables or something like that?..

   To get a list of the tables, you could:

SELECT TABLE_NAME FROM ALL_TABLES;

   ...but, since you're on Oracle anyway, why not do something even quicker?

SELECT SYSDATE FROM DUAL;

   will return the current date.

SELECT TO_CHAR(SYSDATE,'DD-MON-YY HH24:MI:SS') FROM DUAL;

will return the current date and time.

  - Brian

  -
Brian S. Dunworth
Sr. Software Development Engineer
Oracle Database Administrator
The Printing House, Ltd.

(850) 875-1500  x225
[EMAIL PROTECTED]
  -


-- 
PHP General 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]




RE: [PHP] RE: Oracle ODBC sql [ORA-00972: identifier is too long]

2001-03-22 Thread Brian S. Dunworth

At 10:16 AM 3/22/01 -0500, Brooks, Ken wrote:
I got it.

   ah.  :)   good


I had the table name listed as aradmin_eps_service_instructions
when in fact it should have been aradmin.eps_service_instructions (with 
the dot).

I did not know this because all of the tables I had seen linked to this
before used _ ,but the actual name (which i normally don't have priveledge 
to even view) uses the .


   Actually, in Oracle parlance, the table name is 
EPS_SERVICE_INSTRUCTIONS, and it exists in the ARADMIN schema.  If there is 
no public synonym called EPS_SERVICE_INSTRUCTIONS, then you'd need to 
specify both schema and table name (eg: owner.table_name) in order to view 
the table.

   If you didn't have the privs to view a given table, you'd not be able to 
view it whether you specified the schema or not.  :)

   A list of the tables you can "see" along with their schema (owners) can 
be obtained by running the following SQL query:

   SELECT OWNER,TABLE_NAME FROM ALL_TABLES;

Whee!

   Indeed. :)

   ..or, try:

   SELECT OWNER||'.'||TABLE_NAME FROM ALL TABLES;

  - Brian

  -
    Brian S. Dunworth
Sr. Software Development Engineer
Oracle Database Administrator
The Printing House, Ltd.

(850) 875-1500  x225
[EMAIL PROTECTED]
  -


-- 
PHP General 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]




Re: [PHP] .htaccess question

2001-03-22 Thread Brian S. Dunworth

At 06:57 PM 3/22/01 +0100, Jimmy Bckstrm wrote:
Yo!
I need to know how I create a login script that uses the htaccess file to 
authenticate users.
Thankful for any answers!
/Broder B

   Set up your .htaccess file as usual, pointing to a userfile created with 
htpasswd.   Place the .htaccess file in the directory with your PHP 
script(s), and users will be automatically prompted for username/password 
before being served any file in that directory (at least the first time 
during that session, anyway).

   Within your PHP script(s), you can determine the user by reading the 
REMOTE_USER http environment variable:

$user = getenv("REMOTE_USER");

  - Brian

  -
    Brian S. Dunworth
Sr. Software Development Engineer
Oracle Database Administrator
The Printing House, Ltd.

(850) 875-1500  x225
[EMAIL PROTECTED]
  -


-- 
PHP General 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]