[PHP] Re: Bug #14360: Script ends on

2001-12-07 Thread Fred

Just out of curiosity, what makes you think the scripting engine stopped at
that particular spot?

Fred

Thomas Seuring [EMAIL PROTECTED] wrote in message
005744005865206102L412*@MHS">news:005744005865206102L412*@MHS...
Dear friends,

I've opened a Bug I think I've found on PHP, but there I was recommended to
ask
you.

Below you'll find the Mail I wrote and I hope, that you can help me.


[2001-12-06 06:30:32] [EMAIL PROTECTED]
I'm using a generated Script of the PHAKT-Software on a Windows 2000 and
Apache
Server.

The complete Script is:

?php
// *** Restrict Access To Page: Grant or deny access to this page
$KT_authorizedUsers= a;
$KT_authFailedURL= ../ierraccess.php;
$KT_grantAccess=0;
session_start();
if (isset($HTTP_SESSION_VARS[KT_Username])) {
  if (false || !(isset($HTTP_SESSION_VARS[KT_UserAuthorization])) ||
$HTTP_SESSION_VARS[KT_UserAuthorization]== ||
strpos($KT_authorizedUsers, $HTTP_SESSION_VARS[KT_UserAuthorization])) {
$KT_grantAccess = 1;
  }
}
if (!$KT_grantAccess) {
  $KT_qsChar = ?;
  if (strpos($KT_authFailedURL, ?)) $KT_qsChar = ;
  $KT_referrer = $PHP_SELF;
  if (strlen($QUERY_STRING)  0) $KT_referrer .= ? . $QUERY_STRING;
  $KT_authFailedURL = $KT_authFailedURL . $KT_qsChar . accessdenied= .
urlencode($KT_referrer);
  header(Location: $KT_authFailedURL);
  exit;
}
?

On

if (strlen($QUERY_STRING)  0) $KT_referrer .= ? . $QUERY_STRING;

The PHP Engine ends after the  of (strlen($QUERY_STRING)  0).

I think PHP interpretes the  as end of the Scripting Section.

I hope you could help me on this.

Yours

Tom


[2001-12-06 06:36:40] [EMAIL PROTECTED]
Ask for support questions at [EMAIL PROTECTED] .

This is most likely a programming error.

Bogus.

Thank you very much for your Feedback.

Yours,

Tom


Thomas W. Seuring
Senior Manager Corporate IT
DaimlerChrysler Capital Services
Europe  South Africa

HPC 0635
Epplestrasse 225
70546 Stuttgart
Germany

E-Mail: [EMAIL PROTECTED]

Phone: +49 (711) 17 94 783
Fax: +49 (711) 17 91 698

Mobile:+49 (171) 370 71 84
Mobile Fax: +49 (171) 37 48 158
- Forwarded by Thomas Seuring/DEBIS/debis/DCX on 07.12.2001 08:04 -

[EMAIL PROTECTED]
06.12.2001 15:14
Please respond to php-dev

To: Thomas Seuring/DEBIS/debis/DCX@WK-EMEA1
bcc:
Subject: Bug #14360: Script ends on 

From: [EMAIL PROTECTED]
Operating system: Windows 2000
PHP version:  4.0.6
PHP Bug Type: Scripting Engine problem
Bug description:  Script ends on 

I'm using a generated Script of the PHAKT-Software on a Windows 2000 and
Apache Server.

The complete Script is:

?php
// *** Restrict Access To Page: Grant or deny access to this page
$KT_authorizedUsers= a;
$KT_authFailedURL= ../ierraccess.php;
$KT_grantAccess=0;
session_start();
if (isset($HTTP_SESSION_VARS[KT_Username])) {
  if (false ¦¦ !(isset($HTTP_SESSION_VARS[KT_UserAuthorization])) ¦¦
$HTTP_SESSION_VARS[KT_UserAuthorization]== ¦¦
strpos($KT_authorizedUsers, $HTTP_SESSION_VARS[KT_UserAuthorization]))
{
$KT_grantAccess = 1;
  }
}
if (!$KT_grantAccess) {
  $KT_qsChar = ?;
  if (strpos($KT_authFailedURL, ?)) $KT_qsChar = ;
  $KT_referrer = $PHP_SELF;
  if (strlen($QUERY_STRING)  0) $KT_referrer .= ? . $QUERY_STRING;
  $KT_authFailedURL = $KT_authFailedURL . $KT_qsChar . accessdenied= .
urlencode($KT_referrer);
  header(Location: $KT_authFailedURL);
  exit;
}
?

On

if (strlen($QUERY_STRING)  0) $KT_referrer .= ? . $QUERY_STRING;

The PHP Engine ends after the .

I think PHP interpretes the  as end of the Scripting Section.

I hope you could help me on this.

Yours

Tom


--
Edit bug report at: http://bugs.php.net/?id=14360edit=2


=



-- 
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] session_id()

2001-12-07 Thread Gede Gilijk

This is a simple autentification script using session
I try to echo the session_id().
But to my surprise, the value of session_id() is different - in
configuration -
if I use difference browser.

IE :
9ff68d81039d9ece3ba9840328b91488

Opera :
7aa4895172b5a4785c9fb754eaf792aa

NN :
1007630964

Anybody face this thing ?

?
session_start();

 echo h1Members only/h1;

 // Check session variable
 if (session_is_registered(valid_user))
 {
 echo pYou log in as $valid_user./p;
 $sess_id = session_id();
 echo $sess_idbr;
 } else {
 echo pYou have not login yet/p;
 }

 echo a href=\authmain.php\Back to main page/a;

 ?

Regards,

Gede Gilijk



-- 
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] Re: Redirect Function?!!

2001-12-07 Thread Roko Roic


I don't like header('Location: page.php'); so I use a HTTP request class to
call another script/page. This does fork another httpd, but that's life :)

Roko



-- 
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: Redirect Function?!!

2001-12-07 Thread Brian Clark

* Roko Roic [EMAIL PROTECTED] [Dec 07. 2001 03:26]:

 I don't like header('Location: page.php'); so I use a HTTP request class to
 call another script/page. This does fork another httpd, but that's life :)

Just out of curiosity, what's wrong with header('Location ... ');?

-- 
 -Brian Clark


-- 
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] Uploaded Image display problems

2001-12-07 Thread phantom

With thanks to you who have helped me, I have constructed a PHP script
that allows the client to upload an image (jpg or gif) that is stored in
a MySQL Blob field.

And I have a PHP script that will pull the binary data out of the MySQL
database and display the upload image for the client.

THE PROBLEM: HALF MY GIF AND JPG FILES DO NOT DISPLAY PROPERLY WHEN
VIEWING THE DISPLAY.PHP SCRIPT (see below).  Half display fine, half do
not.

Has anyone else had this problem or know what I can do to remedy it?
Thank you.

Source code below * form.htm, insert.php, display.php *

 FORM HTM =

HTML
HEAD
TITLEInsert Binary Data in a Database/TITLE
/HEAD

BODY
H1Upload a File:/H1

FORM enctype=multipart/form-data method=post action=insert.php
input type=hidden name=MAX_FILE_SIZE value=20
INPUT type=file name=img1 size=30
brbr
INPUT type=submit name=submit value=Use This File

/FORM
/BODY
/HTML

 INSERT PHP =

?
if (!isset($img1)) {
 header(Location: insert_file.htm?Msg=EmptyUpload);
 exit();
}

$db = mysql_connect(localhost, $DB_Username, $DB_pass)
 or die (Unable to connect to server.);
mysql_select_db($DB_name)
 or die (Unable to select DB);

$binary_junk  = mysql_escape_string(fread(fopen($img1, r),
filesize($img1)));
// original file used addslashes but here I used mysql_escape_string;

$insert_data = INSERT INTO ImageTable (ImgName,ImgSize,ImgType,ImgData)
VALUES ('$img1_name', '$img1_size', '$img1_type', '$binary_junk');

mysql_query($insert_data)
 or die (Unable to insert data: .mysql_error());

$PKey = mysql_insert_id();

?

HTML
HEAD
TITLESuccessful File Insertion!/TITLE

H1Success!/H1

PYou have inserted the following into your database:br
  ? echo $img1_name;?
  a
  ? echo $img1_size;?
  byte file with a mime type of
  ?
  echo $img1_type; ?./P
View Your Image a href=display.php?PKey=?=$PKey?HERE/a
/BODY
/HTML

 DISPLAY PHP =

?
$db = mysql_connect(localhost, $DB_Username, $DB_pass)
 or die (Unable to connect to server.);
mysql_select_db($DB_name)
 or die (Unable to select DB);

$get_image = SELECT ImgType, ImgData FROM ImageTable WHERE PKey=$PKey;

$get_image_result = mysql_query($get_image)
 or die (Unable to get image.);

$binary_junk = mysql_result($get_image_result,0,ImgData);
$file_type = mysql_result($get_image_result,0,ImgType);

header(Content-Type: $file_type);
header(Content-Length:  . strlen($binary_junk));
echo $binary_junk;

?


-- 
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] Re: Again (still?) problems with php and ldaps

2001-12-07 Thread Yasuo Ohgaki
You also may want to try 4.1.0RC5.
http://www.php.net/~zeev/php-4.1.0RC5.tar.gz

I'm not sure which bugs have been fix, but there are sevral bug
fixes in 4.1.0.

--
Yasuo Ohgaki

Susanne Benkert wrote:

 Hi,
 
 After recompiling my Php with the newest LDAP-Libraries and Openssl
 "ldap_connect("ldap://hostname")" works. But I still have problems with
 "ldap_connect("ldaps://hostname")": 
 
 Connecting works, but Php can't bind with the Openldap-Server. I checked
 the debug output of slapd and found messages like the following.
 
 
 TLS trace: SSL-accept:SSLv3 read client hello A
 TLS trace: SSL-accept:SSLv3 write server hello A
 TLS trace: SSL-accept:SSLv3 write certificate A
 TLS trace: SSL-accept:SSLv3 write server done A
 
 TLS trace: SSL_accept:SSLv3 flush data
 tls_read: want=5 error=Operation would block
 TLS trace SSL_accept:error in SSLv3 read client certificate A
 TLS trace SSL_accept:error in SSLv3 read client certificate A
 TLS trace SSL_accept:failed in SSLv3 read client certificate A
 Tls:can't accept.
 
 
 
 What did I wrong? Does Php need its own Key/Certificate (as client
 certificate)? Or is something wrong with my server certificate of Ldap?
 (But I can't imagine, because other actions like ldapsearch already seem
 to work with TLS.) 
 Has anything should be change in the configuration of php when using it
 with SSL and Openldap?
 
 Can anybody help me? (I am new in SSL and such things and I have no idea
 how to solve this problem.)
 Bye Susanne
 



-- 
Yasuo Ohgaki


-- 
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] Is there a GUI for MySQL?

2001-12-07 Thread Neil Freeman

How about MySQL Front (www.mysqlfront.de). Couple of 'features' here and
there but overall pretty good.

Neil

Hai Nguyen wrote:

 Hi,

 I am a newbie at this.  I was just wondering if there is a Graphical
 User Interface for MySQL?

 Cheers,

 Hai Nguyen

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

 ***
  This message was virus checked with: SAVI 3.51
  last updated 26th November 2001
 ***

--

 Email:  [EMAIL PROTECTED]
 [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] Re: session_id()

2001-12-07 Thread Yasuo Ohgaki
Gede Gilijk wrote:

 This is a simple autentification script using session
 I try to echo the session_id().
 But to my surprise, the value of session_id() is different - in
 configuration -
 if I use difference browser.
 
 IE :
 9ff68d81039d9ece3ba9840328b91488
 
 Opera :
 7aa4895172b5a4785c9fb754eaf792aa
 
 NN :
 1007630964


How did you get this? Normal session ID is MD5 hash value.
Therefore, session id is string that has 32 chars and consists of
a-z0-9.

The only reason that I can think of is you have cookie that has
cookie in your NN.

Check your NN's cookie, I'm sure you have a cookie which has
"1007670964".

BTW, session module will *not* validate if session id is MD5 hash
or not. Programmer should check if session id format is valid or not.

--
Yasuo Ohgaki

 
 Anybody face this thing ?
 
 ?
 session_start();
 
  echo "h1Members only/h1";
 
  // Check session variable
  if (session_is_registered("valid_user"))
  {
  echo "pYou log in as $valid_user./p";
  $sess_id = session_id();
  echo "$sess_idbr";
  } else {
  echo "pYou have not login yet/p";
  }
 
  echo "a href=\"authmain.php\"Back to main page/a";
 
  ?
 
 Regards,
 
 Gede Gilijk
 
 
 


-- 
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] Uploaded Image display problems

2001-12-07 Thread Michael Hall


I can't help you with the problem described below, but I can tell you
this:

I, like many others, do not store images as BLOBs in a database. I store
them in a regular directory (/images), and just store the image name, path
or URL in the database. This generally creates less hassles.

Mick

On Fri, 7 Dec 2001, phantom wrote:

 With thanks to you who have helped me, I have constructed a PHP script
 that allows the client to upload an image (jpg or gif) that is stored in
 a MySQL Blob field.
 
 And I have a PHP script that will pull the binary data out of the MySQL
 database and display the upload image for the client.
 
 THE PROBLEM: HALF MY GIF AND JPG FILES DO NOT DISPLAY PROPERLY WHEN
 VIEWING THE DISPLAY.PHP SCRIPT (see below).  Half display fine, half do
 not.
 
 Has anyone else had this problem or know what I can do to remedy it?
 Thank you.
 
 Source code below * form.htm, insert.php, display.php *
 
  FORM HTM =
 
 HTML
 HEAD
 TITLEInsert Binary Data in a Database/TITLE
 /HEAD
 
 BODY
 H1Upload a File:/H1
 
 FORM enctype=multipart/form-data method=post action=insert.php
 input type=hidden name=MAX_FILE_SIZE value=20
 INPUT type=file name=img1 size=30
 brbr
 INPUT type=submit name=submit value=Use This File
 
 /FORM
 /BODY
 /HTML
 
  INSERT PHP =
 
 ?
 if (!isset($img1)) {
  header(Location: insert_file.htm?Msg=EmptyUpload);
  exit();
 }
 
 $db = mysql_connect(localhost, $DB_Username, $DB_pass)
  or die (Unable to connect to server.);
 mysql_select_db($DB_name)
  or die (Unable to select DB);
 
 $binary_junk  = mysql_escape_string(fread(fopen($img1, r),
 filesize($img1)));
 // original file used addslashes but here I used mysql_escape_string;
 
 $insert_data = INSERT INTO ImageTable (ImgName,ImgSize,ImgType,ImgData)
 VALUES ('$img1_name', '$img1_size', '$img1_type', '$binary_junk');
 
 mysql_query($insert_data)
  or die (Unable to insert data: .mysql_error());
 
 $PKey = mysql_insert_id();
 
 ?
 
 HTML
 HEAD
 TITLESuccessful File Insertion!/TITLE
 
 H1Success!/H1
 
 PYou have inserted the following into your database:br
   ? echo $img1_name;?
   a
   ? echo $img1_size;?
   byte file with a mime type of
   ?
   echo $img1_type; ?./P
 View Your Image a href=display.php?PKey=?=$PKey?HERE/a
 /BODY
 /HTML
 
  DISPLAY PHP =
 
 ?
 $db = mysql_connect(localhost, $DB_Username, $DB_pass)
  or die (Unable to connect to server.);
 mysql_select_db($DB_name)
  or die (Unable to select DB);
 
 $get_image = SELECT ImgType, ImgData FROM ImageTable WHERE PKey=$PKey;
 
 $get_image_result = mysql_query($get_image)
  or die (Unable to get image.);
 
 $binary_junk = mysql_result($get_image_result,0,ImgData);
 $file_type = mysql_result($get_image_result,0,ImgType);
 
 header(Content-Type: $file_type);
 header(Content-Length:  . strlen($binary_junk));
 echo $binary_junk;
 
 ?
 
 
 

-- 

Michael Hall
[EMAIL PROTECTED]
[EMAIL PROTECTED]
http://openlearningcommunity.org



-- 
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] session_id()

2001-12-07 Thread Scott Houseman

This is most probably because PHP sessions use browser cookies to store
data - thus each browser
would have a  different session id, as they all store their cookies in
separate locations on your
PC's hard drive.

Regards

-- Scott
- Original Message -
From: Gede Gilijk [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Friday, December 07, 2001 10:12 AM
Subject: [PHP] session_id()


 This is a simple autentification script using session
 I try to echo the session_id().
 But to my surprise, the value of session_id() is different - in
 configuration -
 if I use difference browser.

 IE :
 9ff68d81039d9ece3ba9840328b91488

 Opera :
 7aa4895172b5a4785c9fb754eaf792aa

 NN :
 1007630964

 Anybody face this thing ?

 ?
 session_start();

  echo h1Members only/h1;

  // Check session variable
  if (session_is_registered(valid_user))
  {
  echo pYou log in as $valid_user./p;
  $sess_id = session_id();
  echo $sess_idbr;
  } else {
  echo pYou have not login yet/p;
  }

  echo a href=\authmain.php\Back to main page/a;

  ?

 Regards,

 Gede Gilijk



 --
 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] Re: session_id()

2001-12-07 Thread Michael Hall



That NN value looks like a UNIX timestamp.

Mick

On Fri, 7 Dec 2001, Yasuo Ohgaki wrote:

  This is a simple autentification script using session
  I try to echo the session_id().
  But to my surprise, the value of session_id() is different - in
  configuration -
  if I use difference browser.
  
  IE :
  9ff68d81039d9ece3ba9840328b91488
  
  Opera :
  7aa4895172b5a4785c9fb754eaf792aa
  
  NN :
  1007630964
 
 

-- 

Michael Hall
[EMAIL PROTECTED]
[EMAIL PROTECTED]
http://openlearningcommunity.org



-- 
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] Multidimensional array construction

2001-12-07 Thread Tim Ward

I haven't seen the rest of this thread so this may be irrelevant ... but

foreach($array as $key=$value)
{   $array[$key] = fred;
}

... alters an array while traversing it. Your case seems more complicated
but I would have thought nesting foreaches in this way would allow you to
access the original element.


foreach($array as $key1=$value1)
{   foreach($array as $key2=$value2)
{   $array[$key1][$key2] = fred;
}
}

Tim
http://www.chessish.com http://www.chessish.com 


--
From:  Darren Gamble [SMTP:[EMAIL PROTECTED]]
Sent:  04 December 2001 15:22
To:  PHP List; 'Mike Eheler'
Subject:  RE: [PHP] Multidimensional array construction

Good day,

Thanks to all who replied.

This isn't quite what I needed, though.  I _have_ the array (or
delimited
list would do, too).  What I need to do is _CREATE_ the array
element
$myarray['foo']['bar']['green']['apple'] and set it to some value.
Actually
traversing said array isn't hard, as you pointed out.

foreach() doesn't work, as it just uses a copy of the original
array.  I
think there might be some way to use variable references, but I
haven't
gotten one to work yet.

Any other suggestions?


Darren Gamble
Planner, Regional Services
Shaw Cablesystems GP
630 - 3rd Avenue SW
Calgary, Alberta, Canada
T2P 4L4
(403) 781-4948


-Original Message-
From: Mike Eheler [mailto:[EMAIL PROTECTED]]
Sent: Monday, December 03, 2001 5:30 PM
To: Martin Towell
Cc: 'Darren Gamble'; PHP List
Subject: Re: [PHP] Multidimensional array construction


I did something like this recently. Here's how I did it:

$some_value1 = 'Hello World';
$myarray['foo']['bar']['green']['apple'] = $some_value1;

function get_opt($arr, $keys,$sep=':') {
$var = $arr;
$tmp = split($sep,$keys);
foreach ($tmp as $k = $v) {
$var = $var[$v];
}
if (isset($var)) return $var;
return '';
}

echo get_opt($myarray, 'foo:bar:green:apple');

It needs refining, but it should do the job. That's entirely from 
memory, mind you.. it should work, though.

Mike

Martin Towell wrote:

I was thinking that you could use a pointer to var, eg:
$var = 'myarray[foo][bar][red][apple]';
// this would obviously be created dynamically, hard coded for
testing
$$var = $some_value1;
echo $myarray[foo][bar][red][apple];
but when I tried it, it didn't work :(
looks like eval() to the rescue...

-Original Message-
From: Darren Gamble [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, December 04, 2001 10:37 AM
To: PHP List
Subject: [PHP] Multidimensional array construction


Here's a question for the list:

I have a two-dimensional array; essentially a list of arrays.  Each
element
(an array) can have any number of elements.  As a small example:

(
  ( foo , bar , red , apple ),
  ( foo , bar , red , car),
  ( foo , green )
)

I would like to traverse this array and place all of the data into
another
multidimensional array.  The following statements illustrate how
I'd like
to
do this from the example:

$myarray[foo][bar][red][apple] = $some_value1;
$myarray[foo][bar][red][car]   = $some_value2;
$myarray[foo][green]   = $some_value3;

Is there any way to easily do this in PHP?  I could cheat and use
eval(),
but there is probably a better way.  I have thought of using each()
or
references, but nothing has come to mind so far. 

Any ideas?  Should I just use eval() ?


Darren Gamble
Planner, Regional Services
Shaw Cablesystems GP
630 - 3rd Avenue SW
Calgary, Alberta, Canada
T2P 4L4
(403) 781-4948



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

2001-12-07 Thread Bharath Bhushan Lohray

I would like to know which header is sent when files are downloaded. I have
constructed a script which sends binary to the client when he clicks the
download button (Helpful on servers that do not permit storage of .zip
files) but the binary is displayed on the browser window. Are there any
special headers

-Bharath Bhushan Lohray



-- 
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: session_id()

2001-12-07 Thread Yasuo Ohgaki

Michael Hall wrote:

 
 That NN value looks like a UNIX timestamp.
 
 Mick
 
 On Fri, 7 Dec 2001, Yasuo Ohgaki wrote:
 
 
This is a simple autentification script using session
I try to echo the session_id().
But to my surprise, the value of session_id() is different - in
configuration -
if I use difference browser.

IE :
9ff68d81039d9ece3ba9840328b91488

Opera :
7aa4895172b5a4785c9fb754eaf792aa

NN :
1007630964


 

He should have set cookie *before*
Deleting the cookie should solve the problem.

Regards,
-- 
Yasuo Ohgaki


_
Do You Yahoo!?
Get your free @yahoo.com address at http://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]




[PHP] sybase_query return

2001-12-07 Thread Calin Uioreanu

Hi,

I have a problem.
I am using sybase_query to update a statistics table, and then reset an
external cache server.
These operations come one after another in the script. The ideea is that the
new thing will be cached
again the next time it's called, but the cache beeing reset will force it to
be the newest thing.

The problem that I am facing is when I put it into a big traffic site. Then
it looks like the cached image
is an older one. No ideea why.
I am assuming that sybase_query returns before finishing the query
execution!? And then the cache
gets reset but beeing constantly called it takes still the old thing from
the database? Any ideeas?

I would appreciate!
Calin



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

2001-12-07 Thread gampid




 VORTEX SUPPLIES 

YOUR LASER PRINTER TONER CARTRIDGE,
COPIER AND FAX CARTRIDGE CONNECTION

SAVE UP TO 30% FROM RETAIL

ORDER BY PHONE:1-888-288-9043
ORDER BY FAX: 1-888-977-1577
E-MAIL REMOVAL LINE: 1-888-248-4930


UNIVERSITY AND/OR SCHOOL PURCHASE ORDERS WELCOME. (NO CREDIT APPROVAL REQUIRED)
ALL OTHER PURCHASE ORDER REQUESTS REQUIRE CREDIT APPROVAL.
PAY BY CHECK (C.O.D), CREDIT CARD OR PURCHASE ORDER (NET 30 DAYS).

IF YOUR ORDER IS BY CREDIT CARD PLEASE LEAVE YOUR CREDIT CARD # PLUS EXPIRATION DATE. 
IF YOUR ORDER IS BY PURCHASE ORDER LEAVE YOUR SHIPPING/BILLING ADDRESSES AND YOUR P.O. 
NUMBER


NOTE: WE DO NOT CARRY 

1) XEROX, BROTHER, PANASONIC, FUJITSU PRODUCTS
2) HP DESKJETJET/INK JET OR BUBBLE JET CARTRIDGES 
3) CANON BUBBLE JET CARTRIDGES 
4) ANY OFFBRANDS BESIDES THE ONES LISTED BELOW.

OUR NEW , LASER PRINTER TONER CARTRIDGE, PRICES ARE  AS FOLLOWS: 
(PLEASE ORDER BY PAGE NUMBER AND/OR ITEM NUMBER)

HEWLETT PACKARD: (ON PAGE 2)

ITEM #1  LASERJET SERIES  4L,4P (74A)$44
ITEM #2  LASERJET SERIES  1100 (92A)-$44
ITEM #3  LASERJET SERIES  2 (95A)$39
ITEM #4  LASERJET SERIES  2P (75A)---$54 
ITEM #5  LASERJET SERIES  5P,6P,5MP, 6MP (3903A)--  -$44
ITEM #6  LASERJET SERIES  5SI, 8000 (09A)$95
ITEM #7  LASERJET SERIES  2100, 2200 (96A)---$74
ITEM #8  LASERJET SERIES  8100 (82X)-$115
ITEM #9  LASERJET SERIES  5L/6L (3906A)--$39
ITEM #10 LASERJET SERIES  4V-$95
ITEM #11 LASERJET SERIES 4000 (27X)--$79
ITEM #12 LASERJET SERIES 3SI/4SI (91A)---$54
ITEM #13 LASERJET SERIES 4, 4M, 5,5M-$49
ITEM #13A LASERJET SERIES 5000 (29X)-$125
ITEM #13B LASERJET SERIES 1200---$59
ITEM #13C LASERJET SERIES 4100---$99
ITEM #18   LASERJET SERIES 3100--$39
ITEM #19 LASERJET SERIES 4500 BLACK--$79
ITEM #20 LASERJET SERIES 4500 COLORS $125

HEWLETT PACKARD FAX (ON PAGE 2)

ITEM #14 LASERFAX 500, 700 (FX1)--$49
ITEM #15  LASERFAX 5000,7000 (FX2)$64
ITEM #16  LASERFAX (FX3)--$59
ITEM #17  LASERFAX (FX4)--$54


LEXMARK/IBM (ON PAGE 3)

OPTRA 4019, 4029 HIGH YIELD---$89
OPTRA R, 4039, 4049 HIGH YIELD---$105
OPTRA E310.312 HIGH YIELD$79

OPTRA E---$59
OPTRA N--$115
OPTRA S--$165
OPTRA T--$195
OPTRA E310/312---$79


EPSON (ON PAGE 4)

ACTION LASER 7000,7500,8000,9000--$105
ACTION LASER 1000,1500$105


CANON PRINTERS (ON PAGE 5)

PLEASE CALL FOR MODELS AND UPDATED PRICES
FOR CANON PRINTER CARTRIDGES

PANASONIC (0N PAGE 7)

NEC SERIES 2 MODELS 90 AND 95--$105

APPLE (0N PAGE 8)

LASER WRITER PRO 600 or 16/600--$49 
LASER WRITER SELECT 300,320,360-$74
LASER WRITER 300 AND 320$54
LASER WRITER NT, 2NT$54
LASER WRITER 12/640-$79

CANON FAX (ON PAGE 9)

LASERCLASS 4000 (FX3)---$59
LASERCLASS 5000,6000,7000 (FX2)-$54
LASERFAX 5000,7000 (FX2)$54
LASERFAX 8500,9000 (FX4)$54

CANON COPIERS (PAGE 10)

PC 3, 6RE, 7 AND 11 (A30)-$69
PC 300,320,700,720,760,900,910,920(E-40)--$89


90 DAY UNLIMITED WARRANTY INCLUDED ON ALL PRODUCTS.

ALL TRADEMARKS AND BRAND NAMES LISTED ABOVE ARE PROPERTY OF THE 
RESPECTIVE HOLDERS AND USED FOR DESCRIPTIVE PURPOSES ONLY.








-- 
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: Redirect Function?!!

2001-12-07 Thread Roko Roic


Brian Clark [EMAIL PROTECTED] wrote in message
20011207082759.GB8750@ganymede">news:20011207082759.GB8750@ganymede...
 * Roko Roic [EMAIL PROTECTED] [Dec 07. 2001 03:26]:

  I don't like header('Location: page.php'); so I use a HTTP request class
to
  call another script/page. This does fork another httpd, but that's life
:)

 Just out of curiosity, what's wrong with header('Location ... ');?

I may be wrong, but I thing Header(Location) sends a Location header back to
the client informing him that he will be redirected. Therefore, you must
expect your client to be aware of that HTTP header, and some WAP client
performed strangely with this. Also some proprietary HTTP clients could act
the same.

I, too, would like to know if this is the case?

Roko



-- 
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] Looking for content writers for new IT magazine

2001-12-07 Thread Siim Einfeldt aka Itpunk


Hi Everyone,

I`m working on an IT magazine called
InfoEdit, and now I have gotten far enough with the back-end to say
that the programming will be finished very soon. Now it`s time
to get superb content editors for the site. If someone of you feels he/she
knows enough about some IT subject and would like to share what you know, 
then
please be sure to contact me, either at this email or
[EMAIL PROTECTED] . The subjects that the mag will cover will be
from employment,creating CV`s to administrating linux server and more, so
if you know much about something and feel you would like to work with the
magazine, get in touch. You will have the chance to be with a new online
magazine from the beginning and help it grow, You will also have a word
to say about the overall contents of this magazine, also we can arrange
some advertising for you or your company on the site. So in case of any
interest in this, please get back to me with informal information about
yourself and your skills and what 'column' would you like to write.
Expected are different articles as well as series or articles and also
tutorials, so once again,in case of interest, please contact me asap.

Best wishes,
Siim Einfeldt



-- 
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] Uploaded Image display problems

2001-12-07 Thread Gareth Hastings

I found this worked fine for me, I used the same method to read the file
into the database and the following lines to print the image out.

I tested this with images from 1kb -- 945kb both gif/jpg and it worked
fine

?
$conn   = mysql_connect(x, x, x);
$db = mysql_select_db (img);
$result = mysql_query (select * from img);
$image  = mysql_result($result, 0, image);
mysql_close($conn);

echo $image;
?

Try taking out your header statements in display.php just to see what
happens. Also, you script doesn't timeout half way through does it ?
(wild guessing now) Does your web server show anything in the logs ?

Gareth


-Original Message-
From: Michael Hall [mailto:[EMAIL PROTECTED]] 
Sent: 07 December 2001 14:08
To: phantom
Cc: [EMAIL PROTECTED]
Subject: Re: [PHP] Uploaded Image display problems


I can't help you with the problem described below, but I can tell you
this:

I, like many others, do not store images as BLOBs in a database. I store
them in a regular directory (/images), and just store the image name,
path
or URL in the database. This generally creates less hassles.

Mick

On Fri, 7 Dec 2001, phantom wrote:

 With thanks to you who have helped me, I have constructed a PHP script
 that allows the client to upload an image (jpg or gif) that is stored
in
 a MySQL Blob field.
 
 And I have a PHP script that will pull the binary data out of the
MySQL
 database and display the upload image for the client.
 
 THE PROBLEM: HALF MY GIF AND JPG FILES DO NOT DISPLAY PROPERLY WHEN
 VIEWING THE DISPLAY.PHP SCRIPT (see below).  Half display fine, half
do
 not.
 
 Has anyone else had this problem or know what I can do to remedy it?
 Thank you.
 
 Source code below * form.htm, insert.php, display.php *
 
  FORM HTM =
 
 HTML
 HEAD
 TITLEInsert Binary Data in a Database/TITLE
 /HEAD
 
 BODY
 H1Upload a File:/H1
 
 FORM enctype=multipart/form-data method=post action=insert.php
 input type=hidden name=MAX_FILE_SIZE value=20
 INPUT type=file name=img1 size=30
 brbr
 INPUT type=submit name=submit value=Use This File
 
 /FORM
 /BODY
 /HTML
 
  INSERT PHP =
 
 ?
 if (!isset($img1)) {
  header(Location: insert_file.htm?Msg=EmptyUpload);
  exit();
 }
 
 $db = mysql_connect(localhost, $DB_Username, $DB_pass)
  or die (Unable to connect to server.);
 mysql_select_db($DB_name)
  or die (Unable to select DB);
 
 $binary_junk  = mysql_escape_string(fread(fopen($img1, r),
 filesize($img1)));
 // original file used addslashes but here I used mysql_escape_string;
 
 $insert_data = INSERT INTO ImageTable
(ImgName,ImgSize,ImgType,ImgData)
 VALUES ('$img1_name', '$img1_size', '$img1_type', '$binary_junk');
 
 mysql_query($insert_data)
  or die (Unable to insert data: .mysql_error());
 
 $PKey = mysql_insert_id();
 
 ?
 
 HTML
 HEAD
 TITLESuccessful File Insertion!/TITLE
 
 H1Success!/H1
 
 PYou have inserted the following into your database:br
   ? echo $img1_name;?
   a
   ? echo $img1_size;?
   byte file with a mime type of
   ?
   echo $img1_type; ?./P
 View Your Image a href=display.php?PKey=?=$PKey?HERE/a
 /BODY
 /HTML
 
  DISPLAY PHP =
 
 ?
 $db = mysql_connect(localhost, $DB_Username, $DB_pass)
  or die (Unable to connect to server.);
 mysql_select_db($DB_name)
  or die (Unable to select DB);
 
 $get_image = SELECT ImgType, ImgData FROM ImageTable WHERE
PKey=$PKey;
 
 $get_image_result = mysql_query($get_image)
  or die (Unable to get image.);
 
 $binary_junk = mysql_result($get_image_result,0,ImgData);
 $file_type = mysql_result($get_image_result,0,ImgType);
 
 header(Content-Type: $file_type);
 header(Content-Length:  . strlen($binary_junk));
 echo $binary_junk;
 
 ?
 
 
 

-- 

Michael Hall
[EMAIL PROTECTED]
[EMAIL PROTECTED]
http://openlearningcommunity.org



-- 
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] HOW to download PHP files without the use of a FTP client

2001-12-07 Thread R. Lindeman

Hello,

i hav e big problem i need to download some php files without the use of a
FTP client or other .

so if you know a solution to my problem please reply

thanx



-- 
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] Re: semaphores not automatically releasing at end of script

2001-12-07 Thread Thomas

ANYONE CAN HELP WITH THIS PLEASE???



-- 
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: semaphores not automatically releasing at end of script

2001-12-07 Thread Jon Haworth

You probably have a better chance if you include

(a) some code
(b) an error message
(c) a description of your environment


Cheers
Jon


-Original Message-
From: Thomas [mailto:[EMAIL PROTECTED]]
Sent: 07 December 2001 11:01
To: [EMAIL PROTECTED]
Subject: [PHP] Re: semaphores not automatically releasing at end of
script


ANYONE CAN HELP WITH THIS PLEASE???



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


_
This message has been checked for all known viruses by UUNET delivered 
through the MessageLabs Virus Control Centre. For further information visit
http://www.uk.uu.net/products/security/virus/

-- 
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 wih select boxes pls

2001-12-07 Thread Yogesh Mahadnac

Hi! I'm trying to make dynamically related select boxes (e.g. i have a 'State' 
select box, which, when i select an item in it, it automatically refreshes the select 
box 'Cities' containing a list of cities in that particular chosen state) 

Anyone can help me with this please?

Thanks



Re: [PHP] Uploaded Image display problems

2001-12-07 Thread phantom

I am starting to wonder if the problem lies in mysql_escape_string and it's
manipulation of the binary data before inserting it into the mysql db
(INSERT.PHP)

I have pretty much the same thing that Gareth has.  I did check, the php
script does not time out.  I have to at least leave the Header:
Content-Type: $ImgType otherwise the script will output a string and not an
image.

Gareth Hastings wrote:

 I found this worked fine for me, I used the same method to read the file
 into the database and the following lines to print the image out.

 I tested this with images from 1kb -- 945kb both gif/jpg and it worked
 fine

 ?
 $conn   = mysql_connect(x, x, x);
 $db = mysql_select_db (img);
 $result = mysql_query (select * from img);
 $image  = mysql_result($result, 0, image);
 mysql_close($conn);

 echo $image;
 ?

 Try taking out your header statements in display.php just to see what
 happens. Also, you script doesn't timeout half way through does it ?
 (wild guessing now) Does your web server show anything in the logs ?

 Gareth

 -Original Message-
 From: Michael Hall [mailto:[EMAIL PROTECTED]]
 Sent: 07 December 2001 14:08
 To: phantom
 Cc: [EMAIL PROTECTED]
 Subject: Re: [PHP] Uploaded Image display problems

 I can't help you with the problem described below, but I can tell you
 this:

 I, like many others, do not store images as BLOBs in a database. I store
 them in a regular directory (/images), and just store the image name,
 path
 or URL in the database. This generally creates less hassles.

 Mick

 On Fri, 7 Dec 2001, phantom wrote:

  With thanks to you who have helped me, I have constructed a PHP script
  that allows the client to upload an image (jpg or gif) that is stored
 in
  a MySQL Blob field.
 
  And I have a PHP script that will pull the binary data out of the
 MySQL
  database and display the upload image for the client.
 
  THE PROBLEM: HALF MY GIF AND JPG FILES DO NOT DISPLAY PROPERLY WHEN
  VIEWING THE DISPLAY.PHP SCRIPT (see below).  Half display fine, half
 do
  not.
 
  Has anyone else had this problem or know what I can do to remedy it?
  Thank you.
 
  Source code below * form.htm, insert.php, display.php *
 
   FORM HTM =
 
  HTML
  HEAD
  TITLEInsert Binary Data in a Database/TITLE
  /HEAD
 
  BODY
  H1Upload a File:/H1
 
  FORM enctype=multipart/form-data method=post action=insert.php
  input type=hidden name=MAX_FILE_SIZE value=20
  INPUT type=file name=img1 size=30
  brbr
  INPUT type=submit name=submit value=Use This File
 
  /FORM
  /BODY
  /HTML
 
   INSERT PHP =
 
  ?
  if (!isset($img1)) {
   header(Location: insert_file.htm?Msg=EmptyUpload);
   exit();
  }
 
  $db = mysql_connect(localhost, $DB_Username, $DB_pass)
   or die (Unable to connect to server.);
  mysql_select_db($DB_name)
   or die (Unable to select DB);
 
  $binary_junk  = mysql_escape_string(fread(fopen($img1, r),
  filesize($img1)));
  // original file used addslashes but here I used mysql_escape_string;
 
  $insert_data = INSERT INTO ImageTable
 (ImgName,ImgSize,ImgType,ImgData)
  VALUES ('$img1_name', '$img1_size', '$img1_type', '$binary_junk');
 
  mysql_query($insert_data)
   or die (Unable to insert data: .mysql_error());
 
  $PKey = mysql_insert_id();
 
  ?
 
  HTML
  HEAD
  TITLESuccessful File Insertion!/TITLE
 
  H1Success!/H1
 
  PYou have inserted the following into your database:br
? echo $img1_name;?
a
? echo $img1_size;?
byte file with a mime type of
?
echo $img1_type; ?./P
  View Your Image a href=display.php?PKey=?=$PKey?HERE/a
  /BODY
  /HTML
 
   DISPLAY PHP =
 
  ?
  $db = mysql_connect(localhost, $DB_Username, $DB_pass)
   or die (Unable to connect to server.);
  mysql_select_db($DB_name)
   or die (Unable to select DB);
 
  $get_image = SELECT ImgType, ImgData FROM ImageTable WHERE
 PKey=$PKey;
 
  $get_image_result = mysql_query($get_image)
   or die (Unable to get image.);
 
  $binary_junk = mysql_result($get_image_result,0,ImgData);
  $file_type = mysql_result($get_image_result,0,ImgType);
 
  header(Content-Type: $file_type);
  header(Content-Length:  . strlen($binary_junk));
  echo $binary_junk;
 
  ?
 
 
 

 --
 
 Michael Hall
 [EMAIL PROTECTED]
 [EMAIL PROTECTED]
 http://openlearningcommunity.org

 --
 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] Help wih select boxes pls

2001-12-07 Thread Jon Haworth


 Hi! I'm trying to make dynamically related select boxes
 (e.g. i have a 'State'  select box, which, when i select 
 an item in it, it automatically refreshes the select box 
 'Cities' containing a list of cities in that particular 
 chosen state) 

Good article on this at Zend:
http://www.zend.com/zend/tut/drop-down.php

HTH
Jon


-- 
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] file with authentication for HTTP

2001-12-07 Thread Nic Skitt

Hi all,

Aplogies if this question has already been asked,

Is it possible to authenticate using HTTP when requesting a file from
another webserver.

In other words:

Assuming you needed to authenticate for the following, how would you do it?

$fcontents = file ('http://www.php.net');

Cheers

Nic



-- 
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] Re: HOW to download PHP files without the use of a FTP client

2001-12-07 Thread Thomas

I had a similar situation, I just made a simple editor on a PHP website,
and then edited the files from any other computer. You can the editor
script over a SSL secure connection or at least have it passworded if
you are worried about security, but either way its safer and simpler
than FTP.



-- 
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] Re: Help wih select boxes pls

2001-12-07 Thread Thomas

This is a client-side situation, so PHP probably wont help much. Some
people do it with javascript and others use it by submitting forms and
refreshing the page everytime it is changed.



-- 
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] Re: Looking for content writers for new IT magazine

2001-12-07 Thread Thomas

I might be interested, I will email you about doing a column.



-- 
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] Uploaded Image display problems

2001-12-07 Thread phantom

hehe.

Just for fun I decided to save a copy of the file in a /images folder and then
save it into MySQL.

Now when I get a bad image in MySQL I also have a bad image in the /images
folder.  When I have a good image in MySQL I have a good image in /images.

So that tells me the problem happens before this step (so before
mysql_escape_string and addslashes (if I were using that)), so for some reason
it appears the data error problem occurs before it reaches this script.  Maybe
it gets tainted on submission time to investigate more.

Phantom wrote:

 I am starting to wonder if the problem lies in mysql_escape_string and it's
 manipulation of the binary data before inserting it into the mysql db
 (INSERT.PHP)

 I have pretty much the same thing that Gareth has.  I did check, the php
 script does not time out.  I have to at least leave the Header:
 Content-Type: $ImgType otherwise the script will output a string and not an
 image.

 Gareth Hastings wrote:

  I found this worked fine for me, I used the same method to read the file
  into the database and the following lines to print the image out.
 
  I tested this with images from 1kb -- 945kb both gif/jpg and it worked
  fine
 
  ?
  $conn   = mysql_connect(x, x, x);
  $db = mysql_select_db (img);
  $result = mysql_query (select * from img);
  $image  = mysql_result($result, 0, image);
  mysql_close($conn);
 
  echo $image;
  ?
 
  Try taking out your header statements in display.php just to see what
  happens. Also, you script doesn't timeout half way through does it ?
  (wild guessing now) Does your web server show anything in the logs ?
 
  Gareth
 
  -Original Message-
  From: Michael Hall [mailto:[EMAIL PROTECTED]]
  Sent: 07 December 2001 14:08
  To: phantom
  Cc: [EMAIL PROTECTED]
  Subject: Re: [PHP] Uploaded Image display problems
 
  I can't help you with the problem described below, but I can tell you
  this:
 
  I, like many others, do not store images as BLOBs in a database. I store
  them in a regular directory (/images), and just store the image name,
  path
  or URL in the database. This generally creates less hassles.
 
  Mick
 
  On Fri, 7 Dec 2001, phantom wrote:
 
   With thanks to you who have helped me, I have constructed a PHP script
   that allows the client to upload an image (jpg or gif) that is stored
  in
   a MySQL Blob field.
  
   And I have a PHP script that will pull the binary data out of the
  MySQL
   database and display the upload image for the client.
  
   THE PROBLEM: HALF MY GIF AND JPG FILES DO NOT DISPLAY PROPERLY WHEN
   VIEWING THE DISPLAY.PHP SCRIPT (see below).  Half display fine, half
  do
   not.
  
   Has anyone else had this problem or know what I can do to remedy it?
   Thank you.
  
   Source code below * form.htm, insert.php, display.php *
  
    FORM HTM =
  
   HTML
   HEAD
   TITLEInsert Binary Data in a Database/TITLE
   /HEAD
  
   BODY
   H1Upload a File:/H1
  
   FORM enctype=multipart/form-data method=post action=insert.php
   input type=hidden name=MAX_FILE_SIZE value=20
   INPUT type=file name=img1 size=30
   brbr
   INPUT type=submit name=submit value=Use This File
  
   /FORM
   /BODY
   /HTML
  
    INSERT PHP =
  
   ?
   if (!isset($img1)) {
header(Location: insert_file.htm?Msg=EmptyUpload);
exit();
   }
  
   $db = mysql_connect(localhost, $DB_Username, $DB_pass)
or die (Unable to connect to server.);
   mysql_select_db($DB_name)
or die (Unable to select DB);
  
   $binary_junk  = mysql_escape_string(fread(fopen($img1, r),
   filesize($img1)));
   // original file used addslashes but here I used mysql_escape_string;
  
   $insert_data = INSERT INTO ImageTable
  (ImgName,ImgSize,ImgType,ImgData)
   VALUES ('$img1_name', '$img1_size', '$img1_type', '$binary_junk');
  
   mysql_query($insert_data)
or die (Unable to insert data: .mysql_error());
  
   $PKey = mysql_insert_id();
  
   ?
  
   HTML
   HEAD
   TITLESuccessful File Insertion!/TITLE
  
   H1Success!/H1
  
   PYou have inserted the following into your database:br
 ? echo $img1_name;?
 a
 ? echo $img1_size;?
 byte file with a mime type of
 ?
 echo $img1_type; ?./P
   View Your Image a href=display.php?PKey=?=$PKey?HERE/a
   /BODY
   /HTML
  
    DISPLAY PHP =
  
   ?
   $db = mysql_connect(localhost, $DB_Username, $DB_pass)
or die (Unable to connect to server.);
   mysql_select_db($DB_name)
or die (Unable to select DB);
  
   $get_image = SELECT ImgType, ImgData FROM ImageTable WHERE
  PKey=$PKey;
  
   $get_image_result = mysql_query($get_image)
or die (Unable to get image.);
  
   $binary_junk = mysql_result($get_image_result,0,ImgData);
   $file_type = mysql_result($get_image_result,0,ImgType);
  
   header(Content-Type: $file_type);
   header(Content-Length:  . strlen($binary_junk));
   echo $binary_junk;
  
   ?
  
  
  
 
  --
  
  Michael Hall
  

[PHP] Re: trigger words

2001-12-07 Thread Julio Nobrega Trabalhando

  Yes! But since one must learn by trying, I will give you some general
rules.

  Okay, make it work as a function. You need the page url to grab and the
word to search. So it's a function with two arguments:

function do_it ($page_url , $word) {

  Then inside the function you fopen() the $page, and ereg($word,
$page_contents). If ereg() is succesful, you will 'return the function' to
create a link similar to:

echo a href=\$page\$word/a;
return 1;

  Or the usual $sql = INSERT INTO table blah blah blah using your
preferred db query function.

--

Julio Nobrega

Don't eat the yellow snow.


Deron [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
 Is there an easy way with PHP, or something else, to have a document on
the
 web where a certain word is mentioned within the page somewhere...in my
case
 a band name and it could automatically take that name/word and create
it
 as a link that's stored in either a flatfile or a database of some sort?

 Deron
 www.metalages.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] Re: Binary Header

2001-12-07 Thread Thomas

You need to send a Content-Type header, I believe it is octet-stream or
something similar to that.



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

2001-12-07 Thread Girish Nath

Hi

Try sending the following header for .zip files

header (Content-Type: application/x-zip-compressed);

Regards


Girish



- Original Message -
From: Bharath Bhushan Lohray [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Friday, December 07, 2001 9:40 AM
Subject: [PHP] Binary Header


 I would like to know which header is sent when files are downloaded. I
have
 constructed a script which sends binary to the client when he clicks the
 download button (Helpful on servers that do not permit storage of .zip
 files) but the binary is displayed on the browser window. Are there any
 special headers

 -Bharath Bhushan Lohray



 --
 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] Re: HOW to download PHP files without the use of a FTP client

2001-12-07 Thread Johan

 i hav e big problem i need to download some php files without the use of a
 FTP client or other .
 
 so if you know a solution to my problem please reply

Do you have possibility to use the PHP FTP functions? Or do you not havr 
ftp access??

regards,
Johan

-- 
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] RE: trigger words

2001-12-07 Thread Tim Ward

Yes, use a combination of file and string (or regex) functions to scan the
file for the string you want.

Tim

--
From:  Deron [SMTP:[EMAIL PROTECTED]]
Sent:  07 December 2001 02:21
To:  [EMAIL PROTECTED]
Subject:  trigger words

Is there an easy way with PHP, or something else, to have a document
on the
web where a certain word is mentioned within the page somewhere...in
my case
a band name and it could automatically take that name/word and
create it
as a link that's stored in either a flatfile or a database of some
sort?

Deron
www.metalages.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] Re: Redirect Function?!!

2001-12-07 Thread Miles Thompson

RFC 2616 is your friend 

14.30 Location The Location response-header field is used to redirect the 
recipient to a location other than the Request-URI for completion of the 
request or identification of a new resource. For 201 (Created) responses, 
the Location is that of the new resource which was created by the request. 
For 3xx responses, the location SHOULD indicate the server's preferred URI 
for automatic redirection to the resource. The field value consists of a 
single absolute URI. Location = Location : absoluteURI An example is: 
Location: http://www.w3.org/pub/WWW/People.html Note: The Content-Location 
header field (section 14.14) differs from Location in that the 
Content-Location identifies the original location of the entity enclosed in 
the request. It is therefore possible for a response to contain header 
fields for both Location and Content-Location. Also see section 13.10 for 
cache requirements of some methods. 

Original, better formatted, is at ftp://ftp.isi.edu/in-notes/rfc2616.txt

Miles

At 11:28 AM 12/7/2001 +0100, Roko Roic wrote:

Brian Clark [EMAIL PROTECTED] wrote in message
20011207082759.GB8750@ganymede">news:20011207082759.GB8750@ganymede...
  * Roko Roic [EMAIL PROTECTED] [Dec 07. 2001 03:26]:
 
   I don't like header('Location: page.php'); so I use a HTTP request class
to
   call another script/page. This does fork another httpd, but that's life
:)
 
  Just out of curiosity, what's wrong with header('Location ... ');?

I may be wrong, but I thing Header(Location) sends a Location header back to
the client informing him that he will be redirected. Therefore, you must
expect your client to be aware of that HTTP header, and some WAP client
performed strangely with this. Also some proprietary HTTP clients could act
the same.

I, too, would like to know if this is the case?

Roko



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

2001-12-07 Thread Peter Lalka


Hi.
I've instaled and cofigured php4 on WinNT with Apache Web server.
I can't use any fuction of Image manipulation, 'cause I get this error
message: ImageGif: No GIF support in this PHP build
In phpinfo() is listed that: gd lib. enabled, zlib lib. enabled.
What do I still miss there?
Peter.


-- 
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] Get links from a page

2001-12-07 Thread Julio Nobrega Trabalhando

  Hi all,

  I was sure I saw something like this on this list one month ago. But I
search for like dozens of word combination to find this post (or anything
related to), and was unsuccesful.

  Anyone has a quick snippet that will scan a bunch of text characters and
return the links as an array element?

  Something like:

text to search:
a
href=http://www.stj.gov.br/stj/noticias/detalhes_noticias.asp?seq_noticia=4
776Proprietário que retoma imóvel negociado responde pelas despesas
condominiais atrasadas/a a
href=http://www.stj.gov.br/stj/noticias/detalhes_noticias.asp?seq_noticia=4
775Ouro Preto garante no STJ o recebimento de parcela de ICMS da Vale do
Rio Doce/a


And it could return:
$array = Array();
$array[] =
'http://http://www.stj.gov.br/stj/noticias/detalhes_noticias.asp?seq_noticia
=4776';
$array[] =
'http://www.stj.gov.br/stj/noticias/detalhes_noticias.asp?seq_noticia=4775';

  Thanks a lot, and again sorry if this is a duplicated question, but I
really did not find.

--

Julio Nobrega

Don't eat the yellow snow.



-- 
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] file with authentication for HTTP

2001-12-07 Thread Miles Thompson


NO answer, but two more questions:

1. Do you want the authentication on your site to extend to the other?
2. Why not have the other site do it's own authentication?

I've noticed this. On a client's publishing site I have two forms of 
authenitication. ONe for subscribers, hacked together by myself, which uses 
sessions. This works fine, not ironclad but it keeps the honest people 
hones, which is all I want.

The administrtation portion of the site uses a slightly modified script 
which Rasmus L. published about 3 yr ago. It uses header( www-authenticate 
... , and sets PHP_AUTH_USER. Once that's set I can roam all over the 
site, including pages set by the other scheme.

No help here, just an observation.

Miles Thompson

At 11:31 AM 12/7/2001 +, Nic Skitt wrote:
Hi all,

Aplogies if this question has already been asked,

Is it possible to authenticate using HTTP when requesting a file from
another webserver.

In other words:

Assuming you needed to authenticate for the following, how would you do it?

$fcontents = file ('http://www.php.net');

Cheers

Nic



--
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] Remove carriage returns

2001-12-07 Thread RoyW

I have a memo type field in a form and I am looking for the PHP command to
strip the carriage returns from the field before inserting into a database.


???

Thx!



-- 
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] Re: Remove carriage returns

2001-12-07 Thread Johan

Royw wrote:

 I have a memo type field in a form and I am looking for the PHP command
 to strip the carriage returns from the field before inserting into a
 database.

addslashes();
htmlentities(); 

??

Regards,

Johan

-- 
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] Re: Image problem

2001-12-07 Thread Johan

 I've instaled and cofigured php4 on WinNT with Apache Web server.
 I can't use any fuction of Image manipulation, 'cause I get this error
 message: ImageGif: No GIF support in this PHP build
 In phpinfo() is listed that: gd lib. enabled, zlib lib. enabled.
 What do I still miss there?

In the newest version of GD library (think it since about 1.3 or something) 
does support GIF, because GIF is a commerial image format.

Use PNG or JPEG instead. That much better, or find a version with GIF 
support.

You can see what Image formats you GD can use by make a file with follow 
content:
?php
phpinfo();
?

:o)

Regards,

Johan

-- 
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] Re: Get links from a page

2001-12-07 Thread lallous

this should work,

if (preg_match_all('/a .+?href=([\'])(.+?)\1/is', $mem, $result))
{
  $linksarray =  $result[2];
}


Julio Nobrega Trabalhando [EMAIL PROTECTED] wrote in
message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
   Hi all,

   I was sure I saw something like this on this list one month ago. But I
 search for like dozens of word combination to find this post (or anything
 related to), and was unsuccesful.

   Anyone has a quick snippet that will scan a bunch of text characters and
 return the links as an array element?

   Something like:

 text to search:
 a

href=http://www.stj.gov.br/stj/noticias/detalhes_noticias.asp?seq_noticia=4
 776Proprietário que retoma imóvel negociado responde pelas despesas
 condominiais atrasadas/a a

href=http://www.stj.gov.br/stj/noticias/detalhes_noticias.asp?seq_noticia=4
 775Ouro Preto garante no STJ o recebimento de parcela de ICMS da Vale do
 Rio Doce/a


 And it could return:
 $array = Array();
 $array[] =

'http://http://www.stj.gov.br/stj/noticias/detalhes_noticias.asp?seq_noticia
 =4776';
 $array[] =

'http://www.stj.gov.br/stj/noticias/detalhes_noticias.asp?seq_noticia=4775';

   Thanks a lot, and again sorry if this is a duplicated question, but I
 really did not find.

 --

 Julio Nobrega

 Don't eat the yellow snow.





-- 
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: Image problem

2001-12-07 Thread Peter Lalka


Thanks, in phpinfo list really isn't support for GIF:(
How can I manipulate jpeg images? Which functions are for this img. format?
P.


|+-
||  Johan [EMAIL PROTECTED] |
||  Odoslané kým:  |
||  php-general-return-77040-lalkap=emo.seas.sk@lis|
||  ts.php.net |
|| |
|| |
||  07.12.2001 14:30   |
|| |
|+-
  
---|
  |
   |
  | Komu:   [EMAIL PROTECTED]  
   |
  | Kópia: 
   |
  |   Predmet:[PHP] Re: Image problem  
   |
  
---|



 I've instaled and cofigured php4 on WinNT with Apache Web server.
 I can't use any fuction of Image manipulation, 'cause I get this error
 message: ImageGif: No GIF support in this PHP build
 In phpinfo() is listed that: gd lib. enabled, zlib lib. enabled.
 What do I still miss there?

In the newest version of GD library (think it since about 1.3 or something)

does support GIF, because GIF is a commerial image format.

Use PNG or JPEG instead. That much better, or find a version with GIF
support.

You can see what Image formats you GD can use by make a file with follow
content:
?php
phpinfo();
?

:o)

Regards,

Johan

--
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] [ Re: [PHP] Re: Image problem]

2001-12-07 Thread Johan Holst Nielsen



 Original Message 
From: - Fri Dec 07 14:52:01 2001
X-Mozilla-Status: 0001
X-Mozilla-Status2: 
Message-ID: [EMAIL PROTECTED]
Date: Fri, 07 Dec 2001 14:51:56 +0100
From: Johan Holst Nielsen [EMAIL PROTECTED]
Reply-To: [EMAIL PROTECTED]
Organization: 1WAY2PRINT A/S
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.2) 
Gecko/20010726 Netscape6/6.1
X-Accept-Language: en-us
MIME-Version: 1.0
To: Peter Lalka [EMAIL PROTECTED]
Subject: Re: [PHP] Re: Image problem
References: [EMAIL PROTECTED]
Content-Type: text/plain; charset=us-ascii; format=flowed
Content-Transfer-Encoding: 7bit



Peter Lalka wrote:

Thanks, in phpinfo list really isn't support for GIF:(
How can I manipulate jpeg images? Which functions are for this img. format?
P.

The same, only one difference. You have to open a file with 
CreateImageFromJPEG etc. and ImageJPEG instead of etc. GIF

Regards,

Johan





[PHP] Good, secure, easy to configure/use PHP website management tool?

2001-12-07 Thread Brinkman, Theodore

I'm looking to add a PHP-based website management tool to a web server I'm
running, so updates can be done remotely without having to open ports for
FTP.  Can anybody recommend a good package that's easy to configure?

- Theo

-- 
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] Good php-tool for administer users on mysql?

2001-12-07 Thread Stefan Rusterholz

Does anyone know a webbrowser/php based tool which allows to administer user 
privileges in mysql easily?

Thanks in advance
Stefan Rusterholz, [EMAIL PROTECTED]
--
interaktion gmbh
Stefan Rusterholz
Zürichbergstrasse 17
8032 Zürich
--
T. +41 1 253 19 55
F. +41 1 253 19 56
W3 www.interaktion.ch
--



[PHP] Good php-tool for administer users on mysql?

2001-12-07 Thread Stefan Rusterholz

Does anyone know a webbrowser/php based tool which allows to administer user 
privileges in mysql easily?

Stefan Rusterholz, [EMAIL PROTECTED]
--
interaktion gmbh
Stefan Rusterholz
Zürichbergstrasse 17
8032 Zürich
--
T. +41 1 253 19 55
F. +41 1 253 19 56
W3 www.interaktion.ch
--



Re: [PHP] Good php-tool for administer users on mysql?

2001-12-07 Thread Kurth Bemis

At 09:56 AM 12/7/2001, Stefan Rusterholz wrote:

phpmyadmin  - its great!

get it at phpwizard.net

~kurth

Does anyone know a webbrowser/php based tool which allows to administer 
user privileges in mysql easily?

Thanks in advance
Stefan Rusterholz, [EMAIL PROTECTED]
--
interaktion gmbh
Stefan Rusterholz
Zürichbergstrasse 17
8032 Zürich
--
T. +41 1 253 19 55
F. +41 1 253 19 56
W3 www.interaktion.ch
--


--
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] Good php-tool for administer users on mysql?

2001-12-07 Thread Stefan Rusterholz

Yes phpMyAdmin IS great, but it does only allow you to access the 'mysql' db
with 'user' table in it. It doesn't provide anything to make it easier to
create new user accounts (user accounts != tables) and setting the users
privileges :(

thats what I'm searching for.

Stefan Rusterholz, [EMAIL PROTECTED]
--
interaktion gmbh
Stefan Rusterholz
Zürichbergstrasse 17
8032 Zürich
--
T. +41 1 253 19 55
F. +41 1 253 19 56
W3 www.interaktion.ch
--
- Original Message -
From: Kurth Bemis [EMAIL PROTECTED]
To: Stefan Rusterholz [EMAIL PROTECTED]; PHP
[EMAIL PROTECTED]
Sent: Wednesday, December 05, 2001 4:08 PM
Subject: Re: [PHP] Good php-tool for administer users on mysql?


 At 09:56 AM 12/7/2001, Stefan Rusterholz wrote:

 phpmyadmin  - its great!

 get it at phpwizard.net

 ~kurth

 Does anyone know a webbrowser/php based tool which allows to administer
 user privileges in mysql easily?
 
 Thanks in advance
 Stefan Rusterholz, [EMAIL PROTECTED]
 --
 interaktion gmbh
 Stefan Rusterholz
 Zürichbergstrasse 17
 8032 Zürich
 --
 T. +41 1 253 19 55
 F. +41 1 253 19 56
 W3 www.interaktion.ch
 --


 --
 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] how to free some memory

2001-12-07 Thread Berthold

Hello!

How can I free some memory after using it in an huge array?

Testing with $oldX = array(); doesn't even free the memory... :-(

-- 
Berthold


-- 
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] Good php-tool for administer users on mysql?

2001-12-07 Thread Stefan Rusterholz

Sorry, ignore my last mail. I was wrong. phpMyAdmin indeed does provide a
surface for adding users and setting privileges.
Sorry.

Stefan Rusterholz, [EMAIL PROTECTED]
--
interaktion gmbh
Stefan Rusterholz
Zürichbergstrasse 17
8032 Zürich
--
T. +41 1 253 19 55
F. +41 1 253 19 56
W3 www.interaktion.ch
--
- Original Message -
From: Kurth Bemis [EMAIL PROTECTED]
To: Stefan Rusterholz [EMAIL PROTECTED]; PHP
[EMAIL PROTECTED]
Sent: Wednesday, December 05, 2001 4:08 PM
Subject: Re: [PHP] Good php-tool for administer users on mysql?


 At 09:56 AM 12/7/2001, Stefan Rusterholz wrote:

 phpmyadmin  - its great!

 get it at phpwizard.net

 ~kurth

 Does anyone know a webbrowser/php based tool which allows to administer
 user privileges in mysql easily?
 
 Thanks in advance
 Stefan Rusterholz, [EMAIL PROTECTED]
 --
 interaktion gmbh
 Stefan Rusterholz
 Zürichbergstrasse 17
 8032 Zürich
 --
 T. +41 1 253 19 55
 F. +41 1 253 19 56
 W3 www.interaktion.ch
 --





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

2001-12-07 Thread Robert Covell

A question about different release versions of PHP.

Why do things like png from gd 1.8 work in 4.0.4p1 and stops working in
4.0.6?  We had to go back to 4.0.4p1.  I have seen similar things with mysql
support.  We used the same config script for each version.  Any ideas?


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] how to free some memory

2001-12-07 Thread R'twick Niceorgaw

unset($oldX);

- Original Message - 
From: Berthold [EMAIL PROTECTED]
To: PHP-General [EMAIL PROTECTED]
Sent: Friday, December 07, 2001 9:52 AM
Subject: [PHP] how to free some memory


 Hello!
 
 How can I free some memory after using it in an huge array?
 
 Testing with $oldX = array(); doesn't even free the memory... :-(
 
 -- 
 Berthold
 
 
 -- 
 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] How to UNSUBSCRIBE ???

2001-12-07 Thread fazer

UNSUBSCRIBE

:)

{[f-a-z-e-r]}--
 mailto:[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] Version To Version

2001-12-07 Thread Neil Freeman

I'm using gd png in 4.0.6 with no problems (Windows). What problems are you
having?

Robert Covell wrote:

 A question about different release versions of PHP.

 Why do things like png from gd 1.8 work in 4.0.4p1 and stops working in
 4.0.6?  We had to go back to 4.0.4p1.  I have seen similar things with mysql
 support.  We used the same config script for each version.  Any ideas?

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

 ***
  This message was virus checked with: SAVI 3.51
  last updated 26th November 2001
 ***

--

 Email:  [EMAIL PROTECTED]
 [EMAIL PROTECTED]




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




RE: [PHP] How to UNSUBSCRIBE ???

2001-12-07 Thread Nathan Cassano


Whats wrong? Is it that you don't like us anymore? Why would you want to
unsubscribe?

Please inspect the bottom of any PHP list email to find you answer.

-Original Message-
From: fazer [mailto:[EMAIL PROTECTED]] 
Sent: Thursday, December 06, 2001 8:25 AM
To: [EMAIL PROTECTED]
Subject: [PHP] How to UNSUBSCRIBE ???
Importance: High


UNSUBSCRIBE


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

2001-12-07 Thread Robert Covell

Don't have the error handy anymore but it was something to the effect of:
ImageCreatPNG is not supported in 4.0.6 or something like that.  When I went
back to 4.0.4pl it was fine.  Very weird.


-Original Message-
From: Neil Freeman [mailto:[EMAIL PROTECTED]]
Sent: Friday, December 07, 2001 10:31 AM
To: Php-General
Subject: Re: [PHP] Version To Version


I'm using gd png in 4.0.6 with no problems (Windows). What problems are you
having?

Robert Covell wrote:

 A question about different release versions of PHP.

 Why do things like png from gd 1.8 work in 4.0.4p1 and stops working in
 4.0.6?  We had to go back to 4.0.4p1.  I have seen similar things with
mysql
 support.  We used the same config script for each version.  Any ideas?

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

 ***
  This message was virus checked with: SAVI 3.51
  last updated 26th November 2001
 ***

--

 Email:  [EMAIL PROTECTED]
 [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] Version To Version

2001-12-07 Thread Valentin V. Petruchek

Your problem is GD, not PHP.
Use gd library corresponding to PHP 4.0.6 and PNG will be ok (tested by
myself).

Zliy Pes

- Original Message -
From: Robert Covell [EMAIL PROTECTED]
To: Neil Freeman [EMAIL PROTECTED]; Php-General
[EMAIL PROTECTED]
Sent: Friday, December 07, 2001 7:08 PM
Subject: RE: [PHP] Version To Version


 Don't have the error handy anymore but it was something to the effect of:
 ImageCreatPNG is not supported in 4.0.6 or something like that.  When I
went
 back to 4.0.4pl it was fine.  Very weird.


 -Original Message-
 From: Neil Freeman [mailto:[EMAIL PROTECTED]]
 Sent: Friday, December 07, 2001 10:31 AM
 To: Php-General
 Subject: Re: [PHP] Version To Version


 I'm using gd png in 4.0.6 with no problems (Windows). What problems are
you
 having?

 Robert Covell wrote:

  A question about different release versions of PHP.
 
  Why do things like png from gd 1.8 work in 4.0.4p1 and stops working in
  4.0.6?  We had to go back to 4.0.4p1.  I have seen similar things with
 mysql
  support.  We used the same config script for each version.  Any ideas?
 
  --
  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]
 
  ***
   This message was virus checked with: SAVI 3.51
   last updated 26th November 2001
  ***

 --
 
  Email:  [EMAIL PROTECTED]
  [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]




[PHP] Dynamic Document Creation

2001-12-07 Thread [ rswfire ]

Hello,

Does anyone have any scripts or know a location to point me to where I can 
dynamically create Microsoft Word documents using PHP.  I need to create 
some nicely formatted forms.  I could do this as text, however, this 
solution is not perfect because I don't know of an escape sequence for 
creating a new page.  I cannot do this using PDF because it's not installed 
on the servers I am using.  I could possibly do this in other formats if you 
know of any solutions.  Thank you.

rswfire

_
Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp


-- 
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] Dynamic Document Creation

2001-12-07 Thread Valentin V. Petruchek

It's from manual do not remember it's chapter exactly:

// starting word
$word = new COM(word.application) or die(Unable to instanciate Word);
print Loaded Word, version {$word-Version}\n;

//bring it to front
$word-Visible = 1;

//open an empty document
$word-Documents-Add();

//do some weird stuff
$word-Selection-TypeText(This is a test...);
$word-Documents[1]-SaveAs(Useless test.doc);

//closing word
$word-Quit();

//free the object
$word-Release();
$word = null;
//--
-
So you can develop this example into powerful tool for generating Word %(
Documents. I advise you to find MS Word DOM Handbook to make your task
easier...

Zliy Pes, http://zliypes.com.ua


- Original Message -
From: [ rswfire ] [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Friday, December 07, 2001 7:43 PM
Subject: [PHP] Dynamic Document Creation


 Hello,

 Does anyone have any scripts or know a location to point me to where I can
 dynamically create Microsoft Word documents using PHP.  I need to create
 some nicely formatted forms.  I could do this as text, however, this
 solution is not perfect because I don't know of an escape sequence for
 creating a new page.  I cannot do this using PDF because it's not
installed
 on the servers I am using.  I could possibly do this in other formats if
you
 know of any solutions.  Thank you.

 rswfire



 _
 Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp


 --
 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] Apache log files

2001-12-07 Thread Dan McCullough

I was looking for the name of the addon to webalizer that makes it nice looking and 
better
features.  I have looked over and over again, but I cannot find it, anyone know the 
name?

dan

=
dan mccullough

Theres no such thing as a problem unless the servers are on fire!


__
Do You Yahoo!?
Send your FREE holiday greetings online!
http://greetings.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] Dynamic Document Creation

2001-12-07 Thread Kurt Lieber

On Friday 07 December 2001 09:43 am, you wrote:
 Does anyone have any scripts or know a location to point me to where I can
 dynamically create Microsoft Word documents using PHP.  

You said you wanted to create some nicely formatted forms -- what's wrong 
with HTML and style sheets?  Assuming you have some control over your end 
users' browsers, you should be able to create a well-formatted, easy-to-use 
HTML form no problem.

Otherwise, I'd look at LaTeX or maybe DocBook format.  

--kurt

-- 
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] Dynamic Document Creation

2001-12-07 Thread Robert Samuel White

These forms are for offline distributionthe information in the form 
is collected from an online database...

 On Friday 07 December 2001 09:43 am, you wrote:
  Does anyone have any scripts or know a location to point me to 
where I can
  dynamically create Microsoft Word documents using PHP.  
 
 You said you wanted to create some nicely formatted forms -- what's 
wrong 
 with HTML and style sheets?  Assuming you have some control over your 
end 
 users' browsers, you should be able to create a well-formatted, easy-
to-use 
 HTML form no problem.
 
 Otherwise, I'd look at LaTeX or maybe DocBook format.  
 
 --kurt
 
 -- 
 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: php-list-
[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] Dynamic Document Creation

2001-12-07 Thread Miles Thompson

Wheee! Sounds like fun.

If you're headed for the latest version of Word (XP), XML would be the way 
to go. I would expect specs available at either StarOffice (Open Office) or 
MSFT.

There's also nice formatting with HTML.

Miles Thompson

At 12:43 PM 12/7/2001 -0500, [ rswfire ] wrote:
Hello,

Does anyone have any scripts or know a location to point me to where I can 
dynamically create Microsoft Word documents using PHP.  I need to create 
some nicely formatted forms.  I could do this as text, however, this 
solution is not perfect because I don't know of an escape sequence for 
creating a new page.  I cannot do this using PDF because it's not 
installed on the servers I am using.  I could possibly do this in other 
formats if you know of any solutions.  Thank you.

rswfire

_
Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp


--
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] Dynamic Document Creation

2001-12-07 Thread Robert Samuel White

Thank you, Valentin.  Your solution sounds like the one I am looking 
for!



 It's from manual do not remember it's chapter exactly:
 
 // starting word
 $word = new COM(word.application) or die(Unable to instanciate 
Word);
 print Loaded Word, version {$word-Version}\n;
 
 //bring it to front
 $word-Visible = 1;
 
 //open an empty document
 $word-Documents-Add();
 
 //do some weird stuff
 $word-Selection-TypeText(This is a test...);
 $word-Documents[1]-SaveAs(Useless test.doc);
 
 //closing word
 $word-Quit();
 
 //free the object
 $word-Release();
 $word = null;
 //
--
 -
 So you can develop this example into powerful tool for generating 
Word %(
 Documents. I advise you to find MS Word DOM Handbook to make your task
 easier...
 
 Zliy Pes, http://zliypes.com.ua
 
 
 - Original Message -
 From: [ rswfire ] [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Friday, December 07, 2001 7:43 PM
 Subject: [PHP] Dynamic Document Creation
 
 
  Hello,
 
  Does anyone have any scripts or know a location to point me to 
where I can
  dynamically create Microsoft Word documents using PHP.  I need to 
create
  some nicely formatted forms.  I could do this as text, however, this
  solution is not perfect because I don't know of an escape sequence 
for
  creating a new page.  I cannot do this using PDF because it's not
 installed
  on the servers I am using.  I could possibly do this in other 
formats if
 you
  know of any solutions.  Thank you.
 
  rswfire
 
 
 
  _
  Get your FREE download of MSN Explorer at 
http://explorer.msn.com/intl.asp
 
 
  --
  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: php-list-
[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: php-list-
[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] application design.

2001-12-07 Thread Kunal Jhunjhunwala

Hey,
Does anyone have any tips or papers on how to design a successfull
aplication in PHP? How to seperate each layer of information. I've read all
the documents @ phpbuilder, but was wondering how everyone else out there
went about making there appz.
Regards,
Kunal Jhunjhunwala


-- 
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] application design.

2001-12-07 Thread Kunal Jhunjhunwala

Hey,
Does anyone have any tips or papers on how to design a successfull
aplication in PHP? How to seperate each layer of information. I've read all
the documents @ phpbuilder, but was wondering how everyone else out there
went about making there appz.
Regards,
Kunal Jhunjhunwala


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

2001-12-07 Thread Rasmus Lerdorf

You probably used different ./configure flags to build the two.  Neither 
MySQL nor GD/PNG stopped working for me going from 4.0.4 to 4.0.6.

-Rasmus

On Fri, 7 Dec 2001, Robert Covell wrote:

 A question about different release versions of PHP.
 
 Why do things like png from gd 1.8 work in 4.0.4p1 and stops working in
 4.0.6?  We had to go back to 4.0.4p1.  I have seen similar things with mysql
 support.  We used the same config script for each version.  Any ideas?
 
 
 


-- 
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] Trying to pass a variable through a form...

2001-12-07 Thread Bryant Brabson

Your homework is finished!

TonyForm.html:
HTML
FORM ACTION=Tony1.php  METHOD=post
Name: INPUT TYPE=text NAME=lname br
INPUT TYPE=Submit  VALUE=Go
/FORM
/HTML

tony1.php
?
 $lname = $HTTP_POST_VARS['lname'];
?
html
body
?
echo (Welcome $lname);
?
A HREF=Tony2.php?name=?echo($lname) ? Link /A
/body
/html

tony2.php
?
 $name = $HTTP_GET_VARS['name'];
?
html
body
?
echo (Hello $name);
?
/body
/html


I'm trying to pass a variable from a form text box into a php file
(Tony1.php).

Then, I'd like to click on a link in the Tony1.php page and get the
Tony2.php page to load with the original variable -$lname - printed on the
next page (Tony2.php).

The Tony2.php loads when I click the link but the value from the variable is
not printed.

Any help would be greatly appreciated.
The code is below.
Tony Ritter
...


file://TonyForm.html//

HTML
FORM ACTION=Tony1.php  METHOD=get
Name: INPUT TYPE=text NAME=lname br
INPUT TYPE=Submit  VALUE=Go
/FORM
/HTML

.
file://Tony1.php//

?
echo (Welcome $lname);
?
A HREF=Tony2.php?name=?echo($lname) ? Link /A


...
file://Tony2.php//

Hello


-- 
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] database with php code

2001-12-07 Thread Sergio Mergen


Hello

 
in my database i have records that contain php code.
i want to put these content on a php file. 
Here´s the problem:  
Suppose the content returned from the Db is:
$codeFromDB = ?do some processing?;


if i do:
echo $codeFromDB;

i´d be writing the content to the returned html file, bu i´d like
the content to be processed by php. I suppose echo is not the way to do it.. 
So what can i do??

thanks for your time



Sérgio Mergen
Web developer VIAVALE Internet



Re: [PHP] database with php code

2001-12-07 Thread Andrey Hristov

strip the ? and ? from the strings and do
eval();

HTH

Regards,
Andrey Hristov
- Original Message -
From: Sergio Mergen [EMAIL PROTECTED]
To: php List (E-mail) [EMAIL PROTECTED]
Sent: Friday, December 07, 2001 9:39 PM
Subject: [PHP] database with php code



Hello


in my database i have records that contain php code.
i want to put these content on a php file.
Here´s the problem:
Suppose the content returned from the Db is:
$codeFromDB = ?do some processing?;


if i do:
echo $codeFromDB;

i´d be writing the content to the returned html file, bu i´d like
the content to be processed by php. I suppose echo is not the way to do it..
So what can i do??

thanks for your time



Sérgio Mergen
Web developer VIAVALE Internet



-- 
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] problem with pdf_set_font

2001-12-07 Thread Philippe Allart

Hi,

I've recently ugraded to apache-1.3.19-6  and pdflib-3.02-52  via SuSE 7.1.

An application which worked before has now a problem with pdf_set_font.

First, it didn't find pdflib.upr, which however were present in the font 
dirctory of pdflib. I've found in the doc that the location of this file, 
under linux, must be specified in the environment, otherwise the file must be 
in the current directory. OK.

Now, I get this error message:

Fatal error: Internal pdflib error: Unknown encoding '1' in 
/data/htdocs/aful/cartes/visite.php3 on line 88

I've also this error this the value 4.
Once again, it worked very welle before. 

What is the problem?

Thanks for helping!

Philippe Allart.

-- 
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] database with php code

2001-12-07 Thread Sergio Mergen

thanks guys..

your suggestion worked.. but there´s a problem..
the code i´m storing on a database mixs phpcode with html, like this:

?echo php code?
br
now it´s html
br
?echo now it´s php again?

how can i deal with that??
one solution would be to split the string into
a php code array and a html code array, and then,
depending on the case, use echo or eval..
but that´s is too much trouble...
could it be an easier way to work these thing around??

thanks again for the replies


Sérgio Mergen


 strip the ? and ? from the strings and do
 eval();

 HTH

 Regards,
 Andrey Hristov
 - Original Message -
 From: Sergio Mergen [EMAIL PROTECTED]
 To: php List (E-mail) [EMAIL PROTECTED]
 Sent: Friday, December 07, 2001 9:39 PM
 Subject: [PHP] database with php code



 Hello


 in my database i have records that contain php code.
 i want to put these content on a php file.
 Here´s the problem:
 Suppose the content returned from the Db is:
 $codeFromDB = ?do some processing?;


 if i do:
 echo $codeFromDB;

 i´d be writing the content to the returned html file, bu i´d like
 the content to be processed by php. I suppose echo is not the way to do
it..
 So what can i do??

 thanks for your time



 Sérgio Mergen
 Web developer VIAVALE Internet





-- 
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] Mutex Access Available?

2001-12-07 Thread Thomas

Is there any mutex access with PHP or just the SysV semaphores?



-- 
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] database with php code

2001-12-07 Thread Mark Roedel


I vaguely remember there being something about this in the user notes at
http://php.net/eval

If I remember correctly, it was something along the lines of adding a ?
to the beginning of your string, and a ? to the end.


---
Mark Roedel |  Blessed is he who has learned to laugh
Systems Programmer  |   at himself, for he shall never cease
LeTourneau University   |   to be entertained.
Longview, Texas, USA|   -- John Powell 

 -Original Message-
 From: Sergio Mergen [mailto:[EMAIL PROTECTED]] 
 Sent: Friday, December 07, 2001 2:08 PM
 To: Andrey Hristov
 Cc: [EMAIL PROTECTED]
 Subject: Re: [PHP] database with php code
 
 
 thanks guys..
 
 your suggestion worked.. but there´s a problem..
 the code i´m storing on a database mixs phpcode with html, like this:
 
 ?echo php code?
 br
 now it´s html
 br
 ?echo now it´s php again?
 
 how can i deal with that??
 one solution would be to split the string into
 a php code array and a html code array, and then,
 depending on the case, use echo or eval..
 but that´s is too much trouble...
 could it be an easier way to work these thing around??
 
 thanks again for the replies
 
 
 Sérgio Mergen
 
 
  strip the ? and ? from the strings and do
  eval();
 
  HTH
 
  Regards,
  Andrey Hristov
  - Original Message -
  From: Sergio Mergen [EMAIL PROTECTED]
  To: php List (E-mail) [EMAIL PROTECTED]
  Sent: Friday, December 07, 2001 9:39 PM
  Subject: [PHP] database with php code
 
 
 
  Hello
 
 
  in my database i have records that contain php code.
  i want to put these content on a php file.
  Here´s the problem:
  Suppose the content returned from the Db is:
  $codeFromDB = ?do some processing?;
 
 
  if i do:
  echo $codeFromDB;
 
  i´d be writing the content to the returned html file, bu i´d like
  the content to be processed by php. I suppose echo is not 
 the way to do
 it..
  So what can i do??
 
  thanks for your time
 
 
 
  Sérgio Mergen
  Web developer VIAVALE Internet
 
 
 
 
 
 -- 
 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] application design.

2001-12-07 Thread Jason Lotito

I would suggest Web Application Development with PHP 4.0 
ISBN: 0-7357-0997-1

Excellent book, covering developing applications, methodologies,
concepts and theories, and using PHP to do the work.  A bit old (July
2000) but covers well the concepts.

Jason Lotito
[EMAIL PROTECTED]
www.NewbieNetwork.net

 -Original Message-
 From: Kunal Jhunjhunwala [mailto:[EMAIL PROTECTED]] 
 Sent: Friday, December 07, 2001 1:27 PM
 To: [EMAIL PROTECTED]
 Subject: [PHP] application design.
 
 
 Hey,
 Does anyone have any tips or papers on how to design a 
 successfull aplication in PHP? How to seperate each layer of 
 information. I've read all the documents @ phpbuilder, but 
 was wondering how everyone else out there went about making 
 there appz. Regards, Kunal Jhunjhunwala
 
 
 -- 
 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] are this bug fixed ?

2001-12-07 Thread Alawi

http://www.securitywatch.com/newsforward/default.asp?Aid=8684




[PHP] incorrect results from is_dir

2001-12-07 Thread Tom Beidler

I'm getting TRUE from is_dir when no directory exists. Here's my code;

//Find out if there is an image folder existing
$image_folder = floor ($service_datex[1]) . _ . floor ($service_datex[2])
. _ . $service_datex[0] . _ . $site_id;

chdir('site_images');

if (is_dir($image_folder) == TRUE) {
$folder_exists = yes;
} else {
$folder_exists = no;
}

Everything comes up TRUE whether the directory exists or not. Any help
greatly appreciated. Running on UNIX.

Thanks,
Tom


-- 
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] are this bug fixed ?

2001-12-07 Thread Rasmus Lerdorf

Not really a bug.  If you do not trust users who are writing scripts on 
your system, you are basically out of luck.  There are all sorts of things 
you can do in a PHP script that will chew away on system resources.

-Rasmus

On Fri, 7 Dec 2001, Alawi wrote:

 http://www.securitywatch.com/newsforward/default.asp?Aid=8684
 
 


-- 
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] MySQL Native Function in PHP Query Not Working?

2001-12-07 Thread ISE

Hello,

Can someone explain to me why the below SQL query when executed with the PHP
mysql functions does not work? (it returns nothing)

SELECT * FROM table WHERE aid=LAST_INSERT_ID()

If I replace the MySQL function LAST_INSERT_ID() with a integer, it works
fine so its not the query.  Further, I was returned results on the above
query when I ran it directly from a MySQL client.  Does PHP not support
certain MySQL native functions?


Thanks,

Michael Caplan
Institute for Social Ecology
http://www.social-ecology.org/

1118 Maple Hill Road
Plainfield, VT, 05667 USA

Tel.: 1 (514) 421-3515
General Tel. / Fax.: 1 (802) 454-8493


-- 
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] database with php code

2001-12-07 Thread Sergio Mergen

nice !

Sérgio Mergen


I vaguely remember there being something about this in the user notes at
http://php.net/eval

If I remember correctly, it was something along the lines of adding a ?
to the beginning of your string, and a ? to the end.


---
Mark Roedel |  Blessed is he who has learned to laugh
Systems Programmer  |   at himself, for he shall never cease
LeTourneau University   |   to be entertained.
Longview, Texas, USA|   -- John Powell

 -Original Message-
 From: Sergio Mergen [mailto:[EMAIL PROTECTED]]
 Sent: Friday, December 07, 2001 2:08 PM
 To: Andrey Hristov
 Cc: [EMAIL PROTECTED]
 Subject: Re: [PHP] database with php code


 thanks guys..

 your suggestion worked.. but there´s a problem..
 the code i´m storing on a database mixs phpcode with html, like this:

 ?echo php code?
 br
 now it´s html
 br
 ?echo now it´s php again?

 how can i deal with that??
 one solution would be to split the string into
 a php code array and a html code array, and then,
 depending on the case, use echo or eval..
 but that´s is too much trouble...
 could it be an easier way to work these thing around??

 thanks again for the replies


 Sérgio Mergen


  strip the ? and ? from the strings and do
  eval();
 
  HTH
 
  Regards,
  Andrey Hristov
  - Original Message -
  From: Sergio Mergen [EMAIL PROTECTED]
  To: php List (E-mail) [EMAIL PROTECTED]
  Sent: Friday, December 07, 2001 9:39 PM
  Subject: [PHP] database with php code
 
 
 
  Hello
 
 
  in my database i have records that contain php code.
  i want to put these content on a php file.
  Here´s the problem:
  Suppose the content returned from the Db is:
  $codeFromDB = ?do some processing?;
 
 
  if i do:
  echo $codeFromDB;
 
  i´d be writing the content to the returned html file, bu i´d like
  the content to be processed by php. I suppose echo is not
 the way to do
 it..
  So what can i do??
 
  thanks for your time
 
 
 
  Sérgio Mergen
  Web developer VIAVALE Internet
 
 



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

2001-12-07 Thread Elsi

While not new to programming, I am new to PHP and to Linux, hence these
'getting started' questions.

I recently installed Red Hat Linux 6.2 and have discovered that it came
with PHP (3.0.15) already installed and configured.  I've written a
couple of [simple] forms handling routines and am getting more
comfortable with using PHP.

Looking around many of the PHP resource sites, I've seen a couple of
functions and applications that I think would be useful, both to add to
my web site and as a learning experience.  But, many of them require
MySQL.  No problem -- I think.

1. I'm presuming that GDBM isn't an alternative to MySQL.  Is this
correct?

2. I need to install MySQL.  The MySQL web site offers 3.23.46, but
there is mention of Linux kernel 2.2.14 having problems and recommending
upgrading to 2.2.19.  Shoot!  I think my system is 2.2.5.  So my next
question is -- will MySQL 3.23.46 run with the Linux level I have
installed or do I have to upgrade Linux first?

3. After installing MySQL, I then have to get it working with PHP.  In
at least one PHP documentation, I noticed that it said MySQL had to be
installed before PHP.  Third question - do I have to reinstall PHP?

4. If the answer to #3 is 'no' and I can use the existing PHP
installation, I now have question #4.  phpinfo() returns the
configuration information and I only see '--with-gdbm' and not
'--with-mysql' so I see that I need to update the PHP configuration.  I
scanned through the PHP Manual located at http://www.php.net/manual/en/
and I can't find how this is done.  (Please don't tell me that I have to
recompile PHP!)  Also, looking at php3.ini, I don't see anything that
looks like the '--with' stuff, though there are some MySQL parameters in
the file.  So my final question (for now) is how do I change/update the
PHP configuration.

Many thanks for any help offered.

Regards,
Elsi

-- 
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] Finding num of days b/t two dates.

2001-12-07 Thread Alex Fritz

If somebody could help me with this, it would save me a lot of heartache.  I
thought that this would be simple, but I can't seem to find a function
anywhere in PHP that has this capability and I can't seem to find any
external libraries for anything actually.  I need to be able to give PHP a
start date and an end date and have it return the number of days between the
dates.  If the first date is more recent than the second, I need it to give
me a negative number.  Can somebody please help?

Alex



-- 
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] Comparison between string failing

2001-12-07 Thread mweb

Hello,

I can't understand why the piece of test code below produces the output :
OK HERE
VALUE 0:image/pjpeg;
UPLOAD FAILED = ;
VALUE =1:image/pjpeg;

Basically I use or print several times the value 
$MYFILES['file_recensione']['tmp_name'][1] 
and it looks like it changes values from line to line (it's not a scope 
thing, I'm almost sure in this case: what is below is the whole file). Look 
at the line below with the string ESTENSIONE, it should be printed instead 
of UPLOAD FAILED, right?
Why doesn't it happen?

mweb
//
global $MYFILES;
$MYFILES['file_recensione']['tmp_name'][1] = 'image/pjpeg';
if ($MYFILES['file_recensione']['tmp_name'][1] == 'image/pjpeg') {print OK 
HEREHR;}
print VALUE 0:.$MYFILES['file_recensione']['tmp_name'][1].;HR;
if (/*is_uploaded_file($MYFILES['file_recensione']['tmp_name'][1])*/
//($VAL == 1)(
($MYFILES['file_recensione']['type'][1] == 'image/jpeg') ||
($MYFILES['file_recensione']['type'][1] == 'image/pjpeg') ||
($MYFILES['file_recensione']['type'][1] == 'image/gif')
// )
) {
$EXTGIF = 'jpg';
if (substr($MYFILES['file_recensione']['type'][1], -3) =='peg') { 
$EXTGIF = 'jpg';}
if (substr($MYFILES['file_recensione']['type'][1], -3) =='gif') { 
$EXTGIF = 'gif';}
print ESTENSIONE = $EXTGIF;BR;
} else {print UPLOAD 
FAILEDBR.$MYFILES['file_recensione']['type'][1].;BR;}
print VALUE =1:.$MYFILES['file_recensione']['tmp_name'][1].;HR;

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

2001-12-07 Thread Matthew Moreton

Hi people.  I am having some trouble with the PREG functions in php.

Here's what I am trying to do...

First of all I am reading in a file which is 1.5mb's in size, it could be many more, 
going up to 8mb's, the contents of the file is input to a string.

The format of the file is as follows...

###quoted textquoted text##

the # represents a number, in the case of the first 3 numbers they are only ever 1 or 
2 digits long.  The final two digits can get to be rather big in size, thousands and 
millions.  Each element is seperated by a tab space and then a carriage return (\r) 
terminates each record.

I use preg_match_all to find all the lines that start with 1 and 1 as there first 
numbers, typically there will be 25 entries of 1 1.  So I am looking for all lines in 
this format:

11#quoted textquoted text##

I have the search pattern figured out, it is as follow:

preg_match_all(/($first)\t($second)\t([0-9]{1,2})\t\([^\]*)\\t\([^\]*)\\t([0-9]*)\t([0-9]*)\r/,
 $input, $output, PREG_SET_ORDER );

When this pattern finds a matching line beginning equal to $first and $second it will 
put all the elements of the record into the array $output. $output[0] being the array 
of the first elements found, $array[1] being the second line that was matched, and so 
on.

This pattern does actually work to some extent.  When the filesize is low (100kb) it 
works fine, but when I start to get over that filesize it becomes greedy and the 
$second value doesnt seem to be taken into account when it searchs.  It seems to 
return everything that equals the following:

1##quoted textquoted text##

Obviously not what I want.  Could this be some sort of overflow problem?  I am at a 
lost end here, so if anyone could offer some insight as to why it is not functioning 
correctly I would most welcome it.  Overwise the only solution I can think of is 
chopping up the input, I dont really want to go down that path, as it seems like a 
rather cheap workaround.

Thanks.

Matt



Re: [PHP] Finding num of days b/t two dates.

2001-12-07 Thread Steve Cayford

Here's one way to do it by converting dates into timestamps.
?php

$date1 = mktime(0,0,0,10,1,2001); // in the form (hours, minutes, 
seconds, month, day, year)
$date2 = mktime(0,0,0,10,1,2000);
$timedif = $date1 - $date2;

print(strftime(date 1 is %b %d, %Y, $date1) . br\n);
print(strftime(date 2 is %b %d, %Y, $date2) . br\n);
print(the difference in seconds is  . $timedif . br\n);
print(the difference in days is  . ($timedif / (60 * 60  * 24)) . 
br\n);
?

-Steve

On Friday, December 7, 2001, at 04:48  PM, Alex Fritz wrote:

 If somebody could help me with this, it would save me a lot of 
 heartache.  I
 thought that this would be simple, but I can't seem to find a function
 anywhere in PHP that has this capability and I can't seem to find any
 external libraries for anything actually.  I need to be able to give 
 PHP a
 start date and an end date and have it return the number of days 
 between the
 dates.  If the first date is more recent than the second, I need it to 
 give
 me a negative number.  Can somebody please help?

 Alex



 --
 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 + MySQL problem (strange behavior)

2001-12-07 Thread Javier Muniz

Unfortunately, mysql returns no error string.  MySQL doesn't appear to think
it's
an error, as it does apply changes to the row I'm trying to change, it
simple isn't
applying the CORRECT change to said row :)

-Javier

-Original Message-
From: David Robley [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, December 05, 2001 4:59 PM
To: Javier Muniz; '[EMAIL PROTECTED]'
Subject: Re: [PHP] PHP + MySQL problem (strange behavior)


On Thu,  6 Dec 2001 08:32, Javier Muniz wrote:
 Hello,

 I'm having trouble determining what's going wrong with a MySQL query
 that I'm doing from PHP.  Now before you go blaming MySQL read on :)

 I have a table with the following columns:
 id (int)
 name (varchar 20)
 starttime (int)
 duration (int)

 now, i have a row that has a starttime of 60, when i attempt to do the
 following update with PHP, it sets it to 0:

 UPDATE mytable SET starttime=starttime-30 WHERE name = 'myname'

 but when I run it from the MySQL command line, copy/pasted from the
 code, it sets the value of starttime to 30 as expected.

 Anyone have any clue why this is?

mysql_error() is a good debugging tool; it will return an error string 
that may be useful.

-- 
David Robley  Techno-JoaT, Web Maintainer, Mail List Admin, etc
CENTRE FOR INJURY STUDIES  Flinders University, SOUTH AUSTRALIA  

   A waist is a terrible thing to mind.

-- 
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: Image problem

2001-12-07 Thread Andrew Chase

PHP needs to be compiled with libjpeg and libpng in addition to the GD
library to use those formats respectively.   The PHP manual section covering
image functions (including those for manipulating JPEGs and PNGs) is at

http://www.php.net/manual/en/ref.image.php

-Andy


 -Original Message-
 From: Peter Lalka [mailto:[EMAIL PROTECTED]]
 Sent: Friday, December 07, 2001 5:50 AM
 To: [EMAIL PROTECTED]
 Subject: Re: [PHP] Re: Image problem



 Thanks, in phpinfo list really isn't support for GIF:(
 How can I manipulate jpeg images? Which functions are for this
 img. format?
 P.


 |+-
 ||  Johan [EMAIL PROTECTED] |
 ||  Odoslané kým:  |
 ||  php-general-return-77040-lalkap=emo.seas.sk@lis|
 ||  ts.php.net |
 || |
 || |
 ||  07.12.2001 14:30   |
 || |
 |+-

 -
 --|
   |
 |
   | Komu:   [EMAIL PROTECTED]
 |
   | Kópia:
 |
   |   Predmet:[PHP] Re: Image problem
 |

 -
 --|



  I've instaled and cofigured php4 on WinNT with Apache Web server.
  I can't use any fuction of Image manipulation, 'cause I get this error
  message: ImageGif: No GIF support in this PHP build
  In phpinfo() is listed that: gd lib. enabled, zlib lib. enabled.
  What do I still miss there?

 In the newest version of GD library (think it since about 1.3 or
 something)

 does support GIF, because GIF is a commerial image format.

 Use PNG or JPEG instead. That much better, or find a version with GIF
 support.

 You can see what Image formats you GD can use by make a file with follow
 content:
 ?php
 phpinfo();
 ?

 :o)

 Regards,

 Johan

 --
 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] RegEx gurus help...

2001-12-07 Thread Brian V Bonini

I need to replace all relative links in an html
doc with absolute links on the fly weather it
be an image link,
img src='/_imgs/imgs_nav/transPix.gif' width='10' height='13'
img src='../_imgs/imgs_nav/transPix.gif' width='10' height='13'

a URL,
a href=/dealers/index.asp

a link to an external JS file
script language='JavaScript' src='/_js/scripts.js'
type='text/javascript'/script

or external css file.
link rel=stylesheet href=../_css/style.css type=text/css

Anyone done this before and have a prefab regex laying
around they want to share?

-Brian


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP] phpautodoc

2001-12-07 Thread Malcolm Clark

I'm trying to get this GNU stuff from
http://sourceforge.net/projects/phpautodoc to work. These are the
instructions for use

---
[php] phpdoc.php [php interpreter options] file(s) [-- -o output path]

Scans the specified PHP source files (given directories are searched
recursively - default: .) and writes HTML files to the specified output path
(default: .).

--


Can any body give me an example of this syntax? I'm a completely baffled
intermediate.

TIA

Malcolm, UK


-- 
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] ASP aplication object

2001-12-07 Thread Max

Hi,

Is exist something similar in PHP?

Regards.
Max.

-- 
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] Re: Comparison between string failing

2001-12-07 Thread Fred

I would like to start by saying that your code is horribly confusing.  Try
taking all those commented out parts out of the script before you post to
the group.

That said, your problem is that you left out a closing curly brace.  Try
this:

 global $MYFILES;
 $MYFILES['file_recensione']['tmp_name'][1] = 'image/pjpeg';
 if ($MYFILES['file_recensione']['tmp_name'][1] == 'image/pjpeg') {print
OK
 HEREHR;}
 print VALUE 0:.$MYFILES['file_recensione']['tmp_name'][1].;HR;
 if (/*is_uploaded_file($MYFILES['file_recensione']['tmp_name'][1])*/
 //($VAL == 1)  (
 ($MYFILES['file_recensione']['type'][1] == 'image/jpeg') ||
 ($MYFILES['file_recensione']['type'][1] == 'image/pjpeg') ||
 ($MYFILES['file_recensione']['type'][1] == 'image/gif')
 //)
 ) {
 $EXTGIF = 'jpg';
 if (substr($MYFILES['file_recensione']['type'][1], -3) =='peg') {
 $EXTGIF = 'jpg';}
 if (substr($MYFILES['file_recensione']['type'][1], -3) =='gif') {
 $EXTGIF = 'gif';}} // **ADDED CLOSING BRACE***
 print ESTENSIONE = $EXTGIF;BR;
 } else {print UPLOAD
 FAILEDBR.$MYFILES['file_recensione']['type'][1].;BR;}
 print VALUE =1:.$MYFILES['file_recensione']['tmp_name'][1].;HR;

Mweb [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]...
 Hello,

 I can't understand why the piece of test code below produces the output :
 OK HERE
 VALUE 0:image/pjpeg;
 UPLOAD FAILED = ;
 VALUE =1:image/pjpeg;

 Basically I use or print several times the value
 $MYFILES['file_recensione']['tmp_name'][1]
 and it looks like it changes values from line to line (it's not a scope
 thing, I'm almost sure in this case: what is below is the whole file).
Look
 at the line below with the string ESTENSIONE, it should be printed
instead
 of UPLOAD FAILED, right?
 Why doesn't it happen?

 mweb


//
 global $MYFILES;
 $MYFILES['file_recensione']['tmp_name'][1] = 'image/pjpeg';
 if ($MYFILES['file_recensione']['tmp_name'][1] == 'image/pjpeg') {print
OK
 HEREHR;}
 print VALUE 0:.$MYFILES['file_recensione']['tmp_name'][1].;HR;
 if (/*is_uploaded_file($MYFILES['file_recensione']['tmp_name'][1])*/
 //($VAL == 1)  (
 ($MYFILES['file_recensione']['type'][1] == 'image/jpeg') ||
 ($MYFILES['file_recensione']['type'][1] == 'image/pjpeg') ||
 ($MYFILES['file_recensione']['type'][1] == 'image/gif')
 //)
 ) {
 $EXTGIF = 'jpg';
 if (substr($MYFILES['file_recensione']['type'][1], -3) =='peg') {
 $EXTGIF = 'jpg';}
 if (substr($MYFILES['file_recensione']['type'][1], -3) =='gif') {
 $EXTGIF = 'gif';}
 print ESTENSIONE = $EXTGIF;BR;
 } else {print UPLOAD
 FAILEDBR.$MYFILES['file_recensione']['type'][1].;BR;}
 print VALUE =1:.$MYFILES['file_recensione']['tmp_name'][1].;HR;



-- 
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] Costum Error Page

2001-12-07 Thread Daniel Urstöger

Hi !

I hope you can help me with that problem :)
I have created a costum error page, and this one is working really fine,
already.
Was quite easy, but the problem I have now:
Somebody trys to access the file:  iamnothere.html
The requests, doesn´t find the file, so apache redirects the request to my
costum error page.
I can check http referer, and such stuff, BUT:
How could I check, which file apache tried to access, and didn´t found ?
That would be a pretty nice function for my PHP skript ..
Thx for your help !

cya !

Daniel Urstöger
WebMaster @ cdrsoft.info



-- 
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] Costum Error Page

2001-12-07 Thread Ashley M. Kirchner

Daniel Urstöger wrote:

 How could I check, which file apache tried to access, and didn´t found ?
 That would be a pretty nice function for my PHP skript ..

Check your REQUEST_URI variable.

--
H | Life is the art of drawing without an eraser. - John Gardner
  +
  Ashley M. Kirchner mailto:[EMAIL PROTECTED]   .   303.442.6410 x130
  Director of Internet Operations / SysAdmin. 800.441.3873 x130
  Photo Craft Laboratories, Inc.. 3550 Arapahoe Ave, #6
  http://www.pcraft.com . .  ..   Boulder, CO 80303, U.S.A.



-- 
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] Getting started - what do I need?

2001-12-07 Thread Indera

Hello,

I have never used php or mysql before and want to know what tools I should use so that 
I can start
learning php and mysql. I would like to build basic things like a login page and forms 
that append
the data to a database. I went to the bookstore and think the book PHP fast and easy 
web development
is something that I could handle. I've read through some of the posts on this news 
group and
realized that there are tools that I can use as front ends for these packages. I went 
to mysql.com
and php.net and it seems that i can download both of these packages to my computer for 
free. Any
help would be greatly appreciated.

Thanks
Indera



-- 
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] Getting started - what do I need?

2001-12-07 Thread Michael Hall


Yes indeed, PHP and MySQL are free ... welcome to the world of open source
software!

What type of computer operating system are you using? Does it have a web
server? You may want to consider downloading Apache as well (also
free).

There are lots of helpful tutorials on the net that can get you going if
you don't want to buy a book right away.

Mick

On Fri, 7 Dec 2001, Indera wrote:

 Hello,
 
 I have never used php or mysql before and want to know what tools I should use so 
that I can start
 learning php and mysql. I would like to build basic things like a login page and 
forms that append
 the data to a database. I went to the bookstore and think the book PHP fast and easy 
web development
 is something that I could handle. I've read through some of the posts on this news 
group and
 realized that there are tools that I can use as front ends for these packages. I 
went to mysql.com
 and php.net and it seems that i can download both of these packages to my computer 
for free. Any
 help would be greatly appreciated.
 
 Thanks
 Indera
 
 
 
 

-- 

Michael Hall
[EMAIL PROTECTED]
[EMAIL PROTECTED]
http://openlearningcommunity.org



-- 
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] Getting started - what do I need?

2001-12-07 Thread Matthew Moreton

I would suggest downloading PHPtriad.  It installs Apache, PHP and mySQL all
set up and ready to go.  http://www.phpgeek.com to get it.

The only resources I have used to teach myself php and mysql is the
documentation provided at www.php.net and www.mysql.com respectively.

Good luck

Matt

- Original Message -
From: Indera [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Saturday, December 08, 2001 3:44 AM
Subject: [PHP] Getting started - what do I need?


 Hello,

 I have never used php or mysql before and want to know what tools I should
use so that I can start
 learning php and mysql. I would like to build basic things like a login
page and forms that append
 the data to a database. I went to the bookstore and think the book PHP
fast and easy web development
 is something that I could handle. I've read through some of the posts on
this news group and
 realized that there are tools that I can use as front ends for these
packages. I went to mysql.com
 and php.net and it seems that i can download both of these packages to my
computer for free. Any
 help would be greatly appreciated.

 Thanks
 Indera



 --
 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] why didnt you come watch me like you said you would?

2001-12-07 Thread

Diese Daten wurden Ihnen von Ihrem OnlineFormular geschickt.  Es wurde erstellt von
 ([EMAIL PROTECTED]) am 8 Dezember ,Samstag , 2001 um 07:57:27
---

: hey babe, it's karina remember me? if you don't im 5'8 with brown hair and blue 
:eyes with an ass you can bounce a quarter off of :-) Im 21 years old and im in my 
:final year of college at OSU in OREGON! i just got my first webcam and i love meeting 
:new people on it and just showing my body off. i want you to come watch me do a 
:striptease! my website is located at: http://www.karinaswebcam.com and i have a 
:backup the url is 
:http://info.netscape.com/fwd/hophb5/http://srd.yahoo.com/srst/56353520/as/4/25452/*http:[EMAIL PROTECTED]/xpdro?http://members.aol.com/katrinarockz/katrina.html
: if that doesnt work try http://hometown.aol.com/vajerr/ ~ LOVE ALWAYS! -Karina 
:XOXOXO33

---


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




Fw: [PHP] Need a script that will read Apache Log files and generate reports

2001-12-07 Thread Papp Gyozo

maybe this is what you need.

- Original Message - 
From: Chris Allen [EMAIL PROTECTED]
To: Dan McCullough [EMAIL PROTECTED]; PHP General List 
[EMAIL PROTECTED]
Sent: Monday, November 26, 2001 11:21 PM
Subject: Re: [PHP] Need a script that will read Apache Log files and generate reports


| http://www.analog.cx/
| Subject: [PHP] Need a script that will read Apache Log files and generate
| reports
| 
| 
| 
| 
| -- 
| 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   >