Hello,
I have a problem when im trying to scale an jpeg image with libgd
my function lookes like this:
function image_resize_jpeg( $img, $w)
{
$image = imagecreatefromjpeg($img);
$img_info = getimagesize ($img);
$orig_height = $img_info[1]; //source hieght from $img_info
$orig_width =
Hi List,
How do I tell if pear is installed ?
If it is not, then how do I add it to my Php.
My Php is 4.3.0 on Unix system
Thanks for any help or advice
Dave C
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.687 / Virus
class B extends A {
function B() {
// call parents constructor
A::A();
}
}
- Markus
Why would you not use ...
class B extends A {
function B() {
{
parent::A();
}
}
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit:
Oôv asäönsson wrote:
...
Does anyone have any suggestion what i can do?
Just a wild guess..
What happens if You use imagecreatetruecolor() instead of imagecreate()
and imagecopyresampled() instead of imagecopyresized()?
--
Pavel a.k.a. Papi
--
PHP General Mailing List (http://www.php.net/)
To
PEAR doesn't need to be installed, so to speak.
PEAR is simply a set of classes, at heart, they can be downloaded and used
without problem from the pear.php.net website. However, PEAR does have an
installer program that allows you to install these packages from command
line.
To check if you have
Me for asking this question, I'm just not sure where to start but with the
experts here.
I'm moving my PHP and MySQL application to a hosting server. Currently, I'm
looking at 1and1.com's dedicated servers on a Linux machine for $49/month
(let me know if there are better choices). One
Thanks Aidan,
I get a list of installed packages.
What do I or one of my users need to do to access / use the DB package?
Any help, advice, example is very much appreciated.
Dave C
-Original Message-
From: Aidan Lister [mailto:[EMAIL PROTECTED]
Sent: 20 May 2004 13:04
To: [EMAIL
Hi I have recently installed gd-2.0.15 on my linux 9.0 machine and this machine has a
database that i need to access through phpMyadmin so the requirements are that php
should be installed but when I error this instruction I get this error;
[EMAIL PROTECTED] root]# apt-get install php
Reading
hello,
i face a problem with send mail via php.
i have a server with ms IIS and i have not access to php.ini
how i send a email with php script with auto add the sendmail_from into
php.ini ?
PS. i write a php script to send email but i receive the follow error
message
mail(): sendmail_from
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Hi All,
After having been talking to lots of people in irc lately who are
haveing problems with SQL injection etc i think that haveing a
*_queryf() function would be really useful to help people esp when it
comes to integers and the id=$id
All of this information is on the http://pear.php.net/ website.
A simple usage example of PEAR::DB is here:
http://pear.php.net/manual/en/package.database.db.intro-connect.php
Basically, once you've established that PEAR is installed the user simply
loads the script.
Eg.
?php
include_once
Hi Phillip,
For future reference, PHP install questions are best asked on the
[EMAIL PROTECTED] mailing list, however I'm sure someone can answer
your question here also.
Khutjo Phillip Leremi [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
Hi I have recently installed gd-2.0.15 on
If you need a better source example/layout goto:
http://nopaste.php-q.net/59720
William Bailey wrote:
Hi All,
After having been talking to lots of people in irc lately who are
haveing problems with SQL injection etc i think that haveing a
*_queryf() function would be really useful to help
On windows I believe this will work:
ini_set(sendmail_from,[EMAIL PROTECTED]);
Try that. http://www.php.net/ini_set
HTH
Craig
Tassos T [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
hello,
i face a problem with send mail via php.
i have a server with ms IIS and i have not
Ryan Schefke wrote:
snip
I'm moving my PHP and MySQL application to a hosting server. Currently, I'm
looking at 1and1.com's dedicated servers on a Linux machine for $49/month
(let me know if there are better choices). One problem though, the
dedicated server, unlike a shared server, does not
Hi there,
I am trying to install following cron job:
0 6 * * * php /home/www/project/app_cron/follow_up_new_members.php
The script works, if I run this php /home... line manually it works out, but
it does not automaticaly at 6 am as supposed.
I do also see in /var/log/messages that the cron job
[snip]
I am trying to install following cron job:
0 6 * * * php /home/www/project/app_cron/follow_up_new_members.php
The script works, if I run this php /home... line manually it works
out, but
it does not automaticaly at 6 am as supposed.
I do also see in /var/log/messages that the cron job
On Thursday 20 May 2004 11:35 am, Jay Blanchard wrote:
At the command line type which php and it will return the full path to
php. Modify your line in the crontab with the full path...
0 6 * * * /usr/local/bin/php
/home/www/project/app_cron/follow_up_new_members.php
I always put the
Hi all,
First off, yeah, it's a dumb Q ;-) but I cant remember enuf about mysql
to know if I need a php script or it might be done from the command
line...
I have a DB that has a field called 'body' - it holds the body of html
pages of course... What I need to do, is add to the very end of each
It looks like that cron line is making it so that the command runs as the
user php...
so, you should check if that user has permission to run the script.
Tim.
At 08:33 AM 5/20/2004, Merlin wrote:
Hi there,
I am trying to install following cron job:
0 6 * * * php
Nick Wilson wrote:
I have a DB that has a field called 'body' - it holds the body of html
pages of course... What I need to do, is add to the very end of each
html page, one short peice of text.. not a footer, just an adition to
every page.
UPDATE table SET body = body + text to append
will update
[snip]
Do I need to select the body, then add the text to
it, then UPDATE it
[/snip]
that is what you want to do
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
* and then Stuart declared
Nick Wilson wrote:
I have a DB that has a field called 'body' - it holds the body of html
pages of course... What I need to do, is add to the very end of each
html page, one short peice of text.. not a footer, just an adition to
every page.
UPDATE table SET
Is the text the same on every page?
Where you print your body, concatenate the string you want to your content
variable.
HTH
Nick Wilson [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
Hi all,
First off, yeah, it's a dumb Q ;-) but I cant remember enuf about mysql
to know if I
* and then Matt Matijevich declared
[snip]
Do I need to select the body, then add the text to
it, then UPDATE it
[/snip]
that is what you want to do
That's what I figured 2, but check the post above ;-)
thanks mate..
--
Nick W
--
PHP General Mailing List (http://www.php.net/)
To
If you know exactly what you need to append, then you can just do the
update query directly.
UPDATE tablename
SET body=concat(body,'string to add')
that should do it...
Tim
At 09:04 AM 5/20/2004, Nick Wilson wrote:
Hi all,
First off, yeah, it's a dumb Q ;-) but I cant remember enuf about mysql
* and then Nick Wilson declared
pages of course... What I need to do, is add to the very end of each
html page, one short peice of text.. not a footer, just an adition to
every page.
UPDATE table SET body = body + text to append
Hehe, it's been such a lng time since i did
* and then Nick Wilson declared
* and then Matt Matijevich declared
[snip]
Do I need to select the body, then add the text to
it, then UPDATE it
[/snip]
that is what you want to do
That's what I figured 2, but check the post above ;-)
Damn, looks like you were
* and then Tim Traver declared
If you know exactly what you need to append, then you can just do the
update query directly.
UPDATE tablename
SET body=concat(body,'string to add')
Awesome, that did it. Thanks for taking the time to show me dude ;-)
--
Nick W
--
PHP General Mailing
yeah, the + modifier thinks you mean you want to add them as integers...
use my previous post with the concat command and that works...
Tim.
At 09:20 AM 5/20/2004, Nick Wilson wrote:
* and then Nick Wilson declared
pages of course... What I need to do, is add to the very end of each
html
I'm trying to compose a general purpose text snip expression to extract
a text segment from a string.
Should this work for all reasonable cases? It seems to work for several
test strings.
$start= str1;
$end= str2;
preg_match (|$start (.*) ? $end |i, $contents, $text);
$segment= $text[1];
Torsten Roehr wrote:
Gabe [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
Torsten Roehr wrote:
Gabe [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
Torsten Roehr wrote:
Gabe [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
Environment:
PHP 4.3.6
Access DB
W2K IIS 5
I recently updated my Apache to 1.3.31 and when it was finished, none of
my PHP scripts are working correctly. They seem to stop in the middle
of displaying a page. On some pages, my footer doesn't come up, it just
quits before it gets there. I got on the PHP website to get the
instructions for
From: Nick Wilson [EMAIL PROTECTED]
* and then Nick Wilson declared
pages of course... What I need to do, is add to the very end of each
html page, one short peice of text.. not a footer, just an adition to
every page.
UPDATE table SET body = body + text to append
Hehe,
Martin, Stanley G [Contractor for Sprint] wrote:
I recently updated my Apache to 1.3.31 and when it was finished, none of
my PHP scripts are working correctly. They seem to stop in the middle
of displaying a page. On some pages, my footer doesn't come up, it just
quits before it gets there. I
I'm getting a segmentation fault in the Apache error log whenever I
access a page the doesn't finish.
Stanley G. Martin
System Administrator
Sprint - EAS Business Intelligence
[EMAIL PROTECTED]
-Original Message-
From: John Nichel [mailto:[EMAIL PROTECTED]
Sent: Thursday, May 20, 2004
From: Al [EMAIL PROTECTED]
I'm trying to compose a general purpose text snip expression to extract
a text segment from a string.
Should this work for all reasonable cases? It seems to work for several
test strings.
$start= str1;
$end= str2;
preg_match (|$start (.*) ? $end |i,
Martin, Stanley G [Contractor for Sprint] wrote:
I'm getting a segmentation fault in the Apache error log whenever I
access a page the doesn't finish.
Dear Contractor for Sprint,
What john meant was for you to share it (error message) with us.
Martin, Stanley G [Contractor for Sprint] wrote:
Gabe [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
Torsten Roehr wrote:
Gabe [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
Torsten Roehr wrote:
Gabe [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
Torsten Roehr wrote:
Gabe [EMAIL
Hi this error is causing me grief.
I installed mySQL Apache and PHP 5. in php.ini at the c:\WINDOWS I assigned the
extension dir as follows:
; Directory in which the loadable extensions (modules) reside.
extension_dir = c:\php\ext
the extension php_mysql.dll resides in this ext
On Thu, May 20, 2004 at 12:28:00PM -0400, Gabe wrote:
I'm trying to store a date in a date/time field using the short date
format ( m/d/ ). For some reason it won't let me post an empty
value to that field in the DB. I've tried using empty quotes ( )
I'm using Microsoft Access for my
What is wrong with whis syntax:
$array = array($_POST['input_1'],$_POST['input_2']);
--
+-+-++
| Blake Schroeder | Owner/Developer |lhwd.net|
+--(http://www.lhwd.net)+--/ \--+
--
PHP General Mailing List
Blake Schroeder [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
What is wrong with whis syntax:
$array = array($_POST['input_1'],$_POST['input_2']);
You don't need the double quotes:
$array = array($_POST['input_1'], $_POST['input_2']);
Regards,
Torsten
--
PHP General Mailing
OK. Here it is
[Thu May 20 11:52:41 2004] [notice] child pid 19615 exit signal
Segmentation fault (11)
Stanley G. Martin
System Administrator
Sprint - EAS Business Intelligence
[EMAIL PROTECTED]
-Original Message-
From: raditha dissanayake [mailto:[EMAIL PROTECTED]
Sent: Thursday,
Blake Schroeder wrote:
What is wrong with whis syntax:
$array = array($_POST['input_1'],$_POST['input_2']);
The error message you should get with it should tell youhowever,
I'll be if you remove the double quotes from around the $_POST
variables, it won't throw the same errors.
--
John C.
Martin, Stanley G [Contractor for Sprint] wrote:
OK. Here it is
[Thu May 20 11:52:41 2004] [notice] child pid 19615 exit signal
Segmentation fault (11)
Was php4.3.6 compiled with the same options as your previous version?
Just a guess here, but your scripts may be calling a function that
existed
When I ran configure for PHP I tried to use the --with-apache and
pointed it to /usr/local/apache but it told me it couldn't find httpd.h
anywhere under there and it is there
(/usr/local/apache/include/httpd.h). So, I ran it with
--with-apxs=/usr/local/apache/bin/apxs. It creates the file
Martin, Stanley G [Contractor for Sprint] wrote:
When I ran configure for PHP I tried to use the --with-apache and
pointed it to /usr/local/apache but it told me it couldn't find httpd.h
anywhere under there and it is there
(/usr/local/apache/include/httpd.h). So, I ran it with
Yes. I used --enable-module=so.
Stanley G. Martin
System Administrator
Sprint - EAS Business Intelligence
913.762.8667
913.221.8241 PCS
[EMAIL PROTECTED]
-Original Message-
From: John Nichel [mailto:[EMAIL PROTECTED]
Sent: Thursday, May 20, 2004 1:21 PM
To: [EMAIL PROTECTED]
Subject:
Martin, Stanley G [Contractor for Sprint] wrote:
-Original Message-
From: John Nichel [mailto:[EMAIL PROTECTED]
Sent: Thursday, May 20, 2004 1:21 PM
To: [EMAIL PROTECTED]
Subject: Re: [PHP] PHP 4.3.6
Martin, Stanley G [Contractor for Sprint] wrote:
When I ran configure for PHP I tried to
Mark Pecaut wrote:
On Thu, May 20, 2004 at 12:28:00PM -0400, Gabe wrote:
I'm trying to store a date in a date/time field using the short date
format ( m/d/ ). For some reason it won't let me post an empty
value to that field in the DB. I've tried using empty quotes ( )
I'm using Microsoft
Torsten Roehr wrote:
Gabe [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
Torsten Roehr wrote:
Gabe [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
Torsten Roehr wrote:
Gabe [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
Torsten Roehr wrote:
Gabe [EMAIL
If I have multiple instances that match the pattern, but only want the
first one, which is the best way to handle it?
Putting the U flag seems to work, but I don't understand the full
implications of using it here.
preg_match(|$start(.*?)$end |Ui, $contents, $text);
Alternatively, I could use
I went back to PHP 4.3.1. I still had the src directory from when I
installed it. When I configured PHP 4.3.6 like this:
./configure --with-apache=/app_source/Apache/apache_1.3.31 --with-mysql
it's supposed to create libmodphp4.a library in
/app_source/Apache/apache_1.3.31/src/modules/php4,
Hi all. Hopefully someone here can show me what I am doing wrong. I am
trying to write a small script to ftp into a server and retrieve a
listing. I am using the Pear module Net_FTP for this. I am able to
connect to the server, but I cannot get a directory listing to work. Here
is my
All the examples I see of socket_select() are on socket servers. But is
it reasonable/feasible to use socket_select() on a socket client, that
is receiving data periodically from a server (and when not receiving,
doing something else)?
...Rene
--
PHP General Mailing List (http://www.php.net/)
Al mailto:[EMAIL PROTECTED]
on Thursday, May 20, 2004 12:51 PM said:
If I have multiple instances that match the pattern, but only want the
first one, which is the best way to handle it?
reread the last sentence in John's post.
John W. Holmes wrote:
From: Al [EMAIL PROTECTED]
[snip]
Hi,
I want program execution to go to one of several other files
based on a decision.
For Example.
if (1==a)
go to this .php file
if (1==b)
go to that .php file
if (1==c)
go to the other .php file
Thank you for your time.
Michael
--
PHP General Mailing List (http://www.php.net/)
To
MY PROGRAM FLOW:
Enter loop
Wait incoming data
If (incoming data) {
do something
} elseif (no data delay 5 seconds) {
send ping to server
return to top of loop
I've seen a sweet script for a multi-client, multi-socket server in PHP
(http://dave.dapond.com/socketselect.php.txt), but its purpose is quite
different from mine, and it's about one billion times more complex than
I need.
I am building a SIMPLE socket client that makes ONE connection to ONE
You could include those other php files, eg.
switch( $i ) {
case 'a':
include('a.php');
break;
case 'b':
include('b.php');
break;
}
On Thu, 20 May 2004, michael young wrote:
Hi,
I want program execution to
This works providing there has NOT been any header (HTML) info outputed.
if (1==a)
header(Location: thisotherfile.php);
Hi,
I want program execution to go to one of several other files
based on a decision.
For Example.
if (1==a)
go to this .php file
if (1==b)
go to
This is a common problem for people coming from other languages where the
file structures are the same as the execution structure. A few of at least
50 answers is as follows;
Force the browser to invoke your next program;
If(1==a) {
header(Location: this.php);
exit; //stop this
Please ignore my previous
I-AM-SO-FRUSTRATED-I-AM-READY-FOR-A-JACKET-WITH-REALLY-LONG-SLEEVES
posts. I have managed to solve my socket woes. My simple client works
loops, timesout, loops again... elegantly. (I've learned not take those
PHP warnings so seriously... and to clear socket errors.)
Hi Chris,
Please send your message to [EMAIL PROTECTED], you are more likely
to get a response there.
Chris [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
Hi all. Hopefully someone here can show me what I am doing wrong. I am
trying to write a small script to ftp into a server
René Fournier mailto:[EMAIL PROTECTED]
on Thursday, May 20, 2004 2:58 PM said:
Please ignore my previous
I-AM-SO-FRUSTRATED-I-AM-READY-FOR-A-JACKET-WITH-REALLY-LONG-SLEEVES
posts. I have managed to solve my socket woes. My simple client works
loops, timesout, loops again... elegantly.
René fournier wrote:
I've seen a sweet script for a multi-client, multi-socket server in PHP
(http://dave.dapond.com/socketselect.php.txt), but its purpose is quite
different from mine, and it's about one billion times more complex than
I need.
I am building a SIMPLE socket client that makes
How can I eval() an HTML template to make a CONSTANT be evaluated
properly?
Previously I have been using regular $variables in my HTML templates.
Today I decided to make one of the $variables a CONSTANT only to find it
would not parse out as it's defined value. It is instead treated as
regular
* Thus wrote Ren Fournier ([EMAIL PROTECTED]):
I am building a SIMPLE socket client that makes ONE connection to ONE
server, and waits for data (socket_read)... and when no data comes for
a few seconds, does something else, then waits for data again. HOW
SHOULD I APPROACH THIS?! PLEASE
Greetings,
I compiled and installed mysql from source, and now I am trying to recompile
php agaisnt the new version of MySQL (was previous running 3.23.53). Here
is the configure string I used:
./configure --with-apxs2=/usr/local/apache/bin/apxs --prefix=/usr/local/php
* Thus wrote Aaron Axelsen ([EMAIL PROTECTED]):
Greetings,
I compiled and installed mysql from source, and now I am trying to recompile
php agaisnt the new version of MySQL (was previous running 3.23.53). Here
is the configure string I used:
./configure
The mysql 3.x was installed with prefix /usr/local/mysql
--
Aaron Axelsen
Email: [EMAIL PROTECTED]
-Original Message-
From: Curt Zirzow [mailto:[EMAIL PROTECTED]
Sent: Thursday, May 20, 2004 7:08 PM
To: [EMAIL PROTECTED]
Subject: Re: [PHP] [PHP 4.3.6] Compiling agaisnt MySQL 4.0.18 on
I'm sure there's a really simple way to do this: how can I grab the
source code of a specified web page and store it in a variable? Is
there something like this:
$siteCode = functionI'mLookingFor('www.123.com/index.htm');
Thanks,
- Brian
--
PHP General Mailing List (http://www.php.net/)
To
Brian Dunning wrote:
I'm sure there's a really simple way to do this: how can I grab the
source code of a specified web page and store it in a variable? Is
there something like this:
$siteCode = functionI'mLookingFor('www.123.com/index.htm');
a cracker's dream and programmer's worst nightmare
Hello Brian,
Friday, May 21, 2004, 1:19:19 AM, you wrote:
BD I'm sure there's a really simple way to do this: how can I grab the
BD source code of a specified web page and store it in a variable? Is
BD there something like this:
BD $siteCode = functionI'mLookingFor('www.123.com/index.htm');
If
Aaron Axelsen wrote:
The mysql 3.x was installed with prefix /usr/local/mysql
So why are you pointing to the 3.x path when compiling with 4.x?
And since you are going through all this trouble might as well use a
very recent version of mysql
--
Aaron Axelsen
Email: [EMAIL PROTECTED]
On May 20, 2004, at 5:43 PM, raditha dissanayake wrote:
I'm sure there's a really simple way to do this: how can I grab the
source code of a specified web page and store it in a variable?
Never mind, I found it:
$string = get_file_contents('www.123.com');
- Brian
--
PHP General Mailing List
I was trying to upgrade over the older one, which is why the paths are the
same. I want to stick with the stable realease
--
Aaron Axelsen
Email: [EMAIL PROTECTED]
-Original Message-
From: raditha dissanayake [mailto:[EMAIL PROTECTED]
Sent: Thursday, May 20, 2004 7:47 PM
Cc: [EMAIL
raditha dissanayake wrote:
a cracker's dream and programmer's worst nightmare
Must everything be negative? You can not assume what other people
are trying to do. Either answer the question, or don't answer at all.
--
W | I haven't lost my mind; it's backed up on tape somewhere.
Aaron Axelsen wrote:
I was trying to upgrade over the older one, which is why the paths are the
same. I want to stick with the stable realease
4.0.18 is stable. Generally you should not install a new version of a
software over the older tree, it leads to many a conflict as you have
just
Hi,
Friday, May 21, 2004, 8:26:30 AM, you wrote:
GD How can I eval() an HTML template to make a CONSTANT be evaluated
GD properly?
GD Previously I have been using regular $variables in my HTML templates.
GD Today I decided to make one of the $variables a CONSTANT only to find it
GD would not
* Thus wrote Aaron Axelsen ([EMAIL PROTECTED]):
I was trying to upgrade over the older one, which is why the paths are the
same. I want to stick with the stable realease
Overwritting versions like that might not work very well, file
names have changed accross the versions. I usually update my
On Thursday, May 20, 2004, at 04:17 PM, Chris W. Parker wrote:
René Fournier mailto:[EMAIL PROTECTED]
on Thursday, May 20, 2004 2:58 PM said:
Please ignore my previous
I-AM-SO-FRUSTRATED-I-AM-READY-FOR-A-JACKET-WITH-REALLY-LONG-SLEEVES
posts. I have managed to solve my socket woes. My simple
On Thursday, May 20, 2004, at 05:15 PM, Curt Zirzow wrote:
* Thus wrote Ren Fournier ([EMAIL PROTECTED]):
I am building a SIMPLE socket client that makes ONE connection to ONE
server, and waits for data (socket_read)... and when no data comes for
a few seconds, does something else, then waits for
On Thursday, May 20, 2004, at 06:42 PM, Brian Dunning wrote:
On May 20, 2004, at 5:43 PM, raditha dissanayake wrote:
I'm sure there's a really simple way to do this: how can I grab the
source code of a specified web page and store it in a variable?
Never mind, I found it:
$string =
You probably mean...
$string = file_get_contents(http://www.123.com;);
Whoops
Well, it worked, so I must have typed it correctly in my code... :) :)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
86 matches
Mail list logo