php-general Digest 9 Feb 2004 05:32:10 -0000 Issue 2579

2004-02-08 Thread php-general-digest-help
php-general Digest 9 Feb 2004 05:32:10 - Issue 2579 Topics (messages 177147 through 177182): Re: Question About Date Function in PHP/MySQL 177147 by: John W. Holmes 177153 by: Freedomware Re: .html or.php extension 177148 by: John Nichel 177149 by: Jason Wong

[PHP] julian date

2004-02-08 Thread adwinwijaya
Hello php-general, I wonder is there any class/function in php to convert from dates (dd/mm/ hh:mm:ss) to Julian date ? (I also wonder why there is no Julian date function in php function libraries ... i think it is nice to have Julian date ) thx -- Best regards, adwinwijaya

[PHP] Re: excel output question

2004-02-08 Thread Jake McHenry
- Original Message - From: "Phillip Jackson" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Saturday, February 07, 2004 4:37 AM Subject: Re: [PHP] Re: excel output question > I would do it like this: > > $build = " '%s','%s','%s','%s'\n"; > $build = sprintf($build,$field1,$field2,$fie

Re: [PHP] Japanese Language

2004-02-08 Thread KidLat Ngayon
Dear Mr. Ray, Before anything else, I would like to thank you for your repsonse. Anyway, as far as the MSWindows is concern, all the language, system and specification are all in Japanese System. And for the Database, here's the variables from the MySQL: | | language| /mys

Re: [PHP] Use a Server or Client Socket?

2004-02-08 Thread Tan Ai Leen
Hi, I need to be polling the connection constantly for new messages as well as have a check that the connection is on. These need to be done in one connection. That's where the headache comes in. In order to poll constantly, I placed the socket read in a while loop. Since the script is looping

[PHP] [ERR] [PHP] compiling php5 with gd-support

2004-02-08 Thread postmaster
Transmit Report: To: [EMAIL PROTECTED], 402 Local User Inbox Full ([EMAIL PROTECTED]) --- Begin Message --- Hi php-general, I have continusously following error compiling php5 with gd-support: ext/gd/gd.lo: In function `zm_deactivate_gd': /usr/local/src/php-5.0.0b3/ext/gd/gd.c:445: undefined re

[PHP] compiling php5 with gd-support

2004-02-08 Thread Safran von Twesla
Hi php-general, I have continusously following error compiling php5 with gd-support: ext/gd/gd.lo: In function `zm_deactivate_gd': /usr/local/src/php-5.0.0b3/ext/gd/gd.c:445: undefined reference to `gdFreeFontCache' collect2: ld returned 1 exit status make: *** [sapi/cli/php] Fehler 1 Here is m

[PHP] check for inactive sessions

2004-02-08 Thread news.php.net
Ok, I've developed a system that allows N number of users to log-in to my site under the same username/password combo. When a user logs-in, a flag is set marking that they have logged-in, their session id is stored and the current # of user's logged-in is iterated by one. If a user account has a ma

RE: [PHP] Revised: RE: [PHP] Re: Can I do this?

2004-02-08 Thread Adam Bregenzer
On Sun, 2004-02-08 at 18:23, PHP Email List wrote: > I am going to be running some more tests, but so far all of the testing that > I have done running a http request is parsing the include files. I have even > checked a broswser based ftp request and nothing shows for the php file. > I'd be intere

Re: [PHP] Revised: RE: [PHP] Re: Can I do this?

2004-02-08 Thread Raditha Dissanayake
Nope i see the server parsed output. Try loading the url directly in your browser!! what you see is what you get when you include. Adam Bregenzer wrote: On Sun, 2004-02-08 at 08:27, Andrew Séguin wrote: A test to confirm that, is to point the browser to the address being included. See the so

RE: [PHP] Revised: RE: [PHP] Re: Can I do this?

2004-02-08 Thread PHP Email List
Ok a couple of questions. I have include files that someone else is including from there server and he is unable to view the source code that he is utilizing in an include script. Of course this is running Apache and Unix with PHP 4.3.4. SO my questions are. 1> Are you testing or referring to this

Re: [PHP] send script output to file

2004-02-08 Thread André Cerqueira
John Nichel wrote: Boneripper wrote: hi, i would like to send the output of a PHP script, to a file, and not to the browser. any ideas on how i can do this? tkx in advance, Use the manual, Luke. http://www.php.net/manual/en/ref.filesystem.php and: http://www.php.net/manual/en/ref.outcontr

Re: [PHP] send script output to file

2004-02-08 Thread John Nichel
Boneripper wrote: hi, i would like to send the output of a PHP script, to a file, and not to the browser. any ideas on how i can do this? tkx in advance, Use the manual, Luke. http://www.php.net/manual/en/ref.filesystem.php -- By-Tor.com It's all about the Rush http://www.by-tor.com -- PHP Ge

[PHP] Re: how to conver a string to float

2004-02-08 Thread André Cerqueira
Sebastian wrote: Is there a possibility to convert a string like "10*500" (parsed from a XML-File) to a float? When i try to store this String in a float variable it only coverts the "10" but nothing after the "*"-sign, but i need the result of this expresison... Is there a function to calculate s

[PHP] send script output to file

2004-02-08 Thread Boneripper
hi, i would like to send the output of a PHP script, to a file, and not to the browser. any ideas on how i can do this? tkx in advance, -- Herberto Graça. _ E-mail : [EMAIL PROTECTED] MSN : [EMAIL PROTECTED] HomePage : http://herbertograca.no-ip.org É devido à

[PHP] Re: Can I do this?

2004-02-08 Thread André Cerqueira
John Taylor-Johnston wrote: Can I include a script on another server doing this? $sql = 'SELECT * FROM '.$table.' where number like '.$number.';'; http://foo.com?list.php?number=16 include("http://elsewhere.com/list.php";); My $sql is error-ing - obviously. http://elsewhere.com/list.php is not

[PHP] Re: [SOLVED] $_POST trouble with html form

2004-02-08 Thread Paul Furman
OK, this is what I've done and it seems to work: Paul Furman wrote: So maybe the better way is to just submit the form with the action file simply reloading the main page to refresh it then put my code below with an if statement checking if the form has been submitted yet and clearing $_POST wh

Re: [PHP] $_POST trouble with html form

2004-02-08 Thread Adam Bregenzer
On Sun, 2004-02-08 at 13:58, Paul Furman wrote: > OK thanks, I made this: > > # jpeg-comment-public.php > include ("C:/_Paul/web/phplib/action/jpeg-comment.php"); > ?> > > but now the hidden one isn't aware of any variables. > > "Forbidden > You don't have permission to access > Notice: Un

Re: [PHP] $_POST trouble with html form

2004-02-08 Thread Paul Furman
Adam Bregenzer wrote: You will not have access to the $_POST["comment"] variable until the form is submitted. Understood. That debug test only worked after submitting the form. So maybe the better way is to just submit the form with the action file simply reloading the main page to refresh it t

Re: [PHP] $_POST trouble with html form

2004-02-08 Thread Paul Furman
Adam Bregenzer wrote: Should I make a little php action file in public_html that includes the actual file? yes OK thanks, I made this: but now the hidden one isn't aware of any variables. "Forbidden You don't have permission to access Notice: Undefined variable: thumb_num in C:/_Paul/web/php

Re: [PHP] $_POST trouble with html form

2004-02-08 Thread Adam Bregenzer
On Sun, 2004-02-08 at 13:32, Paul Furman wrote: > No, it's not accessible from the web, it's in my protected php_library > outside public_html. Can't I execute a hidden script with a form? no > Should > I make a little php action file in public_html that includes the actual > file? yes -- A

Re: [PHP] mcrypt don't work.

2004-02-08 Thread Adam Bregenzer
On Sun, 2004-02-08 at 05:18, [EMAIL PROTECTED] wrote: > Hi all, > I have problem with mcrypt function. > There is always an error that I don't know how to correct this. > This is my code: > > $string = "Text string"; > $key= "My key"; > $encrypted = mcrypt_cfb(MCRYPT_RIJNDAEL-256, $key, $string, M

Re: [PHP] $_POST trouble with html form

2004-02-08 Thread Paul Furman
Paul Furman wrote: Adam Bregenzer wrote: > Make sure the directory this file is in is accessible from the web. No, it's not accessible from the web, it's in my protected php_library outside public_html. It does load the protected action file as long as I don't try to call $_POST["comment"]

Re: [PHP] $_POST trouble with html form

2004-02-08 Thread Paul Furman
Adam Bregenzer wrote: Also perhaps related, when I call $_POST["comment"] in the action file, it gives me "Forbidden You don't have permission to access...[error message]" but this is my own server at home. I'm quite unfamiliar with forms (and new to PHP for that matter). That looks like an a

Re: [PHP] $_POST trouble with html form

2004-02-08 Thread Adam Bregenzer
On Sun, 2004-02-08 at 13:15, Paul Furman wrote: > Why am I getting the error "Undefined index: comment"? > > It's probably a typo because I had something similar that worked. > > " > method="post"> > > > > > >echo $_POST["comment"]; # this is just for debug

[PHP] Re: $_POST trouble with html form

2004-02-08 Thread Paul Furman
OK, it's only when I call $_POST["comment"] in the included action file that I get "Forbidden You don't have permission to access...[error message]". I set it up with the action as an include because if I tried to just give the location, it tried to download jpeg-comment.php. Like I said, this

Re: [PHP] Re: Can I do this?

2004-02-08 Thread John Taylor-Johnston
>they would be able to see your php code. How?!?! Adam Bregenzer wrote: > On Sun, 2004-02-08 at 03:18, John Taylor-Johnston wrote: > > Ah! A little experimenting ... Yes I can :) Answered my own question. > > > > include("http://elsewhere.com/list.php?number=$number";); > > Careful with that. I

[PHP] $_POST trouble with html form

2004-02-08 Thread Paul Furman
Why am I getting the error "Undefined index: comment"? It's probably a typo because I had something similar that worked. " method="post"> echo $_POST["comment"]; # this is just for debugging ?> Also perhaps related, when I call $_POST["comment"] in the action

Re: [PHP] Revised: RE: [PHP] Re: Can I do this?

2004-02-08 Thread Adam Bregenzer
On Sun, 2004-02-08 at 08:27, Andrew Séguin wrote: > A test to confirm that, is to point the browser to the address being > included. See the source? vulnerable. See the results? not vulnerable. If you do not see 'source' then what are you including? For example the following script could be inclu

Re: [PHP] Question About Date Function in PHP/MySQL

2004-02-08 Thread Freedomware
John W. Holmes wrote: Freedomware wrote: EMS lists the following: Short Date: M/d/ Long Date: , dd, Day followed by month, followed by another day, then year??? That format means something like "Friday, May 5, 2004" I thought it was supposed to be year first, followed by mont

Re: [PHP] Re: .html or.php extension

2004-02-08 Thread John W. Holmes
Paul Furman wrote: If you start with one index.php then use that to include additional files, it should accept any file, even with no extension. At least it works that way for me. Just be careful with that. Remember that the files can be requested on their own, also. If you have "database.inc"

[PHP] Re: .html or.php extension

2004-02-08 Thread Paul Furman
If you start with one index.php then use that to include additional files, it should accept any file, even with no extension. At least it works that way for me. E . H . Terwiel wrote: My PHP system demands that files to be interpreted by PHP MUST have the .php extension. If I have an .html file

Re: [PHP] .html or.php extension

2004-02-08 Thread Chris Garaffa
On Feb 5, 2004, at 5:15 PM, E.H.Terwiel wrote: My PHP system demands that files to be interpreted by PHP MUST have the .php extension. If I have an .html file with in it, it won't interpret the PHP code. Unlike JavaScript, f.i. Right, the browser interprets the JavaScript that's sent to it; the

Re: [PHP] .html or.php extension

2004-02-08 Thread Jason Wong
On Friday 06 February 2004 06:15, E.H.Terwiel wrote: > My PHP system demands that files to be interpreted by PHP MUST have > the .php extension. > If I have an .html file with in it, it won't interpret > the PHP code. > Unlike JavaScript, f.i. > Is there a way to make the server do the PHP code an

Re: [PHP] .html or.php extension

2004-02-08 Thread John Nichel
E.H.Terwiel wrote: My PHP system demands that files to be interpreted by PHP MUST have the .php extension. If I have an .html file with in it, it won't interpret the PHP code. Unlike JavaScript, f.i. Is there a way to make the server do the PHP code anyway, in an HTML file ? Or must the action yes

Re: [PHP] Question About Date Function in PHP/MySQL

2004-02-08 Thread John W. Holmes
Freedomware wrote: EMS lists the following: Short Date: M/d/ Long Date: , dd, Day followed by month, followed by another day, then year??? That format means something like "Friday, May 5, 2004" I thought it was supposed to be year first, followed by month and day, as in the ex

php-general Digest 8 Feb 2004 16:58:49 -0000 Issue 2578

2004-02-08 Thread php-general-digest-help
php-general Digest 8 Feb 2004 16:58:49 - Issue 2578 Topics (messages 177121 through 177146): Re: how to conver a string to float 177121 by: Michal Migurski 177123 by: Adam Bregenzer Re: refresh page (might be 0t) 177122 by: Adam Bregenzer Re: Use a Server or Client

[PHP] .html or.php extension

2004-02-08 Thread E . H . Terwiel
My PHP system demands that files to be interpreted by PHP MUST have the .php extension. If I have an .html file with in it, it won't interpret the PHP code. Unlike JavaScript, f.i. Is there a way to make the server do the PHP code anyway, in an HTML file ? Or must the action yes-php/no-php be take

Re: [PHP] Question About Date Function in PHP/MySQL

2004-02-08 Thread Freedomware
John W. Holmes wrote: Freedomware wrote: When I view my data in phpMyAdmin, all I see in that column is NULL. When I preview it in a webpage, nothing displays at all. If I change it to NOT NULL, I see -00-00 in every cell. Here's a row of text from the CSV file I imported into my MySQL tab

Re: [PHP] Revised: RE: [PHP] Re: Can I do this?

2004-02-08 Thread Raditha Dissanayake
Hi, As andrew has said there is no risk here. What you will see is the parsed output (if the webserver has PHP installed) If this is indeed a vulerability we can just add lines similar to include("http://elsewhere.com/list.php";); in our code and be able to easily view other peoples php scrip

Re: [PHP] Use a Server or Client Socket?

2004-02-08 Thread Raditha Dissanayake
Hi, If you only need to make a connection to the server every ten minutes you will be saving a lot of resources if you use a cron job to connect at intervals instead of keeping a permanently open connections. Creating a cron job is quite simple, if you type man 5 crontab you will be able to r

Re: [PHP] Question About Date Function in PHP/MySQL

2004-02-08 Thread John W. Holmes
Freedomware wrote: When I view my data in phpMyAdmin, all I see in that column is NULL. When I preview it in a webpage, nothing displays at all. If I change it to NOT NULL, I see -00-00 in every cell. Here's a row of text from the CSV file I imported into my MySQL table: "Alberta","Edmonto

Re: [PHP] connecting with C-code

2004-02-08 Thread Marek Kilimajer
E.H.Terwiel wrote: I have a tried-and-tested (15 years of it) piece of C code that I could port from Windows to Linux, and I thought I put a PHP front on it. Is there a way to interface the C-code with PHP 4.3.4 ? If so, could you point me to docs ? frgr Erik Hello, there are two ways - you can exe

[PHP] Re: How can I run php 5 beta 3 on windows?

2004-02-08 Thread omer katz
plz Help "Omer Katz" <[EMAIL PROTECTED]> ëúá áäåãòä:[EMAIL PROTECTED] > Help!!! > "Omer Katz" <[EMAIL PROTECTED]> ëúá > áäåãòä:[EMAIL PROTECTED] > > Can I update PHPTraid's php files? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Question About Date Function in PHP/MySQL

2004-02-08 Thread Freedomware
I'm using PHP to display a MySQL table. I've got everything working fine except the date function. I designated the first two fields VARCHAR. Those columns display just fine when I preview my web page, as do all the other columns except the third. I designated that one DATE. (The field name is

[PHP] connecting with C-code

2004-02-08 Thread E . H . Terwiel
I have a tried-and-tested (15 years of it) piece of C code that I could port from Windows to Linux, and I thought I put a PHP front on it. Is there a way to interface the C-code with PHP 4.3.4 ? If so, could you point me to docs ? frgr Erik -- PHP General Mailing List (http://www.php.net/) To un

[PHP] PHP Image : resolutions differs between platform

2004-02-08 Thread jun
I created a script that creates a thumbnail based on the script . I tested the scripting using WinXP/Apache/PHP/php_gd ... the resolution is desirable .. but when I finally deployed my script on the web.. where the Host runs on Linux/Apache/PHP/php_gd ... the resolution of the resized image is n

Re: [PHP] Revised: RE: [PHP] Re: Can I do this?

2004-02-08 Thread Andrew Séguin
The security hole is probably not existant in my opinion. PHP is (normaly) parsed by the remote server(no source viewable) and the result is being included, not the source. When "http://.../script.php?var=value"; was mentioned, it implies the script is being parsed remotedly so that the http reque

Re: [PHP] Application-level variables

2004-02-08 Thread Shaunak Kashyap
I haven't worked with ColdFusion much so I'm not quite sure what application-level variables are. However, I did do some quick research and I believe they are basically variables that are available to all scripts running on the server (correct me if I'm wrong). Assuming the above definition of app

Re: [PHP] Application-level variables

2004-02-08 Thread Justin French
You can auto-prepend a file to all PHP scripts as they are called, in which you could store some application-wide variables like database usernames and passwords, config irectives, etc, BUT it's important to note that this file is loaded into PHP on every call basically as an include, and each

[PHP] Application-level variables

2004-02-08 Thread Lloyd Bayley
Greetings Everyone, I am still new to PHP but am progressing nicely. I has helped a lot that I have had vast experience with ColdFusion (sorry) but have seen the light and am now doing rather nicely in PHP. My question is as follows... I have certain functions, variables etc that I would like

Re: [PHP] mcrypt don't work.

2004-02-08 Thread "Miguel J. Jiménez"
Mmm this same problem happen to me also... I use Apache 1.3.29 for Win32 and PHP v4.3.4 ... I do not know why but mcrypt module failed to initialize [EMAIL PROTECTED] wrote: Hi all, I have problem with mcrypt function. There is always an error that I don't know how to correct this. This is

[PHP] mcrypt don't work.

2004-02-08 Thread francesco
Hi all, I have problem with mcrypt function. There is always an error that I don't know how to correct this. This is my code: $string = "Text string"; $key= "My key"; $encrypted = mcrypt_cfb(MCRYPT_RIJNDAEL-256, $key, $string, MCRYPT_ENCRYPT); echo"stringa cifrata= $encrypted"; $key = "My key";

Re: [PHP] Revised: RE: [PHP] Re: Can I do this?

2004-02-08 Thread Adam Bregenzer
On Sun, 2004-02-08 at 04:14, PHP Email List wrote: > Ok so on this topic, I do something similar to this with my scripts, and if > my includes are vulnerable... I need to know how? > > I have tested this and the includes parse the information as it includes it, > I can't see the code, so how is th

[PHP] Revised: RE: [PHP] Re: Can I do this?

2004-02-08 Thread PHP Email List
Ok so on this topic, I do something similar to this with my scripts, and if my includes are vulnerable... I need to know how? I have tested this and the includes parse the information as it includes it, I can't see the code, so how is this possible where you say: { "If someone were to stu

Re: [PHP] Re: Can I do this?

2004-02-08 Thread Adam Bregenzer
On Sun, 2004-02-08 at 03:18, John Taylor-Johnston wrote: > Ah! A little experimenting ... Yes I can :) Answered my own question. > > include("http://elsewhere.com/list.php?number=$number";); Careful with that. If someone were to stumble upon your list.php script they would be able to see your ph

[PHP] Re: Can I do this?

2004-02-08 Thread John Taylor-Johnston
Ah! A little experimenting ... Yes I can :) Answered my own question. include("http://elsewhere.com/list.php?number=$number";); André Cerqueira wrote: > John Taylor-Johnston wrote: > > > Can I include a script on another server doing this? > > > > $sql = 'SELECT * FROM '.$table.' where number li