[PHP] Even Newer-Viewing Problem

2011-01-03 Thread Fr. Vincent Benoit OP
I have Linux with Firefox reading mail at yahoo.  All the messages I get in the 
digest contain html elements making it very hard to read the messages.  Is 
there 
anything I can do to make the messages come in clear text? or get this system 
to 
read the html in the digest?

 Thank you,
Fr. Vincent Benoit, OP


[PHP] on the fly picture problem

2003-08-14 Thread Benoit LEFEVRE
I'm using jpgraph or GD for charts making, and the picture is correctly made
in cache or in directory and there is no error log but when I use it in php
page ( IMG src=graph.php , I have a no-pict icon instead of my graph.



For information the graph.php script :

%

$sitename=scafoot; include(/var/www/jpgraph/src/jpgraph.php);

include(/var/www/jpgraph/src/jpgraph_line.php);

require(./connect.php);



$graph = new Graph(400,250,auto); $graph-SetScale(textlin);
$graph-img-SetMargin(40,20,20,40);



$sql=select idstat,week(date) as week,count(*) as count from pages where
host like '%$sitename%' group by week; condb($sql,$result);
$ydata=array(0); $xdata=array(0);

while($row=mysql_fetch_array($result))

{

  array_push($xdata,$row[week])

  array_push($ydata,$row[count])

}

$graph-yaxis-title-Set(freq);

$graph-xaxis-title-Set(semaine);



$graph-xaxis-SetTrickLabels($xdata);

$lineplot=new LinePlot($ydata);

$lineplot-SetColor(blue);



$graph-Add($lineplot);

Header(Content-type: image/png);

$graph-Stroke();

%









-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Form Data History

2002-02-12 Thread Sebastian Benoit

Analysis and Solutions([EMAIL PROTECTED])@2002.02.11 23:19:57 +:
  back'... but upon going back in history, all the data that was in the
  form is lost. This did not occur on my regular not-secure web server.
 
 Page caching.  You can alter that through the header() function.  But, a

No, you can't.

At least mozilla does not honour Cache-Control for SSL connections. I
haven't checked if thats because Cache-Control is not part of HTTPS (?) or
if its for security reasons. SSL connections are treated like
Cache-Control: no-store.

 cleaner way handle user validation problems is to reprint the form and data
 on the present page.  I like to have both the initiating form and the form

yep.

/B.

-- 
Sebastian Benoit [EMAIL PROTECTED]
GnuPG 0x5BA22F00 2001-07-31 2999 9839 6C9E E4BF B540  C44B 4EC4 E1BE 5BA2 2F00

Life is Xerox , you are only a copy



msg49620/pgp0.pgp
Description: PGP signature


[PHP] search a text file

2001-03-12 Thread Peter Benoit

I've got a bit of a task where I need to poll a text file for several lines
of text which is buried deep within the file.  These lines change each day,
but the text surrounding them do not.

Is it possible to extract these lines of information based on the text
surrounding them?


-- 
PHP General Mailing List (http://www.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] search a text file

2001-03-12 Thread Peter Benoit

OK, I'm a little new to this, else I would have known that.  Any examples
out there I could use/modify?  

thanks,
pete

-Original Message-
From: CC Zona [mailto:[EMAIL PROTECTED]]
Sent: Monday, March 12, 2001 2:16 PM
To: [EMAIL PROTECTED]
Subject: Re: [PHP] search a text file


In article 
[EMAIL PROTECTED],
 [EMAIL PROTECTED] (Peter Benoit) wrote:

 I've got a bit of a task where I need to poll a text file for several
lines
 of text which is buried deep within the file.  These lines change each
day,
 but the text surrounding them do not.
 
 Is it possible to extract these lines of information based on the text
 surrounding them?

Sure.  preg_match() would be one way.

-- 
CC

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



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




[PHP] In my attempt to read from a text file...

2001-03-12 Thread Peter Benoit

I'm trying preg_match with no success.

I'd like to search inside the text file for my name, then pull all the info
from that point till the next name which is Fred.

The text file would be called names.txt


So I'm trying to 

preg_match("Peter",names.txt,$myname)

then do the same for Fred, and grab all the stuff in between.

Is this the right way to do this?  Or is there something easier?

How can I search names.txt?  Can I load it into a variable somehow?

Please help


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




RE: [PHP] Need to download files in IE

2001-03-12 Thread Peter Benoit

Yes, zip the pdf.  Search the MSKB for more info.

-Original Message-
From: James R. Edgar [mailto:[EMAIL PROTECTED]]
Sent: Monday, March 12, 2001 3:50 PM
To: 'Pierre-Yves Lemaire'
Cc: [EMAIL PROTECTED]
Subject: RE: [PHP] Need to download files in IE


Hello,

This is the URL of the link that I use.
http://www.sitename.com/pizzeria.php3?pizzeria=aldentes

Here is the code from the script.
$file_path = "menus";
$file = $pizzeria . ".pdf";
$full_file = $file_path."/".$file;
$filesize=filesize($full_file);

header("Content-disposition: attachment; filename=\"$file\"");
header("Content-type: application-download");
header("Pragma: no-cache");
header("Expires: 0");
$fn=fopen($full_file,"r");
fpassthru($fn);
fclose($fn);
exit;

I tried it and it did not work. When I click on the link it shows
"pizzeria.htm"
in the File Name field. Any other suggestions.

Regards,
Edgar

-Original Message-
From: Pierre-Yves Lemaire [mailto:[EMAIL PROTECTED]]
Sent: Monday, March 12, 2001 10:41 AM
To: [EMAIL PROTECTED]
Subject: Re: [PHP] Need to download files in IE


Hello,

I do that with this piece of code. ( This will close the window, so open a
new one and put this code inside)

header("Content-disposition: attachment; filename=\"$fileName\"");
header("Content-type: application-download");
header("Pragma: no-cache");
header("Expires: 0");
$fn=fopen($FileName,"r");
fpassthru($fn);
fclose($fn);
exit;

py

- Original Message -
From: James R. Edgar [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Monday, March 12, 2001 7:57 PM
Subject: [PHP] Need to download files in IE


 I am trying to set my script up so that when a person clicks on the link,
that
 the page will prompt for a download w/ the filename in the File Name field
in
 the Save As prompt.
 I can get this to work in Netscapse but when I try to do it with Internet
 Explorer I encounter problems. It either says there is no application to
read
 the file (I have acrobat reader on the computer.) or it displays the
prompt with
 either [variable's name passed to script].htm or download.php. And the
file I am
 trying to download is a PDF file. If anyone can help me with this I would
 greatly appreciate this, and thanks in advance.

 Regards,
 Edgar


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



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


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



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




[PHP] Re: PHP Apache 2.0 - NOT WORKING ?

2001-03-07 Thread Benoit

Apache 2.0 seem to be now supported by PHP4.04pl1.
I tried PHP4.0.4pl1  Apache 2.0a8 (configure don't seem to work for me with
2.0a9)

But. I did not succeded to make it working !
Do someone have a tips on some compiling flags working, or other versions ?
Mine made apache to show a segmentation fault (in PHP ?), and show a message
that comes from
'create_php_config' function:
'Creating new config (0x80f0c54) for (null).'

Or is it just a config problem ? I have a php.ini in /usr/local/lib, but it
makes the same error if I remove it !


I am interesed with it because it will provide multithreading instead of
multiprocess,... which I prefer for writing PHP modules that can handle
persitent and reusable data (to keep the same connection within a HTTP
session).

(
Apache was compiled with: configure --enable-shared --enable-so
PHP was compiled with: configure --with-apxs2
)


""Benoit"" [EMAIL PROTECTED] wrote in message
97voih$och$[EMAIL PROTECTED]">news:97voih$och$[EMAIL PROTECTED]...
 Do someone know when PHP will work as apixs under Apache 2.0 ?




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




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




[PHP] PHP Apache 2.0

2001-03-05 Thread Benoit

Do someone know when PHP will work as apixs under Apache 2.0 ?




-- 
PHP General Mailing List (http://www.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 - I can't create jpegs with GD

2001-03-02 Thread Cherie Benoit

 Depends on what errors you get. "I can't create or manipulate jpegs"
 isn't particularly helpful...

OK, it returns a broken image and when I download that the resulting file
reads "ImageJpeg: No JPG support in this PHP build". But tech support says
they installed the jpeg support and that they did it correctly.

I've tried using code that Rasmus wrote, too. And that definitely should
work. :)

-- 
Cherie Benoit



-- 
PHP General Mailing List (http://www.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 - I can't create jpegs with GD

2001-03-01 Thread Cherie Benoit

I can't create or manipulate jpegs, but pngs work fine. I am using a hosting
service. They installed GD 1.8.4 with jpeg support a few days ago, but I'm
thinking they did it wrong. I'm using code I know works because it's
straight out of the PHP Cookbook. What do I need to tell them to correct the
problem?


phpinfo() tells me this:
   './configure'
   '--with-gd=/opt/local/src/gd-1.8.4'
   '--with-config-file-path=/usr/local/lib'
   '--with-ttf=/opt/local/src/freetype-1.3.1'
   '--with-jpeg-dir=/opt/local/src/jpeg-6b'
   '--libdir=/usr/local/lib/'

This is the code I've tried:
   ?php
   header("Content-type: image/jpeg");
   if (($im = ImageCreateFromJpeg("test.jpeg")) == "") {
   echo "error opening file";
  exit;
   }
   $red = ImageColorAllocate($im, 255, 0, 0);
   ImageString($im, 3, 20, 10, "Hi", $red);
   ImageJpeg($im);
   ?


Thanks!
-- 
Cherie Benoit


-- 
PHP General Mailing List (http://www.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 creating and manipulating Jpegs with GD

2001-02-28 Thread Cherie Benoit

I know you've addressed this already, but I'm still learning a lot of things
and didn't get much from the previous posts. :)  I am using a hosting
service, not my own server. So before I complain that they installed the
jpeg module incorrectly I need someone to make sure it is not my code.

This code with Png works fine:
?php
header("Content-type: image/png");
if (($im = ImageCreateFromPng("test.png")) == "") {
echo "error opening file";
   exit;
}
$red = ImageColorAllocate($im, 255, 0, 0);
ImageString($im, 3, 20, 10, "Hi", $red);
ImagePng($im);
?

However, if I change it to Jpeg it gives me a broken image icon. I get no
other errors.
?php
header("Content-type: image/jpeg");
if (($im = ImageCreateFromJpeg("test.jpeg")) == "") {
echo "error opening file";
   exit;
}
$red = ImageColorAllocate($im, 255, 0, 0);
ImageString($im, 3, 20, 10, "Hi", $red);
ImageJpeg($im);
?

phpinfo() tell me this:
'./configure'
'--with-gd=/opt/local/src/gd-1.8.4'
'--with-config-file-path=/usr/local/lib'
'--with-ttf=/opt/local/src/freetype-1.3.1'
'--with-jpeg-dir=/opt/local/src/jpeg-6b'
'--libdir=/usr/local/lib/'

Is it me or the server? And what do I tell them to do to fix it?

Thanks!
-- 
Cherie Benoit


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