php-windows Digest 16 Dec 2002 02:44:34 -0000 Issue 1488
Topics (messages 17409 through 17416):
!Imagettftext() lib_gd2 ttf font problem Solution!
17409 by: owczi \(Wojciech Owczarek\)
Installing PEAR on windows
17410 by: Davy Obdam
Per site php.ini
17411 by: Charles P. Killmer
Re: newbie question (forms)
17412 by: Luis Ferro
need explanation about includes
17413 by: Davide
question about includes
17414 by: Davide
Re: php-windows Digest 14 Dec 2002 22:32:58 -0000 Issue 1487
17415 by: Neil Smith
session
17416 by: bump
Administrivia:
To subscribe to the digest, e-mail:
[EMAIL PROTECTED]
To unsubscribe from the digest, e-mail:
[EMAIL PROTECTED]
To post to the list, e-mail:
[EMAIL PROTECTED]
----------------------------------------------------------------------
--- Begin Message ---
Hi, I've recently found a way out from that nasty php + win32 problem with
imagettftext() that can't find/open fontfile.
Apparently sth was compiled wrong, so that lib_gd2 bastart won't let anyone
override it's original path.
The solution is to put your ttf files into:
c:\winnt\fonts
dir
(that path is compiled into lib_gd2.dll)
so when you copy like arial.ttf there,
then all you need to do is use "arial" as the font parameter and it WORKS.
Enjoy :>
----owczi the humble sheep
--- End Message ---
--- Begin Message ---
Hi people,
I have a question, i would like to use PEAR in some of my applications,
how can i download and iinstall PEAR on windows. I have Apache 2.0.43
with PHP 4.3.0 RC3 installed on a windows XP machine. I read on
http://pear.php.net/manual/en/faq.windows.php .....
To make PEAR work on Windows, you simple need to add the PEAR
installation dir (e.g. c:\php\pear) to the include_path directive in
your php.ini.
Well i thats easy, but i dont have a pear directory? Making a new
directory is easy also;-), but...... How and where do i download and
instal the PEAR packages on my machine... Thanks...
Best regards,..
Davy Obdam
mailto:[EMAIL PROTECTED]
--- End Message ---
--- Begin Message ---
Does anyone know how to configure PHP to have per website ini files. I
am using IIS 5.0 on Windows 2000 Server. I have searched and only found
people asking. I have found a few responses but only for servers with
Apache. And while I would love to switch, that is not my decision. Oh
well.
Any help is appreciated
Thanks
Charles Killmer
--- End Message ---
--- Begin Message ---
Better yet:
<?php
if (!isset($a)) {
$a = "";
}
echo $a;
?>
If the user passes something in the form, you will see it in the page,
if not, it will show a empty string (which is equal to nothing in web,
but avoids the warning).
Always take note to the warnings... they can be just warnings, but
normally, having warnings such as this will only show bad programming
tecnics in use... and will show of a badly programmed site (which by
itself can be a security problem).
Cheers,
Luis Ferro
TelaDigital.Net
Dash McElroy wrote:
This probably has to do with one/both of two things:
1. register_globals is off (not a bad thing - just requires a tidbit more
code. see http://php.net/register_globals)
2. A variable is being called before it has been initialized.
Example PHP script:
<?php
echo $a;
$a = "Hello World";
echo $a;
?>
First you will get the undefined variable message, then "Hello World" (w/o
quotes). Leaving a variable uninitialized before you use it can be a very
bad thing. If your code uses that variable to do something and it's forged
by Joe Black Cracker (i.e. http://host/page.php?var=forged" - not hard to do
at all) you could end up getting incorrect results or worse.
What can you do about this?
1. You can ignore the errors and make the reporting of them go away. Change
your Error Reporting in php.ini to a different level (see
http://php.net/error_reporting for the levels and what they do). Restart
your web server after this change is made (unless you use PHP as CGI, but
safest just to restart it).
2. You can initialize the variables in the script before you use them.
Example of 2:
<?php
$a = "";
//php stuff here
echo $a;
?>
Good luck and have fun.
-Dash (.php)
-----Original Message-----
From: Elvin Certeza [mailto:[EMAIL PROTECTED]]
Sent: Thursday, December 12, 2002 1:52 PM
To: php
Subject: [PHP-WIN] newbie question (forms)
I have just recently installed apache and php into my system (win98).
The system test is ok....(showing php pages)
Now for the question...
I've created a form.. (rather cut and paste a form). This form works online
I have tested it myself.. but locally it gives me an error..
When my php page loads it tells me "Notice: Undefined variable" at line
whatever.. etc..
So what I've done it tested it online to see if it's the code...(full
knowing that code works..since it's a cut out from a tutorial showing it's
samples).. and it does work..
So the question is .. is there anything missing from my local server ???
Elvin
---
[This E-mail scanned for viruses by Declude Virus]
--- End Message ---
--- Begin Message ---
I have installed php-4.3.0 (I tried 4.2. but I couldn't make Apache2 to run
with it here in win32). Now I noticed a different behaviour in respect of
4.0.6 installed before.
I use php_lib_login 0-9b to manage session login and I found it nice and
quite reliable for my job; but when i went to test my scripts with new
version of php i got no output from them. I disabled the include of
php_lib_login and they are ok. After some trouble i found the problem:
from php_lib_login :
@include("php_lib_login_includes/adodb/adodb.inc.php"); // *
@include("adodb/adodb.inc.php"); //ugly but prevents user from fiddling with
paths
@include("php_lib_login_includes/languages.inc.php"); // *
@include("languages.inc.php");
disabling the 2 lines I marked with * the scripts runs ok.
Someone can tell me where is the problem? many thanks.
N.B. If i put the entire scripts php_lib_login inline in my scripts all is
ok without removing the two incudes.
Davide.
--- End Message ---
--- Begin Message ---
I have installed php-4.3.0 (I tried 4.2. but I couldn't make Apache2 to run
with it here in win32). Now I noticed a different behaviour in respect of
4.0.6 installed before.
I use php_lib_login 0-9b to manage session login and I found it nice and
quite reliable for my job; but when i went to test my scripts with new
version of php i got no output from them. I disabled the include of
php_lib_login and they are ok. After some trouble i found the problem:
from php_lib_login :
@include("php_lib_login_includes/adodb/adodb.inc.php"); // *
@include("adodb/adodb.inc.php"); //ugly but prevents user from fiddling with
paths
@include("php_lib_login_includes/languages.inc.php"); // *
@include("languages.inc.php");
disabling the 2 lines I marked with * the scripts runs ok.
Someone can tell me where is the problem? many thanks.
N.B. If i put the entire scripts php_lib_login inline in my scripts all is
ok without removing the two incudes.
Davide.
--- End Message ---
--- Begin Message ---
GD comes with versions of PHP triad to my knowledge. You mean for apache
1.3 or apache 2? I think the version of this and other files may differ.
Have you searched your PHP and windows directories for this file? Its
called php_gd.dll and should be in your PHP extensions folder
If you don't have it I can probably forward a copy of mine - contact me off
list for this (its ca 408k)
Regards,
Neil Smith.
At 22:32 14/12/2002 +0000, you wrote:
----------------------------------------------------------------------
From: "Clay Culver" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Date: Sat, 14 Dec 2002 15:33:05 -0700
Message-ID: <002301c2a3c0$c594d930$1202a8c0@dark>
MIME-Version: 1.0
Content-Type: multipart/alternative;
boundary="----=_NextPart_000_0024_01C2A386.19360130"
Subject: GD Library
Hi,
I would like to know where I can download the gd library
that is already precompiled in to a dll. Seems every where I search it's
uncomplied and I do not have a complier on my system (nor the need nor
wish to install one). The server is a Windows server if that helps any,
running PHP 4.2.3 default install.
Clay
--- End Message ---
--- Begin Message ---
hi,
i have some problem about session in PHP
ok.. start
i write program like this.
session1.php
<?
session_start();
session_register("data3");
$data3="0123456789";
echo session_id();
?>
now i user Omnihttpd version2.10 for webserver and winXP on my Comp.
i open IE web browser
i try http://127.0.0.1/session1.php
This program display seesion'id is 8c15e05183ac143f7dc517e62be59957
in the same browser i press F5 to refresh this page
The session'id is changed .it not remember old value why??????
My program is wrong...
i know.i read the book it's tell me "session'id will change when close
browser and start new browser".. right??
after that i to use this program run at the real
server...(Linux+Apache+php4.12)
it's OK...the session'id is the same when i refresh this page the session'id
is the same too..
i don't know what happen???
please help me..
um..today i change Omnihttpd to Apache Webserver .it has the same problem..
thank you
krisda kosolkarn
[EMAIL PROTECTED]
--- End Message ---