Re: [PHP] Seek for the Web Site Info.

2001-03-22 Thread Harshdeep S Jawanda

Go to http://uptime.netcraft.com/ . That should give you part of the
information you want.

Ian wrote:

> Does anybody know that any web site allow me to enter web address example,
> www.yahoo.com, and enter go.
>
> The result will shown me that yahoo server,
> 1. Operating System?
> 2. Programming?
> 3. Database?
> etc 

--
Regards,
Harshdeep Singh Jawanda.



-- 
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] Seek for the Web Site Info.

2001-03-22 Thread Ian

Does anybody know that any web site allow me to enter web address example,
www.yahoo.com, and enter go.

The result will shown me that yahoo server,
1. Operating System?
2. Programming?
3. Database?
etc 

Thanks in advance.



-- 
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] writing to a file

2001-03-22 Thread adam

nevermind ^^ i am jsut going to have posts that go from top to bottom oldest
to newest



-- 
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-CVS] cvs: php4 /pear/HTML Select.php

2001-03-22 Thread Adam Daniel

adaniel Thu Mar 22 22:24:07 2001 EDT

  Modified files:  
/php4/pear/HTML Select.php 
  Log:
  forgot the license header
  
Index: php4/pear/HTML/Select.php
diff -u php4/pear/HTML/Select.php:1.1 php4/pear/HTML/Select.php:1.2
--- php4/pear/HTML/Select.php:1.1   Thu Mar 22 22:18:12 2001
+++ php4/pear/HTML/Select.php   Thu Mar 22 22:24:07 2001
@@ -1,7 +1,27 @@
 http://www.php.net/license/2_02.txt. |
+// | If you did not receive a copy of the PHP license and are unable to   |
+// | obtain it through the world-wide-web, please send a note to  |
+// | [EMAIL PROTECTED] so we can mail you a copy immediately.   |
+// +--+
+// | Authors: Adam Daniel <[EMAIL PROTECTED]>|
+// +--+
+//
+// $Id: Select.php,v 1.2 2001/03/23 06:24:07 adaniel Exp $
+
 require_once "DB.php";
 require_once "PEAR.php";
 require_once "HTML/Common.php";
+
 /**
  * Class to dynamically create an HTML SELECT
  *



-- 
PHP CVS 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-CVS] cvs: php4 /pear/HTML Select.php

2001-03-22 Thread Adam Daniel

adaniel Thu Mar 22 22:18:12 2001 EDT

  Added files: 
/php4/pear/HTML Select.php 
  Log:
  original commit. Basic html select loaded manually, from a DB result, or an array
  

Index: php4/pear/HTML/Select.php
+++ php4/pear/HTML/Select.php

 * @version  1.0
 * @sincePHP4.04pl1
 * @access   public
 */
class HTML_Select extends HTML_Common
{

/**
 * Contains the select options
 *
 * @var   array
 * @since 1.0
 * @accessprivate
 */
var $_options = array();

/**
 * Default values of the SELECT
 * 
 * @var   string
 * @since 1.0
 * @accessprivate
 */
var $_values = array();

/**
 * Class constructor
 *
 * @param string$name   Name attribute of the SELECT
 * @param int   $size   Size attribute of the SELECT
 * @param bool  $multiple   Whether the select will allow multiple 
 *  selections or not
 * @param mixed $attributes Either a typical HTML attribute string 
 *  or an associative array
 * @param int   $tabOffset  Number of tabs to offset HTML source
 * @since 1.0
 * @accesspublic
 * @returnvoid
 * @throws
 */
function HTML_Select($name="", $size=1, $multiple=false, $attributes=null, 
$tabOffset=0)
{
HTML_Common::HTML_Common($attributes, $tabOffset);
$attr = array("name"=>$name, "size"=>$size);
if ($multiple) {
$attr[] = "MULTIPLE";
}
$this->updateAttributes($attr);
} // end constructor 

/**
 * Returns the current API version 
 * 
 * @since 1.0
 * @accesspublic
 * @returndouble
 * @throws
 */
function apiVersion()
{
return 1.0;
} //end func apiVersion

/**
 * Sets the default values of the select box
 * 
 * @param mixed$values  Array or comma delimited string of selected values
 * @since 1.0
 * @accesspublic
 * @returnvoid
 * @throws
 */
function setSelectedValues($values)
{
if (is_string($values)) {
$values = split("[ ]?,[ ]?", $values);
}
$this->_values = $values;  
} //end func setSelectedValues

/**
 * Returns an array of the selected values
 * 
 * @since 1.0
 * @accesspublic
 * @returnarray of selected values
 * @throws
 */
function getSelectedValues()
{
return $this->_values;
} // end func getSelectedValues

/**
 * Adds a new OPTION to the SELECT
 *
 * @param string$text   Display text for the OPTION
 * @param string$value  Value for the OPTION
 * @param bool  $selected   Whether the option is selected or not
 * @param mixed $attributes Either a typical HTML attribute string 
 *  or an associative array
 * @since 1.0
 * @accesspublic
 * @returnvoid
 * @throws
 */
function addOption($text, $value, $selected=false, $attributes=null)
{
if ($selected && !in_array($value, $this->_values)) {
$this->_values[] = $value;
array_unique($this->_values);
}
$attributes = $this->_parseAttributes($attributes);
$attr = array("value"=>$value);
if (in_array($value, $this->_values)) {
$attr[] = "SELECTED";
}
$this->_updateAttrArray($attributes, $attr);
$this->_options[] = array("text"=>$text, "attr"=>$attributes);
} // end func addOption

/**
 * Loads the options from an associative array
 * 
 * @param array$arr Associative array of options
 * @param mixed$values  (optional) Array or comma delimited string of 
selected values
 * @since 1.0
 * @accesspublic
 * @returnPEAR_Error on error or true
 * @throwsPEAR_Error
 */
function loadArray($arr, $values=null)
{
if (!is_array($arr)) {
return new PEAR_ERROR("First argument to HTML_Select::loadArray is not a 
valid array");
}
if (isset($values)) {
$this->setSelectedValues($values);
}
while (list($key, $value) = each($arr)) {
if (in_array($value, $this->_values)) {
$this->addOption($key, $value, true);
} else {
$this->addOption($key, $value);
}
}
return true;
} // end func loadArray
/**
 * Loads the options from DB_result object
 * 
 * If no column names are specified the first two columns of the result are
 * used as the text and value columns respectively
 * @param object$result DB_result object 
 * @param string  

[PHP] mail(): "\r\n" gives extra empty line between each line in Outlook

2001-03-22 Thread Eelco de Vries

Hi all,

First I had a problem that text from a textarea form object passed to mail()
ended up as a single line of text in MS Outlook.
I changed the newlines to newlines _with_ carriage returns:
strtr($mailbody, "\n", "\r\n");

Now it's not a single line of text but every newline skips an extra line
?!?!
The following is typed in the textarea en passed to mail():
"line 1
line 2
line 3"

In Outlook it shows as:
"line 1

line 2

line 3"

The "\n" alone gives a single line of text, the "\r\n" gives an extra empty
line between each line. (the "\r" alone ends up the same as "\r\n").

What is going on here?
How can I fix this?


Regards;
Eelco.


-- 
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] Complex IF statement

2001-03-22 Thread David Robley

On Wed, 13 Dec 2000 15:49, JCampbell wrote:
> Thank you all for your help earlier!
>
> Now I need to know if it is possible to create a complex if statement?
>
> if ($variable=="duck") || ($variable=="goose"){ }else{ }
>
> Is how I thought it would work. I just need to know if there is an easy
> way to do an OR in if statements IF variable equals duck or goose...
>
> 

Pretty much so; you might want to add extra parens thus:

if (($variable=="duck") || ($variable=="goose")){ }else{ }

You could, depending on exactly what you want, use a switch:
switch($variable){

case 'duck':
case 'goose':
 duck or goose action;
 break;
default:
 elephants, tigers etc action;
}

-- 
David Robley| WEBMASTER & Mail List Admin
RESEARCH CENTRE FOR INJURY STUDIES  | http://www.nisu.flinders.edu.au/
AusEinet| http://auseinet.flinders.edu.au/
Flinders University, ADELAIDE, SOUTH AUSTRALIA

-- 
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] writing to a file

2001-03-22 Thread adam

how would that look on a code view? i plan to write the variable $message on
top of the existing data

""hi"" <[EMAIL PROTECTED]> wrote in message
99ektl$gf0$[EMAIL PROTECTED]">news:99ektl$gf0$[EMAIL PROTECTED]...
> Don't even bother with that previous answer.  You have what you want to
> write in a string, $new.  Read the file and put that into another string,
> $previous.  Then concatenate the strings with the "." operator:
>
> $previous=$new . $previous
>
> and write $previous to the file.
>
>
>
>
> --
> 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]




[PHP] Complex IF statement

2001-03-22 Thread JCampbell

Thank you all for your help earlier!

Now I need to know if it is possible to create a complex if statement?

if ($variable=="duck") || ($variable=="goose"){ }else{ }

Is how I thought it would work. I just need to know if there is an easy way
to do an OR in if statements IF variable equals duck or goose...


===
And shepards we shall be
For thee, my lord, for thee
For thou hath descended forth from thy hands
That our feats may swiftly carry out thy command
We will flow a river forth unto thee
And teaming with souls shall it ever be...
===
http://jcampbell.blacklightning.net


-- 
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] Silly sessions problem.

2001-03-22 Thread hi

WRONG!!



-- 
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-CVS] cvs: php4 / configure.in

2001-03-22 Thread Stephen van Egmond

svanegmond  Thu Mar 22 20:56:51 2001 EDT

  Modified files:  
/php4   configure.in 
  Log:
  Added configuration for detecting the BeOS thread implementation 
  (which will be used once I get my patches into Zend to use bthreads).
  
  Also, a check for a library distributed with the new BeOS networking
  environment.
  
  
  
Index: php4/configure.in
diff -u php4/configure.in:1.223 php4/configure.in:1.224
--- php4/configure.in:1.223 Mon Mar 19 03:03:29 2001
+++ php4/configure.in   Thu Mar 22 20:56:51 2001
@@ -1,4 +1,4 @@
-dnl ## $Id: configure.in,v 1.223 2001/03/19 11:03:29 joosters Exp $ -*- sh -*-
+dnl ## $Id: configure.in,v 1.224 2001/03/23 04:56:51 svanegmond Exp $ -*- sh -*-
 dnl ## Process this file with autoconf to produce a configure script.
 
 divert(1)
@@ -107,7 +107,8 @@
 *bsdi*)
 BSD_MAKEFILE=yes;;
 *beos*)
-   LIBS="$LIBS -lbe -lroot"
+   beos_threads=1
+   LIBS="$LIBS -lbe -lroot";;
 esac
 
 AM_PROG_CC_STDC
@@ -253,7 +254,9 @@
   AC_ADD_LIBRARY(bind)
   AC_DEFINE(HAVE_LIBBIND,1,[Whether you have bind]) ], [
 AC_CHECK_LIB(resolv, inet_aton)
-  ]) 
+  ])
+AC_CHECK_LIB(bind, __inet_aton)
+
 
 dnl The res_search may be in libsocket as well, and if it is
 dnl make sure to check for dn_skipname in libresolv, or if res_search



-- 
PHP CVS 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] writing to a file

2001-03-22 Thread hi

Don't even bother with that previous answer.  You have what you want to
write in a string, $new.  Read the file and put that into another string,
$previous.  Then concatenate the strings with the "." operator:

$previous=$new . $previous

and write $previous to the file.




-- 
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 Digest 23 Mar 2001 04:46:34 -0000 Issue 583

2001-03-22 Thread php-general-digest-help


php-general Digest 23 Mar 2001 04:46:34 - Issue 583

Topics (messages 45137 through 45244):

Directory rights: Create and delete is possible but not ccggrp, why?
45137 by: Dominique Paquin
45139 by: Keith Vance
45146 by: Dominique Paquin

Freshmeat Ad?
45138 by: Michael Geier

Probs with PHP4 and MySQL File Upload...
45140 by: Kilian
45228 by: David Robley

Re: Oracle ODBC sql [ORA-00972: identifier is too long]
45141 by: Brian S. Dunworth
45143 by: Brian S. Dunworth
45235 by: Nold, Mark

A problem under Solaris
45142 by: Emiliano Marmonti
45147 by: Sebastien Roy
45148 by: Emiliano Marmonti
45153 by: Joe Rice
45162 by: Sebastien Roy
45223 by: Dunaway, Brian

Web Based PHP Content Manager Problems
45144 by: Phil
45151 by: CC Zona

ODBC only working for 82 rows
45145 by: Brooks, Ken
45156 by: Brooks, Ken

Date subtraction
45149 by: BlackLord
45168 by: almir

Re: LDAP problem
45150 by: Brett Bandy

.htaccess question
45152 by: Jimmy Bäckström
45155 by: Brian S. Dunworth

mail(), how can one specify  ?
45154 by: Richard
45165 by: David Smith

Problems uploading Files
45157 by: Renzi, Sebastian
45158 by: John Almberg
45159 by: Kilian
45161 by: Kilian
45164 by: Julian Wood

Make Script login to password protected web sites
45160 by: Brandon Orther

sessions.. again...
45163 by: Miguel Loureiro
45185 by: Chris Lee

Re: PAM authentification
45166 by: Matt McClanahan

imagepstext
45167 by: J.R. Carlson

need help with cookies
45169 by: kris.grinz.com
45170 by: Brian V Bonini
45172 by: kris.grinz.com
45183 by: Chris Lee
45239 by: Jack Sasportas

Re: Form help
45171 by: darion mapp

Array confusion.
45173 by: Sterling
45174 by: CC Zona
45175 by: Altunergil, Oktay
45177 by: Sterling

extract images from pdfs
45176 by: James

Register session in function without global?
45178 by: Tobias Talltorp
45179 by: CC Zona
45180 by: Chris Lee
45181 by: Tobias Talltorp

Re: mysql backup
45182 by: Henrik Hansen

ODBC & Oracle
45184 by: Brooks, Ken
45189 by: Brooks, Ken
45194 by: Brooks, Ken
45198 by: Joe Brown

libclntsh.so.8.0 : oracle+php under linux rh 6.2
45186 by: Robert Mena
45240 by: Adi Wibowo

Environment Variables
45187 by: Joe Rice
45192 by: Joe Rice

Printing MySQL into HTML Tables
45188 by: Jeff Oien
45199 by: darion mapp
45202 by: ..s.c.o.t.t.. [gts]

php 4.04pl 1-3 for red hat 7
45190 by: Larry Hotchkiss
45205 by: ..s.c.o.t.t.. [gts]

Crypt problem
45191 by: Randy Johnson
45204 by: ..s.c.o.t.t.. [gts]

I need an authentication method that is good... any Ideas? - please help
45193 by: Romulo Roberto Pereira
45196 by: ..s.c.o.t.t.. [gts]

Fopen help
45195 by: Kenneth R Zink II

Encryption Problem
45197 by: darion mapp
45201 by: ..s.c.o.t.t.. [gts]

PHP/CGI Help
45200 by: Maroufski
45203 by: ..s.c.o.t.t.. [gts]
45206 by: Peter Houchin
45227 by: Maroufski

Move data from one MySql table to another?
45207 by: YoBro
45208 by: Cal Evans
45209 by: James Atkinson
45210 by: YoBro
45211 by: Cal Evans

Oracle + apache + php + linux Red Hat 6.2(update)
45212 by: Robert Mena

Silly sessions problem.
45213 by: Lic. Rodolfo Gonzalez Gonzalez
45217 by: Chris Lee
45238 by: Lic. Rodolfo Gonzalez Gonzalez

Hello $variable, whats your name?
45214 by: JCampbell
45215 by: Cal Evans
45216 by: Jerry Lake
45222 by: Data Driven Design
45226 by: Noah Spitzer-Williams

Re: carriage return required??
45218 by: Eelco de Vries
45221 by: CC Zona
45225 by: Eelco de Vries

Re: Help!
45219 by: Fred
45220 by: Keith Vance

HELP? HTTP HEADER GURUS etc?
45224 by: brunatex

Re: reading microsoft word document text in php?
45229 by: David Robley

Sessions to password protect directory?
45230 by: Kyutums

Re: executables (.exe)
45231 by: Christian Dechery

how do I find out how many pixels wide / tall a string will be with gd ?
45232 by: Chris Lee
45233 by: Peter Houchin

writing to a file
45234 by: adam
45237 by: David Robley

Anyone have the wording for a license for clients?
45236 by: Cameron Just

security
45241 by: Randy Johnson
45242 by: Cal Evans
45243 by: David Robley

libt1 returned error 11
45244 by: J.R. Carlson

Administrivia:

To subscribe to the digest, e-mail:
[EMAIL PROTECTED]

To 

[PHP] libt1 returned error 11

2001-03-22 Thread J.R. Carlson

I'm using PHP4.0.4pl1 and t1lib.1.1.0

I'm getting this warning with imagepstext on some of my scripts (not
all), but everything prints fine. I only saw it because I commented out
the jpeg header line. Has anyone seen this?

Thanks,
JR


-- 
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-CVS] cvs: php4 /ext/standard microtime.c

2001-03-22 Thread Stephen van Egmond

svanegmond  Thu Mar 22 20:36:29 2001 EDT

  Modified files:  
/php4/ext/standard  microtime.c 
  Log:
  Simple patch to deal with lack of fields in the BeOS implementation of rusage.
  
  
  
Index: php4/ext/standard/microtime.c
diff -u php4/ext/standard/microtime.c:1.29 php4/ext/standard/microtime.c:1.30
--- php4/ext/standard/microtime.c:1.29  Sun Feb 25 22:07:23 2001
+++ php4/ext/standard/microtime.c   Thu Mar 22 20:36:29 2001
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: microtime.c,v 1.29 2001/02/26 06:07:23 andi Exp $ */
+/* $Id: microtime.c,v 1.30 2001/03/23 04:36:29 svanegmond Exp $ */
 
 #include "php.h"
 
@@ -116,7 +116,7 @@
array_init(return_value);
 #define PHP_RUSAGE_PARA(a) \
add_assoc_long(return_value, #a, usg.a)
-#ifndef _OSD_POSIX /* BS2000 has only a few fields in the rusage struct */
+#if !defined( _OSD_POSIX) && !defined(__BEOS__) /* BS2000 has only a few fields in 
+the rusage struct */
PHP_RUSAGE_PARA(ru_oublock);
PHP_RUSAGE_PARA(ru_inblock);
PHP_RUSAGE_PARA(ru_msgsnd);



-- 
PHP CVS 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] security

2001-03-22 Thread David Robley

On Fri, 23 Mar 2001 14:18, Randy Johnson wrote:
> In PHP how do I make it so a script cannot be called from somewhere
> else other than from my server.
>
> Example
>
> http://domain.com/mail.php   is my mail script that is called by
> http://domain.com/signup.html
>
> How do I make it so
>
> http://somebodyelsesdomain.com/signup.html cannot call the mail.php
> script.
>
>
> thanks
>
> Randy


If you are using the POST method to pass data, set a hidden value in 
signup.html which you can test for in mail.php. Not a perfect method, as 
doing a 'view source' on signup.html will reveal it.


-- 
David Robley| WEBMASTER & Mail List Admin
RESEARCH CENTRE FOR INJURY STUDIES  | http://www.nisu.flinders.edu.au/
AusEinet| http://auseinet.flinders.edu.au/
Flinders University, ADELAIDE, SOUTH AUSTRALIA

-- 
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] security

2001-03-22 Thread Cal Evans

check HTTP_REFERER. If it's not your server. toss it. It's not the most
secure way but check the page, there are other variables you can use to
accomplish the same thing.

http://www.php.net/manual/en/language.variables.predefined.php



Cal
http://www.calevans.com


-Original Message-
From: Randy Johnson [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 22, 2001 9:48 PM
To: [EMAIL PROTECTED]
Subject: [PHP] security


In PHP how do I make it so a script cannot be called from somewhere else
other than from my server.

Example

http://domain.com/mail.php   is my mail script that is called by
http://domain.com/signup.html

How do I make it so

http://somebodyelsesdomain.com/signup.html cannot call the mail.php script.


thanks

Randy


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




[PHP] security

2001-03-22 Thread Randy Johnson

In PHP how do I make it so a script cannot be called from somewhere else
other than from my server.

Example

http://domain.com/mail.php   is my mail script that is called by
http://domain.com/signup.html

How do I make it so

http://somebodyelsesdomain.com/signup.html cannot call the mail.php script.


thanks

Randy


-- 
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] libclntsh.so.8.0 : oracle+php under linux rh 6.2

2001-03-22 Thread Adi Wibowo


On Thu, 22 Mar 2001, Robert Mena wrote:
> Hi, I've succesfully installed a oracle 8.1.7 (chose
> server option) under a development redhat 6.2 box.
> 
> I've compiled php as DSO with a
> --with-oci8=path/to/ORACLE_HOME and it compiled ok. 
> If I try to start httpd I keep getting
> 
> Cannot load /etc/httpd/modules/libphp4.so into server:
> libclntsh.so.8.0: cannot open shared object file: No
> such file or directory

Try include your ORACLE_HOME or ORACLE_HOME/lib to ld.so.conf and run
ldconfig.

Try start apache again.
Good luck.

Adi Wibowo ---
* Work matter: [EMAIL PROTECTED]
* Private matter : [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] need help with cookies

2001-03-22 Thread Jack Sasportas

I would suggest for you to take all the complicated stuff out of a simple text
script and try something like this:
<%
setcookie("TestValue","Working",600)
%>

Make sure that nothing is being sent prior to setting the cookie, and see if IE
prompts you...

Good Luck!

[EMAIL PROTECTED] wrote:

> Hi, I am trying to set a cookie and it doesn't work.  I am running IE 5.
> I have IE set to prompt before setting cookies but I never get a prompt.
>
> Here is my code - basically, if someone logs in, it is to set a cookie.
> What am I missing?   Kris
>
> if($success==1){
> $loginid="$id";
> NewSessionID($id);
> GetProfile($id);
> $page_title="LTT: $loginid Index";
> include("html-head.php3");
> if($id==""){
> include("ln/ln_ln_dna.php3");
> exit;
> }
> include("ms/rg1/index.php3");
> exit;
> }
>
> function NewSessionID($id){
> $sid="";
> $length=16;
> srand((double)microtime()*100);
> $SessPool = "ABCDEFGHIJKLMNOPQRSTUVWXYZ";
> $SessPool .= "abcdefghijklmnopqrstuvwxyz";
> $SessPool .= "0123456789";
>
> for($tempslime=0; $tempslime < $length; $tempslime++) {
> $sid .= substr($SessPool, (rand()%(strlen($SessPool))), 1);
> }
> setcookie("LoginAuth", $sid,time()+3600);
> }
>
> --
> 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]

--
___
Jack Sasportas
Innovative Internet Solutions
Phone 305.665.2500
Fax 305.665.2551
www.innovativeinternet.com
www.web56.net



-- 
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] Silly sessions problem.

2001-03-22 Thread Lic. Rodolfo Gonzalez Gonzalez

> I just can't make sessions work.

Now this is strange! I copied exactly the same scripts I posted to my
win98SE box running Apache 1.3.19 and PHP  4.0.4pl1 and they worked!.
Which could be the reasons for the sessions not to work?. Do they work
transparently for name based virtuals, don't they?.




-- 
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] writing to a file

2001-03-22 Thread David Robley

On Fri, 23 Mar 2001 12:39, adam wrote:
> how might i write to a file called "comment.php.comment" and only write
> the text specified to the top of the file, instead of writing it to the
> bottom?

You need several steps to achieve this:

read all of comment.php.comment into an array
open a temp file to write
write the 'text specified' to the temp file
write the array from comment.php.comment to the temp file
once you're happy all is written, close open temp file
rename temp file to comment.php.comment

The functions you need for this can be found in the Filesystem section of 
the docs.

-- 
David Robley| WEBMASTER & Mail List Admin
RESEARCH CENTRE FOR INJURY STUDIES  | http://www.nisu.flinders.edu.au/
AusEinet| http://auseinet.flinders.edu.au/
Flinders University, ADELAIDE, SOUTH AUSTRALIA

-- 
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] Anyone have the wording for a license for clients?

2001-03-22 Thread Cameron Just

Hi,

I have been developing PHP for a few years now as an employeee of other companies.
I have now started working from home doing contracts for various businesses.

Does anyone know of where I can find the wording of a software license I can give to 
my clients when I hand over the code.
It should cover the following points.

1. I am offering them unlimited licensed use of the code I have produced.
2. They cannot on sell my code.
3. I retain copyright for my code. (This might come as a default)
4. 40% - 60% of my code is generic functions that I use in all my websites and I 
retain the ability to use this code again in developing work for other businesses.
5. They are free to modify and adjust my code as much as they want.

Does anyone know where I can find some sort of legal document I can give to these 
clients as a license for the software I produce for them.

Is there any important points I have missed?
I know the law is very different from country to country but I'm sure much of this 
would be the same.




Cameron Just ([EMAIL PROTECTED])

Phoenix Digital Development



-- 
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 Nold, Mark


- 
Disclaimer: The information contained in this email is intended only for the
use of the person(s) to whom it is addressed and may be confidential or
contain legally privileged information. If you are not the intended
recipient you are hereby notified that any perusal, use, distribution,
copying or disclosure is strictly prohibited. If you have received this
email in error please immediately advise us by return email at
[EMAIL PROTECTED] and delete the email document without making a
copy. 

-
Ken,

Just a comment, have you tried using the OCI or ORA interface? instead of
going through ODBC. Since you already have SQL*Net setup (you must have for
ODBC from memory) why not try it. It should be faster than straight ODBC
plus you wont get caught by any ODBC driver issues (i know the drivers can
change things like they do accept COLUMN like '*foo*' and they have limits
on very large SQL statements).

Using ODBC will be easier if you are swapping from Access to Oracle, but if
you use a DB Abstaction layer (see PEAR, PHPLib, Metabase) this wont be an
issue either.

mn




Mark Nold
[EMAIL PROTECTED]  
Senior Consultant
 
Change is inevitable, except from vending machines. 



-Original Message-
From: Brooks, Ken [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 22, 2001 11:16 PM
To: [EMAIL PROTECTED]
Subject: RE: [PHP] RE: Oracle ODBC sql [ORA-00972: identifier is too
long]


I got it.

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 .

Whee!

-Original Message-
From: Brooks, Ken [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 22, 2001 9:52 AM
To: [EMAIL PROTECTED]
Subject: RE: [PHP] RE: Oracle ODBC sql [ORA-00972: identifier is too
long]


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?..

-ken

-Original Message-
From: Brooks, Ken [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 22, 2001 9:32 AM
To: [EMAIL PROTECTED]
Subject: [PHP] RE: Oracle ODBC sql [ORA-00972: identifier is too long]


I only mentioned the part about the access, just to prove that I know i have
a select
statement working with an ODBC source. 

I know that I am connecting to the Oracle database, because if i put in a
bogus user/pass
i get an error stating so, when I supply the correct credentials I get no
errors.

So that just leaves something to do with possibly the table names.
The exact table name is: ARADMIN_EPS_SERVICE_INSTRUCTIONS
by my count that is 32 characters. That could be a problem. Any way around
that, or
to alias a name to that? (Mind you, i don't have access to that database to
change
the table names). I can only query from it.


The exact offending line number that is returned is 37.

36: $si_oracle_query = "SELECT * FROM ARADMIN_EPS_SERVICE_INSTRUCTIONS where
ATMID = 'PN2000'";
37: $si_oracle_result = odbc_exec($td_oracle, $si_oracle_query);

-ken


-Original Message-
From: Greig, Euan [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 22, 2001 9:21 AM
To: Brooks, Ken
Cc: [EMAIL PROTECTED]
Subject: [PHP] RE: Oracle ODBC sql [ORA-00972: identifier is too long]


I haven't used Oracle with ODBC, but nothing leaps out at me from your code.
Some comments/ideas: 

The full meaning of error 0972 is that the name of a schema object (table,
view, username etc) is too long (longer than 30 characters, maybe more for
Oracle 8). The query statement you are using looks OK. How about displaying
$username and $password? And have you isolated which line is causing the
error?

The relevance of ' and " I suppose is this. By default Oracle is not case
sensitive about the names of database objects, but it is if when you create
them you enclose the name in double quotes. For instance if you simply say
'create table euan', then you will be able to access it with  'select * from
euan', 'select * from EUAN', 'select * from Euan' etc. But if you say
'create table "euan"', then you will forever have to say 'select * from
"euan"'.

Problems can indeed arise when interfacing between Access and Oracle,
because I believe that Access is case sensitive by default, and Oracle
programmers tend not to expect this. But none of this seems very applicable
to your case... or is it?

-Original Message-
From: Brooks, Ken [mailto:[EMAIL PROTECTED]]
Sent: 22 March 2001 14:04
To: 'Greig, Euan'; [EMAIL PROTECTED]
Subject: Oracle ODBC sql [ORA-00972: identifier is too long]


I'm getting this message when i try to ru

[PHP-CVS] cvs: php4 /pear/HTML Table.php

2001-03-22 Thread Adam Daniel

adaniel Thu Mar 22 18:14:05 2001 EDT

  Modified files:  
/php4/pear/HTML Table.php 
  Log:
  moved the display method to HTML_Common and updated some comments
  

Index: php4/pear/HTML/Table.php
diff -u php4/pear/HTML/Table.php:1.3 php4/pear/HTML/Table.php:1.4
--- php4/pear/HTML/Table.php:1.3Thu Mar 22 06:32:51 2001
+++ php4/pear/HTML/Table.phpThu Mar 22 18:14:05 2001
@@ -17,184 +17,184 @@
 // |  Bertrand Mansion <[EMAIL PROTECTED]> |
 // +--+
 //
-// $Id: Table.php,v 1.3 2001/03/22 14:32:51 mj Exp $
+// $Id: Table.php,v 1.4 2001/03/23 02:14:05 adaniel Exp $
 
 require_once "PEAR.php";
 require_once "HTML/Common.php";
 
 /**
-* Builds an HTML table
-*
-* @author  Adam Daniel <[EMAIL PROTECTED]>
-* @author  Bertrand Mansion <[EMAIL PROTECTED]>
-* @version 1.5
-* @since   PHP 4.0.3pl1
-*
-* Example:
-*   $table = new HTML_Table;
-*   ...
-*/
+ * Builds an HTML table
+ *
+ * @authorAdam Daniel <[EMAIL PROTECTED]>
+ * @authorBertrand Mansion <[EMAIL PROTECTED]>
+ * @version   1.5
+ * @since PHP 4.0.3pl1
+ *
+ * Example:
+ *   $table = new HTML_Table;
+ *   ...
+ */
 class HTML_Table extends HTML_Common {
 
-   /**
-   * Automatically adds a new row or column if a given row or column index does 
not exist
-   * @var  bool
-   * @access   private
-   */
-   var $_autoGrow = true;
-
-   /**
-   * Value to insert into empty cells
-   * @var  string
-   * @access   private
-   */
-   var $_autoFill = " ";
-
-   /**
-   * Array containing the table structure
-   * @var  array
-   * @access   private
-   */
-   var $_structure = array();
-
-   /**
-   * Number of rows composing in the table
-   * @var  int
-   * @access   private
-   */
-   var $_rows = 0;
-
-   /**
-   * Number of column composing the table
-   * @var  int
-   * @access   private
-   */
-   var $_cols = 0;
-
-   /**
-   * Class constructor
-   * @paramarray   $attributes Associative array of table tag 
attributes
-* @paramint $tabOffset
-   * @access   public
-   */
-   function HTML_Table($attributes=null, $tabOffset=0)
-   {
+/**
+ * Automatically adds a new row or column if a given row or column index does not 
+exist
+ * @varbool
+ * @accessprivate
+ */
+var $_autoGrow = true;
+
+/**
+ * Value to insert into empty cells
+ * @varstring
+ * @accessprivate
+ */
+var $_autoFill = " ";
+
+/**
+ * Array containing the table structure
+ * @vararray
+ * @accessprivate
+ */
+var $_structure = array();
+
+/**
+ * Number of rows composing in the table
+ * @varint
+ * @accessprivate
+ */
+var $_rows = 0;
+
+/**
+ * Number of column composing the table
+ * @varint
+ * @accessprivate
+ */
+var $_cols = 0;
+
+/**
+ * Class constructor
+ * @paramarray$attributesAssociative array of table tag attributes
+ * @paramint $tabOffset
+ * @accesspublic
+ */
+function HTML_Table($attributes=null, $tabOffset=0)
+{
 $commonVersion = 1.3;
 if (HTML_Common::apiVersion() < $commonVersion) {
 return new PEAR_Error("HTML_Table version " . $this->apiVersion() . " 
requires " .
 "HTML_Common version $commonVersion or greater.", 0, 
PEAR_ERROR_TRIGGER);
 }
-   HTML_Common::HTML_Common($attributes, $tabOffset);
-   } // end constructor
+HTML_Common::HTML_Common($attributes, $tabOffset);
+} // end constructor
 
-   /**
-   * Returns the API version
-   * @access   public
-* @returns  double
-   */
-   function apiVersion()
-   {
-   return 1.5;
-   } // end func apiVersion
-
-   /**
-   * Sets the table caption
-   * @paramstring  $caption
-   * @parammixed   $attributes Associative array or string of 
table row attributes
-   * @access   public
-   */
-   function setCaption($caption, $attributes=null)
-   {
-   $attributes = $this->_parseAttributes($attributes);
-   $this->_structure["caption"] = array("attr"=>$attributes, 
"contents"=>$caption);
-   } // end func setCaption
-
-/**
-* Sets the autoFill value
-* @parammixed   $fill
-* @access   public
-*/
+/**
+ * Returns the API version
+ * @access  public
+ * @returns double
+ */
+function apiVersion()
+{
+return 1.5;
+} // end func apiVersion
+
+/**
+ * Sets the table caption
+ * @param   string$caption
+   

[PHP-CVS] cvs: php4 /pear/HTML Common.php

2001-03-22 Thread Adam Daniel

adaniel Thu Mar 22 18:13:19 2001 EDT

  Modified files:  
/php4/pear/HTML Common.php 
  Log:
  updated some comments, added display method, and added the toHtml abstract method
  
Index: php4/pear/HTML/Common.php
diff -u php4/pear/HTML/Common.php:1.4 php4/pear/HTML/Common.php:1.5
--- php4/pear/HTML/Common.php:1.4   Thu Mar 22 17:11:59 2001
+++ php4/pear/HTML/Common.php   Thu Mar 22 18:13:18 2001
@@ -16,37 +16,38 @@
 // | Authors: Adam Daniel <[EMAIL PROTECTED]>|
 // +--+
 //
-// $Id: Common.php,v 1.4 2001/03/23 01:11:59 adaniel Exp $
+// $Id: Common.php,v 1.5 2001/03/23 02:13:18 adaniel Exp $
 
 /**
-* Base class for all HTML classes
-*
-* @author  Adam Daniel <[EMAIL PROTECTED]>
-* @version 1.3
-* @since   PHP 4.0.3pl1
-*/
+ * Base class for all HTML classes
+ *
+ * @author  Adam Daniel <[EMAIL PROTECTED]>
+ * @version 1.3
+ * @since   PHP 4.0.3pl1
+ * @abstract
+ */
 class HTML_Common {
 
 /**
-* Associative array of table attributes
-* @var  array
-* @access   private
-*/
+ * Associative array of table attributes
+ * @var  array
+ * @access   private
+ */
 var $_attributes = array();
 
 /**
-* Tab offset of the table
-* @var  int
-* @access   private
-*/
+ * Tab offset of the table
+ * @var  int
+ * @access   private
+ */
 var $_tabOffset = 0;
 
 /**
-* Class constructor
-* @parammixed   $attributes Associative array of table tag attributes 
-*   or HTML attributes name="value" pairs
-* @access   public
-*/
+ * Class constructor
+ * @parammixed   $attributes Associative array of table tag attributes 
+ *   or HTML attributes name="value" pairs
+ * @access   public
+ */
 function HTML_Common($attributes=null, $tabOffset=0)
 {
 $this->setTabOffset($tabOffset);
@@ -54,30 +55,30 @@
 } // end constructor
 
 /**
-* Returns the current API version
-* @access   public
-* @returns  double
-*/
+ * Returns the current API version
+ * @access   public
+ * @returns  double
+ */
 function apiVersion()
 {
 return 1.3;
 } // end func apiVersion
 
 /**
-* Returns a string of \t for the tabOffset property
-* @access   private
-*/
+ * Returns a string of \t for the tabOffset property
+ * @access   private
+ */
 function _getTabs()
 {
 return $this->_tabOffset > 0 ? str_repeat("\t", $this->_tabOffset) : "";
 } // end func _getTabs
 
 /**
-* Returns an HTML formatted attribute string
-* @paramarray   $attributes
-* @return   string
-* @access   private
-*/
+ * Returns an HTML formatted attribute string
+ * @paramarray   $attributes
+ * @return   string
+ * @access   private
+ */
 function _getAttrString($attributes)
 {
 $strAttr = "";
@@ -94,10 +95,10 @@
 } // end func _getAttrString
 
 /**
-* Returns a valid atrributes array from either a string or array
-* @parammixed   $attributes Either a typical HTML attribute string or an 
associative array
-* @access   private
-*/
+ * Returns a valid atrributes array from either a string or array
+ * @parammixed   $attributes Either a typical HTML attribute string or an 
+associative array
+ * @access   private
+ */
 function _parseAttributes($attributes)
 {
 if (is_array($attributes)) {
@@ -127,12 +128,12 @@
 } // end func _parseAttributes
 
 /**
-* Updates the attributes in $attr1 with the values in $attr2 without changing the 
other existing attributes
-* @paramarray   $attr1  Original attributes array
-* @paramarray   $attr2  New attributes array
-* @access   private
-* @return   array
-*/
+ * Updates the attributes in $attr1 with the values in $attr2 without changing 
+the other existing attributes
+ * @paramarray   $attr1  Original attributes array
+ * @paramarray   $attr2  New attributes array
+ * @access   private
+ * @return   array
+ */
 function _updateAttrArray(&$attr1, $attr2)
 {
 while (list($key, $value) = each($attr2)) {
@@ -162,20 +163,20 @@
 } // end func _updateAtrrArray
 
 /**
-* Sets the HTML attributes
-* @parammixed   $attributes Either a typical HTML attribute string or an 
associative array
-* @access   public
-*/
+ * Sets the HTML attributes
+ * @parammixed   $attributes Either a typical HTML attribute string or an 
+associative array
+ * @access   public
+ */
 function setAttributes($attributes) 
 {
 $this->_attributes = $this->_parseAttributes($attributes);
 } // end func _s

[PHP] writing to a file

2001-03-22 Thread adam

how might i write to a file called "comment.php.comment" and only write the
text specified to the top of the file, instead of writing it to the bottom?



-- 
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 do I find out how many pixels wide / tall a string will be with gd ?

2001-03-22 Thread Peter Houchin

Chris,

 why wouldn't you just use the html way of right justifying text? ie 
so in php just use echo " blah foo boo"; 
-Original Message-
From: Chris Lee [mailto:[EMAIL PROTECTED]]
Sent: Friday, March 23, 2001 10:56 AM
To: [EMAIL PROTECTED]
Subject: [PHP] how do I find out how many pixels wide / tall a string
will be with gd ?


I would like to right justify some text, as far as I know, I will need to determin how 
many pixels wide a string will be on the image, then subtract that value from the x 
cord of the line your right justifing it to. you know have the x cord for the text. am 
I correct? if so how do I figure our how long my string is ?


-- 

 Chris Lee
 [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]




[PHP] how do I find out how many pixels wide / tall a string will be with gd ?

2001-03-22 Thread Chris Lee

I would like to right justify some text, as far as I know, I will need to determin how 
many pixels wide a string will be on the image, then subtract that value from the x 
cord of the line your right justifing it to. you know have the x cord for the text. am 
I correct? if so how do I figure our how long my string is ?


-- 

 Chris Lee
 [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] executables (.exe)

2001-03-22 Thread Christian Dechery

At 18:18 21/3/2001 -0800, you wrote:
>If you're on windows, (which i'm assuming you are) you can call the PHP
>binary with the path to your php script...
>
>so (assuming you have C:\php\bin\ as part of your PATH enviromental
>variables for windows) you could do PHP C:\path\to\php-script.php and it
>will run on the command line...or just give the full path to the php.exe
>file...
>
>C:\php\bin\php.exe C:\path\to\php-script.php

oh okay... I was thinking more of a standalone file like php-script.exe... 
but that should work as well...
Thanks!

. Christian Dechery (lemming)
. http://www.tanamesa.com.br
. Gaita-L Owner / Web Developer


-- 
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-CVS] cvs: php4 /pear DB.php PEAR.php.in /pear/DB STATUS common.php oci8.php /pear/DB/tests errors.inc fetchrow.inc numrows.inc sequences.inc /pear/DB/tests/ibase mktable.inc /pear/DB/tests/mysql mktable.inc /pear/DB/tests/oci8 002.phpt 007.phpt 009.phpt 010.phpt connect.inc mktable.inc skipif.inc /pear/DB/tests/odbc mktable.inc /pear/DB/tests/pgsql mktable.inc

2001-03-22 Thread Stig Bakken

ssb Thu Mar 22 17:15:10 2001 EDT

  Modified files:  
/php4/pear  DB.php PEAR.php.in 
/php4/pear/DB   STATUS common.php oci8.php 
/php4/pear/DB/tests errors.inc fetchrow.inc numrows.inc 
sequences.inc 
/php4/pear/DB/tests/ibase   mktable.inc 
/php4/pear/DB/tests/mysql   mktable.inc 
/php4/pear/DB/tests/oci8002.phpt 007.phpt 009.phpt 010.phpt 
connect.inc mktable.inc skipif.inc 
/php4/pear/DB/tests/odbcmktable.inc 
/php4/pear/DB/tests/pgsql   mktable.inc 
  Log:
  * fixed Oracle tests, fixed some bugs in DB_oci8, all tests but
errorNative() pass now (but that may be a bug in the test :-)
  * implemented numRows() emulation in DB_oci8 that is available
in "optimize portability" mode only
  
  

Index: php4/pear/DB.php
diff -u php4/pear/DB.php:1.51 php4/pear/DB.php:1.52
--- php4/pear/DB.php:1.51   Tue Mar 20 20:15:40 2001
+++ php4/pear/DB.phpThu Mar 22 17:15:05 2001
@@ -17,7 +17,7 @@
 // |  Tomas V.V.Cox <[EMAIL PROTECTED]> |
 // +--+
 //
-// $Id: DB.php,v 1.51 2001/03/21 04:15:40 jon Exp $
+// $Id: DB.php,v 1.52 2001/03/23 01:15:05 ssb Exp $
 //
 // Database independent query interface.
 //
@@ -56,6 +56,7 @@
 define("DB_ERROR_NOT_LOCKED", -21);
 define("DB_ERROR_VALUE_COUNT_ON_ROW", -22);
 define("DB_ERROR_INVALID_DSN",-23);
+define("DB_ERROR_CONNECT_FAILED", -24);
 
 /*
  * Warnings are not detected as errors by DB::isError(), and are not
@@ -326,6 +327,8 @@
 DB_ERROR_SYNTAX => 'syntax error',
 DB_ERROR_UNSUPPORTED=> 'not supported',
 DB_ERROR_VALUE_COUNT_ON_ROW => 'value count on row',
+DB_ERROR_INVALID_DSN=> "invalid DSN",
+DB_ERROR_CONNECT_FAILED => "connect failed",
 DB_OK   => 'no error',
 DB_WARNING  => 'unknown warning',
 DB_WARNING_READ_ONLY=> 'read only'
Index: php4/pear/PEAR.php.in
diff -u php4/pear/PEAR.php.in:1.15 php4/pear/PEAR.php.in:1.16
--- php4/pear/PEAR.php.in:1.15  Sat Mar 10 01:59:15 2001
+++ php4/pear/PEAR.php.in   Thu Mar 22 17:15:05 2001
@@ -17,7 +17,7 @@
 // |  Stig Bakken <[EMAIL PROTECTED]>   |
 // +--+
 //
-// $Id: PEAR.php.in,v 1.15 2001/03/10 09:59:15 ssb Exp $
+// $Id: PEAR.php.in,v 1.16 2001/03/23 01:15:05 ssb Exp $
 //
 
 define('PEAR_ERROR_RETURN', 1);
@@ -513,12 +513,12 @@
 $modes[] = "return";
 }
 return sprintf('[%s: message="%s" code=%d mode=%s level=%s prefix="%s" '.
-   'prepend="%s" append="%s" debug="%s"]',
+   'prepend="%s" append="%s" info="%s"]',
get_class($this), $this->message, $this->code,
implode("|", $modes), $levels[$this->level],
$this->error_message_prefix,
$this->error_prepend, $this->error_append,
-   $this->debuginfo);
+   $this->userinfo);
 }
 
 // }}}
Index: php4/pear/DB/STATUS
diff -u php4/pear/DB/STATUS:1.14 php4/pear/DB/STATUS:1.15
--- php4/pear/DB/STATUS:1.14Sun Jan 14 17:19:28 2001
+++ php4/pear/DB/STATUS Thu Mar 22 17:15:06 2001
@@ -10,14 +10,14 @@
   "-" - no implementation of this feature
 
 FEATURE ibase   msqlmssql   mysql   oci8odbcpgsql   sybase
-simpleQuery   x   x   x   T   x   x   T   x
-numCols   x   x   x   T   x   x   T   x
-numRows   n   x   x   T   n   n   T   n
+simpleQuery   x   x   x   T   T   x   T   x
+numCols   x   x   x   T   T   x   T   x
+numRows   n   x   x   T   E   n   T   n
 errorNative   n   n   n   T   x   x   T   n
-prepare/execute   x   e   e   E   x   e   E   e
-sequences n   n   n   E   n   n   T   n
-affectedRows  n   n   n   T   x   n   T   n
-fetch modes   x   x   x   T   x   x   T   x
+prepare/execute   x   e   e   E   T   e   E   e
+sequences n   n   n   E   T   n   T   n
+affectedRows  n   n   n   T   T   n   T   n
+fetch modes   x   x   x   T   T   x   T   x
 transactions  x   n   n   n   x   x   x   n
 auto-commit   x   n   n   n   x   x   x   n
-error ma

[PHP-CVS] cvs: php4 /pear/HTML Common.php

2001-03-22 Thread Adam Daniel

adaniel Thu Mar 22 17:11:59 2001 EDT

  Modified files:  
/php4/pear/HTML Common.php 
  Log:
  removed the pass by reference on the second parameter of _updateAttrArray
  
Index: php4/pear/HTML/Common.php
diff -u php4/pear/HTML/Common.php:1.3 php4/pear/HTML/Common.php:1.4
--- php4/pear/HTML/Common.php:1.3   Thu Mar 22 07:27:07 2001
+++ php4/pear/HTML/Common.php   Thu Mar 22 17:11:59 2001
@@ -16,7 +16,7 @@
 // | Authors: Adam Daniel <[EMAIL PROTECTED]>|
 // +--+
 //
-// $Id: Common.php,v 1.3 2001/03/22 15:27:07 mj Exp $
+// $Id: Common.php,v 1.4 2001/03/23 01:11:59 adaniel Exp $
 
 /**
 * Base class for all HTML classes
@@ -129,11 +129,11 @@
 /**
 * Updates the attributes in $attr1 with the values in $attr2 without changing the 
other existing attributes
 * @paramarray   $attr1  Original attributes array
-* @paramarray   $attr2  New attrbiutes array
+* @paramarray   $attr2  New attributes array
 * @access   private
 * @return   array
 */
-function _updateAttrArray(&$attr1, &$attr2)
+function _updateAttrArray(&$attr1, $attr2)
 {
 while (list($key, $value) = each($attr2)) {
 if (!is_int($key)) {



-- 
PHP CVS 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] Sessions to password protect directory?

2001-03-22 Thread Kyutums

Good day to all!

Before, I was able to password protect html and php files via a username
and passowrd script which used sessions. Now, I need to password protect
a folder (via .htaccess) that has images (for a family album thing). Can
this be done via sessions (or even cookies)? I don't want to
authenticate the user via forms and not via the pop-up that a browser
presents when using an .htaccess file. Any scripts that already do this
(password protect a directory)?

Thanks for all your help.

- Kyutums


-- 
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] reading microsoft word document text in php?

2001-03-22 Thread David Robley

On Thu, 22 Mar 2001 12:51, Erick Papadakis wrote:
> hello, i need to read a microsoft Word document on the server through
> my file system. is there a way i can read the text of a word document?
>
> thanks/erick

If youu are on a *nix system, there is a package called mswordview, or 
alternatively you could check the www.htdig.org site for document parsers 
(catdoc.pl and parsedoc.pl, I think).

If you are on Windows you could of course use Turd itself, but I think 
there is also some sort of Word doc viewer; whether they will do what you 
want is another story.

-- 
David Robley| WEBMASTER & Mail List Admin
RESEARCH CENTRE FOR INJURY STUDIES  | http://www.nisu.flinders.edu.au/
AusEinet| http://auseinet.flinders.edu.au/
Flinders University, ADELAIDE, SOUTH AUSTRALIA

-- 
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] Probs with PHP4 and MySQL File Upload...

2001-03-22 Thread David Robley

On Fri, 23 Mar 2001 03:46, Kilian wrote:
> Hello All!
>
> Since I upgraded to PHP4, file upload into MySQL tables seems not to
> work anymore. I am using PHPMyAdmin to access the database. When I try
> to upload a file there, I get the Error "The file '[tmpdir]/php129947'
> must be in the database directory or be readable by all" where [tmpdir]
> is the upload_tmp_dir specified in php.ini. This directory has 777
> permissions, so it is readable by all.
>
> I'm confused because it worked without any problems with PHP 3.
>
> Thanks very much for any hint...
>
> Greetz,
> Kilian

You saty the _directory_ is world readable, but the file being uploaded 
may not be world readable - you may have to chmod it as part of the 
process.

-- 
David Robley| WEBMASTER & Mail List Admin
RESEARCH CENTRE FOR INJURY STUDIES  | http://www.nisu.flinders.edu.au/
AusEinet| http://auseinet.flinders.edu.au/
Flinders University, ADELAIDE, SOUTH AUSTRALIA

-- 
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-CVS] cvs: php4 /ext/fbsql php_fbsql.c

2001-03-22 Thread Frank M. Kromann

fmk Thu Mar 22 16:58:59 2001 EDT

  Modified files:  
/php4/ext/fbsql php_fbsql.c 
  Log:
  Removing extra check for warnings.
  
Index: php4/ext/fbsql/php_fbsql.c
diff -u php4/ext/fbsql/php_fbsql.c:1.6 php4/ext/fbsql/php_fbsql.c:1.7
--- php4/ext/fbsql/php_fbsql.c:1.6  Thu Mar 22 13:16:23 2001
+++ php4/ext/fbsql/php_fbsql.c  Thu Mar 22 16:58:59 2001
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_fbsql.c,v 1.6 2001/03/22 21:16:23 fmk Exp $ */
+/* $Id: php_fbsql.c,v 1.7 2001/03/23 00:58:59 fmk Exp $ */
 
 /* TODO:
  *
@@ -552,12 +552,12 @@
 }
 
 
-int phpfbFetchRow (PHPFBResult* result, int row)
+int phpfbFetchRow(PHPFBResult* result, int row)
 {
if (result->rowHandler == NULL)
{
-void *rawData = 
fbcdcFetch(result->connection,result->batchSize,result->fetchHandle);
-if (rawData == NULL)
+   void *rawData = 
+fbcdcFetch(result->connection,result->batchSize,result->fetchHandle);
+   if (rawData == NULL)
result->rowCount = 0;
else
result->rowHandler = fbcrhInitWith(rawData, result->metaData);
@@ -1513,26 +1513,6 @@
 
meta = fbcdcExecuteDirectSQL(database->connection,sql);
 
-   if (fbcmdErrorCount(meta) > 0) {
-   FBCErrorMetaData *errorMeta;
-   char *errorMessage;
-   unsigned error_type = 0;
-
-   errorMeta = fbcdcErrorMetaData(database->connection, meta);
-   error_type = fbcemdErrorCodeAtIndex(errorMeta, 0);
-   errorMessage = fbcemdAllErrorMessages(errorMeta);
-   if (error_type != 250) {
-   php_error(E_WARNING, "Error executing SQL-statement (%s)", 
sql);
-   }
-// free(errorMessage);
-   fbcemdRelease(errorMeta);
-
-   if (error_type != 250) {
-   fbcmdRelease(meta);
-   return NULL;
-   }
-   }
-
if (fbcmdHasMetaDataArray(meta)) {
sR = fbcmdMetaDataArrayCount(meta);
md = (FBCMetaData*)fbcmdMetaDataAtIndex(meta, cR);
@@ -1540,7 +1520,7 @@
else
md = meta;
 
-   ok = mdOk(database,md);
+   ok = mdOk(database, md);
tp = fbcmdStatementType(md);
 
return_value->value.lval = ok?-1:0;



-- 
PHP CVS 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/CGI Help

2001-03-22 Thread Nicholas Marouf

Hi Peter,
Thanks for all the help.  I actually started playing with what you told
me, and then did some trial-and-error testing
and found out that I didn't need ScriptAlias /src "/home/src/" at all.The
.php3 files ran when I removed it, then I added these
two lines to get the .pl and .cgi to work for the virtual host.

AddHandler cgi-script .cgi
AddHandler cgi-script .pl

Works like a charm.

Thanks again.

Nick



Peter Houchin wrote:

> you also need to have
> ScriptAlias /src "/home/src/"
> Action application/x-httpd-php4 "php excicution file location"
> AddType application/x-httpd-php4 .php
>

> > -Original Message-
> > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf
> > Of Maroufski
> > Sent: Thursday, March 22, 2001 5:41 PM
> > To: [EMAIL PROTECTED]
> > Subject: [PHP] PHP/CGI Help
> >
> >
> > Hi all,
> > This is a tough one, wasn't able to find a solution so far. But
> > I hope that someone can help me out
> > or point me in the right direction.
> >
> > Here is what I got:
> >
> > /src contains a bunch of cgi scripts that require apache to have an
> > entry like this
> >
> > ScriptAlias /src "/home/src/"
> >
> > When I try to run a file with .php extension in /src I get an error.
> > I figured out since I have ScriptAlias /src,  Apache will handle every
> > file called in that directory as if it were a perl /cgi program.
> >
> > I need to be able to have apache  execute the .cgi and .php files in
> > /src
> > Any ideas on how to make Apache differentiate between the two.
> >
> > Any help would be greatly appreciated.
> >
> >
> > Nick
> >

--
Nicholas Marouf || System Administrator/Security Response Team
http://www.ramallahonline.com




-- 
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] Hello $variable, whats your name?

2001-03-22 Thread Noah Spitzer-Williams

theres even $GLOBALS()

""Data Driven Design"" <[EMAIL PROTECTED]> wrote in message
001301c0b347$d96ca5c0$[EMAIL PROTECTED]">news:001301c0b347$d96ca5c0$[EMAIL PROTECTED]...
> You can cycle through the $HTTP_POST_VARS or $HTTP_GET_VARS arrays
depending
> on whether you use 'post' or 'get' for the methos in you form
>
> while(list($key,$val)=each($HTTP_POST_VARS)) {
> print "$key:$val\n";
> }
>
>
> - Original Message -
> From: JCampbell <[EMAIL PROTECTED]>
> To: Main PHP List <[EMAIL PROTECTED]>
> Sent: Tuesday, December 12, 2000 4:05 PM
> Subject: [PHP] Hello $variable, whats your name?
>
>
> > I would like to know if there is a way to determine the name of a
> variable.
> >
> > Example:
> > I have the variable $firstname, with a value of Jon
> >
> > I want to be able to
> >
> > echo name_of_variable : value_of_variable;
> >
> > So the user would see
> >
> > firstname : Jon
> >
> > I want to be able to do this without knowing what variables will be
passed
> > to the PHP script in advance.
> >
> > Any help is appreciated in advance.
> >
> > 
> > ===
> > And shepards we shall be
> > For thee, my lord, for thee
> > For thou hath descended forth from thy hands
> > That our feats may swiftly carry out thy command
> > We will flow a river forth unto thee
> > And teaming with souls shall it ever be...
> > ===
> > http://jcampbell.blacklightning.net
> >
> >
> > --
> > 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]
>



-- 
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] mail(): carriage return required??

2001-03-22 Thread Eelco de Vries

> > I read the mail fine in my hotmail.com account, but when I read
> that same
> > mail in my MS Outlook client the mail is one long line of text:
> > "this is line 1 this is line 2 this the 3rd etc etc"
> >
> > I understand from this difference in layout that the 'carriage
> return' is
> > required. Is there a function that adds a 'carriage return' after every
> > 'newline' found in a string? Or is this another problem?
>
> Use \r\n for email line breaks.
>


Should I write a function that replace any corrance of '\n' with '\r\n' in a
string myself?
Hard to believe that the PHP guys haven't encountered this before and didn't
write some PHP function to do this for us, not?

Cheers;
Eelco.


-- 
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] HELP? HTTP HEADER GURUS etc?

2001-03-22 Thread brunatex


Hello,

Not sure if this is exactly focused on PHP, but i thought some of you
guys might know.

The general problem:
I want to be able to send SMS messages from my computer using one of
the free SMS services.
I want to be able to do this without logging on each time - i.e.
from a program (eiither C or java or the like).

In essence, the problem is to get a program to 'Log In' to a site, and
keep the user 'Logged In' (by sending cookies with
each request i presume..)

So the 2 questions are:

1. how do i send a POST query (containing login details) to a page?
(if it were GET, i could just append to the URL, how do i do it with
POST?)

2. once i have sent this (correct) login, i will receive back a
cookie. I can store this, but need to know how to send it back with each
request? (in the header somehow i presume..?)

Thanks in advance,

Jonathan


-- 
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] A problem under Solaris

2001-03-22 Thread Dunaway, Brian


>   I´m trying to compile PHP 4.0 under Solaris 8.0 - SPARC 
> 250. When I try to configure using the appropiate script, it 
> test for the existence of one package called lex and another 
> called flex, both couldn´t be found and the script can´t 
> continue. Anybody has be in the same trouble? Any idea? What 
> are those packages?

Yes, Flex is a rewrite of lex.

http://www.gnu.org/manual/flex-2.5.4/html_mono/flex.html

is all you never wanted to know about flex.

Install FLEX.

you can probably find it at http://www.sunfreeware.com

--
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] Hello $variable, whats your name?

2001-03-22 Thread Data Driven Design

You can cycle through the $HTTP_POST_VARS or $HTTP_GET_VARS arrays depending
on whether you use 'post' or 'get' for the methos in you form

while(list($key,$val)=each($HTTP_POST_VARS)) {
print "$key:$val\n";
}


- Original Message -
From: JCampbell <[EMAIL PROTECTED]>
To: Main PHP List <[EMAIL PROTECTED]>
Sent: Tuesday, December 12, 2000 4:05 PM
Subject: [PHP] Hello $variable, whats your name?


> I would like to know if there is a way to determine the name of a
variable.
>
> Example:
> I have the variable $firstname, with a value of Jon
>
> I want to be able to
>
> echo name_of_variable : value_of_variable;
>
> So the user would see
>
> firstname : Jon
>
> I want to be able to do this without knowing what variables will be passed
> to the PHP script in advance.
>
> Any help is appreciated in advance.
>
> 
> ===
> And shepards we shall be
> For thee, my lord, for thee
> For thou hath descended forth from thy hands
> That our feats may swiftly carry out thy command
> We will flow a river forth unto thee
> And teaming with souls shall it ever be...
> ===
> http://jcampbell.blacklightning.net
>
>
> --
> 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] mail(): carriage return required??

2001-03-22 Thread CC Zona

In article <[EMAIL PROTECTED]>,
 [EMAIL PROTECTED] (Eelco de Vries) wrote:

> "this is line 1
> this is line 2
> this the 3rd
> etc
> etc"
> 
> I read the mail fine in my hotmail.com account, but when I read that same
> mail in my MS Outlook client the mail is one long line of text:
> "this is line 1 this is line 2 this the 3rd etc etc"
> 
> I understand from this difference in layout that the 'carriage return' is
> required. Is there a function that adds a 'carriage return' after every
> 'newline' found in a string? Or is this another problem?

Use \r\n for email line breaks.

-- 
CC

-- 
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] Help!

2001-03-22 Thread Keith Vance

Windows, ha ha ha.

K E I T H  V A N C E
Software Engineer
n-Link Corporation

On Thu, 22 Mar 2001, Fred wrote:

> i found the problem , could you believe one of my scripts caused php to
> crash,,, how frustrating, i sent al evening fiddling with the bloody
> software
> "Yasuo Ohgaki" <[EMAIL PROTECTED]> wrote in message
> 99bkir$es0$[EMAIL PROTECTED]">news:99bkir$es0$[EMAIL PROTECTED]...
> > I think this should go to BugDB.
> > http://bugs.php.net
> >
> > Try older versions if you in hurry.
> >
> > Regards,
> > --
> > Yasuo Ohgaki
> >
> >
> > ""Fred"" <[EMAIL PROTECTED]> wrote in message
> > 99be8l$m4u$[EMAIL PROTECTED]">news:99be8l$m4u$[EMAIL PROTECTED]...
> > > I got this error when i try to ran a script of mine:
> > > "PHP caused a stack fault in module MSVCRT.DLL at 0177:7800f75d.
> > > Registers:
> > > EAX=005421f4 CS=0177 EIP=7800f75d EFLGS=00010202
> > > EBX=00542254 SS=017f ESP=00541f94 EBP=005421dc
> > > ECX=00542244 DS=017f ESI=019dab14 FS=7f67
> > > EDX=006a ES=017f EDI=0029 GS=
> > > Bytes at CS:EIP:
> > > 53 56 57 8b 7d 0c 33 f6 8a 1f 47 84 db 89 75 f4
> > > Stack dump:
> > >        
> > >        
> "
> > >
> > > this is the details of the "illegal operation" box, for some reason when
> i
> > > try to run a script using the mysql databases the thing crashes, ive
> jsut
> > > installed MyODBC and im pretty sure that's what's causing hte problem,
> im on
> > > a win32, running the latest version of php,mysql,apache and myodbc,
> > >
> > > please reply asap
> > > ~Fred
> > >
> > >
> > >
> > > --
> > > 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]
> >
>
>
>
> --
> 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] Silly sessions problem.

2001-03-22 Thread Chris Lee

other way around, set the variable the register it

session_start();
$hello = 'chris lee';
session_register('hello');

here is my session file.




-- 

 Chris Lee
 [EMAIL PROTECTED]




""Lic. Rodolfo Gonzalez Gonzalez"" <[EMAIL PROTECTED]> wrote in message 
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
Hello list,

I just can't make sessions work. This is driving me mad, I'm sure it's
something silly, but maybe my headache made me a fool :P :) ... could you
please tell me what's wrong here?. hello.php has a link to next.php:

--- start of hello.php ---





$hello";
?>



--- end of hello.php ---

-- start of next.php











--- end of next.php ---

Now I click on the hyperlink and get a new cookie (produced by call to
session_start() in next.php). Using PHP4.0.4pl1 (with --enable-trans-id),
Apache, and the linux version of ns navigator as browser.

Thank you!,
Rodolfo.



-- 
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] Hello $variable, whats your name?

2001-03-22 Thread Jerry Lake

$HTTP_POST_VARS

Jerry Lake- [EMAIL PROTECTED]
Web Designer
Europa Communications - http://www.europa.com
Pacifier Online - http://www.pacifier.com


-Original Message-
From: JCampbell [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 12, 2000 4:06 PM
To: Main PHP List
Subject: [PHP] Hello $variable, whats your name?


I would like to know if there is a way to determine the name of a variable.

Example:
I have the variable $firstname, with a value of Jon

I want to be able to

echo name_of_variable : value_of_variable;

So the user would see

firstname : Jon

I want to be able to do this without knowing what variables will be passed
to the PHP script in advance.

Any help is appreciated in advance.


===
And shepards we shall be
For thee, my lord, for thee
For thou hath descended forth from thy hands
That our feats may swiftly carry out thy command
We will flow a river forth unto thee
And teaming with souls shall it ever be...
===
http://jcampbell.blacklightning.net


-- 
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] Hello $variable, whats your name?

2001-03-22 Thread Cal Evans

If it's in some kind of collections, you could iterate through the
collection.  ($HTTP_POST, $HTTP_GET, any associative array, etc.)

Cal
http://www.calevans.com


-Original Message-
From: JCampbell [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 12, 2000 6:06 PM
To: Main PHP List
Subject: [PHP] Hello $variable, whats your name?


I would like to know if there is a way to determine the name of a variable.

Example:
I have the variable $firstname, with a value of Jon

I want to be able to

echo name_of_variable : value_of_variable;

So the user would see

firstname : Jon

I want to be able to do this without knowing what variables will be passed
to the PHP script in advance.

Any help is appreciated in advance.


===
And shepards we shall be
For thee, my lord, for thee
For thou hath descended forth from thy hands
That our feats may swiftly carry out thy command
We will flow a river forth unto thee
And teaming with souls shall it ever be...
===
http://jcampbell.blacklightning.net


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




[PHP] Hello $variable, whats your name?

2001-03-22 Thread JCampbell

I would like to know if there is a way to determine the name of a variable.

Example:
I have the variable $firstname, with a value of Jon

I want to be able to

echo name_of_variable : value_of_variable;

So the user would see

firstname : Jon

I want to be able to do this without knowing what variables will be passed
to the PHP script in advance.

Any help is appreciated in advance.


===
And shepards we shall be
For thee, my lord, for thee
For thou hath descended forth from thy hands
That our feats may swiftly carry out thy command
We will flow a river forth unto thee
And teaming with souls shall it ever be...
===
http://jcampbell.blacklightning.net


-- 
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] Silly sessions problem.

2001-03-22 Thread Lic. Rodolfo Gonzalez Gonzalez

Hello list,

I just can't make sessions work. This is driving me mad, I'm sure it's
something silly, but maybe my headache made me a fool :P :) ... could you
please tell me what's wrong here?. hello.php has a link to next.php:

--- start of hello.php ---





$hello";
?>



--- end of hello.php ---

-- start of next.php











--- end of next.php ---

Now I click on the hyperlink and get a new cookie (produced by call to
session_start() in next.php). Using PHP4.0.4pl1 (with --enable-trans-id),
Apache, and the linux version of ns navigator as browser.

Thank you!,
Rodolfo.



-- 
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] Oracle + apache + php + linux Red Hat 6.2(update)

2001-03-22 Thread Robert Mena

Hi,

I've managed to install oracle and to compile and
install php (--with-oci8).  Unfortunately when I start
the server it gives me a httpd dead but subsys locked.

Searching the archives I found one link to PHP.net
manual (http://www.php.net/manual/en/ref.oci8.php)
where it tells me that I should compile apache with
pthreads support.

Well, I downloaded apache-1.3.14.src.rpm from redhat
(6.2 updates) and compiled it but no luck (the same
result).

My ldd /usr/sbin/httpd shows :
libpthread.so.0 => /lib/libpthread.so.0 (0x4001b000)
libm.so.6 => /lib/libm.so.6 (0x4002e000)
libcrypt.so.1 => /lib/libcrypt.so.1 (0x4004b000)
libdb.so.3 => /lib/libdb.so.3 (0x40078000)
libdl.so.2 => /lib/libdl.so.2 (0x400b2000)
libc.so.6 => /lib/libc.so.6 (0x400b7000)
/lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x4000)

I do not know if is this is related but the
/var/log/httpd/errorlog shows me
PHP Warning:  Function registration failed - duplicate
name - define in Unknown on line 0
PHP Warning:  Function registration failed - duplicate
name - defined in Unknown on line 0
PHP Warning:  Function registration failed - duplicate
name - each in Unknown on line 0
PHP Warning:  Function registration failed - duplicate
name - strlen in Unknown on line 0
PHP Warning:  Function registration failed - duplicate
name - strcmp in Unknown on line 0
PHP Warning:  Function registration failed - duplicate
name - strcasecmp in Unknown on line 0
PHP Warning:  Function registration failed - duplicate
name - error_reporting in Unknown on line 0
PHP Warning:  Function registration failed - duplicate
name - leak in Unknown on line 0
PHP Warning:  Function registration failed - duplicate
name - function_exists in Unknown on line 0
PHP Warning:  Basic Functions:  Unable to register
functions, unable to load in Unknown on line 0

Thanks.

__
Do You Yahoo!?
Get email at your own domain with Yahoo! Mail. 
http://personal.mail.yahoo.com/

-- 
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] Move data from one MySql table to another?

2001-03-22 Thread Cal Evans

Technically, that would be a COPY. The original data would still be there.
To do a MOVE he would need to issue a delete in old_table after confirming
that the insert into new_table succeeded.

HTH,
Cal
http://www.calevans.com


-Original Message-
From: James Atkinson [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 22, 2001 5:26 PM
To: YoBro
Cc: [EMAIL PROTECTED]
Subject: RE: [PHP] Move data from one MySql table to another?


OK say you old table is this
create table old_table (
id int auto_increment,
name varchar(100),
address varchar(200),
comments text);

and you new table is:

create table new_table (
id int auto_increment,
name varchar(200),
address varchar(200));

To populate new_table from old_table you can give it this SQL:

INSERT INTO new_table (name, address) VALUES SELECT name, address FROM
old_table;

Hope that helps

- James

> -Original Message-
> From: YoBro [mailto:[EMAIL PROTECTED]]
> Sent: March 22, 2001 3:20 PM
> To: [EMAIL PROTECTED]
> Subject: [PHP] Move data from one MySql table to another?
>
>
> Hello,
>
> Does anybody know where I could find out how to Move data from one Mysql
> table to another.
>
> I have a query showing all the results, and I am trying to put a
> link at the
> end of each row that says "move"
>
> Clicking this will move that records information to another table.
> IE From table orders to table ordered
>
> Make sense?
>
> Please help
>
> --
> Regards,
>
>
> YoBro
> -
> DO NOT REPLY TO THIS VIA EMAIL
> PLEASE USE THE NEWSGROUP
> All emails sent to this address are automatically deleted.
> This is to avoid SPAM!
> -
>
>
>
> --
> 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]



-- 
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] Move data from one MySql table to another?

2001-03-22 Thread YoBro

I need to know how to do it in PHP?


""Cal Evans"" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
: Probably on the MySQL list.  This is the PHP. (This is arguments,abuse is
: down the hall.)
:
: Try:
: http://www.mysql.com/documentation/lists.html
:
:
: Cal
: http://www.calevans.com
:
:
: -Original Message-
: From: YoBro [mailto:[EMAIL PROTECTED]]
: Sent: Thursday, March 22, 2001 5:20 PM
: To: [EMAIL PROTECTED]
: Subject: [PHP] Move data from one MySql table to another?
:
:
: Hello,
:
: Does anybody know where I could find out how to Move data from one Mysql
: table to another.
:
: I have a query showing all the results, and I am trying to put a link at
the
: end of each row that says "move"
:
: Clicking this will move that records information to another table.
: IE From table orders to table ordered
:
: Make sense?
:
: Please help
:
: --
: Regards,
:
:
: YoBro
: -
: DO NOT REPLY TO THIS VIA EMAIL
: PLEASE USE THE NEWSGROUP
: All emails sent to this address are automatically deleted.
: This is to avoid SPAM!
: -
:
:
:
: --
: 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]
:



-- 
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] Move data from one MySql table to another?

2001-03-22 Thread James Atkinson

OK say you old table is this
create table old_table (
id int auto_increment,
name varchar(100),
address varchar(200),
comments text);

and you new table is:

create table new_table (
id int auto_increment,
name varchar(200),
address varchar(200));

To populate new_table from old_table you can give it this SQL:

INSERT INTO new_table (name, address) VALUES SELECT name, address FROM
old_table;

Hope that helps

- James

> -Original Message-
> From: YoBro [mailto:[EMAIL PROTECTED]]
> Sent: March 22, 2001 3:20 PM
> To: [EMAIL PROTECTED]
> Subject: [PHP] Move data from one MySql table to another?
>
>
> Hello,
>
> Does anybody know where I could find out how to Move data from one Mysql
> table to another.
>
> I have a query showing all the results, and I am trying to put a
> link at the
> end of each row that says "move"
>
> Clicking this will move that records information to another table.
> IE From table orders to table ordered
>
> Make sense?
>
> Please help
>
> --
> Regards,
>
>
> YoBro
> -
> DO NOT REPLY TO THIS VIA EMAIL
> PLEASE USE THE NEWSGROUP
> All emails sent to this address are automatically deleted.
> This is to avoid SPAM!
> -
>
>
>
> --
> 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] Move data from one MySql table to another?

2001-03-22 Thread Cal Evans

Probably on the MySQL list.  This is the PHP. (This is arguments,abuse is
down the hall.)

Try:
http://www.mysql.com/documentation/lists.html


Cal
http://www.calevans.com


-Original Message-
From: YoBro [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 22, 2001 5:20 PM
To: [EMAIL PROTECTED]
Subject: [PHP] Move data from one MySql table to another?


Hello,

Does anybody know where I could find out how to Move data from one Mysql
table to another.

I have a query showing all the results, and I am trying to put a link at the
end of each row that says "move"

Clicking this will move that records information to another table.
IE From table orders to table ordered

Make sense?

Please help

--
Regards,


YoBro
-
DO NOT REPLY TO THIS VIA EMAIL
PLEASE USE THE NEWSGROUP
All emails sent to this address are automatically deleted.
This is to avoid SPAM!
-



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




[PHP] Move data from one MySql table to another?

2001-03-22 Thread YoBro

Hello,

Does anybody know where I could find out how to Move data from one Mysql
table to another.

I have a query showing all the results, and I am trying to put a link at the
end of each row that says "move"

Clicking this will move that records information to another table.
IE From table orders to table ordered

Make sense?

Please help

--
Regards,


YoBro
-
DO NOT REPLY TO THIS VIA EMAIL
PLEASE USE THE NEWSGROUP
All emails sent to this address are automatically deleted.
This is to avoid SPAM!
-



-- 
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/CGI Help

2001-03-22 Thread Peter Houchin


you also need to have 
ScriptAlias /src "/home/src/"
Action application/x-httpd-php4 "php excicution file location"
AddType application/x-httpd-php4 .php
> -Original Message-
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf
> Of Maroufski
> Sent: Thursday, March 22, 2001 5:41 PM
> To: [EMAIL PROTECTED]
> Subject: [PHP] PHP/CGI Help
> 
> 
> Hi all,
> This is a tough one, wasn't able to find a solution so far. But
> I hope that someone can help me out
> or point me in the right direction.
> 
> Here is what I got:
> 
> /src contains a bunch of cgi scripts that require apache to have an
> entry like this
> 
> ScriptAlias /src "/home/src/"
> 
> When I try to run a file with .php extension in /src I get an error.
> I figured out since I have ScriptAlias /src,  Apache will handle every
> file called in that directory as if it were a perl /cgi program.
> 
> I need to be able to have apache  execute the .cgi and .php files in
> /src
> Any ideas on how to make Apache differentiate between the two.
> 
> Any help would be greatly appreciated.
> 
> 
> Nick
> 
> --
> ~
> Nicholas Marouf || http://www.RamallahOnline.com
> 
> 
> 
> 
> -- 
> 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]



-- 
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 4.04pl 1-3 for red hat 7

2001-03-22 Thread ..s.c.o.t.t.. [gts]

check php.net and read the 'README' and
'INSTALL' files that come in the .tar.gz file
for more detailed information.

very basically, you want to get the sources,
untar/zip them, run configure, then build the
thing and test it (you can do all of this
as an unprivileged user).   then install as
root (or whatever account has the necessary
privileges)

(replace php. with whatever the PHP
tarball is named)

at the prompt (you dont need to be root) type:
tar xvfz php.tar.gz
cd php.
./configure --enable-trans-sid
make
make test


if you didnt get any errors, then (as root) type:
make install

then configure your webserver and
restart the webserver 

if you have any specific troubles, let me know,
i've config'd PHP on three different redhat
linux installations using apache and havent
had any problems yet.


> -Original Message-
> From: Larry Hotchkiss [mailto:[EMAIL PROTECTED]]
> Subject: [PHP] php 4.04pl 1-3 for red hat 7
> 
> 
>   Ok, I am working on a site where I would like to use sessions but NOT
> cookies. I would also like to have the sessions automatically appended
> to URL but I have a few questions. The current php rpm distribution was
> not compiled with --enable-trans-sid (according to phpinfo.php), am I
> correct in assuming I need to recompile? If that is the case, can
> someone recommend a good "how-to" to walk me through it. I have no
> experience with compiling at all.
> 
> -- 
> Larry H

-- 
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] Crypt problem

2001-03-22 Thread ..s.c.o.t.t.. [gts]

you dont... as far as i know,
crypt only works on <= 8 chars
it will truncate anything over 8.

perhaps try using md5 or mcrypt...




> -Original Message-
> From: Randy Johnson [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, March 22, 2001 4:33 PM
> To: [EMAIL PROTECTED]
> Subject: [PHP] Crypt problem
> 
> 
> hello
> 
> I use crypt to crypt member's passwords and use the following verify
> 
> 
> "$stored_password" is the encrypted, stored password.
> 
> "$password" is the plain text password you just got from the form.
> 
> ## Check the passwords
> $encrypted_password = crypt($password,$stored_password);
> 
> if ($encrypted_password = $stored_password) { $logged_in = 1; };
> 
> 
> the problem I am having is that it is only comparing the first 8 characters
> of the password
> 
> so if my password was randyrandy
> 
> i could get in with randyran
> 
> How do I fix this
> 
> the crypt password is stored in the database with enough room to store the
> password so it isn't cutting it off when inserting to the database.
> 
> thanks
> 
> randy
> 
> 
> -- 
> 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] PHP/CGI Help

2001-03-22 Thread ..s.c.o.t.t.. [gts]

do .php files work anywhere else?


> -Original Message-
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf
> Of Maroufski
> Sent: Thursday, March 22, 2001 5:41 PM
> To: [EMAIL PROTECTED]
> Subject: [PHP] PHP/CGI Help
> 
> 
> Hi all,
> This is a tough one, wasn't able to find a solution so far. But
> I hope that someone can help me out
> or point me in the right direction.
> 
> Here is what I got:
> 
> /src contains a bunch of cgi scripts that require apache to have an
> entry like this
> 
> ScriptAlias /src "/home/src/"
> 
> When I try to run a file with .php extension in /src I get an error.
> I figured out since I have ScriptAlias /src,  Apache will handle every
> file called in that directory as if it were a perl /cgi program.
> 
> I need to be able to have apache  execute the .cgi and .php files in
> /src
> Any ideas on how to make Apache differentiate between the two.
> 
> Any help would be greatly appreciated.
> 
> 
> Nick
> 
> --
> ~
> Nicholas Marouf || http://www.RamallahOnline.com
> 
> 
> 
> 
> -- 
> 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] Printing MySQL into HTML Tables

2001-03-22 Thread ..s.c.o.t.t.. [gts]

modulus also works for finding even nums:

if ($i % 2) { 
  // not even
}


> -Original Message-
> From: darion mapp [mailto:[EMAIL PROTECTED]]
> Subject: Re: [PHP] Printing MySQL into HTML Tables
> 
> 
> now it seems like you know what is to be done and you are not willing to 
> do the work. Now i have not tested this and you may have to do some work 
> with it but you get the picture. if you lookup the syntax and ensure how 
> to use the command then you will be ok.
> of course if you still have problems then let em know
> 
> 
> FOR($i = 0;$i < $numrows; ++$i)
> {
> echo"$mysql_result($resultidentiferfromquery, $i, 
> fieldwithproduct)$mysql_result($resultidentiferfromquery, ++$i, 
> fieldwithproduct)";
> echo"$mysql_result($resultidentiferfromquery, ++$i, 
> fieldwithproduct) ";
> if($i/2 > 0) //not even
> {
> echo" > ";
> }
> }


-- 
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] Encryption Problem

2001-03-22 Thread ..s.c.o.t.t.. [gts]

quite possibly you did not compile PHP with mcrypt
library support.

for linux distrib's, mcrypt is not default, you have
to specify ./configure --with-mcrypt to get mcrypt
functionality (i dont know whether it's included
by default with the win binary, but i doubt it)

do the phpinfo() thing and see if mcrypt is there.


> -Original Message-
> From: darion mapp [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, March 22, 2001 5:19 PM
> To: [EMAIL PROTECTED]
> Subject: [PHP] Encryption Problem
> 
> 
> ok, so i have want to encrypt my user password in the mySQL Database and 
> well that is not working but in addition to that when the user logges into 
> the system i have to encrypt their password and compare the two encrypted 
> passwords to see if they match. this is where my problem starts. I get the 
> same error for both the registration process where the password is 
> encrypted to be placed into the database and when the use logs in and the 
> password is encrypted to be compared.
> 
> The web browser errors to "Page cannot bbe displayed (IE)" and only when 
> the line below is commented out does it work fine.
> 
> HELP Project was due last week so i am pressed for time
> 
> $txtPass = mcrypt_ecb(MCRYPT_BLOWFISH, $key, $txtPass, MCRYPT_ENCRYPT);
> 
> 
> Get 250 color business cards for FREE! at Lycos Mail
> http://mail.lycos.com/freemail/vistaprint_index.html
> 
> -- 
> 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]




[PHP] PHP/CGI Help

2001-03-22 Thread Maroufski

Hi all,
This is a tough one, wasn't able to find a solution so far. But
I hope that someone can help me out
or point me in the right direction.

Here is what I got:

/src contains a bunch of cgi scripts that require apache to have an
entry like this

ScriptAlias /src "/home/src/"

When I try to run a file with .php extension in /src I get an error.
I figured out since I have ScriptAlias /src,  Apache will handle every
file called in that directory as if it were a perl /cgi program.

I need to be able to have apache  execute the .cgi and .php files in
/src
Any ideas on how to make Apache differentiate between the two.

Any help would be greatly appreciated.


Nick

--
~
Nicholas Marouf || http://www.RamallahOnline.com




-- 
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] Printing MySQL into HTML Tables

2001-03-22 Thread darion mapp

now it seems like you know what is to be done and you are not willing to do the work. 
Now i have not tested this and you may have to do some work with it but you get the 
picture. if you lookup the syntax and ensure how to use the command then you will be 
ok.
of course if you still have problems then let em know


FOR($i = 0;$i < $numrows; ++$i)
{
echo"$mysql_result($resultidentiferfromquery, $i, 
fieldwithproduct)$mysql_result($resultidentiferfromquery, ++$i, 
fieldwithproduct)";
echo"$mysql_result($resultidentiferfromquery, ++$i, 
fieldwithproduct) ";
if($i/2 > 0) //not even
{
echo" > ";
}
}

 
--

On Thu, 22 Mar 2001 15:19:09  
 Jeff Oien wrote:
>I would like to do this with a MySQL database containing
>product information:
>
>Product 1 InfoProduct 2 Info
>Product 3 Info 
>
>And if there are an odd number of products I want it to 
>complete the table row with nothing in the cell. I want
>it to be able to automatically do this no matter how many
>products there are. I'm not sure how to set it up to 
>print every other like that.
>Jeff Oien
>
>-- 
>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]
>
>


Get 250 color business cards for FREE! at Lycos Mail
http://mail.lycos.com/freemail/vistaprint_index.html

-- 
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] ODBC & Oracle

2001-03-22 Thread Joe Brown

There is a timeout, that should halt a script if it runs too long.  If you
can, check
php.ini
set max_execution_time to something greater than 30 seconds, see if that
helps.

""Brooks, Ken"" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> I thought maybe the php script was running to fast for the network
> connection.
> So i put in a sleep(1)
> It still only ran for about the same amount of time (less records pulled
of
> course).
>
> Could it be losing the connection instead because of lack of activity?
>
> Would a persistent connection make any difference?
>
> -Original Message-
> From: Brooks, Ken [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, March 22, 2001 4:04 PM
> To: [EMAIL PROTECTED]
> Subject: [PHP] ODBC & Oracle
>
>
> Are there any limitations on how many records I can pull from an Oracle
> Database
> over ODBC?
>
> I have it pulling one record just fine, but when I tell it to pull all
> records,
> which should be about 75,000, it only gets about 600 or so.
>
> Does the php script time out (i'm running it thru a web browser).
>
> What could it be?...
>
> thanks,
> ken
>
> --
> 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]
>



-- 
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-CVS] cvs: php4 /sapi/fastcgi fastcgi.c

2001-03-22 Thread Derick Rethans

On Thu, 22 Mar 2001, Ben Mansell wrote:

> joosters  Thu Mar 22 10:48:51 2001 EDT
>
>   Modified files:
> /php4/sapi/fastcgifastcgi.c
>   Log:
>   Fix a bug with POST requests. If the Content-Type header wasn't present,
>   we were setting SG(request_info).content_type to NULL, instead of
>   an empty string. This was stopping PHP from processing the data.

I think it should be nice if this fix (and the CGI SAPI fix too) would be
added to the PHP_4_0_5 branch too.

Goodnight,

Derick Rethans

-
PHP: Scripting the Web - www.php.net - [EMAIL PROTECTED]
 SRM: Site Resource Manager - www.vl-srm.net
-
JDI Media Solutions - www.jdimedia.nl - [EMAIL PROTECTED]
 Boulevard Heuvelink 102 - 6828 KT Arnhem - The Netherlands
-


-- 
PHP CVS 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] Encryption Problem

2001-03-22 Thread darion mapp

ok, so i have want to encrypt my user password in the mySQL Database and well that is 
not working but in addition to that when the user logges into the system i have to 
encrypt their password and compare the two encrypted passwords to see if they match. 
this is where my problem starts. I get the same error for both the registration 
process where the password is encrypted to be placed into the database and when the 
use logs in and the password is encrypted to be compared.

The web browser errors to "Page cannot bbe displayed (IE)" and only when the line 
below is commented out does it work fine.

HELP Project was due last week so i am pressed for time

$txtPass = mcrypt_ecb(MCRYPT_BLOWFISH, $key, $txtPass, MCRYPT_ENCRYPT);


Get 250 color business cards for FREE! at Lycos Mail
http://mail.lycos.com/freemail/vistaprint_index.html

-- 
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] I need an authentication method that is good... any Ideas? - please help

2001-03-22 Thread ..s.c.o.t.t.. [gts]

the way i do it for sites that need minimal to medium
is to generate a session id whenever a user comes to
the site.  this session id is stored in mysql table
and as a cookie on the user's computer.  when the
user logs in correctly, the username is stored in
the database with the session ID (not as a cookie, 
only the session ID is saved as a cookie).

i try and make it my goal to never store any usernames
or passwords on the user's computer.  the existence
of the session ID is enough to allow me to look up
that ID in the database and see if the user logged
in correctly in the past few hours (expire time is ~6
hours, so after 6 hours of inactivity, the id is
cleansed from the database)

at the top of ever PHP page that requires a 
valid login, i check to see if the user has
a session ID stored as a cookie, then look up
that ID in the database to check if it's valid.
if the ID is valid, i check to see if a username
is also stored in the database.  if there's a
valid username stored alongside the session ID,
then the user is recognized as being logged in.
if no username is in the database, then i ask the
user to log in.

the session table has these fields:
id (the generated session id)
lastused (last time the user accessed a page)
username (the username that the user logged in as)

(password information is stored in another table)


so... basically, if the user logs in correctly,
it will generate a random session id and store
the username in the database.  *only* the session
id will be stored on the client.

when the user comes back to the website, if the
id in their cookie matches an id in the database
*and* the username field has a valid username,
the user is not asked to log in again.  if the
session id is not found in the database (or is
expired) the user is directed to a login page.


any comments or thoughts on my method are welcome;
especially any weaknesses that you may find in my system.

thanks


> -Original Message-
> From: Romulo Roberto Pereira [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, March 22, 2001 4:30 PM
> To: [EMAIL PROTECTED]
> Subject: [PHP] I need an authentication method that is good... any
> Ideas? - please help
> 
> 
> Hello!
> 
> I am constructing an intranet site. The site is all secure, I mean, all the
> pages are under a directory that needs a password to get in. These are
> facts:
> 
> A) The user information is on a LDAP;
> B) The user should entry the pair login/password only once;
> C) Any access to the site without logging first will be routated to a login
> page;
> 
> So what would be a good solution on that?
> 
> If this work, I would like to create a documentation about it. All help will
> be welcome.
> 
> Thank you in advance and for your attention,
> 
> Romulo
> 
> 
> -- 
> 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]




[PHP] Fopen help

2001-03-22 Thread Kenneth R Zink II

I'm trying to use Fopen to check and see if a URL exist with this bit of code.  
$url=$row[url];
echo "Old URL = ".$url."";
$urlcheck = fopen($url,"r");
echo "urlcheck = ".$urlcheck."";
switch ($url){
case "":
case "http://":
echo "No URL Set";
break;
default:
switch ($urlcheck){
case 1:
echo "Valid URL";
break;
case 0: 
echo "URL Is Not Valid";
$url="http://";
break;
default:
echo "Fopen Did Not Work";
}
break;
}
echo "New URL = ".$url."";


So far all I can get it to do is the default response.  Can someone point out what I'm 
doing wrong or tell me how to see what the contents of a resource id is please?

Old URL = http://www.s-series.org/htm/firestorm/firestorm.htm
urlcheck = Resource id #4
Fopen Did Not Work
New URL = http://www.s-series.org/htm/firestorm/firestorm.htm



Kenneth R Zink II [EMAIL PROTECTED]ICQ# 5095094
'87 2.8L TBI GMC S-15 Ext. Cab (Hurricane) ...524 in the works !!!  
http://www.s-series.org/htm/windstorm/project-windstorm.htm
'85 3.4L Carbed Chevy S-10 Blazer (FireStorm) ...Soon to be 3.4L SFI DIS !!!  
http://www.s-series.org/htm/firestorm/firestorm.htm
'84 5.0L (307 "Y") Carbed Oldsmobile Delta 88 Royal Brougham.  Daily driver until 
FireStorm is ready.
Racing by the Grace of God!!



RE: [PHP] ODBC & Oracle

2001-03-22 Thread Brooks, Ken

Okay, I'm baffled.

I told it to Connect to the database.
I then started a loop of (odbc_fetch_row)
I get about 6000 records returned (that i'm just plopping into an array for
speed).

That's all, much more than when i process each one, but I would think it is
more than possible
to grab more than 6000 records from a database.

right?

thanks,
ken

-Original Message-
From: Brooks, Ken [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 22, 2001 4:21 PM
To: [EMAIL PROTECTED]
Subject: RE: [PHP] ODBC & Oracle


I thought maybe the php script was running to fast for the network
connection.
So i put in a sleep(1)
It still only ran for about the same amount of time (less records pulled of
course).

Could it be losing the connection instead because of lack of activity?

Would a persistent connection make any difference?

-Original Message-
From: Brooks, Ken [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 22, 2001 4:04 PM
To: [EMAIL PROTECTED]
Subject: [PHP] ODBC & Oracle


Are there any limitations on how many records I can pull from an Oracle
Database
over ODBC?

I have it pulling one record just fine, but when I tell it to pull all
records,
which should be about 75,000, it only gets about 600 or so.

Does the php script time out (i'm running it thru a web browser).

What could it be?...

thanks,
ken

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

-- 
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] I need an authentication method that is good... any Ideas? - please help

2001-03-22 Thread Romulo Roberto Pereira

Hello!

I am constructing an intranet site. The site is all secure, I mean, all the
pages are under a directory that needs a password to get in. These are
facts:

A) The user information is on a LDAP;
B) The user should entry the pair login/password only once;
C) Any access to the site without logging first will be routated to a login
page;

So what would be a good solution on that?

If this work, I would like to create a documentation about it. All help will
be welcome.

Thank you in advance and for your attention,

Romulo


-- 
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] Environment Variables

2001-03-22 Thread Joe Rice

i figured it out...thanks.
putenv()

Joe Rice([EMAIL PROTECTED])@Thu, Mar 22, 2001 at 03:16:35PM -0600:
> 
> 
> how do you sent a Environment Variables for the php script
> to execute in?  i need to set INFORMIXSERVER so i can
> use the informix php functions.  This is going live tomorrow
> and we don't have it working yet...PLEASE HELP!
> 
> thanks,
> joe rice
> Web Admin
> www.bigidea.com
> 
> 
> 
> -- 
> 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]




[PHP] Crypt problem

2001-03-22 Thread Randy Johnson

hello

I use crypt to crypt member's passwords and use the following verify


"$stored_password" is the encrypted, stored password.

"$password" is the plain text password you just got from the form.

## Check the passwords
$encrypted_password = crypt($password,$stored_password);

if ($encrypted_password = $stored_password) { $logged_in = 1; };


the problem I am having is that it is only comparing the first 8 characters
of the password

so if my password was randyrandy

i could get in with randyran

How do I fix this

the crypt password is stored in the database with enough room to store the
password so it isn't cutting it off when inserting to the database.

thanks

randy


-- 
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] php 4.04pl 1-3 for red hat 7

2001-03-22 Thread Larry Hotchkiss

Ok, I am working on a site where I would like to use sessions but NOT
cookies. I would also like to have the sessions automatically appended
to URL but I have a few questions. The current php rpm distribution was
not compiled with --enable-trans-sid (according to phpinfo.php), am I
correct in assuming I need to recompile? If that is the case, can
someone recommend a good "how-to" to walk me through it. I have no
experience with compiling at all.

-- 
Larry H

-- 
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] ODBC & Oracle

2001-03-22 Thread Brooks, Ken

I thought maybe the php script was running to fast for the network
connection.
So i put in a sleep(1)
It still only ran for about the same amount of time (less records pulled of
course).

Could it be losing the connection instead because of lack of activity?

Would a persistent connection make any difference?

-Original Message-
From: Brooks, Ken [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 22, 2001 4:04 PM
To: [EMAIL PROTECTED]
Subject: [PHP] ODBC & Oracle


Are there any limitations on how many records I can pull from an Oracle
Database
over ODBC?

I have it pulling one record just fine, but when I tell it to pull all
records,
which should be about 75,000, it only gets about 600 or so.

Does the php script time out (i'm running it thru a web browser).

What could it be?...

thanks,
ken

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




[PHP-CVS] cvs: php4 /ext/fbsql php_fbsql.c

2001-03-22 Thread Frank M. Kromann

fmk Thu Mar 22 13:16:23 2001 EDT

  Modified files:  
/php4/ext/fbsql php_fbsql.c 
  Log:
  Adding warning when query fails
  
Index: php4/ext/fbsql/php_fbsql.c
diff -u php4/ext/fbsql/php_fbsql.c:1.5 php4/ext/fbsql/php_fbsql.c:1.6
--- php4/ext/fbsql/php_fbsql.c:1.5  Wed Mar 21 13:53:45 2001
+++ php4/ext/fbsql/php_fbsql.c  Thu Mar 22 13:16:23 2001
@@ -16,7 +16,7 @@
+--+
  */
 
-/* $Id: php_fbsql.c,v 1.5 2001/03/21 21:53:45 fmk Exp $ */
+/* $Id: php_fbsql.c,v 1.6 2001/03/22 21:16:23 fmk Exp $ */
 
 /* TODO:
  *
@@ -788,7 +788,6 @@
fbcdcClose(c);
fbcdcRelease(c);
free(result);
-/* printf("Returning Null\n"); */
return NULL;
}
result->retainCount  = 2;
@@ -813,7 +812,6 @@
link->databases[i] = result;
 
FB_SQL_G(databaseCount)++;
-/* printf("Return database %x %x\n",result,c); */
}
link->currentDatabase = result;
return_value->value.lval  = result->index;
@@ -1514,6 +1512,26 @@
FBSQLLS_FETCH();
 
meta = fbcdcExecuteDirectSQL(database->connection,sql);
+
+   if (fbcmdErrorCount(meta) > 0) {
+   FBCErrorMetaData *errorMeta;
+   char *errorMessage;
+   unsigned error_type = 0;
+
+   errorMeta = fbcdcErrorMetaData(database->connection, meta);
+   error_type = fbcemdErrorCodeAtIndex(errorMeta, 0);
+   errorMessage = fbcemdAllErrorMessages(errorMeta);
+   if (error_type != 250) {
+   php_error(E_WARNING, "Error executing SQL-statement (%s)", 
+sql);
+   }
+// free(errorMessage);
+   fbcemdRelease(errorMeta);
+
+   if (error_type != 250) {
+   fbcmdRelease(meta);
+   return NULL;
+   }
+   }
 
if (fbcmdHasMetaDataArray(meta)) {
sR = fbcmdMetaDataArrayCount(meta);



-- 
PHP CVS 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] Printing MySQL into HTML Tables

2001-03-22 Thread Jeff Oien

I would like to do this with a MySQL database containing
product information:

Product 1 InfoProduct 2 Info
Product 3 Info 

And if there are an odd number of products I want it to 
complete the table row with nothing in the cell. I want
it to be able to automatically do this no matter how many
products there are. I'm not sure how to set it up to 
print every other like that.
Jeff Oien

-- 
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] Environment Variables

2001-03-22 Thread Joe Rice



how do you sent a Environment Variables for the php script
to execute in?  i need to set INFORMIXSERVER so i can
use the informix php functions.  This is going live tomorrow
and we don't have it working yet...PLEASE HELP!

thanks,
joe rice
Web Admin
www.bigidea.com



-- 
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] libclntsh.so.8.0 : oracle+php under linux rh 6.2

2001-03-22 Thread Robert Mena

Hi, I've succesfully installed a oracle 8.1.7 (chose
server option) under a development redhat 6.2 box.

I've compiled php as DSO with a
--with-oci8=path/to/ORACLE_HOME and it compiled ok. 
If I try to start httpd I keep getting

Cannot load /etc/httpd/modules/libphp4.so into server:
libclntsh.so.8.0: cannot open shared object file: No
such file or directory
  
  

I've tried to find it with no luck.  Any tips ?

Thanks.

__
Do You Yahoo!?
Get email at your own domain with Yahoo! Mail. 
http://personal.mail.yahoo.com/

-- 
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] sessions.. again...

2001-03-22 Thread Chris Lee

attachments ar stripped for security purposes by the mailing list server. please post 
the code in your msg.


-- 

 Chris Lee
 [EMAIL PROTECTED]


""Miguel Loureiro"" <[EMAIL PROTECTED]> wrote in message 
00ad01c0b2ff$f12a9c00$[EMAIL PROTECTED]">news:00ad01c0b2ff$f12a9c00$[EMAIL PROTECTED]...
Hello all,
I'm mad with mesorry but see if can understand why I'm mad.
Copy the 3 attached files, and run it.
In one.php just click to the link (it works.), now in two.php you can see: " and 
now: aaa", cool hum...
Clicking in OFF link you can see the result of phpinfo, but section of Apache 
Evironment, in HTTP_COOKIE you (at least I have) the PHPSESSID with value, in spite of 
in off.php code I make a session_destroy
Now if you use history back button, go to two.php, and OK the session variable dont 
appear, Back again, Forward and voila' here is 
a.
I have try to follow some Jeff Armstrong tips, but I have no success.Thank you very 
much Jeff (really...I'm no jocking...).
Any ideas ?? 
T.Y all

Best Regards
Miguel Loureiro <[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]



[PHP] ODBC & Oracle

2001-03-22 Thread Brooks, Ken

Are there any limitations on how many records I can pull from an Oracle
Database
over ODBC?

I have it pulling one record just fine, but when I tell it to pull all
records,
which should be about 75,000, it only gets about 600 or so.

Does the php script time out (i'm running it thru a web browser).

What could it be?...

thanks,
ken

-- 
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] need help with cookies

2001-03-22 Thread Chris Lee

as allready stated you need to set the cookie before data is outpued, you can override 
this by editing your php.ini 

output_buffering = on;

on another note, I would use sessions for all this, youve created a tone of code that 
does almost exactly what sessions can do in a matter of a few lines.

-- 

 Chris Lee
 [EMAIL PROTECTED]


<[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
Hi, I am trying to set a cookie and it doesn't work.  I am running IE 5.
I have IE set to prompt before setting cookies but I never get a prompt.

Here is my code - basically, if someone logs in, it is to set a cookie.
What am I missing?   Kris

if($success==1){
$loginid="$id";
NewSessionID($id);
GetProfile($id);
$page_title="LTT: $loginid Index";
include("html-head.php3");
if($id==""){
include("ln/ln_ln_dna.php3");
exit;
}
include("ms/rg1/index.php3");
exit;
}

function NewSessionID($id){
$sid="";
$length=16;
srand((double)microtime()*100);
$SessPool = "ABCDEFGHIJKLMNOPQRSTUVWXYZ";
$SessPool .= "abcdefghijklmnopqrstuvwxyz";
$SessPool .= "0123456789";

for($tempslime=0; $tempslime < $length; $tempslime++) {
$sid .= substr($SessPool, (rand()%(strlen($SessPool))), 1);
}
setcookie("LoginAuth", $sid,time()+3600);
}

-- 
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] mysql backup

2001-03-22 Thread Henrik Hansen

"McShen" <[EMAIL PROTECTED]> wrote:

 > hi
 > 
 > how do i back up a mysql DB table? Can you please write me the code?

i would just stop the database server and dump the table to a file
with mysqldump, just run it from the command line for example:

/path/to/mysqldump -h host -p password -u username databasename >
/path/to/file

then you have a comple dump of your database and database structure.

-- 
Henrik Hansen


-- 
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] Register session in function without global?

2001-03-22 Thread Tobias Talltorp

Well... Whadda ya know. Right after I sent the post I figured it out.
(Solution? Variable variables!)

function register_vars($reg_var) {

// Make the $reg_var global
$global_vars=explode("|", $reg_var);
for ($i=0; $i wrote in message
99dn35$duo$[EMAIL PROTECTED]">news:99dn35$duo$[EMAIL PROTECTED]...
> I am trying to register a session variable in a function without using the
> global in the beginning.
> The reason for this is that I don´t always know how many variables I am
> going to register (I separate the different fields with | like this,
> "username|email|cellphone" and explode them).
>
> Is there some way I can make all the variables in the function global, so
I
> can get the session variables registered?
>
> function test() {
> global $username // <-- With this, it works. Without it, it doesn´t
> session_start();
> $username="tobias";
> session_register("username");
> }
>
> The best I could come up with was (didn´t work):
> global $HTTP_SESSION_VARS;
>
> Any thoughts?
> // Tobias
>
>
>
>
>
> --
> 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] Register session in function without global?

2001-03-22 Thread Chris Lee

so your trying to take a list of variables and register them as session vars?

 $val)
  {
   global $val;
   session_register($val);
  }
 }

?>

this will work for that.


-- 

 Chris Lee
 [EMAIL PROTECTED]



""Tobias Talltorp"" <[EMAIL PROTECTED]> wrote in message 
99dn35$duo$[EMAIL PROTECTED]">news:99dn35$duo$[EMAIL PROTECTED]...
I am trying to register a session variable in a function without using the
global in the beginning.
The reason for this is that I don´t always know how many variables I am
going to register (I separate the different fields with | like this,
"username|email|cellphone" and explode them).

Is there some way I can make all the variables in the function global, so I
can get the session variables registered?

function test() {
global $username // <-- With this, it works. Without it, it doesn´t
session_start();
$username="tobias";
session_register("username");
}

The best I could come up with was (didn´t work):
global $HTTP_SESSION_VARS;

Any thoughts?
// Tobias





-- 
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] Register session in function without global?

2001-03-22 Thread CC Zona

In article <99dn35$duo$[EMAIL PROTECTED]>,
 [EMAIL PROTECTED] ("Tobias Talltorp") wrote:

> I am trying to register a session variable in a function without using the
> global in the beginning.

You can pass the variable(s) to the function as an argument.  Perhaps it 
will be easier to deal with a variable number variables  by  packing all 
of them into a single array, then passing the array.

-- 
CC

-- 
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-CVS] cvs: php4 /ext/dbx dbx.c dbx_mysql.c dbx_mysql.hdbx_odbc.c dbx_odbc.h php_dbx.h

2001-03-22 Thread Sterling Hughes

On Thu, 22 Mar 2001, Marc Boeren wrote:

> mboeren   Thu Mar 22 07:14:35 2001 EDT
> 
>   Modified files:  
> /php4/ext/dbx dbx.c dbx_mysql.c dbx_odbc.c dbx_mysql.h dbx_odbc.h 
>   php_dbx.h 
>   Log:
>   Changed C++ style comments to C-style comments (Marc)
>   #I hope I got 'em all
>   @Changed C++ style comments to C-style comments (Marc)
>   

This shouldn't be a news entry.

NEWS entries are only for things that are relevant to end users, such as
the addition of a new function, or a changed behaviour, or the fixing of
an important bug/crash.

-Sterling   


-- 
PHP CVS 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] Register session in function without global?

2001-03-22 Thread Tobias Talltorp

I am trying to register a session variable in a function without using the
global in the beginning.
The reason for this is that I don´t always know how many variables I am
going to register (I separate the different fields with | like this,
"username|email|cellphone" and explode them).

Is there some way I can make all the variables in the function global, so I
can get the session variables registered?

function test() {
global $username // <-- With this, it works. Without it, it doesn´t
session_start();
$username="tobias";
session_register("username");
}

The best I could come up with was (didn´t work):
global $HTTP_SESSION_VARS;

Any thoughts?
// Tobias





-- 
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] Array confusion.

2001-03-22 Thread Sterling

H-

Thanks to all that wrote in with input on this issue. 

I really appreciate the assistance. 

Thanks to CC Zona and James for the code sample. It looks like there
were typo's in my code and it threw me for a minute after
recieving/applying all the emails. 
That backslash wasn't suppose to be in the original email I sent out, it
was just from my Emacs window wrapping and the = next to Dec became a
problem after I quoted everything else but I found it eventually.

Thanks again. It's now working as I expected it too. 
-Sterling


CC Zona wrote:
> 
> In article <[EMAIL PROTECTED]>,
>  [EMAIL PROTECTED] (Sterling) wrote:
> 
> >  $m = "03";
> >  $list = array(01=>"Jan", 02=>"Feb", 03=>"Mar", 04=>"Apr", 05=>"May",
> > 06=>"Jun", 07=>"Jul", 08=>"Aug", 09=>"Sep\", 10=>"Oct", 11=>"Nov",
> > 12="Dec");
> >  $month = $list[$m];
> >  print "$month\n";
> >
> > What I want to print is the month in Text format, which in this instance
> > should be Mar .
> > I even tried: $month = array_keys($list, $m);
> >
> > Now I know that $list[x]; references the location of an item so I know
> > why the previous code doesn't work in that respect, since nowhere is 01
> > a location but an association within the array. Right?
> 
> The keys to an associative array should be quoted.  Also, that escaped
> quote on "Sep\" is throwing everything off.  Try:
> 
>  $m = "03";
>  $list = array("01"=>"Jan", "02"=>"Feb", "03"=>"Mar", "04"=>"Apr",
> "05"=>"May", "06"=>"Jun", "07"=>"Jul", "08"=>"Aug", "09"=>"Sep",
> "10"=>"Oct", "11"=>"Nov","12"="Dec");//keys quoted, no escaped quotes
>  $month = $list["$m"];//associative array element index quoted
>  print "$month\n";
> 
> --
> CC
> 
> --
> 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]




[PHP-CVS] cvs: CVSROOT / cvsusers

2001-03-22 Thread Stig Bakken

ssb Thu Mar 22 12:12:02 2001 EDT

  Modified files:  
/CVSROOTcvsusers 
  Log:
  * added Thomas V.V.Cox here too
  
  
Index: CVSROOT/cvsusers
diff -u CVSROOT/cvsusers:1.242 CVSROOT/cvsusers:1.243
--- CVSROOT/cvsusers:1.242  Thu Mar 22 11:18:24 2001
+++ CVSROOT/cvsusersThu Mar 22 12:12:02 2001
@@ -285,3 +285,4 @@
 ohrn  Fredrik Öhrn[EMAIL PROTECTED]YP and 
ClibPDF
 mboeren   Marc Boeren [EMAIL PROTECTED]"dbx" 
db.abstraction extension
 romoloRomolo Manfredini   [EMAIL PROTECTED]Bug 
fixes
+cox   Thomas V.V.Cox  [EMAIL PROTECTED] PEAR DB 
+Informix extension



-- 
PHP CVS 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-CVS] cvs: CVSROOT / avail gen_acl_file.m4

2001-03-22 Thread Stig Bakken

ssb Thu Mar 22 12:10:57 2001 EDT

  Modified files:  
/CVSROOTavail gen_acl_file.m4 
  Log:
  added Thomas V.V.Cox (pear)
  
  
Index: CVSROOT/avail
diff -u CVSROOT/avail:1.125 CVSROOT/avail:1.126
--- CVSROOT/avail:1.125 Thu Mar 22 11:18:23 2001
+++ CVSROOT/avail   Thu Mar 22 12:10:57 2001
@@ -2,7 +2,7 @@
 unavail
 avail|andi,andrei,jimw,rasmus,rubys,sas,ssb,thies,zeev,shane|CVSROOT
 
avail|andi,andrei,jimw,rasmus,rubys,sas,ssb,thies,zeev,shane,cmv,tcobb,gareth,jah,eschmid,ronabop,derick,sterling,stas,phildriscoll,jmoore,andre,sniper,david,lyric,zimt,mk,goba,zak,jmcastagnetto,dams|phpweb
-avail|andi,andrei,jimw,rasmus,rubys,sas,ssb,thies,zeev,shane,fmk,hirokawa,jah,eschmid,dbeu,sbergmann,samjam,avsm,ronabob,derick,sterling,venaas,stas,hholzgra,cmv,phildriscoll,jmoore,andre,sniper,changelog,sr,david,jdonagher,chagenbu,jon,elixer,joosters,jason,mysql,kalowsky,opaquedave,steinm,phanto,gluke,shuric,svanegmond,rjs,vlad,jimjag,emile,wez,sasha,camber,ohrn,romolo,jon,rael,jlp,sbergmann,troels,urs,jpm,adaniel,tuupola,mj,ssb,metallic,heyesr,aj,andre,zimt,uw,jeichorn,bjoern,chregu,bkelly,tfromm,subjective|php4/pear,pearweb,pear
+avail|andi,andrei,jimw,rasmus,rubys,sas,ssb,thies,zeev,shane,fmk,hirokawa,jah,eschmid,dbeu,sbergmann,samjam,avsm,ronabob,derick,sterling,venaas,stas,hholzgra,cmv,phildriscoll,jmoore,andre,sniper,changelog,sr,david,jdonagher,chagenbu,jon,elixer,joosters,jason,mysql,kalowsky,opaquedave,steinm,phanto,gluke,shuric,svanegmond,rjs,vlad,jimjag,emile,wez,sasha,camber,ohrn,romolo,jon,rael,jlp,sbergmann,troels,urs,jpm,adaniel,tuupola,mj,ssb,metallic,heyesr,aj,andre,zimt,uw,jeichorn,bjoern,chregu,bkelly,tfromm,subjective,cox,mboeren|php4/pear,pearweb,pear
 
avail|andi,andrei,jimw,rasmus,rubys,sas,ssb,thies,zeev,shane,fmk,hirokawa,jah,eschmid,dbeu,sbergmann,samjam,avsm,ronabob,derick,sterling,venaas,stas,hholzgra,cmv,phildriscoll,jmoore,andre,sniper,changelog,sr,david,jdonagher,chagenbu,jon,elixer,joosters,jason,mysql,kalowsky,opaquedave,steinm,phanto,gluke,shuric,svanegmond,rjs,vlad,jimjag,emile,wez,sasha,camber,ohrn,romolo|php4,php3,php31,phpfi
 
avail|andi,andrei,jimw,rasmus,rubys,sas,ssb,thies,zeev,shane,fmk,hirokawa,jah,eschmid,dbeu,sbergmann,samjam,avsm,ronabob,derick,sterling,venaas,stas,hholzgra,cmv,phildriscoll,jmoore,andre,sniper,changelog,sr,david,jdonagher,chagenbu,jon,elixer,joosters,jason,mysql,kalowsky,opaquedave,steinm,phanto,gluke,shuric,svanegmond,rjs,vlad,jimjag,emile,wez,sasha,camber,ohrn,romolo,hholzgra|functable
 avail|rasmus,sterling,jimw|pres
Index: CVSROOT/gen_acl_file.m4
diff -u CVSROOT/gen_acl_file.m4:1.129 CVSROOT/gen_acl_file.m4:1.130
--- CVSROOT/gen_acl_file.m4:1.129   Thu Mar 22 11:18:24 2001
+++ CVSROOT/gen_acl_file.m4 Thu Mar 22 12:10:57 2001
@@ -7,7 +7,7 @@
 dnl Quality Assurance Team
 define(`php_qa', 
`jalal,zak,andre,ultrapingo,lyric,jmoore,ronabop,sbergmann,joey,sniper,torben,hellekin,cnewbill')dnl
 dnl PEAR Team
-define(`php_pear', 
`jon,rael,jlp,sbergmann,troels,urs,jpm,adaniel,tuupola,mj,ssb,metallic,heyesr,aj,andre,zimt,uw,jeichorn,bjoern,chregu,bkelly,tfromm,subjective')dnl
+define(`php_pear', 
+`jon,rael,jlp,sbergmann,troels,urs,jpm,adaniel,tuupola,mj,ssb,metallic,heyesr,aj,andre,zimt,uw,jeichorn,bjoern,chregu,bkelly,tfromm,subjective,cox,mboeren')dnl
 dnl PHP.NET Website
 define(`php_web', 
`cmv,tcobb,gareth,jah,eschmid,ronabop,derick,sterling,stas,phildriscoll,jmoore,andre,sniper,david,lyric,zimt,mk,goba,zak,jmcastagnetto,dams')dnl
 dnl



-- 
PHP CVS 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] extract images from pdfs

2001-03-22 Thread James

I want to extract and save images from a large directory of PDF's... is this
possible with php? Has anyone done this??

 James



-- 
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] Array confusion.

2001-03-22 Thread Altunergil, Oktay

You can do this instead..
$month[] = array("Jan","Feb" .."Dec");

$m = 3;
$real_m = $m-1
echo "Month= $month[$real_m]; //Mar


You can also have PHP assign the first element of the array to index 1
instead of 0.. I think you accomplish that by doing something like $month[]
= array(1=>Jan,Feb,Mar...);
If you need to get the month as $m='03';  you can strip the first zero using
any one of the suitable string functions.


PS: (i noticed that this doesn't really answer your specific question. But
this will work properly for your needs)

oktay

-Original Message-
From: Sterling [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 22, 2001 2:46 PM
To: [EMAIL PROTECTED]
Subject: [PHP] Array confusion.


H-

I'm kinda new to the PHP scene so if the below plea for help is
incredibly simple ... well.. What can I say? I'm stuck. 

I've been on the PHP website for the last hour reading the documentation
on arrays and all the functions associated with it but have yet to find
a straight forward explaination on how to accomplish this code. 
Here's what I have: (PHP4)
 $m = "03";
 $list = array(01=>"Jan", 02=>"Feb", 03=>"Mar", 04=>"Apr", 05=>"May",
06=>"Jun", 07=>"Jul", 08=>"Aug", 09=>"Sep\", 10=>"Oct", 11=>"Nov",
12="Dec");
 $month = $list[$m];
 print "$month\n";

What I want to print is the month in Text format, which in this instance
should be Mar . 
I even tried: $month = array_keys($list, $m);

Now I know that $list[x]; references the location of an item so I know
why the previous code doesn't work in that respect, since nowhere is 01
a location but an association within the array. Right?

I've seen examples on printing every element of an array. Printing every
element of a 2d array, poping elements from the beginning and end of an
array but not an example of getting a single element from an array. 

I'm sure I'm doing something backwards and might even be confused on how
the array works but don't know what. 
If any one has any better solutions to this code please feel free to
post. 

Thanks for any assistance anyone can provide. 
-Sterling

-- 
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] Array confusion.

2001-03-22 Thread CC Zona

In article <[EMAIL PROTECTED]>,
 [EMAIL PROTECTED] (Sterling) wrote:

>  $m = "03";
>  $list = array(01=>"Jan", 02=>"Feb", 03=>"Mar", 04=>"Apr", 05=>"May",
> 06=>"Jun", 07=>"Jul", 08=>"Aug", 09=>"Sep\", 10=>"Oct", 11=>"Nov",
> 12="Dec");
>  $month = $list[$m];
>  print "$month\n";
> 
> What I want to print is the month in Text format, which in this instance
> should be Mar . 
> I even tried: $month = array_keys($list, $m);
> 
> Now I know that $list[x]; references the location of an item so I know
> why the previous code doesn't work in that respect, since nowhere is 01
> a location but an association within the array. Right?

The keys to an associative array should be quoted.  Also, that escaped 
quote on "Sep\" is throwing everything off.  Try:

 $m = "03";
 $list = array("01"=>"Jan", "02"=>"Feb", "03"=>"Mar", "04"=>"Apr", 
"05"=>"May", "06"=>"Jun", "07"=>"Jul", "08"=>"Aug", "09"=>"Sep", 
"10"=>"Oct", "11"=>"Nov","12"="Dec");//keys quoted, no escaped quotes
 $month = $list["$m"];//associative array element index quoted
 print "$month\n";

-- 
CC

-- 
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] Array confusion.

2001-03-22 Thread Sterling

H-

I'm kinda new to the PHP scene so if the below plea for help is
incredibly simple ... well.. What can I say? I'm stuck. 

I've been on the PHP website for the last hour reading the documentation
on arrays and all the functions associated with it but have yet to find
a straight forward explaination on how to accomplish this code. 
Here's what I have: (PHP4)
 $m = "03";
 $list = array(01=>"Jan", 02=>"Feb", 03=>"Mar", 04=>"Apr", 05=>"May",
06=>"Jun", 07=>"Jul", 08=>"Aug", 09=>"Sep\", 10=>"Oct", 11=>"Nov",
12="Dec");
 $month = $list[$m];
 print "$month\n";

What I want to print is the month in Text format, which in this instance
should be Mar . 
I even tried: $month = array_keys($list, $m);

Now I know that $list[x]; references the location of an item so I know
why the previous code doesn't work in that respect, since nowhere is 01
a location but an association within the array. Right?

I've seen examples on printing every element of an array. Printing every
element of a 2d array, poping elements from the beginning and end of an
array but not an example of getting a single element from an array. 

I'm sure I'm doing something backwards and might even be confused on how
the array works but don't know what. 
If any one has any better solutions to this code please feel free to
post. 

Thanks for any assistance anyone can provide. 
-Sterling

-- 
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] need help with cookies

2001-03-22 Thread kris

I beleive I am attempting to set this cookie before any headers are sent.
?
Kris
On 22 Mar 01, at 14:38, Brian V Bonini wrote:

> I believe you need to set the cookie
> before any other header information is 
> passed.
> 
> -brian
> 
> > -Original Message-
> > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> > Sent: Thursday, March 22, 2001 2:23 PM
> > To: [EMAIL PROTECTED]
> > Subject: [PHP] need help with cookies
> > 
> > 
> > Hi, I am trying to set a cookie and it doesn't work.  I am running IE 5.
> > I have IE set to prompt before setting cookies but I never get a prompt.
> > 
> > Here is my code - basically, if someone logs in, it is to set a cookie.
> > What am I missing?   Kris
> > 
> > if($success==1){
> > $loginid="$id";
> > NewSessionID($id);
> > GetProfile($id);
> > $page_title="LTT: $loginid Index";
> > include("html-head.php3");
> > if($id==""){
> > include("ln/ln_ln_dna.php3");
> > exit;
> > }
> > include("ms/rg1/index.php3");
> > exit;
> > }
> > 
> > function NewSessionID($id){
> > $sid="";
> > $length=16;
> > srand((double)microtime()*100);
> > $SessPool = "ABCDEFGHIJKLMNOPQRSTUVWXYZ";
> > $SessPool .= "abcdefghijklmnopqrstuvwxyz";
> > $SessPool .= "0123456789";
> > 
> > for($tempslime=0; $tempslime < $length; $tempslime++) {
> > $sid .= substr($SessPool, 
> > (rand()%(strlen($SessPool))), 1);
> > }
> > setcookie("LoginAuth", $sid,time()+3600);
> > }
> > 
> > -- 
> > 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]
> 



-- 
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] Form help

2001-03-22 Thread darion mapp

why don't you check to see is a variable was passed to the page. If you use the post 
method then a hidden field can be used o check that the user did come from the 
application page.

a sample of the check will be

if(!$var_from_previous_page)
{
header("location: application.php");
}

--

On Thu, 22 Mar 2001 14:34:21  
 Good Fella wrote:
>Hi All,
>
>I currently have a small problem with my PHP form.  I have made two PHP 
>files (application.php and process_application.php).
>
>On submitting the form, you then move to process_application.php.  Any 
>errors will force the form NOT to be submitted to me.
>
>However, how do I stop people from accessing process_application.php 
>directly?  You can still type in the URL of this address without filling in 
>any details.
>
>Although it serves up an error, is there anyway I can prevent people from 
>getting to this page unless they press "Submit" on the actual form on 
>application.php?
>
>Thanks,
>
>SK
>_
>Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.
>
>
>-- 
>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]
>
>


Get 250 color business cards for FREE! at Lycos Mail
http://mail.lycos.com/freemail/vistaprint_index.html

-- 
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] need help with cookies

2001-03-22 Thread Brian V Bonini

I believe you need to set the cookie
before any other header information is 
passed.

-brian

> -Original Message-
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, March 22, 2001 2:23 PM
> To: [EMAIL PROTECTED]
> Subject: [PHP] need help with cookies
> 
> 
> Hi, I am trying to set a cookie and it doesn't work.  I am running IE 5.
> I have IE set to prompt before setting cookies but I never get a prompt.
> 
> Here is my code - basically, if someone logs in, it is to set a cookie.
> What am I missing?   Kris
> 
> if($success==1){
> $loginid="$id";
> NewSessionID($id);
> GetProfile($id);
> $page_title="LTT: $loginid Index";
> include("html-head.php3");
> if($id==""){
> include("ln/ln_ln_dna.php3");
> exit;
> }
> include("ms/rg1/index.php3");
> exit;
> }
> 
> function NewSessionID($id){
> $sid="";
> $length=16;
> srand((double)microtime()*100);
> $SessPool = "ABCDEFGHIJKLMNOPQRSTUVWXYZ";
> $SessPool .= "abcdefghijklmnopqrstuvwxyz";
> $SessPool .= "0123456789";
> 
> for($tempslime=0; $tempslime < $length; $tempslime++) {
> $sid .= substr($SessPool, 
> (rand()%(strlen($SessPool))), 1);
> }
> setcookie("LoginAuth", $sid,time()+3600);
>   }
> 
> -- 
> 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]




[PHP-CVS] cvs: CVSROOT / avail cvsusers gen_acl_file.m4

2001-03-22 Thread Rasmus Lerdorf

rasmus  Thu Mar 22 11:18:25 2001 EDT

  Modified files:  
/CVSROOTavail cvsusers gen_acl_file.m4 
  Log:
  CVS account for Romolo (have been discussion patches with him)
  
  

Index: CVSROOT/avail
diff -u CVSROOT/avail:1.124 CVSROOT/avail:1.125
--- CVSROOT/avail:1.124 Wed Mar 21 08:10:38 2001
+++ CVSROOT/avail   Thu Mar 22 11:18:23 2001
@@ -2,12 +2,12 @@
 unavail
 avail|andi,andrei,jimw,rasmus,rubys,sas,ssb,thies,zeev,shane|CVSROOT
 
avail|andi,andrei,jimw,rasmus,rubys,sas,ssb,thies,zeev,shane,cmv,tcobb,gareth,jah,eschmid,ronabop,derick,sterling,stas,phildriscoll,jmoore,andre,sniper,david,lyric,zimt,mk,goba,zak,jmcastagnetto,dams|phpweb
-avail|andi,andrei,jimw,rasmus,rubys,sas,ssb,thies,zeev,shane,fmk,hirokawa,jah,eschmid,dbeu,sbergmann,samjam,avsm,ronabob,derick,sterling,venaas,stas,hholzgra,cmv,phildriscoll,jmoore,andre,sniper,changelog,sr,david,jdonagher,chagenbu,jon,elixer,joosters,jason,mysql,kalowsky,opaquedave,steinm,phanto,gluke,shuric,svanegmond,rjs,vlad,jimjag,emile,wez,sasha,camber,ohrn,jon,rael,jlp,sbergmann,troels,urs,jpm,adaniel,tuupola,mj,ssb,metallic,heyesr,aj,andre,zimt,uw,jeichorn,bjoern,chregu,bkelly,tfromm,subjective|php4/pear,pearweb,pear
-avail|andi,andrei,jimw,rasmus,rubys,sas,ssb,thies,zeev,shane,fmk,hirokawa,jah,eschmid,dbeu,sbergmann,samjam,avsm,ronabob,derick,sterling,venaas,stas,hholzgra,cmv,phildriscoll,jmoore,andre,sniper,changelog,sr,david,jdonagher,chagenbu,jon,elixer,joosters,jason,mysql,kalowsky,opaquedave,steinm,phanto,gluke,shuric,svanegmond,rjs,vlad,jimjag,emile,wez,sasha,camber,ohrn|php4,php3,php31,phpfi
-avail|andi,andrei,jimw,rasmus,rubys,sas,ssb,thies,zeev,shane,fmk,hirokawa,jah,eschmid,dbeu,sbergmann,samjam,avsm,ronabob,derick,sterling,venaas,stas,hholzgra,cmv,phildriscoll,jmoore,andre,sniper,changelog,sr,david,jdonagher,chagenbu,jon,elixer,joosters,jason,mysql,kalowsky,opaquedave,steinm,phanto,gluke,shuric,svanegmond,rjs,vlad,jimjag,emile,wez,sasha,camber,ohrn,hholzgra|functable
+avail|andi,andrei,jimw,rasmus,rubys,sas,ssb,thies,zeev,shane,fmk,hirokawa,jah,eschmid,dbeu,sbergmann,samjam,avsm,ronabob,derick,sterling,venaas,stas,hholzgra,cmv,phildriscoll,jmoore,andre,sniper,changelog,sr,david,jdonagher,chagenbu,jon,elixer,joosters,jason,mysql,kalowsky,opaquedave,steinm,phanto,gluke,shuric,svanegmond,rjs,vlad,jimjag,emile,wez,sasha,camber,ohrn,romolo,jon,rael,jlp,sbergmann,troels,urs,jpm,adaniel,tuupola,mj,ssb,metallic,heyesr,aj,andre,zimt,uw,jeichorn,bjoern,chregu,bkelly,tfromm,subjective|php4/pear,pearweb,pear
+avail|andi,andrei,jimw,rasmus,rubys,sas,ssb,thies,zeev,shane,fmk,hirokawa,jah,eschmid,dbeu,sbergmann,samjam,avsm,ronabob,derick,sterling,venaas,stas,hholzgra,cmv,phildriscoll,jmoore,andre,sniper,changelog,sr,david,jdonagher,chagenbu,jon,elixer,joosters,jason,mysql,kalowsky,opaquedave,steinm,phanto,gluke,shuric,svanegmond,rjs,vlad,jimjag,emile,wez,sasha,camber,ohrn,romolo|php4,php3,php31,phpfi
+avail|andi,andrei,jimw,rasmus,rubys,sas,ssb,thies,zeev,shane,fmk,hirokawa,jah,eschmid,dbeu,sbergmann,samjam,avsm,ronabob,derick,sterling,venaas,stas,hholzgra,cmv,phildriscoll,jmoore,andre,sniper,changelog,sr,david,jdonagher,chagenbu,jon,elixer,joosters,jason,mysql,kalowsky,opaquedave,steinm,phanto,gluke,shuric,svanegmond,rjs,vlad,jimjag,emile,wez,sasha,camber,ohrn,romolo,hholzgra|functable
 avail|rasmus,sterling,jimw|pres
 
avail|jalal,zak,andre,ultrapingo,lyric,jmoore,ronabop,sbergmann,joey,sniper,torben,hellekin,cnewbill|qaweb
-avail|andi,andrei,jimw,rasmus,rubys,sas,ssb,thies,zeev,shane,fmk,hirokawa,jah,eschmid,dbeu,sbergmann,samjam,avsm,ronabob,derick,sterling,venaas,stas,hholzgra,cmv,phildriscoll,jmoore,andre,sniper,changelog,sr,david,jdonagher,chagenbu,jon,elixer,joosters,jason,mysql,kalowsky,opaquedave,steinm,phanto,gluke,shuric,svanegmond,rjs,vlad,jimjag,emile,wez,sasha,camber,ohrn,php_ext,chad,torben,lynch,kk,ted,kwazy,aka,affinity,paul,skaag,pglat,mbritton,coar,lwest,joey,bibi,mrobinso,lwh,perugini,hamoralesr,tzwenny,hirokawa,drews,paulsen,hartmann,philross,leon,valdirh,dmarion,dubois,jonen,tschuer,tfromm,manuel,stas,danbeck,sli,jmcastagnetto,mohrt,cris,goba,samesch,jon,soneca,kaufm,ronabop,glace,latoserver,phpguru_dk,lojmann,rafael,jan,jcmeloni,chrullrich,mk,sbergmann,troels,mathieu,voize,phaethon,mgx,mj,corean,pandach,brown,cycle98,vizvil,openlife,regina,cynic,jpm,dams,alponce,menuconfig,obst,topgoods,karoora,pcraft,suvia,zak,zimt,mgx,sintoris,jmoore,ftfuture,uttam,ag315,ropik,jbi1979,bbonev,malo,afortaleza,neotron,cg,delrom,dickmeiss,jkj,hellekin,kgergely,andreroq,eduardh,cnewbill,fuzzy74,inki,bjoern,fams,smasiello,dim,lucasr,cpereira,lagflores,kjh90,ernani,theseer,cevm,noribsd,eskaly,mctrash,berto,leobopp,tcr,subjective,mboeren|phpdoc
+avail|andi,andrei,jimw,rasmus,rubys,sas,ssb,thies,zeev,shane,fmk,hirokawa,jah,eschmid,dbeu,sbergmann,samjam,avsm,ronabob,derick,sterling,venaas,stas,hholzgra,cmv,phildriscoll,jmoore,andre,sniper,changelog,sr,david,jdonagher,chagenbu,jon,elixer,joosters,jason,mysql,kalowsky,opaquedave,steinm,

[PHP] need help with cookies

2001-03-22 Thread kris

Hi, I am trying to set a cookie and it doesn't work.  I am running IE 5.
I have IE set to prompt before setting cookies but I never get a prompt.

Here is my code - basically, if someone logs in, it is to set a cookie.
What am I missing?   Kris

if($success==1){
$loginid="$id";
NewSessionID($id);
GetProfile($id);
$page_title="LTT: $loginid Index";
include("html-head.php3");
if($id==""){
include("ln/ln_ln_dna.php3");
exit;
}
include("ms/rg1/index.php3");
exit;
}

function NewSessionID($id){
$sid="";
$length=16;
srand((double)microtime()*100);
$SessPool = "ABCDEFGHIJKLMNOPQRSTUVWXYZ";
$SessPool .= "abcdefghijklmnopqrstuvwxyz";
$SessPool .= "0123456789";

for($tempslime=0; $tempslime < $length; $tempslime++) {
$sid .= substr($SessPool, (rand()%(strlen($SessPool))), 1);
}
setcookie("LoginAuth", $sid,time()+3600);
}

-- 
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] Date subtraction

2001-03-22 Thread almir

PERIOD_DIFF(P1,P2)
or convert them both tu unix_time(p1) - unix_time(p2) then you can have
seconds and format them as you want

almir
""BlackLord"" <[EMAIL PROTECTED]> schrieb im Newsbeitrag
99dcs5$cbh$[EMAIL PROTECTED]">news:99dcs5$cbh$[EMAIL PROTECTED]...
> Hi!
>
> I want to subtract to date times from each other. Like :
>
> '2000 12 01 12:12:12' - '2000 11 10 11:39:59'
>
> Is there any function to do this subtraction or can i do it with MySQL's
> SELECT query ?
>
> Thanks
>
>
>
> --
> 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]




  1   2   3   >