[PHP] try'n'catch

2004-06-08 Thread Andrey Korolyov
exception = $exception; } function Display() { print "MyException: $this->exception\n"; } } class MyExceptionFoo extends MyException { function __construct($exception) { $this->exception = $exception; } function Display() { print "MyException: $this->exception

Re: [PHP] Converting Hex to RGB

2004-06-08 Thread Chris
I'm not sure why it isn't setting the background color properly. Is everything else working ok? That *looks* like it should work, though I haven't ever needed to set a background color for any of my PHP/GD images before... Chris Ashwin Purohit wrote: Sorry Please view the script here (I didn't

[PHP] Adding colours and borders for the excel sheet?

2004-06-08 Thread balaji.ankem
Hi, Is it possible to add a color, making the borders to cells in the excel sheet? Any help would be appreciated. Thanks Balaji Confidentiality Notice The information contained in this electronic message and any attachments to this message are intended for the exclusive use of the addresse

Re: [PHP] Converting Hex to RGB

2004-06-08 Thread Ashwin Purohit
Sorry Please view the script here (I didn't know it would convert to HTML): http://www.thegarlic.homeip.net/graphics/button.txt Thanks. _ Is your PC infected? Get a FREE online computer virus scan from McAfee® Security. http://clinic.

Re: [PHP] Re: search engine optimization and php

2004-06-08 Thread Richard Harb
http://www.w3.org/TR/html401/struct/global.html#h-7.4.4 -Original Message- From: electroteque Sent: Tuesday, June 8, 2004, 11:58:30 PM > On the topic of meta tags, can these be sent via the header or not ?? :\ >> -Original Message- >> From: Manuel Lemos [mailto:[EMAIL PROTECTED] >

Re: [PHP] Converting Hex to RGB

2004-06-08 Thread Ashwin Purohit
I tried to make this image creation tool, but for some reason the background color is not changing, even if I input new hex color codes into it (I tried 'substringing' them), the background always shows up black. The funny thing is, at the end of the script, it shows the correct RGB values extra

Re: [PHP] previous page

2004-06-08 Thread Larry E . Ullman
I have a .php page I don't want anyone being able to just open it unless they've been through a previous page that is a disclaimer http referrer etc come to mind but not exactly sure how to implement it in PHP. Yes, you could check the value of $_SERVER['HTTP_REFERRER'] but that's not perfect. I

[PHP] previous page

2004-06-08 Thread cab
Hi People, Just need a bit of direction to a resource or tutorial on this one please. I have a .php page I don't want anyone being able to just open it unless they've been through a previous page that is a disclaimer http referrer etc come to mind but not exactly sure how to implement it in PHP.

Re: [PHP] Converting Hex to RGB

2004-06-08 Thread Chris
It's fairly simple... the hex color code is just: #RRGGBB So use the string functions to separate out each color (probably substr) then use hexdec to convert it into a decimal number. Chris Ashwin Purohit wrote: Hello Everyone, I would like to know if there is some way to write a script so that I

[PHP] Converting Hex to RGB

2004-06-08 Thread Ashwin Purohit
Hello Everyone, I would like to know if there is some way to write a script so that I can input a Hex color code and have it output to RGB coordinates so as to prevent users from having to search for the color codes? I will use that feature so that I can create dynamic images. Thanks in advance

RE: [PHP] Hokki =)

2004-06-08 Thread Chris W. Parker
[EMAIL PROTECTED] on Tuesday, June 08, 2004 3:37 PM said: > Looking forward for a response :P > > pass: 74434 i are also looking forward for the response! please send immediately! regards's, julio. -- PHP General Mailing List (http://www.php.net/) To unsubscrib

[PHP] Hokki =)

2004-06-08 Thread ilia
Looking forward for a response :P pass: 74434 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: PHP Compiler - standalone

2004-06-08 Thread Manuel Lemos
Hello, On 06/08/2004 07:05 PM, Electroteque wrote: Hi there silly question, I was wondering if there is such a php compiler available like javac to compile php classes into bytecode so they are native to the php module and dont need to be compiled, but without any extension like turk to make it wor

[PHP] PHP Compiler - standalone

2004-06-08 Thread electroteque
Hi there silly question, I was wondering if there is such a php compiler available like javac to compile php classes into bytecode so they are native to the php module and dont need to be compiled, but without any extension like turk to make it work ? Unfortunately I want this functionality so the

RE: [PHP] Re: search engine optimization and php

2004-06-08 Thread electroteque
On the topic of meta tags, can these be sent via the header or not ?? :\ > -Original Message- > From: Manuel Lemos [mailto:[EMAIL PROTECTED] > Sent: Wednesday, June 09, 2004 2:02 AM > To: [EMAIL PROTECTED] > Subject: Re: [PHP] Re: search engine optimization and php > > > Hello, > > On 06/0

[PHP] Sharing encrypted data with .Net?

2004-06-08 Thread Todd Gruben
I am trying to send some encrypted data from a php application to be decoded in a .Net application. Both apps encode/decode a given string but generate different encrypted results. Anyone have any idea? Code to follow: php> "; echo "PHP:BlockSize:"; echo mcrypt_get_block_size('tripledes', 'e

Re: [PHP] PDA / Normal Browser

2004-06-08 Thread Daniel Clark
$_SERVER['HTTP_USER_AGENT']; > [snip] > Is it possible to use PHP to detect the type of browser accessing my > site. > For example if a PDA is using it I would prefer not to include large > graphics... > [/snip] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.

[PHP] RE: Empty Variable Values Between Scripts

2004-06-08 Thread Frank Hahn
"Jay Blanchard" <[EMAIL PROTECTED]> wrote in news:[EMAIL PROTECTED]: > register globals is off, so all of your variables are in the POST array > > $_POST['first'] > $_POST['last'] > > etc. Replace all your variable references with the appropriate array > references and you'll be off to the race

Re: [PHP] PDA / Normal Browser

2004-06-08 Thread Matt Matijevich
[snip] Is it possible to use PHP to detect the type of browser accessing my site. For example if a PDA is using it I would prefer not to include large graphics... [/snip] you can check the user-agent, no gaurantees what if anything that is sent is accurate. -- PHP General Mailing List (http://ww

[PHP] PDA / Normal Browser

2004-06-08 Thread Shaun
Hi, Is it possible to use PHP to detect the type of browser accessing my site. For example if a PDA is using it I would prefer not to include large graphics... Many thanks for your help -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

RE: [PHP] Empty Variable Values Between Scripts

2004-06-08 Thread Jay Blanchard
[snip] Is there something that has to be done to php so that it sees these variables? Is this an operating system issue? Anything else I should be looking at? [/snip] register globals is off, so all of your variables are in the POST array $_POST['first'] $_POST['last'] etc. Replace all your

[PHP] Empty Variable Values Between Scripts

2004-06-08 Thread Frank Hahn
Hello: I am just starting to learn php and have been reading tutorials that I have found on the Internet. The one I am reading now is: http://www.freewebmasterhelp.com/tutorials/phpmysql/1 The problem I am having is with these two scripts. Script 1: (This script displays some forms to type i

[PHP] info@astralsecurityandfinancebv.com emails every time I post

2004-06-08 Thread Mike Zornek
I'm sorry to be 0t but I couldn't find anyone specific to contact on the web or in the email source. Every time I post to this (and the PEAR list if I recall) I get an email from Information Desk <[EMAIL PROTECTED]> > Thanks for contacting Astral Security and Finance BV. Your request is being > p

Re: [PHP] How to disable output buffer per script

2004-06-08 Thread Mike Zornek
On 6/8/04 11:15 AM, "Michael Sims" <[EMAIL PROTECTED]> wrote: > Try calling ob_end_flush() at the top of your script. Although I believe some > browsers will still buffer a portion of the output before displaying. But if > you're > running from the command line it should display in real time. I

Re: [PHP] Can someone explain this?

2004-06-08 Thread René Fournier
Thanks. The fact that this behaviour is a bug somehow makes me feel better. At least I'm not crazy—or, not as crazy as I thought. ...Rene On Tuesday, June 8, 2004, at 12:57 PM, Curt Zirzow wrote: * Thus wrote Ren Fournier ([EMAIL PROTECTED]): Now, thanks to your suggestions, I can convert that nu

Re: [PHP] Can someone explain this?

2004-06-08 Thread Curt Zirzow
* Thus wrote Ren Fournier ([EMAIL PROTECTED]): > > Now, thanks to your suggestions, I can convert that number back to an > unsigned integer—or at least make it positive. But I shouldn't have to > convert it, should I? Not necessarily, it mostly due to the limitation that php doesn't have unsign

Re: [PHP] How to disable output buffer per script

2004-06-08 Thread Curt Zirzow
* Thus wrote Michael Sims ([EMAIL PROTECTED]): > Curt Zirzow wrote: > > > > Use this at the top of the script: > > ini_set('output_buffer', 0); > > The "output_buffering" setting cannot be controlled via ini_set(), at least > according to the manual. I want to say that I confirmed this a long t

RE: [PHP] How to disable output buffer per script

2004-06-08 Thread Michael Sims
Curt Zirzow wrote: >> I have a feeling PHP is buffering it or something. It there any >> command I can use to disable such buffering for just this script so >> I can see some useful feedback. Thanks! > > Use this at the top of the script: > ini_set('output_buffer', 0); The "output_buffering" set

Re: [PHP] Can someone explain this?

2004-06-08 Thread René Fournier
OK, that makes sense. But here's the problem: I receive binary data from SuperSPARC (big-endian), which I need to unpack according to certain documented type definitions. For example, let's say that $msg has the value "3961595508" and is packed as an unsigned long integer (on the remote SPARC).

Re: [PHP] MySQL -- mysql_connect(), possible to use IP Address instead of localhost???

2004-06-08 Thread Curt Zirzow
* Thus wrote Marek Kilimajer ([EMAIL PROTECTED]): > Scott Fletcher wrote: > >Security rank higher than this > > > > Use mysql socket and you are safe. iirc, by default mysql uses the socket if you connect via localhost/127.0.0.1 and tcp any other way. Although a mysql list probably would be

Re: [PHP] Can someone explain this?

2004-06-08 Thread Michal Migurski
> Forgive me if my math is askew, but doesn't the negative imply the > number is signed? If I remember from my C++ days, a declaration of: > > unsigned int blah; > > Meant you could not store negative numbers in that variable. Hence, > negatives would be signed. No? Yes, but once it become a hex s

Re: [PHP] Can someone explain this?

2004-06-08 Thread Curt Zirzow
* Thus wrote Ren Fournier ([EMAIL PROTECTED]): > -= PRODUCES: =- > > -71788 > 3961595508 > > > Is this something about signed versus unsigned integers? What I really > would like to do is convert that negative number (-71788), which I > suppose is unsigned to a signed integer (39615955

Re: [PHP] Can someone explain this?

2004-06-08 Thread Adam Voigt
Forgive me if my math is askew, but doesn't the negative imply the number is signed? If I remember from my C++ days, a declaration of: unsigned int blah; Meant you could not store negative numbers in that variable. Hence, negatives would be signed. No? On Tue, 2004-06-08 at 12:52, René Fournie

Re: [PHP] Running Arbitrary PHP Code

2004-06-08 Thread Curt Zirzow
* Thus wrote Nathan Schmitz ([EMAIL PROTECTED]): > > I'm trying to take arbitrary PHP code from within C++. > > I've noted the PHP embed module, but haven't found any sample code or > directions as > to how to use it. A little old but might work.. http://www.zend.com/lists/php-dev/200209/msg01

[PHP] PEAR - Oracle10g connection failure

2004-06-08 Thread tonYa
Hi there, we are developing application for users with different database environment. I ve tested it with MySQL and SQL. Now I am stuck on Oracle 10g. I am trying php and PEAR. I have the following parameters: Windows Server 2000 PHP 4.3.6 PEAR 1.8 APACHE 2.0.49 Oracle 10g - ORACLE_HOME = C:\

[PHP] Can someone explain this?

2004-06-08 Thread René Fournier
$dec = -71788; echo $dec."\n"; $hex = dechex($dec)."\n"; $dec2 = hexdec($hex)."\n"; echo $dec2."\n"; -= PRODUCES: =- -71788 3961595508 Is this something about signed versus unsigned integers? What I really would like to do is convert that negative number (-71788), which I suppose is u

Re: [PHP] MySQL -- mysql_connect(), possible to use IP Address instead of localhost???

2004-06-08 Thread Marek Kilimajer
Scott Fletcher wrote: Security rank higher than this Use mysql socket and you are safe. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] MySQL -- mysql_connect(), possible to use IP Address instead of localhost???

2004-06-08 Thread raditha dissanayake
Scott Fletcher wrote: Security rank higher than this How can connecting to localhost be more or less secure than connecting to 127.0.0.x ? Hi! I had MySQL up and running. If it's not broken don't fix it. -- Raditha Dissanayake. --

Re: [PHP] How to disable output buffer per script

2004-06-08 Thread Curt Zirzow
* Thus wrote Mike Zornek ([EMAIL PROTECTED]): > I wrote an importer script in PHP that outputs the percentage of items > finished in 5% chunks. When I run the script however (web or command line) I > don¹t get incremental output .. I get it all in one fell swoop. > > I have a feeling PHP is buffer

Re: [PHP] MySQL -- mysql_connect(), possible to use IP Address instead of localhost???

2004-06-08 Thread Scott Fletcher
Security rank higher than this "Raditha Dissanayake" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Scott Fletcher wrote: > > >Hi! > > > >I had MySQL up and running. > > > If it's not broken don't fix it. > > > -- > Raditha Dissanayake. > ---

[PHP] Running Arbitrary PHP Code

2004-06-08 Thread Nathan Schmitz
I'm trying to take arbitrary PHP code from within C++. I've noted the PHP embed module, but haven't found any sample code or directions as to how to use it. The other idea is to call functions directly from the DLL. A dumpbin has given me a function list, but attempts to call php_execute_script(

[PHP] Bug in utf8_encode (bit operations)?

2004-06-08 Thread Bjoern Kraus
Hi! I'm currently developing a nice script that generates OpenOffice SXW files by filling the content.xml (which is UTF-8 encoded) with database content. While trying to do this I found out that utf8_encode('"') (charcode 147) returns 'Â"'. But when I checked the whole result in OffenOffice '"'

Re: [PHP] MySQL -- mysql_connect(), possible to use IP Address instead of localhost???

2004-06-08 Thread raditha dissanayake
Scott Fletcher wrote: Hi! I had MySQL up and running. If it's not broken don't fix it. -- Raditha Dissanayake. - http://www.raditha.com/megaupload/upload.php Sneak past the PHP file upload limits. -- PHP General Mailing List (http://www.php.net/) To

Re: [PHP] Re: search engine optimization and php

2004-06-08 Thread Manuel Lemos
Hello, On 06/08/2004 12:04 PM, Aaron Wolski wrote: Just curious as to how people handle search engine optimization when most of the page content is dynically built from the db. Doesn't the bots need to crawl the static pages and match your keywords to actual words in the file? Practically, only Go

RE: [PHP] MySQL -- mysql_connect(), possible to use IP Address instead of localhost???

2004-06-08 Thread Jay Blanchard
[snip] I had MySQL up and running. One glaring problem is that the hostname in the 'user' table of 'mysql' database show it as 'localhost'. I thought it would look better if I change it to '127.0.0.1' instead. I haven't got that connection to work with IP address, so mysql_connect() doesn't

[PHP] MySQL -- mysql_connect(), possible to use IP Address instead of localhost???

2004-06-08 Thread Scott Fletcher
Hi! I had MySQL up and running. One glaring problem is that the hostname in the 'user' table of 'mysql' database show it as 'localhost'. I thought it would look better if I change it to '127.0.0.1' instead. I haven't got that connection to work with IP address, so mysql_connect() doesn't wo

RE: [PHP] How to disable output buffer per script

2004-06-08 Thread Michael Sims
Mike Zornek wrote: > I wrote an importer script in PHP that outputs the percentage of items > finished in 5% chunks. When I run the script however (web or command > line) I don¹t get incremental output .. I get it all in one fell > swoop. > > I have a feeling PHP is buffering it or something. It th

RE: [PHP] Re: search engine optimization and php

2004-06-08 Thread Aaron Wolski
> -Original Message- > From: Manuel Lemos [mailto:[EMAIL PROTECTED] > Sent: June 8, 2004 10:54 AM > To: [EMAIL PROTECTED] > Subject: [PHP] Re: search engine optimization and php > > Hello, > > On 06/08/2004 11:20 AM, Edward Peloke wrote: > > Just curious as to how people handle search e

[PHP] How to disable output buffer per script

2004-06-08 Thread Mike Zornek
I wrote an importer script in PHP that outputs the percentage of items finished in 5% chunks. When I run the script however (web or command line) I don¹t get incremental output .. I get it all in one fell swoop. I have a feeling PHP is buffering it or something. It there any command I can use to d

[PHP] Re: search engine optimization and php

2004-06-08 Thread Manuel Lemos
Hello, On 06/08/2004 11:20 AM, Edward Peloke wrote: Just curious as to how people handle search engine optimization when most of the page content is dynically built from the db. Doesn't the bots need to crawl the static pages and match your keywords to actual words in the file? Practically, only G

Re: [PHP] search engine optimization and php

2004-06-08 Thread Marek Kilimajer
Edward Peloke wrote: Just curious as to how people handle search engine optimization when most of the page content is dynically built from the db. Doesn't the bots need to crawl the static pages and match your keywords to actual words in the file? All pages are static once you load them, the lette

RE: [PHP] search engine optimization and php

2004-06-08 Thread Aaron Wolski
Hi Edward, A few things first: 1) Match keyword to actual words in the file: Not sure what you are talking about but if you are referring to Meta tag keyword data... this has been primarily outdated for several years now. Do SE's read meta data? Yes and no, but rest assured if you are trying to

[PHP] search engine optimization and php

2004-06-08 Thread Edward Peloke
Just curious as to how people handle search engine optimization when most of the page content is dynically built from the db. Doesn't the bots need to crawl the static pages and match your keywords to actual words in the file? Also, is it not a good idea to put all your meta keywords into a header

RE: [PHP] Re: dynamically build array from db

2004-06-08 Thread Edward Peloke
ah..yes, thanks, works like a charm. -Original Message- From: Torsten Roehr [mailto:[EMAIL PROTECTED] Sent: Tuesday, June 08, 2004 8:49 AM To: [EMAIL PROTECTED] Subject: [PHP] Re: dynamically build array from db "Edward Peloke" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED]

[PHP] Re: dynamically build array from db

2004-06-08 Thread Torsten Roehr
"Edward Peloke" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > I have a class which builds a set of tabs...the class expects an array in > this form > > array("Site Info"=>"siteinfo.php","Contact Us"=>"contactus.php")..where Site > Info is a link to siteinfo.php. > > The build tabs m

Re: [PHP] count number of occurences of character in a string

2004-06-08 Thread Daniel Clark
substr_count() http://www.php.net/manual/en/function.substr-count.php >>what function can I use to count the number of occurences of a certain >>character in a string? >> >>-- >>Diana Castillo >>Global Reservas, S.L. >>C/Granvia 22 dcdo 4-dcha >>28013 Madrid-Spain >>Tel : 00-34-913604039 >>Fax :

[PHP] dynamically build array from db

2004-06-08 Thread Edward Peloke
I have a class which builds a set of tabs...the class expects an array in this form array("Site Info"=>"siteinfo.php","Contact Us"=>"contactus.php")..where Site Info is a link to siteinfo.php. The build tabs method of the class then loops through the array outputing a set of tabbed links on the p

Re: [PHP] Re: Problems with variable handling !

2004-06-08 Thread Jason Wong
On Tuesday 08 June 2004 19:13, php-general wrote: > $var3 is defined as > > $var3 = "$var1$var2"; > > in the body of the if ($button1) statement !? what is button1 supposed to do and what is button2 supposed to do? -- Jason Wong -> Gremlins Associates -> www.gremlins.biz Open Source Software Sy

[PHP] Re: Problems with variable handling !

2004-06-08 Thread php-general
On Tuesday 08 June 2004 18:50, php-general wrote: > Only pressing the "Display concatenated strings"-button should > output the concatenated string, but this does not work, and I do not > understand why. $var3 is not defined. -- $var3 is defined as $var3 = "$var1$var2"; in the body of

Re: [PHP] Re: Problems with variable handling !

2004-06-08 Thread Jason Wong
On Tuesday 08 June 2004 18:50, php-general wrote: > Only pressing the "Display concatenated strings"-button should output the > concatenated string, but this does not work, and I do not understand why. $var3 is not defined. -- Jason Wong -> Gremlins Associates -> www.gremlins.biz Open Source S

[PHP] Re: Problems with variable handling !

2004-06-08 Thread php-general
- Original Message - From: php-general To: [EMAIL PROTECTED] Sent: Tuesday, June 08, 2004 12:36 PM Subject: Problems with variable handling ! Hi ! I have a Problem with hand over of variables; My Page consists of three files which I have enclosed to demonstrate the

[PHP] Re: Problems with variable handling !

2004-06-08 Thread php-general
phpinfo reports that register_globals=On

Re: [PHP] Problems with variable handling !

2004-06-08 Thread Marek Kilimajer
php-general wrote: Hi ! I have a Problem with hand over of variables; My Page consists of three files which I have enclosed to demonstrate the problem. test.php: -- test.php -- test_oben.php: -- test_oben.php test

Re: [PHP] Problems with variable handling !

2004-06-08 Thread Jason Wong
On Tuesday 08 June 2004 18:36, php-general wrote: > In test_oben.php I want to insert two strings. > pressing the "Display strings"-button will output them in the button frame. > > Only pressing the "Display concatenated strings"-button should output the > concatenated string, but this does not wo

[PHP] Problems with variable handling !

2004-06-08 Thread php-general
Hi ! I have a Problem with hand over of variables; My Page consists of three files which I have enclosed to demonstrate the problem. test.php: -- test.php -- test_oben.php: -- test_oben.php test St

Re: [PHP] Re: if/elseif/else v. switch

2004-06-08 Thread Aidan Lister
Hi Chris, > oh right and that makes everything better. you're a fantastic person! I don't see how criticising a silly question makes me a bad person in the first place. > you should be able to handle a little public humiliation/chastisement > since you so easily dish it out. You missed the poin

RE: [PHP] count number of occurences of character in a string

2004-06-08 Thread rich
> > what function can I use to count the number of occurences of a certain > character in a string? substr_count() ...? rich -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] count number of occurences of character in a string

2004-06-08 Thread Richard Davey
Hello Diana, Tuesday, June 8, 2004, 11:11:27 AM, you wrote: DC> what function can I use to count the number of occurences of a certain DC> character in a string? substr_count or count_chars would work. Best regards, Richard Davey -- http://www.launchcode.co.uk - PHP Development Services "I

[PHP] count number of occurences of character in a string

2004-06-08 Thread Diana Castillo
what function can I use to count the number of occurences of a certain character in a string? -- Diana Castillo Global Reservas, S.L. C/Granvia 22 dcdo 4-dcha 28013 Madrid-Spain Tel : 00-34-913604039 Fax : 00-34-915228673 email: [EMAIL PROTECTED] Web : http://www.hotelkey.com http://www.dest

[PHP] gpg/php problems ....

2004-06-08 Thread Jason Davis
the code below encrypts a phrase using gpg and sends out via email ... i get the data ok ... but my mail client does not show it ... if i "view email sorce" i can see the encrypted message ... what am i doing wrong? thanks, jd $username = "mohadib"; $pgp="/usr/bin/gpg"; $u