Re[2]: [PHP] Re: weird header() (bug may be)

2004-02-12 Thread Richard Davey
Hello Jason,

Thursday, February 12, 2004, 6:38:05 AM, you wrote:

 It should be this:
 header(Location: another_page.php);
 and NOT header(Location:another_page.php);

JW Also it should be an absolute URL otherwise it might break on some (standards
JW compliant only) browsers:

While I totally agree with both these pieces of advice, they're
unlikely to be the cause of the problem. YES you should have a space
after the Location: part and YES you should have an absolute URL,
*but* most modern browsers won't care if you haven't - the following
works perfectly on IE6/Opera7/Firefox - no matter how malformed it
looks:

Header(Location:page2.php);

Chris provided the solution to the original problem in his reply, but
I just wanted to bring this up. The OP should of course modify his
header statements, but its unlikely to resolve his problem on its own.

-- 
Best regards,
 Richardmailto:[EMAIL PROTECTED]

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



[PHP] Re: Zlib - Insert files?

2004-02-12 Thread Till Krüss
Thanks

But how can i put it into an tar archive before?


rgds Till

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



[PHP] getting month from date variable

2004-02-12 Thread Angelo Zanetti
HI,

I have looked the php manual and cannot find a function where I can extract
the month (in words) from a variable which contains a date.

eg:
I input :
 2004-01-26
 and the function must return:

January

Is there a php function like this? I dont want to reinvent the wheel. If
there isnt i will have to write my own.

Thanx in advance.
Angelo


Disclaimer 
This e-mail transmission contains confidential information,
which is the property of the sender.
The information in this e-mail or attachments thereto is 
intended for the attention and use only of the addressee. 
Should you have received this e-mail in error, please delete 
and destroy it and any attachments thereto immediately. 
Under no circumstances will the Cape Technikon or the sender 
of this e-mail be liable to any party for any direct, indirect, 
special or other consequential damages for any use of this e-mail.
For the detailed e-mail disclaimer please refer to 
http://www.ctech.ac.za/polic or call +27 (0)21 460 3911

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



RE: [PHP] getting month from date variable

2004-02-12 Thread Vincent Jansen
Don't reinvent

http://www.php.net/manual/en/function.strftime.php


-Original Message-
From: Angelo Zanetti [mailto:[EMAIL PROTECTED] 
Sent: donderdag 12 februari 2004 10:13
To: [EMAIL PROTECTED]
Subject: [PHP] getting month from date variable


HI,

I have looked the php manual and cannot find a function where I can
extract the month (in words) from a variable which contains a date.

eg:
I input :
 2004-01-26
 and the function must return:

January

Is there a php function like this? I dont want to reinvent the wheel. If
there isnt i will have to write my own.

Thanx in advance.
Angelo


Disclaimer 
This e-mail transmission contains confidential information, which is the
property of the sender. The information in this e-mail or attachments
thereto is 
intended for the attention and use only of the addressee. 
Should you have received this e-mail in error, please delete 
and destroy it and any attachments thereto immediately. 
Under no circumstances will the Cape Technikon or the sender 
of this e-mail be liable to any party for any direct, indirect, 
special or other consequential damages for any use of this e-mail. For
the detailed e-mail disclaimer please refer to 
http://www.ctech.ac.za/polic or call +27 (0)21 460 3911

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

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



[PHP] find some application

2004-02-12 Thread Poltak Reynold Priyadi
dear all,
i'm new in php programming
i would like to find some sample application to increase my knowledge.
would you tell me where will i find a sample application
or maybe some of you want to sent me anything about php or the sample code

thank you
best regards

-- 
Poltak Reynold Priyadi
Student of PI-DEL
Address : Jl Sisingamangaraja, Sitoluama, Laguboti, 
  Tobasa, North Sumatera,Indonesia
e-mail  : [EMAIL PROTECTED] or [EMAIL PROTECTED]
web : http://students.del.ac.id/~if02076
phone   : (061) 7871533

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



RE: [PHP] find some application

2004-02-12 Thread Jonathan Wilkes
How lazy are you ?

Just look up PHP on the web, give www.google.com a go - you might just learn 
something.



-Original Message-
From: Poltak Reynold Priyadi [mailto:[EMAIL PROTECTED]
Sent: 12 February 2004 09:58
To: [EMAIL PROTECTED]
Subject: [PHP] find some application


dear all,
i'm new in php programming
i would like to find some sample application to increase my knowledge.
would you tell me where will i find a sample application
or maybe some of you want to sent me anything about php or the sample code

thank you
best regards

-- 
Poltak Reynold Priyadi
Student of PI-DEL
Address : Jl Sisingamangaraja, Sitoluama, Laguboti, 
  Tobasa, North Sumatera,Indonesia
e-mail  : [EMAIL PROTECTED] or [EMAIL PROTECTED]
web : http://students.del.ac.id/~if02076
phone   : (061) 7871533

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



This message has been scanned for viruses by MailController - 
www.MailController.altohiway.com

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



RE: [PHP] [Q]PHP not taking input values from forms

2004-02-12 Thread Ford, Mike [LSS]
On 11 February 2004 18:01, Dan Aloma wrote:

 Sorry about not including code the first time. Here is a
 snippet of code I
 am fairly certain should be doing something. Thank you SOOO
 much for the
 help. I've been working on setting up php for four days now
 and EVERYTHING
 else works (phpinfo() calls, etc), but for some reason forms,
 even ones that
 I know should be working don't take values. They just return
 you to the same
 screen.
 
 CODE:
 html
 body
 
 brbr
 ?=$errormessage?
 br
 
 form action=?=$_SERVER['PHP_SELF']? method=post
 table width=500 border=0 cellpadding=5 cellspacing=0 tr
 tdYour name:/td
 tdinput type=text name=namevalue=?=$_POST['name']?/td
 /tr tr
 tdYour email:/td
 tdinput type=text name=email value=?=$_POST['email']?td
 tr tr
 tdYour message:/td
 tdtextarea
 name=message?=$_POST['message']?/textarea/td/tr /table
 input type=hidden name=required value=name,email,message
 input type=submit name=submit value=submit
 
 /body/html

H'mmm -- one other thought in addition to all the other good pointers: is 
short_open_tag On or Off?  Because if it's off, none of those ?= snippets will fire 
anyway.

Cheers!

Mike

-
Mike Ford,  Electronic Information Services Adviser,
Learning Support Services, Learning  Information Services,
JG125, James Graham Building, Leeds Metropolitan University,
Beckett Park, LEEDS,  LS6 3QS,  United Kingdom
Email: [EMAIL PROTECTED]
Tel: +44 113 283 2600 extn 4730  Fax:  +44 113 283 3211 

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



[PHP] Imagejpeg and image size question

2004-02-12 Thread John
Hi,
I am new to manipulating JPGs using PHP. But i managed to create an
application that displays an JPG image in the browser (see below).

I have boiled the code down to the most nesesary.

My problem is that when i load the file c:\file.jpg directly in the
IE browser (using IMG SRC='c:\file.jpg'), and then get properties on the
image by
right clicking in the browser. the size is the same as it is on the HD
(83Kb).

However when i use the PHP code and get properties on the image by
right clicking in the browser. the image size is 264Kb.

How come the picture is bigger when loaded trough PHP as it is when
loaded trough the browser directly ?

best regards
John


-generate_jpg_picture.php starts---
?php
 header(Content-type: image/jpeg, true);
 $path = $_GET['filepath'];
 $im = imagecreatefromjpeg($path);
 Imagejpeg($im, '', 100);
 ImageDestroy($im);
?
-generate_jpg_picture.php ends---
-some_file.php starts---
html
head
titlePHP Test/title
/head
body
 IMG SRC='generate_jpg_picture.php?filepath=?php echo
urlencode(c:\\file.jpg); ?'
 IMG SRC='c:\file.jpg'
/body
/html
-some_file.php ends---

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



RE: [PHP] find some application

2004-02-12 Thread Angelo Zanetti
go to www.php.net and www.phpfreaks.com

and look at the manual and on the NET!!! 

-Original Message-
From: Poltak Reynold Priyadi [mailto:[EMAIL PROTECTED]
Sent: Thursday, February 12, 2004 11:58 AM
To: [EMAIL PROTECTED]
Subject: [PHP] find some application


dear all,
i'm new in php programming
i would like to find some sample application to increase my knowledge.
would you tell me where will i find a sample application
or maybe some of you want to sent me anything about php or the sample code

thank you
best regards

-- 
Poltak Reynold Priyadi
Student of PI-DEL
Address : Jl Sisingamangaraja, Sitoluama, Laguboti, 
  Tobasa, North Sumatera,Indonesia
e-mail  : [EMAIL PROTECTED] or [EMAIL PROTECTED]
web : http://students.del.ac.id/~if02076
phone   : (061) 7871533

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


Disclaimer 
This e-mail transmission contains confidential information,
which is the property of the sender.
The information in this e-mail or attachments thereto is 
intended for the attention and use only of the addressee. 
Should you have received this e-mail in error, please delete 
and destroy it and any attachments thereto immediately. 
Under no circumstances will the Cape Technikon or the sender 
of this e-mail be liable to any party for any direct, indirect, 
special or other consequential damages for any use of this e-mail.
For the detailed e-mail disclaimer please refer to 
http://www.ctech.ac.za/polic or call +27 (0)21 460 3911

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



Re: [PHP] find some application

2004-02-12 Thread Richard Davey
Hello Poltak,

Thursday, February 12, 2004, 9:58:09 AM, you wrote:

PRP i would like to find some sample application to increase my knowledge.
PRP would you tell me where will i find a sample application
PRP or maybe some of you want to sent me anything about php or the sample code

http://www.hotscripts.com

and learn to use Google.

-- 
Best regards,
 Richardmailto:[EMAIL PROTECTED]

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



[PHP] bar code scaning in intranet ap

2004-02-12 Thread Michal Strnad
Hi,
I would like to make an application for DVD,VHS rental with PHP,MySQL, but I
don't know how to connect it with bar code scaner. Do you have an idea? I
hope, that I can use PHP for it :-)
Thanks
Michal

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



[PHP] Unique ID - again

2004-02-12 Thread Alex
Hi folks,
I'm using usual md5(microtime()); to create IDs, but now I've encountered a
problem with that. I need to create explicitly 6 digit unique
number(decimal). Yes, I know I can use for/while loop to fill a string with
digits, but is it ABSOLUTELY sure that the random will never return same
number when seed is microtime()? It is very important as the number will
identify a bank transfer...

Is there any other way than checking with all previous IDs? Or some MySQL
function to do this for me?

thank you
Alex

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



Re: [PHP] Unique ID - again

2004-02-12 Thread Richard Davey
Hello Alex,

Thursday, February 12, 2004, 11:00:41 AM, you wrote:

A I'm using usual md5(microtime()); to create IDs, but now I've encountered a
A problem with that. I need to create explicitly 6 digit unique
A number(decimal). Yes, I know I can use for/while loop to fill a string with
A digits, but is it ABSOLUTELY sure that the random will never return same
A number when seed is microtime()? It is very important as the number will
A identify a bank transfer...

If the data is so important - why are you restricting it to a 6 digit
key? You should ideally use the uniqid() function perhaps with a
combined lcg entropy at the end. That will give you a 13 character
long unique id - or md5 it for a 32 character one (see the manual for
examples).

A Is there any other way than checking with all previous IDs? Or some MySQL
A function to do this for me?

For something so important I would use (a) a longer unique ID and (b)
I'd still run a SQL check to see if the ID has been already used or
not. A simple MySQL count will bring that result back very quickly.

-- 
Best regards,
 Richardmailto:[EMAIL PROTECTED]

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



RE: [PHP] Please help me understand gmmktime()

2004-02-12 Thread Ford, Mike [LSS]
On 11 February 2004 20:26, Richard Day wrote:

 Hello:
 
 
 Environment:
 Linux server
 PHP 4.3.4
 
 This code:
 
 echo 'br'.strftime('%T %Z',mktime()).', Timestamp='.mktime();
 echo 'br'.strftime('%T GMT',gmmktime()).',
 Timestamp='.gmmktime();
 
 yields this result:
 
 23:52:08 EST, Timestamp=1076475128
 18:52:08 GMT, Timestamp=1076457128
 
 Why? GMT should be 5 hours ahead of EST, not 5 behind. Right?
 What am I
 missing here??

Well, that looks very suspicious, and probably not for the reasons you're
thinking.

I can explain why you get that result, but it means that either (a) there's
a bug in gmmktime(), or (b) the documentation for gmmktime() is wrong (or,
at least, misleading).  So, let's take it step-by-step:

1. gmmktime(), according to the manual, should use the current
corresponding GMT value for it's omitted arguments.
2. In my book, at 23:52:08 EST that means it should be using 04:52:08 GMT on
the following day (we'll discuss this later, since, whilst giving a
different result, it still wouldn't produce what you're expecting!).
3. However, let's guess that gmmktime() is actually using the *local* time
value of 23:52:08, but treating it as if it were GMT.
4. In which case, you'll get a timestamp for 23:52:08 GMT.
5. Because timestamps are absolute (not adjusted for timezone), this is also
the timestamp for 18:52:08 EST.
6. 18:52:08 is what you're getting printed.
7. QED.

This behaviour is *not* what the manual says should happen, and in my
opinion is counter-intuitive.  However, if gmmktime() were to behave as the
manual, at least how I read it, suggests, this is what would happen:

1. gmmktime() would calculate a timestamp for 04:52:08 GMT (next day).
2. Because timestamps are absolute, this is also the timestamp for 23:52:08
EST.
3. So strftime() still outputs 23:52:08.

Ergo, this is not the way to produce an adjusted time.  One way to do what
you're looking for is to feed the same timestamp to date('%H:%i:%s') and
gmdate('%H:%i:%s).  If you want something you can feed to strftime() for the
GMT date, you need to acquire your timezone's offset from GMT in seconds
(e.g. with date('Z');) and subtract that from the timestamp.

HTH

Cheers!

Mike

-
Mike Ford,  Electronic Information Services Adviser,
Learning Support Services, Learning  Information Services,
JG125, James Graham Building, Leeds Metropolitan University,
Beckett Park, LEEDS,  LS6 3QS,  United Kingdom
Email: [EMAIL PROTECTED]
Tel: +44 113 283 2600 extn 4730  Fax:  +44 113 283 3211 

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



Re[2]: [PHP] weird header() (bug may be)

2004-02-12 Thread adwinwijaya
Hello Chris,
Thursday, February 12, 2004, 5:57:55 PM, you wrote:


CS Nope. As others have pointed out, your Location header is improperly
CS formed.
CS However, your immediate problem is that, regardless of whether $foo ==
CS 'something', you *always* set the Location header to to_previous_page.php.
CS So, even if you set it to to_another_page.php previously, you're
CS overwriting it.
CS Hope that helps.
CS Chris
CS =
CS Chris Shiflett - http://shiflett.org/
CS PHP Security - O'Reilly
CS  Coming mid-2004
CS HTTP Developer's Handbook - Sams
CS  http://httphandbook.org/
CS PHP Community Site
CS  http://phpcommunity.org/


-- ok guys ... thanks for your answer   and my another question
-- why the php didnt stop processing after sending the header ?
-- because in my logic ... after sending the (redirect) to another
-- page .. the process shall be stopped  and thanks for your
-- advise ... I just know that I have to write location: with space
-- ... I am get used to do that for almost 1 year :)


-- 
Best regards,
 adwinwijayamailto:[EMAIL PROTECTED]

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



Re[3]: [PHP] weird header() (bug may be)

2004-02-12 Thread Richard Davey
Hello adwinwijaya,

Thursday, February 12, 2004, 11:11:48 AM, you wrote:

-- because in my logic ... after sending the (redirect) to another
-- page .. the process shall be stopped

In PHP's logic however, it doesn't stop :)

(Unless you tell it to by either using an exit() call or just making
the header function the last line of your script).

-- 
Best regards,
 Richardmailto:[EMAIL PROTECTED]

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



RE: [PHP] mutliple select form not passing multiple values

2004-02-12 Thread Ford, Mike [LSS]
On 11 February 2004 21:39, Ben Ramsey wrote:

 Ah-ha!  I missed that, and I always do.  Let's hope I don't anymore.
 While we're on the subject, why is PHP set up this way?  Why can't it
 just add the elements to the array automatically, since adding the
 square brackets to one's HTML form name is not a standard practice?

Well, then you would get the tradeoff that you have to test whether the value supplied 
is a simple scalar (because only one option was checked) or an array, before you could 
work with it.  IIRC, that's what you do in perl and ASP.  PHP takes the attitude that 
the code should be as simple as possible, and therefore it's the FORM's responsibility 
to indicate where POSTed values should be treated as arrays.

Personally, I think I could live with having to write code such as $checkboxes = 
(array)$checkboxes, but this is a choice the PHP implementers have taken, and I don't 
see it changing in the foreseeable future.

Cheers!

Mike

-
Mike Ford,  Electronic Information Services Adviser,
Learning Support Services, Learning  Information Services,
JG125, James Graham Building, Leeds Metropolitan University,
Beckett Park, LEEDS,  LS6 3QS,  United Kingdom
Email: [EMAIL PROTECTED]
Tel: +44 113 283 2600 extn 4730  Fax:  +44 113 283 3211 

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



Re: [PHP] bar code scaning in intranet ap

2004-02-12 Thread Andrew Séguin
Programming bar code reader from PHP?

It truly largely depends on the brand of bar code reader, and even then,
the model.

For example, I programed for an Intermec Antares 24xx series handheld
(that model is made for standalone/independant operation). For your
operations, this isn't very good model (not counting expensive).

Bar code readers work in serveral possible ways...
1. RF/networked (more advanced models)
2. serial port, where the reader streams what has been read in
3. keyboard port, and when it reads a bar code, it sends the proper
characters back to the computer.

I'd recommend baseing your design on models where the computer can have a
driver that does direct translation and the bar code reader acts like a
keyboard. Then you just have to make a standard webapp, and your text
input fields are populated by the values that are read in from the bar
codes.

I don't have any links off the top of my head to help you get a better
foundation in this, but google must have plenty ;)
To visit a company that works in bar code equipement, find Intermec's
website.

HTH,
Andrew

 Hi,
 I would like to make an application for DVD,VHS rental with PHP,MySQL, but
 I
 don't know how to connect it with bar code scaner. Do you have an idea? I
 hope, that I can use PHP for it :-)
 Thanks
 Michal

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




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



Re: [PHP] Running Apache in one machine and php in another

2004-02-12 Thread Harry Sufehmi
On 06/02/2004 at 11:55 Mrs. Geeta Thanu wrote:
This is in addition to my previous mail.
I feel the PHP script and the C program should be in one machine
and apache in another.
When a user click the link the php script should upload a form get the
input and show the result.
So apache should support running PHP in another machine.Is it possible.

It's possible.

The easiest way to do this is:

# On the webserver, you just need Apache, with a redirection setup.
So if a user entered http://webserver/genome-processing/ then it'll be redirected to 
http://application-server/genome-processing/
Example (put these in httpd.conf):


IfModule mod_proxy.c
ProxyPass /genome-processing/ http://application-server/genome-processing/
ProxyPassReverse /genome-processing/ http://application-server/genome-processing/
/IfModule


# On the application server, you'll need Apache+PHP and that C program.
genome-processing/index.php in this box should process all user input, and then 
execute the C program with system() function:
http://uk.php.net/manual/en/function.system.php

# Ensure that the output from the C program can be easily parsed in PHP, or better 
yet, already HTML-tagged properly so you don't need to process it any further in your 
PHP script - just printf() the whole of its output straightaway.

There are other ways to do this, but as I said I think this is the easiest way.
CMIIW of course.


regards,
-HS



On Fri, 6 Feb 2004, Jason Wong wrote:
 On Saturday 07 February 2004 02:57, Mrs. Geeta Thanu wrote:
  I have configured Apache webserver executing PHP scripts on sun machine
  and everything is  working fine.
 
  Now I want the web server to pass on the PHP executions to
  another machine and once done should get the result and display it.
 
  Is it possible .

--
Kampanye open-source Indonesia - http://www.DariWindowsKeLinux.com
Solusi canggih, bebas ikatan, dan bebas biaya

v0sw6Chw5ln3ck4u6Lw5-2Tl6+8Ds5MRr5e7t2Tb8TOp2/3en5+7g5HC - hackerkey.com

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



[PHP] Call to a member function on a non-object

2004-02-12 Thread Angelo Zanetti
HI,

I used my scripts yesterday and suddenly today they dont work and I get this
error: Call to a member function on a non-object
 it points to erroneous line that calls a function in 1 of my classes. The
class and this particular file have not been changed since i used them yest.
I also checked my DB and all is perfect. I read somewhere on the net that it
could have something to do with cache. But i couldnt find any helpful info.

perhaps someone has experienced this error before and what could cause it
and how do i fix it?

thanx in advance
Angelo


Disclaimer 
This e-mail transmission contains confidential information,
which is the property of the sender.
The information in this e-mail or attachments thereto is 
intended for the attention and use only of the addressee. 
Should you have received this e-mail in error, please delete 
and destroy it and any attachments thereto immediately. 
Under no circumstances will the Cape Technikon or the sender 
of this e-mail be liable to any party for any direct, indirect, 
special or other consequential damages for any use of this e-mail.
For the detailed e-mail disclaimer please refer to 
http://www.ctech.ac.za/polic or call +27 (0)21 460 3911

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



Re[2]: [PHP] Re: weird header() (bug may be)

2004-02-12 Thread adwinwijaya
Hello Eric,
Thursday, February 12, 2004, 10:57:57 PM, you wrote:

EB That's pretty wierd
EB Think i'll do some research on headers, need more info anyway ;)
EB But did my tip work in your script when you took a space there?
EB Just wondering...
EB Eric

No it still doesnt work ... I have to put die() or exit() after
calling the header();  and whether I put space and not using space
.. the result still same .. ( I am get used not to use space for
almost 1 year .. and suddenly I just know that I should put space :) )

In my logic, after we call header('location: foo.php'); the php
processor should terminated and open the page foo.php instead ...
cmmiw

-- 
Best regards,
 adwinwijayamailto:[EMAIL PROTECTED]

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



Re[3]: [PHP] Re: weird header() (bug may be)

2004-02-12 Thread Richard Davey
Hello adwinwijaya,

Thursday, February 12, 2004, 12:27:07 PM, you wrote:

a In my logic, after we call header('location: foo.php'); the php
a processor should terminated and open the page foo.php instead ...

Except that doesn't happen. See my other reply on this subject.

-- 
Best regards,
 Richardmailto:[EMAIL PROTECTED]

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



Re: [PHP] weird header() (bug may be)

2004-02-12 Thread Marek Kilimajer
adwinwijaya wrote:
-- ok guys ... thanks for your answer   and my another question
-- why the php didnt stop processing after sending the header ?
-- because in my logic ... after sending the (redirect) to another
-- page .. the process shall be stopped  and thanks for your
-- advise ... I just know that I have to write location: with space
-- ... I am get used to do that for almost 1 year :)
You might still want to do some processing after the redirect header.

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


Re: [PHP] Call to a member function on a non-object

2004-02-12 Thread Richard Davey
Hello Angelo,

Thursday, February 12, 2004, 12:33:39 PM, you wrote:

AZ I used my scripts yesterday and suddenly today they dont work and I get this
AZ error: Call to a member function on a non-object

If you have changed *nothing* at all that could influence the outcome
of this script then I would suggest you just upload your original
files again and over-write what is on the server. It's possible they
have been corrupted somehow.

Failing that it's time to start debugging - if you use a decent IDE
like Zend then start slapping breakpoints and watches all over the
place. If you don't, start echo'ing out values left right and centre
as you enter key parts of your script.

-- 
Best regards,
 Richardmailto:[EMAIL PROTECTED]

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



Re: [PHP] Call to a member function on a non-object

2004-02-12 Thread adwinwijaya
Hello Angelo,

Thursday, February 12, 2004, 11:33:39 PM, you wrote:

AZ HI,

AZ I used my scripts yesterday and suddenly today they dont work and I get this
AZ error: Call to a member function on a non-object
AZ  it points to erroneous line that calls a function in 1 of my classes. The
AZ class and this particular file have not been changed since i used them yest.
AZ I also checked my DB and all is perfect. I read somewhere on the net that it
AZ could have something to do with cache. But i couldnt find any helpful info.
AZ perhaps someone has experienced this error before and what could cause it
AZ and how do i fix it?
AZ thanx in advance
AZ Angelo

-- may be you have to check whether you have already include the file
-- or not .. sometimes, include_once (or require_once) could lead to
-- this error .. so try to use include or require .. hope it work :)


-- 
Best regards,
 adwinwijayamailto:[EMAIL PROTECTED]


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



[PHP] Re: weird header() (bug may be)

2004-02-12 Thread memoimyself
On 12 Feb 2004 at 17:20, adwinwijaya wrote:

 Hello php-generaler's ,
 
   I have a script like this :
 
   if($foo == 'something'){
   header('Location:to_another_page.php') ;
   }else
   {
do another thing in here
   }
 
   header('Location:to_previous_page.php');
 
 
   I got a problem ... when $foo == 'something' .. it wont redirect me to
   to_another_page.php  but if I put die(); after calling header(); ..
   it will work ...
 
   is this the bug ?

You're joking, right? Your second header statement is outside the if/else loop, so 
it's 
executed every time, obviously. This in turn means that your script will always 
redirect to 
previous_page.php, unless, of course, you kill it before it gets to the second 
header 
statement. Suggestion: read up on control structures (chapter 11 in the PHP manual).

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



[PHP] {ot help needed} mod_auth_mysql

2004-02-12 Thread Jay Blanchard
Does anyone here use mod_auth_mysql for authentication? I am STFW like
crazy, but I cannot find a solution for connecting to another mysql
server on the network. TVMIA!

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



[PHP] Re: form array

2004-02-12 Thread memoimyself
On 12 Feb 2004 at 0:29, Matthew Oatham wrote:

 I have a form on page1 that i want to submit to another php page - page2
 
 the form has the fields
 
 input type=hidden name=image[one] value=one
 input type=hidden name=image[two] value=two
 input type=hidden name=image[three] value=three
 
 Basically I want to have these form field values as an array of values I
 can loop through on page 2 but what do I put on page 2 too get the array
 and loop through ?

On page two you'll have $_POST['image'] as an array containing elements 'one', 'two' 
and 'three' ($_POST['image']['one'] etc). This is *pretty* basic, so I'm guessing 
you'll 
have to learn some more PHP before you can actually do anything with this array.

If you have some experience with other programming languages, you'll probably find 
that the first few chapters of the official PHP manual (http://www.php.net/manual/en/ 
) 
will get you up and running in no time flat.

Good luck,

Erik

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



Re: [PHP] weird header() (bug may be)

2004-02-12 Thread Marek Kilimajer
adwinwijaya wrote:

Hello php-generaler's ,

  I have a script like this :

  if($foo == 'something'){
  header('Location:to_another_page.php') ;
  }else
  {
   do another thing in here
  }
  header('Location:to_previous_page.php');

  I got a problem ... when $foo == 'something' .. it wont redirect me
  to to_another_page.php  but if I put die(); after calling
  header(); .. it will work ...
  is this the bug ?

  I use php 4.3.4 ... and Apache 2.x

  thanks
Another thing you need to know, header checks if the same header was 
output before, if yes, it is owerwriten by the second one. So if you write:

header('Location: foo.php');
header('Location: bar.php');
only one header is output.

You can pass false as the second parameter to header (replace 
parameter), in this case both headers are output.

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


Re: [PHP] bar code scaning in intranet ap

2004-02-12 Thread Michal
Great idea. Can I use a keyboard and bar code scanner together? How to use a
keyboard, if i connect a scanner into a keyboard port?

Michal



Andrew Séguin [EMAIL PROTECTED] píse v diskusním príspevku
news:[EMAIL PROTECTED]
 Programming bar code reader from PHP?

 It truly largely depends on the brand of bar code reader, and even then,
 the model.

 For example, I programed for an Intermec Antares 24xx series handheld
 (that model is made for standalone/independant operation). For your
 operations, this isn't very good model (not counting expensive).

 Bar code readers work in serveral possible ways...
 1. RF/networked (more advanced models)
 2. serial port, where the reader streams what has been read in
 3. keyboard port, and when it reads a bar code, it sends the proper
 characters back to the computer.

 I'd recommend baseing your design on models where the computer can have a
 driver that does direct translation and the bar code reader acts like a
 keyboard. Then you just have to make a standard webapp, and your text
 input fields are populated by the values that are read in from the bar
 codes.

 I don't have any links off the top of my head to help you get a better
 foundation in this, but google must have plenty ;)
 To visit a company that works in bar code equipement, find Intermec's
 website.

 HTH,
 Andrew

  Hi,
  I would like to make an application for DVD,VHS rental with PHP,MySQL,
but
  I
  don't know how to connect it with bar code scaner. Do you have an idea?
I
  hope, that I can use PHP for it :-)
  Thanks
  Michal
 
  --
  PHP General Mailing List (http://www.php.net/)
  To unsubscribe, visit: http://www.php.net/unsub.php
 
 
 

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



Re: [PHP] bar code scaning in intranet ap

2004-02-12 Thread Michal
Great idea. Can I use a keyboard and bar code scanner together? How to use a
keyboard, if i connect a scanner into a keyboard port?

Michal



Andrew Séguin [EMAIL PROTECTED] píse v diskusním príspevku
news:[EMAIL PROTECTED]
 Programming bar code reader from PHP?

 It truly largely depends on the brand of bar code reader, and even then,
 the model.

 For example, I programed for an Intermec Antares 24xx series handheld
 (that model is made for standalone/independant operation). For your
 operations, this isn't very good model (not counting expensive).

 Bar code readers work in serveral possible ways...
 1. RF/networked (more advanced models)
 2. serial port, where the reader streams what has been read in
 3. keyboard port, and when it reads a bar code, it sends the proper
 characters back to the computer.

 I'd recommend baseing your design on models where the computer can have a
 driver that does direct translation and the bar code reader acts like a
 keyboard. Then you just have to make a standard webapp, and your text
 input fields are populated by the values that are read in from the bar
 codes.

 I don't have any links off the top of my head to help you get a better
 foundation in this, but google must have plenty ;)
 To visit a company that works in bar code equipement, find Intermec's
 website.

 HTH,
 Andrew

  Hi,
  I would like to make an application for DVD,VHS rental with PHP,MySQL,
but
  I
  don't know how to connect it with bar code scaner. Do you have an idea?
I
  hope, that I can use PHP for it :-)
  Thanks
  Michal
 
  --
  PHP General Mailing List (http://www.php.net/)
  To unsubscribe, visit: http://www.php.net/unsub.php
 
 
 

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



Re: [PHP] bar code scaning in intranet ap

2004-02-12 Thread Michal
Great idea. Can I use a keyboard and bar code scanner together? How to use a
keyboard, if i connect a scanner into a keyboard port?

Michal


Andrew Séguin [EMAIL PROTECTED] píse v diskusním príspevku
news:[EMAIL PROTECTED]
 Programming bar code reader from PHP?

 It truly largely depends on the brand of bar code reader, and even then,
 the model.

 For example, I programed for an Intermec Antares 24xx series handheld
 (that model is made for standalone/independant operation). For your
 operations, this isn't very good model (not counting expensive).

 Bar code readers work in serveral possible ways...
 1. RF/networked (more advanced models)
 2. serial port, where the reader streams what has been read in
 3. keyboard port, and when it reads a bar code, it sends the proper
 characters back to the computer.

 I'd recommend baseing your design on models where the computer can have a
 driver that does direct translation and the bar code reader acts like a
 keyboard. Then you just have to make a standard webapp, and your text
 input fields are populated by the values that are read in from the bar
 codes.

 I don't have any links off the top of my head to help you get a better
 foundation in this, but google must have plenty ;)
 To visit a company that works in bar code equipement, find Intermec's
 website.

 HTH,
 Andrew

  Hi,
  I would like to make an application for DVD,VHS rental with PHP,MySQL,
but
  I
  don't know how to connect it with bar code scaner. Do you have an idea?
I
  hope, that I can use PHP for it :-)
  Thanks
  Michal
 
  --
  PHP General Mailing List (http://www.php.net/)
  To unsubscribe, visit: http://www.php.net/unsub.php
 
 
 

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



[PHP] Re: bar code scaning in intranet ap

2004-02-12 Thread Michal
Great idea. Can I use a keyboard and bar code scanner together? How to use a
keyboard, if i connect a scanner into a keyboard port?

Michal


Michal Strnad [EMAIL PROTECTED] pí¹e v diskusním pøíspìvku
news:[EMAIL PROTECTED]
 Hi,
 I would like to make an application for DVD,VHS rental with PHP,MySQL, but
I
 don't know how to connect it with bar code scaner. Do you have an idea? I
 hope, that I can use PHP for it :-)
 Thanks
 Michal

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



Re: [PHP] Re: I think this is a mysql question

2004-02-12 Thread Marek Kilimajer
Ronald Ramos wrote:

create table oras(
NameVARCHAR(30),
TimeIn DATETIME,
TimeOut DATETIME,
Total   DATETIME
);
insert into oras values('Nhadie','2004-10-10 10:10:00','2004-11-11
12:12:00','TIMEDIFF(TimeIn,TImeOut)');
Hi,

Are those correct? Because the value on the Total field is 000-00-00
00:00:00.
I think there's something wrong. I'm using 4.0.
mysql select * from oras;
++-+-+--
---+
| Name   | TimeIn  | TimeOut | Total
|
++-+-+--
---+
| Nhadie | 2004-10-10 10:10:00 | 2004-11-11 12:12:00 | -00-00
00:00:00 |
++-+-+--
---+
1 row in set (0.01 sec)
TIA
I would not use DATETIME column type for Total as it is dependable on 
the number of days in the month. Use INT and store the number of seconds 
instead. Then you can update the column using:

UPDATE oras SET Total = SELECT UNIX_TIMESTAMP(field1) - 
UNIX_TIMESTAMP(field2) [WHERE where_condition]

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


Re: [PHP] Re: I think this is a mysql question

2004-02-12 Thread Marek Kilimajer
Ronald Ramos wrote:

create table oras(
NameVARCHAR(30),
TimeIn DATETIME,
TimeOut DATETIME,
Total   DATETIME
);
insert into oras values('Nhadie','2004-10-10 10:10:00','2004-11-11
12:12:00','TIMEDIFF(TimeIn,TImeOut)');
Hi,

Are those correct? Because the value on the Total field is 000-00-00
00:00:00.
I think there's something wrong. I'm using 4.0.
mysql select * from oras;
++-+-+--
---+
| Name   | TimeIn  | TimeOut | Total
|
++-+-+--
---+
| Nhadie | 2004-10-10 10:10:00 | 2004-11-11 12:12:00 | -00-00
00:00:00 |
++-+-+--
---+
1 row in set (0.01 sec)
TIA
I would not use DATETIME column type for Total as it is dependable on 
the number of days in the month. Use INT and store the number of seconds 
instead. Then you can update the column using:

UPDATE oras SET Total = SELECT UNIX_TIMESTAMP(TimeIn) - 
UNIX_TIMESTAMP(TimeOut) [WHERE where_condition]

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


Re: [PHP] bar code scaning in intranet ap

2004-02-12 Thread James E Hicks III
On Thursday 12 February 2004 08:26 am, Michal wrote:
 Great idea. Can I use a keyboard and bar code scanner together? How to use
 a keyboard, if i connect a scanner into a keyboard port?

 Michal

You use a thing called a wedge. It plugs into your keyboard port on your 
computer. Then you plug in the keyboard and the scanner into the wedge. You 
must program your PHP to not look for submit buttons. You also need a 
browser that will submit a page when you press enter in a field.

You can also get scanners with USB connections that work like keyboards.

We've written a Warehouse Management System using these devices and a barcode 
printer. It's written in PHP and uses MySQL database. We use walkabout 
computers connected to the forklifts and cherrypickers. It's been working 
great now for almost a year now.

James Hicks

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



Re: [PHP] Imagejpeg and image size question

2004-02-12 Thread Tom Rogers
Hi,

Tuesday, February 10, 2004, 9:50:20 PM, you wrote:
J Hi,
J I am new to manipulating JPGs using PHP. But i managed to create an
J application that displays an JPG image in the browser (see below).

J I have boiled the code down to the most nesesary.

J My problem is that when i load the file c:\file.jpg directly in the
J IE browser (using IMG SRC='c:\file.jpg'), and then get properties on the
J image by
J right clicking in the browser. the size is the same as it is on the HD
J (83Kb).

J However when i use the PHP code and get properties on the image by
J right clicking in the browser. the image size is 264Kb.

J How come the picture is bigger when loaded trough PHP as it is when
J loaded trough the browser directly ?

J best regards
J John


J -generate_jpg_picture.php starts---
J ?php
J  header(Content-type: image/jpeg, true);
J  $path = $_GET['filepath'];
J  $im = imagecreatefromjpeg($path);
J  Imagejpeg($im, '', 100);
J  ImageDestroy($im);
?
J -generate_jpg_picture.php ends---
J -some_file.php starts---
J html
J head
J titlePHP Test/title
J /head
J body
J  IMG SRC='generate_jpg_picture.php?filepath=?php echo
J urlencode(c:\\file.jpg); ?'
J  IMG SRC='c:\file.jpg'
J /body
J /html
J -some_file.php ends---


Because you are sending it at 100% quality which is no compression, try
backing it off to 30%. Probably the original was not at 100% quality
anyway.

-- 
regards,
Tom

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



[PHP] Problem with SQL Server.

2004-02-12 Thread Juan Torres
Hello,

I'm working with a DB SQL Server. This DB has a table with Japanese
characters.
When I read a field (with Japanese characters) with function
mssql_fetch_array(), always it return characters '?'.

If I put 'print((Japanese characters));', these Japanese characters are
shown correctly.

My PHP file has follow code to work with Japanese characters:

mb_internal_encoding(EUC-JP);
mb_http_output(EUC-JP);
mb_http_input(EUC-JP);
mb_language(Japanese);

My question: How can I show correctly the Japanese characters from a SQL
Server DataBase?

Thanks very much!
Juan Torres.

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



Re: [PHP] Problem with XSLT Sablotron

2004-02-12 Thread Raditha Dissanayake
Hi,

I believe it's hiccuping at this:

msxsl:script language=JScript implements-prefix=user
![CDATA[
  function EscapeURL(selection) {
if (selection(0) == null)
  return ;
else if (selection(0).hasChildNodes())
  return escape(selection(0).childNodes(0).nodeTypedValue);
else
  return escape(selection(0).nodeTypedValue);
  }
]]
/msxsl:script
not being an expert on the MS XML api i not in a position to help you further. you should send this to an XSLT list.



Juan Torres wrote:

Hi,

When I run my php file, this error message is shown:
Warning: Sablotron error on line 27: function 'user:EscapeURL' not supported
in c:\inetpub\wwwroot\projects_php\testing\test_xsl.php on line 7
Sorry, sample.xml could not be transformed by sample.xsl into result.xml the
reason is that function 'user:EscapeURL' not supported and the error code is
51
Can anybody help me? I cann't solve this error.

Thanks very much!
Juan Torres.
PS: Excuse me, my english is bad :(

 



--
Raditha Dissanayake.

http://www.radinks.com/sftp/ | http://www.raditha.com/megaupload
Lean and mean Secure FTP applet with | Mega Upload - PHP file uploader
Graphical User Inteface. Just 150 KB | with progress bar.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[PHP] PHP and DDE

2004-02-12 Thread Manuel Ochoa
Can PHP interface with other programs through DDE?


[PHP] recode segmentation fault

2004-02-12 Thread mehdi
hi,
I am having problems with recode  extension for php 4.3.4.
this is the configure options :
'./configure' '--prefix=/usr/local/linkbynet/php'
'--with-gd=/usr/local/linkbynet/gd2' '--enable-gd-native-ttf'
'--with-freetype-dir=/usr/local/linkbynet/freetype2'
'--with-jpeg-dir=/usr/local/linkbynet/jpeg6b/'
'--with-pdflib=/usr/local/linkbynet/pdflib'
'--with-png-dir=/usr/local/linkbynet/libpng'
'--with-dom=/usr/local/linkbynet/libxml2'
'--with-zlib=/usr/local/linkbynet/zlib'
'--with-mysql=/usr/local/linkbynet/mysql'
'--with-apxs=/usr/local/linkbynet/apache/bin/apxs' '--with-imap'
'--with-recode' '--enable-ftp' '--enable-bcmath'
this sample code gives me a segmentation fault :
?
   $text =
 062806310648062D002006270644063306480642002006270630062
.70631062C0639062A002006460643064506440020064A062706380
.628064A00200627064406270645062706310627062A00200645064
.6002006280646062A0020062706440631064A06270636;
   $text = pack(H*, $text);
   $text = recode(ucs2..utf-8, $text);
   echo '$text'\n;
?
$text is a ucs2 text in hexadecimal. so I just decode it with pack() and
then convert it into utf-8.
if I remove 4 digits at the end of the hexa or add 4 digits (0623 for
example) at the end, it works.
what can I do about this?
thanks for your help.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] [Q]PHP not taking input values from forms

2004-02-12 Thread Dan Aloma
that tag is working fine and shows me the info. For some reason php will 
take input values only from the URL, not from the html code. any ideas?


From: André Cerqueira [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Subject: Re: [PHP] [Q]PHP not taking input values from forms
Date: Wed, 11 Feb 2004 23:56:37 -0300
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
time() is only echo'ed if $_POST['submit'] is something on this case
maybe he has a really old version of php...
$HTP_POST_VARS...?
do what Richard Davey is saying, ?=phpinfo()? on the top

Richard Davey wrote:

Hello Dan,

Wednesday, February 11, 2004, 6:39:35 PM, you wrote:

DA they're being tested on a testing machine we use. I know PHP is 
(rather
DA appears to be) working fine. Why would it be parsing files fine and 
calling
DA phpinfo() fine, but not being able to take input values. that's 
strange

echo time() isn't an input value.

If it can't even do that then it's not surprising it can't handle
$_POST values either, there is something else at play here and it's
not your code.
Stick echo phpinfo() at the top of your form code - does it work?

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.2.4 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQFAKutoaxdA/5C8vH8RAo1WAJ9MZMtBAvXcJDizOVXblxp1DlCqSgCeNDdm
rmE+jBIlMe4Hb6qaIUObCiQ=
=NvxC
-END PGP SIGNATURE-
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
_
Plan your next US getaway to one of the super destinations here. 
http://special.msn.com/local/hotdestinations.armx

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


Re: [PHP] [Q]PHP not taking input values from forms

2004-02-12 Thread Philip Olson
On Thu, 12 Feb 2004, Dan Aloma wrote:

 that tag is working fine and shows me the info. For some reason php will 
 take input values only from the URL, not from the html code. any ideas?

A few questions:

  a) What's the exact version of PHP?
  b) Please post the smallest possible form that creates this 
 problem.
  c) And how are you attempting to access these form values?

If you're interested in some working examples and related
information, have a look at the following manual page:

  http://www.php.net/variables.external

Regards,
Philip

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



Re: Re[2]: [PHP] weird header() (bug may be)

2004-02-12 Thread Chris Shiflett
--- adwinwijaya [EMAIL PROTECTED] wrote:
 why the php didnt stop processing after sending the header? because
 in my logic ... after sending the (redirect) to another page .. the
 process shall be stopped

This might make sense to you, but only because you're thinking of header()
as a redirect function. First, you must realize that it is not. It is a
function that sets an HTTP header.

If you've worked with headers much before, you may have run into an error
that says something like this:

Warning: Cannot add header information - headers already sent by (output
started at ...) in ... on line ...

To avoid this error, people must either set the headers they want prior to
any output (often by placing calls to header() at the top), or they use
output buffering.

So, consider that you use header() at the top of your script. Now, you
want to generate an image, so your script begins like this:

?
header('Content-Type: image/png');

The rest of the script generates the image. Wouldn't you be frustrated if
PHP decided to stop at the header() call? That would certainly frustrate
me.

Now, PHP could identify when the header() call is going to change the
status code of the response. Perhaps, if the response is going to be a
300-level response, PHP should exit afterward. But, why make such a
dangerous assumption when the developer can exit if he/she wants?

It would also break things like this:

?
header('Location: http://default.org/');

if ($foo)
{
 header('Location: http://foo.org/');
}
elseif ($bar)
{
 header('Location: http://bar.org/');
}
?

While this may not be eloquent, hopefully it is clear that the author
intends for the user to only get redirected to http://default.org/ if both
$foo and $bar are false. If PHP exited immediately after the first line,
this script would not behave as the developer intendend. PHP's assumption
would be wrong.

Hope that helps.

Chris

=
Chris Shiflett - http://shiflett.org/

PHP Security - O'Reilly
 Coming mid-2004
HTTP Developer's Handbook - Sams
 http://httphandbook.org/
PHP Community Site
 http://phpcommunity.org/

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



Re: [PHP] Unique ID - again

2004-02-12 Thread Galen
MySQL (or another SQL database) is the answer. You can check for an 
existing OR use it's auto_increment or whatever else you like.

Create a field to track all this stuff. There is no other way to 
guarantee that an ID is unique than to check it against existing. 
Random functions yield random results, so each time, there is ALWAYS 
a chance of a number being repeated. Microtime works pretty well, but 
there is STILL a chance two people could have a transaction at the same 
time. Yes, the odds can be insanely, insanely small for various 
functions (i.e. MD5) but as you shorten the length of your number, the 
odds get higher.

And yes, it's important to realize that a 6 digit unique identifier is 
limited to 1 million possible combinations, not nearly enough for most 
banks.

I might suggest you do some more PHP learning before you go and develop 
an online bank application - this stuff is pretty fundamental 
programming and database concepts. If your overall skill level isn't 
very high, you're likely to make mistakes, and either have errors, 
problems in functionality, or, worse, security problems.

-Galen

On Feb 12, 2004, at 3:00 AM, Alex wrote:

Hi folks,
I'm using usual md5(microtime()); to create IDs, but now I've 
encountered a
problem with that. I need to create explicitly 6 digit unique
number(decimal). Yes, I know I can use for/while loop to fill a string 
with
digits, but is it ABSOLUTELY sure that the random will never return 
same
number when seed is microtime()? It is very important as the number 
will
identify a bank transfer...

Is there any other way than checking with all previous IDs? Or some 
MySQL
function to do this for me?

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


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


Re: [PHP] [Q]PHP not taking input values from forms

2004-02-12 Thread Dan Aloma
Thanks for the suggestions, first of all. I tried that exact code from the 
code you included and I cut and pasted the Simple HTML Form, and below 
that I pasted the Accessing Data... php code. When I go to the page, all 
it does after I hit the submit button with data in the fields, is say no 
input file specified. But when I run it through the url giving the input 
names with values, it returns them. I tried getting it working with like ten 
people so far, and no one's been able to figure out... I am running PHP 
4.3.4, btw.

From: Philip Olson [EMAIL PROTECTED]
To: Dan Aloma [EMAIL PROTECTED]
CC: [EMAIL PROTECTED], [EMAIL PROTECTED]
Subject: Re: [PHP] [Q]PHP not taking input values from forms
Date: Thu, 12 Feb 2004 16:44:37 + (GMT)
On Thu, 12 Feb 2004, Dan Aloma wrote:

 that tag is working fine and shows me the info. For some reason php will
 take input values only from the URL, not from the html code. any ideas?
A few questions:

  a) What's the exact version of PHP?
  b) Please post the smallest possible form that creates this
 problem.
  c) And how are you attempting to access these form values?
If you're interested in some working examples and related
information, have a look at the following manual page:
  http://www.php.net/variables.external

Regards,
Philip
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
_
Find great local high-speed Internet access value at the MSN High-Speed 
Marketplace. http://click.atdmt.com/AVE/go/onm00200360ave/direct/01/

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


Re: [PHP] A dumb question

2004-02-12 Thread David T-G
Jeremy --

You have started a new thread by taking an existing message and replying
to it while merely changing the Subject: line.

That is bad, because it breaks threading.  Whenever you reply to a
message, your mail client generates a References: header that tells all
recipients to which posting(s) your posting refers.  A mail client uses
this information to build a thread tree of the postings so that it is
easy to see just how they relate to each other.

With your posting style you successfully torpedoed this useful feature;
your posting shows up within an existing thread even though it is
completely unrelated.

Always do a fresh post when you want to start a new thread.  That means
that you do not select any sort of Reply when you start your message.
You can save the list address in your address book (or equivalent) for
convenience.

...and then Jeremy Schroeder said...
% 
% Hey Group

Hi!


% 
% I am starting to write class and objects and came across some syntax 
% that I dont understand.
% 
% What does the ampersand do in the bottom example code, they both work.
% 
% $n1 = $num1 - function();
% $n1 =  $num1 - function();

1) Search the manual.

2) Assigning by reference, as compared to the default assigning by value,
means that the variable on the left of the '=' now points to the very
same little chunk of memory as the variable on the right.  This is
different from the usual assignment in that when you change the left var
you change the value for the right var, too.

  $a = 1 ;
  $b = $a ;
  $c = $a ;
  $b++ ; $c-- ;
  print a = $a ; b = $b ; c = $c ;\n ;
  // a = 0 ; b = 2 ; c = 0

3) You can't, as far as I know, assign-by-reference a function, so your
code should generate a parse error.


% 
% -Blake


HTH  HAND

:-D
-- 
David T-G  * There is too much animal courage in 
(play) [EMAIL PROTECTED] * society and not sufficient moral courage.
(work) [EMAIL PROTECTED]  -- Mary Baker Eddy, Science and Health
http://justpickone.org/davidtg/  Shpx gur Pbzzhavpngvbaf Qrprapl Npg!



pgp0.pgp
Description: PGP signature


RE: [PHP] A dumb question

2004-02-12 Thread Alex Hogan
HAND?

I haven't seen that one...

 -Original Message-
 From: David T-G [mailto:[EMAIL PROTECTED]
 Sent: Thursday, February 12, 2004 11:34 AM
 To: PHP General list
 Cc: Jeremy Schroeder
 Subject: Re: [PHP] A dumb question
 
 Jeremy --
 
 You have started a new thread by taking an existing message and replying
 to it while merely changing the Subject: line.
 
 That is bad, because it breaks threading.  Whenever you reply to a
 message, your mail client generates a References: header that tells all
 recipients to which posting(s) your posting refers.  A mail client uses
 this information to build a thread tree of the postings so that it is
 easy to see just how they relate to each other.
 
 With your posting style you successfully torpedoed this useful feature;
 your posting shows up within an existing thread even though it is
 completely unrelated.
 
 Always do a fresh post when you want to start a new thread.  That means
 that you do not select any sort of Reply when you start your message.
 You can save the list address in your address book (or equivalent) for
 convenience.
 
 ...and then Jeremy Schroeder said...
 %
 % Hey Group
 
 Hi!
 
 
 %
 % I am starting to write class and objects and came across some syntax
 % that I dont understand.
 %
 % What does the ampersand do in the bottom example code, they both work.
 %
 % $n1 = $num1 - function();
 % $n1 =  $num1 - function();
 
 1) Search the manual.
 
 2) Assigning by reference, as compared to the default assigning by value,
 means that the variable on the left of the '=' now points to the very
 same little chunk of memory as the variable on the right.  This is
 different from the usual assignment in that when you change the left var
 you change the value for the right var, too.
 
   $a = 1 ;
   $b = $a ;
   $c = $a ;
   $b++ ; $c-- ;
   print a = $a ; b = $b ; c = $c ;\n ;
   // a = 0 ; b = 2 ; c = 0
 
 3) You can't, as far as I know, assign-by-reference a function, so your
 code should generate a parse error.
 
 
 %
 % -Blake
 
 
 HTH  HAND
 
 :-D
 --
 David T-G  * There is too much animal courage in
 (play) [EMAIL PROTECTED] * society and not sufficient moral courage.
 (work) [EMAIL PROTECTED]  -- Mary Baker Eddy, Science and
 Health
 http://justpickone.org/davidtg/  Shpx gur Pbzzhavpngvbaf Qrprapl Npg!



** 
The contents of this e-mail and any files transmitted with it are 
confidential and intended solely for the use of the individual or 
entity to whom it is addressed.  The views stated herein do not 
necessarily represent the view of the company.  If you are not the 
intended recipient of this e-mail you may not copy, forward, 
disclose, or otherwise use it or any part of it in any form 
whatsoever.  If you have received this e-mail in error please 
e-mail the sender. 
** 




Re: [PHP] A dumb question

2004-02-12 Thread John Nichel
Alex Hogan wrote:
HAND?

I haven't seen that one...
Have A Nice Day

--
By-Tor.com
It's all about the Rush
http://www.by-tor.com
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] A dumb question

2004-02-12 Thread Jeremy Schroeder
Sorry for the mistake.

I check the email I sent and I only sent it to the group,  I changed the 
subject an removed all the of the message.

Blake

David T-G wrote:

Jeremy --

You have started a new thread by taking an existing message and replying
to it while merely changing the Subject: line.
That is bad, because it breaks threading.  Whenever you reply to a
message, your mail client generates a References: header that tells all
recipients to which posting(s) your posting refers.  A mail client uses
this information to build a thread tree of the postings so that it is
easy to see just how they relate to each other.
With your posting style you successfully torpedoed this useful feature;
your posting shows up within an existing thread even though it is
completely unrelated.
Always do a fresh post when you want to start a new thread.  That means
that you do not select any sort of Reply when you start your message.
You can save the list address in your address book (or equivalent) for
convenience.
...and then Jeremy Schroeder said...
% 
% Hey Group

Hi!

% 
% I am starting to write class and objects and came across some syntax 
% that I dont understand.
% 
% What does the ampersand do in the bottom example code, they both work.
% 
% $n1 = $num1 - function();
% $n1 =  $num1 - function();

1) Search the manual.

2) Assigning by reference, as compared to the default assigning by value,
means that the variable on the left of the '=' now points to the very
same little chunk of memory as the variable on the right.  This is
different from the usual assignment in that when you change the left var
you change the value for the right var, too.
 $a = 1 ;
 $b = $a ;
 $c = $a ;
 $b++ ; $c-- ;
 print a = $a ; b = $b ; c = $c ;\n ;
 // a = 0 ; b = 2 ; c = 0
3) You can't, as far as I know, assign-by-reference a function, so your
code should generate a parse error.
% 
% -Blake

HTH  HAND

:-D
 

--

+-+-++
| Blake Schroeder | Owner/Developer |lhwd.net|
+--(http://www.lhwd.net)+--/3174026352\--+
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[PHP] Re: weird header() (bug may be)

2004-02-12 Thread Anil Kumar K.

This is not a bug. Here you expect that the script should end executing
after the statement:header('Location:to_another_page.php') if the if
statement is true. But it won't and it proceeds to the next statement;
the next header statement:header('Location:to_previous_page.php');

An exit statement after the first header will solve the problem. With
most browsers, if multiple redirect headers are received, the last
instruction is followed. I'm not sure what the RFC says about this.

   Anil

On Thu, 12 Feb 2004, adwinwijaya wrote:

 Hello php-generaler's ,
 
   I have a script like this :
 
   if($foo == 'something'){
   header('Location:to_another_page.php') ;
   }else
   {
do another thing in here
   }
 
   header('Location:to_previous_page.php');
 
 
   I got a problem ... when $foo == 'something' .. it wont redirect me
   to to_another_page.php  but if I put die(); after calling
   header(); .. it will work ...
 
   is this the bug ?
 
   I use php 4.3.4 ... and Apache 2.x
 
   thanks
   
 
 

--

Linuxense Information Systems Pvt. Ltd., Trivandrum, India
http://www.linuxense.com/

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



[PHP] Using date() with the function fileatime() doesn't return accurate timestamp...

2004-02-12 Thread Scott Fletcher
I saw the article at http://us2.php.net/manual/en/function.fileatime.php and
gave it a shot with the timestamp for the file but it doesn't work correctly
because it only returned the current timestamp (as it is from our watch or
clock) but not the one from the file...

I had verify that the file is correct and that the date() is working
correctly and that the timeatime() is working correctly if they are tested
independantly, so it is just putting them all three together cause them not
to work right...

--snip--
$current_filename = test.pdf;
echo (date('F j, Y, h:i a', (fileatime($current_filename;
--snip--

What did I do wrong??

Scott F.

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



[PHP] PHP with FTP installation

2004-02-12 Thread rodner
Hi,
  I just know how to reconfigure php installation with --ftp-enable. I
already did a ./configure --ftp-enable command but when echo the
phpinfo() hust to see if its been updated, its still showing
./configure' '--with-mysql' '--with-apxs=/www/bin/apxs' on the configure
command.

I would appreciate any help. thanks

Rodner

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



[PHP] Re: Using date() with the function fileatime() doesn't return accurate timestamp...

2004-02-12 Thread Scott Fletcher
Oh I understand now.  There is a different between fileatime(), filectime()
and filemtime(), with a letter 'a', 'c' or 'm'...  The one with the m is
what work with Unix/Linux..

Scott F.

Scott Fletcher [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
 I saw the article at http://us2.php.net/manual/en/function.fileatime.php
and
 gave it a shot with the timestamp for the file but it doesn't work
correctly
 because it only returned the current timestamp (as it is from our watch or
 clock) but not the one from the file...

 I had verify that the file is correct and that the date() is working
 correctly and that the timeatime() is working correctly if they are tested
 independantly, so it is just putting them all three together cause them
not
 to work right...

 --snip--
 $current_filename = test.pdf;
 echo (date('F j, Y, h:i a', (fileatime($current_filename;
 --snip--

 What did I do wrong??

 Scott F.

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



RE: [PHP] Re: Using date() with the function fileatime() doesn't return accurate timestamp...

2004-02-12 Thread Roger B.A. Klorese
 Oh I understand now.  There is a different between 
 fileatime(), filectime()
 and filemtime(), with a letter 'a', 'c' or 'm'...  The one 
 with the m is
 what work with Unix/Linux..

Um, they all work with Unix/Linux -- they just mean different things.

Atime is the time a file was last accessed.
Mtime is the time the contents of a file were last modified.
Ctime is the time the metadata about a file -- length, owner, permissions,
times -- were last updated.

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



[PHP] php5beta4 problem

2004-02-12 Thread Gareth Thomas
Hi,

just updated from beta3 (which worked fine) and now my system is hosed. I am
running Apache 1.3.29 on WinXP and when I try and simply bring up phpinfo I
get the following message in the Apache error log file:

Premature end of script headers: c:/php/php.exe

Anyone any idea what is causing this?? One thing I did notice is that the
Zip distribution of b4 is different to b3, for example it no longer creates
a sapi directory with the apache dll's in, so I am wondering if this problem
might be due to subtle differences in the distribution.

Any help would be much appreciated.

G.

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



[PHP] PHP License question

2004-02-12 Thread Ben Ramsey
I currently developing a project that I wish to release under a, 
preferably, open-source and copy-left license.  So, I'm taking a close 
look at the GNU GPL for this, and it seems to serve this purpose, well. 
 However, I am aware that the PHP license conflicts with the GNU GPL, 
and, thus, anything released under the PHP license cannot also be 
released in software under the GPL.  At least, this is my assumption.

Now, to my question: if a PEAR package is released under the PHP 
license, and my product is under the GPL, can I include the PEAR package 
in my product?  Under the above assumption, the answer would be no.  So, 
what license should I release my product under to maintain it's 
copy-left status and yet still allow the PEAR packages to be included?

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


[PHP] sql query question

2004-02-12 Thread tony
hi

if i have  new  car and i want to search
each word in description
can i do
SELECT * FROM table WHERE
descript = new OR descript =car??

any help is appreciated

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



[PHP] Re: sql query question

2004-02-12 Thread Ben Ramsey
This is a SQL question, rather than a PHP question, so I would suggest 
doing a google search on SQL tutorials, but I think what you are trying 
to do would work like this:

SELECT * FROM table WHERE descript LIKE '%new%' OR descript LIKE '%car%'



Tony wrote:

hi

if i have  new  car and i want to search
each word in description
can i do
SELECT * FROM table WHERE
descript = new OR descript =car??
any help is appreciated
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[PHP] (retry) [ANN] Kwartz -- a template system for PHP, Ruby and Java

2004-02-12 Thread [EMAIL PROTECTED]
Hi all,
(B
(BI'm pleased to announce a public release of Kwartz.
(B
(BKwartz(*1) is a template sysmtem for web-designer and web-programmer.
(B
(BKwartz has the following features.
(B
(B* Kwartz can separate presentation logic from a template.
(B* Kwartz can be available in PHP, Ruby and Java.
(B* Kwartz doesn't break HTML design at all.
(B* Kwartz can handle any type of text file.
(B* Kwartz can sanitize automatically.
(B
(BSee Kwartz User's Guide for more detail. 
(B
(BHomepage:
(Bhttp://www.kuwata-lab.com/webtech/kwartz/index.html
(B
(BDownload:
(Bhttp://www.kuwata-lab.com/webtech/kwartz/kwartz_2004-02-12.tar.gz
(B
(BUser's Guide:
(B(English)
(Bhttp://www.kuwata-lab.com/webtech/kwartz/users-guide.en.html
(B(Japanese)
(Bhttp://www.kuwata-lab.com/webtech/kwartz/users-guide.ja.html
(B
(B
(B(*1) Development of Kwartz is subsidized by Exploratory Software
(B Project of IPA  (Information-Technology Promotion Agency Japan).
(B
(B
(BHave fun!
(B
(B--
(Bregards,
(Bkwa
(B
(B-- 
(BPHP General Mailing List (http://www.php.net/)
(BTo unsubscribe, visit: http://www.php.net/unsub.php

[PHP] IMAP/SSL on Windows

2004-02-12 Thread Dan Phiffer
Hello,

I'm trying to get an SSL-encrypted IMAP connection to work on my Windows
box. Here's the error message I get when attempting to connect:
Warning: imap_open(): Couldn't open stream
{snip:993/imap/ssl/novalidate-cert}INBOX in
D:\Dan\Projects\Mail\mail.php on line 92
I'm running Windows XP Pro, Apache 2 and PHP 4.3.4 (CGI) and have the 
following listed in my phpinfo():

imap
IMAP c-Client Version   2001
openssl
OpenSSL support enabled
OpenSSL Version OpenSSL 0.9.7b 10 Apr 2003
Thanks for any help,
-Dan
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] [Q]PHP not taking input values from forms

2004-02-12 Thread Philip Olson

   that tag is working fine and shows me the info. For some reason php will
   take input values only from the URL, not from the html code. any ideas?
 
 A few questions:
 
a) What's the exact version of PHP?
b) Please post the smallest possible form that creates this
   problem.
c) And how are you attempting to access these form values?
 
 If you're interested in some working examples and related
 information, have a look at the following manual page:
 
http://www.php.net/variables.external

 Thanks for the suggestions, first of all. I tried that exact code from the 
 code you included and I cut and pasted the Simple HTML Form, and below 
 that I pasted the Accessing Data... php code. When I go to the page, all 
 it does after I hit the submit button with data in the fields, is say no 
 input file specified. But when I run it through the url giving the input 
 names with values, it returns them. I tried getting it working with like ten 
 people so far, and no one's been able to figure out... I am running PHP 
 4.3.4, btw.


Be sure you rename the action part of the simple html form 
to whatever page you are using, instead of foo.php, as otherwise 
it will literally attempt to access foo.php  I'm guessing this 
is what's happening by seeing no input file specified.

Either fix that or on that same manual page is the example 
titled More complex form variables, this prints to itself
as it demonstrates a use of the popular $_SERVER['PHP_SELF'] 
variable.

Also, it's important you realize the difference between POST
and GET, and how to access them, so you may want to read that
manual page too. (hint: GET is through the URL's QUERY_STRING
(the stuff after the ?) while POST is not).

Regards,
Philip

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



[PHP] Re: PHP License question

2004-02-12 Thread Dan Phiffer
Ben Ramsey wrote:

Now, to my question: if a PEAR package is released under the PHP 
license, and my product is under the GPL, can I include the PEAR package 
in my product?
I don't know if this satisfies the legal requirement, but perhaps you 
could script some kind of automatic PEAR installation (assuming PEAR was 
already configured)?

-Dan

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


RE: [PHP] [Q]PHP not taking input values from forms

2004-02-12 Thread Vail, Warren
Suggestion,

Stick the following line of code in a spot in the php code that gets control
from the form submit and see what is actually being passed from the form;

foreach($_POST as $k = $v) echo POST[.$k.] = [.$v.]br;

see if this shows you what you are looking for.

NOTE: if you are not using the form POST method, change all instances of
POST to GET in the statement.

good luck,

Warren Vail


-Original Message-
From: Philip Olson [mailto:[EMAIL PROTECTED]
Sent: Thursday, February 12, 2004 1:55 PM
To: Dan Aloma
Cc: [EMAIL PROTECTED]; [EMAIL PROTECTED]
Subject: Re: [PHP] [Q]PHP not taking input values from forms



   that tag is working fine and shows me the info. For some reason php
will
   take input values only from the URL, not from the html code. any
ideas?
 
 A few questions:
 
a) What's the exact version of PHP?
b) Please post the smallest possible form that creates this
   problem.
c) And how are you attempting to access these form values?
 
 If you're interested in some working examples and related
 information, have a look at the following manual page:
 
http://www.php.net/variables.external

 Thanks for the suggestions, first of all. I tried that exact code from the

 code you included and I cut and pasted the Simple HTML Form, and below 
 that I pasted the Accessing Data... php code. When I go to the page, all

 it does after I hit the submit button with data in the fields, is say no 
 input file specified. But when I run it through the url giving the input 
 names with values, it returns them. I tried getting it working with like
ten 
 people so far, and no one's been able to figure out... I am running PHP 
 4.3.4, btw.


Be sure you rename the action part of the simple html form 
to whatever page you are using, instead of foo.php, as otherwise 
it will literally attempt to access foo.php  I'm guessing this 
is what's happening by seeing no input file specified.

Either fix that or on that same manual page is the example 
titled More complex form variables, this prints to itself
as it demonstrates a use of the popular $_SERVER['PHP_SELF'] 
variable.

Also, it's important you realize the difference between POST
and GET, and how to access them, so you may want to read that
manual page too. (hint: GET is through the URL's QUERY_STRING
(the stuff after the ?) while POST is not).

Regards,
Philip

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

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



[PHP] negative impact on session management after turning off trans_id?

2004-02-12 Thread Chris W. Parker
Hi.

I'm wondering if there are any negative side affects to turning off the
trans_id? Does it just mean that the site can't keep track of a user
unless they have cookies turned on?

There are enough parts of my site that don't require a session that I
think requiring cookies is not a problem so I'm willing to turn it off.
But I imagine there's something I'm not thinking about regarding this.
If anyone can elaborate a little that'd be great!



Thanks,
Chris.

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



[PHP] Re: PHP License question

2004-02-12 Thread Greg Beaver
Ben,

You can ship the package as two separately licensed components.  The 
PEAR packages will retain their original licenses.  If you customize the 
package, then you should redistribute it as a different thing under your 
own license, and probably rename the files/classes so that they don't 
confuse with the PEAR package.

The only thing you cannot do is release the unomdified PEAR package 
under GPL.

A better alternative is to use the LGPL, which does not force other 
packages to use GPL, but is still copy-left/open-source.

Greg

P.S. I'm not an expert, this is my common sense understanding of how the 
license works.  The PHP License is less restrictive than GPL.  You can 
do anything you want with the code as long as it doesn't affect the 
original code's license.

Ben Ramsey wrote:
I currently developing a project that I wish to release under a, 
preferably, open-source and copy-left license.  So, I'm taking a close 
look at the GNU GPL for this, and it seems to serve this purpose, well. 
 However, I am aware that the PHP license conflicts with the GNU GPL, 
and, thus, anything released under the PHP license cannot also be 
released in software under the GPL.  At least, this is my assumption.

Now, to my question: if a PEAR package is released under the PHP 
license, and my product is under the GPL, can I include the PEAR package 
in my product?  Under the above assumption, the answer would be no.  So, 
what license should I release my product under to maintain it's 
copy-left status and yet still allow the PEAR packages to be included?
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[PHP] Re: sql query question

2004-02-12 Thread Steve Solomon
select * from table where locate(new,descript)0 or
locate(car,descript)0;

Tony [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
hi

if i have  new  car and i want to search
each word in description
can i do
SELECT * FROM table WHERE
descript = new OR descript =car??

any help is appreciated

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



[PHP] Mp3 with php?

2004-02-12 Thread carlos castillo

does anyone know how to reproduce a mp3 file with php?

Thanks

Carlos A. Castillo.
Ingeniero de desarrollo
[EMAIL PROTECTED]


Su Aliado Efectivo en Internet
www.imagine.com.co
(57 1)2182064 - (57 1)6163218
Bogotá - Colombia 

- Soluciones web para Internet e Intranet
- Soluciones para redes
- Licenciamiento de Software
- Asesoría y Soporte Técnico


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



RE: [PHP] Mp3 with php?

2004-02-12 Thread Chris W. Parker
carlos castillo mailto:[EMAIL PROTECTED]
on Thursday, February 12, 2004 3:53 PM said:

 does anyone know how to reproduce a mp3 file with php?

What do you mean reproduce? Copy? Create from scratch? Represent
visually?

In any case.. I'd say PHP cannot do anything but create a copy of a
file. It cannot read in data from a microphone or a cd player or the
like (as far as I know).

Chris.

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



[PHP] IPTC image comments utility

2004-02-12 Thread Paul Furman
Does anyone know of a utility for WRITING or at least reading IPTC data 
in images with PHP? I found lots of EXIF utilities and did an 
experimental thing with that. PHP even has a built in EXIF reader but 
the only IPTC utilities I've found are expensive ActiveX or Delphi 
components and I don't even know if those could be operated by PHP. THe 
one I used worked at a command line  I just did a shell command with a 
constructed syntax.

Here's some stuff I dug up:

COMIPTC 900 Euros
http://www.j2s.net/EN/Products/comiptc.html
Works with Visual Basic, ASP or PHP
Matches Photoshop format
Works on JPEG, TIFF, PSD
TIPTC Delphi $566.60
http://www.atom5.com/Development/Components-Libraries-for-Delphi/tiptc-delphi-component-to-read-and-write-iptc-data-from-jpeg-tiff-files-2620.html
JPEG/TIFF
source code in pure Delphi code
Atalasoft dotImage $329-$999
http://www.atalasoft.com/Components/dotImage
C# ActiveX component .NET compatible
many features
AiS EXIF ActiveX $25-$99 (server)
http://www.watermarker.com/exif-iptc-gps/
ActiveX component for Win9X/ME/NT/2k/XP
Visual Basic, Delphi, C++, ASP, ASPX, PHP.
EXIF, IPTC for JPEG/TIFF
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


RE: [PHP] Re: sql query question

2004-02-12 Thread Hamid Hossain
Hi,

It is better to use FullText. Convert the description field to FullText. You 
will gain a powerfull control in this case. For more information on how to 
use FullText read a little-bit in the MySql manual (MATCH AGAINST) commands.

Regards,
Hamid Hossain
---
Check Amazon.com Latest PHP books:
http://www.amazon.com/exec/obidos/redirect?tag=zawraqclassif-20path=tg/browse/-/295223
Start Accepting CreditCard at your site in minutes:
http://www.2checkout.com/cgi-bin/aff.2c?affid=106720
Download Alexa Tool Bar to stop Pop-ups for FREE:
http://download.alexa.com/?amzn_id=zawraqclassif-20
Download Ready-Made Templates for your site:
http://www.aplustemplates.com/cgi/affiliates/c1.cgi/zawraq_ad
Original Message Follows
From: Ben Ramsey [EMAIL PROTECTED]
To: [EMAIL PROTECTED], tony [EMAIL PROTECTED]
Subject: [PHP] Re: sql query question
Date: Thu, 12 Feb 2004 16:05:16 -0500
This is a SQL question, rather than a PHP question, so I would suggest doing 
a google search on SQL tutorials, but I think what you are trying to do 
would work like this:

SELECT * FROM table WHERE descript LIKE '%new%' OR descript LIKE '%car%'



Tony wrote:

hi

if i have  new  car and i want to search
each word in description
can i do
SELECT * FROM table WHERE
descript = new OR descript =car??
any help is appreciated
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
_
The new MSN 8: advanced junk mail protection and 2 months FREE* 
http://join.msn.com/?page=features/junkmail

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


[PHP] Re: IPTC image comments utility

2004-02-12 Thread Paul Furman
OK this looks like the thing:
http://multipart-mixed.com/photo/iptc.html
It's a perl module. Can I use that in PHP?
Paul Furman wrote:

Does anyone know of a utility for WRITING or at least reading IPTC data 
in images with PHP? I found lots of EXIF utilities and did an 
experimental thing with that. PHP even has a built in EXIF reader but 
the only IPTC utilities I've found are expensive ActiveX or Delphi 
components and I don't even know if those could be operated by PHP. THe 
one I used worked at a command line  I just did a shell command with a 
constructed syntax.

Here's some stuff I dug up:

COMIPTC 900 Euros
http://www.j2s.net/EN/Products/comiptc.html
Works with Visual Basic, ASP or PHP
Matches Photoshop format
Works on JPEG, TIFF, PSD
TIPTC Delphi $566.60
http://www.atom5.com/Development/Components-Libraries-for-Delphi/tiptc-delphi-component-to-read-and-write-iptc-data-from-jpeg-tiff-files-2620.html 

JPEG/TIFF
source code in pure Delphi code
Atalasoft dotImage $329-$999
http://www.atalasoft.com/Components/dotImage
C# ActiveX component .NET compatible
many features
AiS EXIF ActiveX $25-$99 (server)
http://www.watermarker.com/exif-iptc-gps/
ActiveX component for Win9X/ME/NT/2k/XP
Visual Basic, Delphi, C++, ASP, ASPX, PHP.
EXIF, IPTC for JPEG/TIFF
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] Mp3 with php?

2004-02-12 Thread Gerard Samuel
On Thursday 12 February 2004 06:52 pm, carlos castillo wrote:
 does anyone know how to reproduce a mp3 file with php?


reproduce???

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



[PHP] Browser Detection another page

2004-02-12 Thread PETCOL
PHP Newbie here,

I have been able to work out how to detect the browser I'm looking for.

Then I need to take the user to another page.

? php

if (strstr($HTTP_USER_AGENT,'Windows CE')) {
//go to the Windows CE version of the site
} else {
// go to or Stay on the large version
}

?

Suggestions

Col

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



Re: [PHP] Browser Detection another page

2004-02-12 Thread Richard Davey
Hello PETCOL,

Friday, February 13, 2004, 12:57:59 AM, you wrote:

P I have been able to work out how to detect the browser I'm looking for.
P Then I need to take the user to another page.

P if (strstr($HTTP_USER_AGENT,'Windows CE')) {
P //go to the Windows CE version of the site
P } else {
P // go to or Stay on the large version
P }

if (strstr($HTTP_USER_AGENT, Windows CE))
{
   Header(Location: http://www.yoursite.dom/ce_page.php;);
   exit;
}
else
{
   Header(Location: http://www.yoursite.dom/another_page.php;);
   exit;
}

-- 
Best regards,
 Richardmailto:[EMAIL PROTECTED]

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



Re: [PHP] Browser Detection another page

2004-02-12 Thread joel boonstra
On Fri, Feb 13, 2004 at 11:57:59AM +1100, PETCOL wrote:
 Then I need to take the user to another page.
 
 ? php
 
 if (strstr($HTTP_USER_AGENT,'Windows CE')) {
 //go to the Windows CE version of the site
 } else {
 // go to or Stay on the large version
 }
 
 ?

Hopefully you're aware that $HTTP_USER_AGENT is an unreliable variable,
in that it is sent by the client, and can contain virtually anything.

I saw a response letting you know how to do this, but I would recommend
not sending people to different pages based on which browser/OS they're
using.  

The most I would use $HTTP_USER_AGENT for is if I'm presenting a list of
different OSes (say, for links to OS-specific downloads), and I want to
select an intelligent default.

It should be possible to use CSS/(X)HTML to present your content in a
way that is accessible to whichever browser accesses your site.  IMHO,
browser-sniffing to serve different content is a bad idea.

/$.02

-- 
[ joel boonstra | gospelcom.net ]

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



[PHP] Re: [SOLVED][PHP] Browser Detection another page

2004-02-12 Thread PETCOL
Richard,

Thanks for that, looks too simple ;-)

It's exactly what I want for this particular application.

Thanks
Col

Richard Davey [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
 Hello PETCOL,

 Friday, February 13, 2004, 12:57:59 AM, you wrote:

 P I have been able to work out how to detect the browser I'm looking for.
 P Then I need to take the user to another page.

 P if (strstr($HTTP_USER_AGENT,'Windows CE')) {
 P //go to the Windows CE version of the site
 P } else {
 P // go to or Stay on the large version
 P }

 if (strstr($HTTP_USER_AGENT, Windows CE))
 {
Header(Location: http://www.yoursite.dom/ce_page.php;);
exit;
 }
 else
 {
Header(Location: http://www.yoursite.dom/another_page.php;);
exit;
 }

 -- 
 Best regards,
  Richardmailto:[EMAIL PROTECTED]

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



Re: [PHP] Mp3 with php?

2004-02-12 Thread John Nichel
carlos castillo wrote:

does anyone know how to reproduce a mp3 file with php?
Copy an existing file?  Yes.

Other than that, the only thing I know you can do with Mp3's is 
modify/add/delete id3 tags.

--
By-Tor.com
It's all about the Rush
http://www.by-tor.com
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


RE: [PHP] Re: IPTC image comments utility

2004-02-12 Thread Andy Crain
This might help:
http://pear.php.net/package/Image_IPTC
Andy

 -Original Message-
 From: Paul Furman [mailto:[EMAIL PROTECTED]
 Sent: Thursday, February 12, 2004 7:36 PM
 To: [EMAIL PROTECTED]
 Subject: [PHP] Re: IPTC image comments utility
 
 OK this looks like the thing:
 http://multipart-mixed.com/photo/iptc.html
 It's a perl module. Can I use that in PHP?
 
 Paul Furman wrote:
 
  Does anyone know of a utility for WRITING or at least reading IPTC data
  in images with PHP? I found lots of EXIF utilities and did an
  experimental thing with that. PHP even has a built in EXIF reader but
  the only IPTC utilities I've found are expensive ActiveX or Delphi
  components and I don't even know if those could be operated by PHP. THe
  one I used worked at a command line  I just did a shell command with a
  constructed syntax.
 
  Here's some stuff I dug up:
 
 
  COMIPTC 900 Euros
  http://www.j2s.net/EN/Products/comiptc.html
  Works with Visual Basic, ASP or PHP
  Matches Photoshop format
  Works on JPEG, TIFF, PSD
 
  TIPTC Delphi $566.60
  http://www.atom5.com/Development/Components-Libraries-for-Delphi/tiptc-
 delphi-component-to-read-and-write-iptc-data-from-jpeg-tiff-files-
 2620.html
 
  JPEG/TIFF
  source code in pure Delphi code
 
  Atalasoft dotImage $329-$999
  http://www.atalasoft.com/Components/dotImage
  C# ActiveX component .NET compatible
  many features
 
  AiS EXIF ActiveX $25-$99 (server)
  http://www.watermarker.com/exif-iptc-gps/
  ActiveX component for Win9X/ME/NT/2k/XP
  Visual Basic, Delphi, C++, ASP, ASPX, PHP.
  EXIF, IPTC for JPEG/TIFF
 
 --
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php

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



Re: [PHP] PHP with FTP installation

2004-02-12 Thread Jason Wong
On Friday 13 February 2004 03:19, [EMAIL PROTECTED] wrote:

   I just know how to reconfigure php installation with --ftp-enable. I
 already did a ./configure --ftp-enable command but when echo the
 phpinfo() hust to see if its been updated, its still showing
 ./configure' '--with-mysql' '--with-apxs=/www/bin/apxs' on the configure
 command.

Everytime you use ./configure it 'reconfigures' php from scratch. Meaning you 
have to specify every option you need/don't need. Thus in your case you would 
probably want to do:

  ./configure --with-mysql --with-apxs=/www/bin/apxs --enable-ftp

Then you need to compile:

  make

Then stop your webserver and install the newly compiled php:

  make install

Then start your webserver.

-- 
Jason Wong - Gremlins Associates - www.gremlins.biz
Open Source Software Systems Integrators
* Web Design  Hosting * Internet  Intranet Applications Development *
--
Search the list archives before you post
http://marc.theaimsgroup.com/?l=php-general
--
/*
Rebellion lay in his way, and he found it.
-- William Shakespeare, Henry IV
*/

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



[PHP] E-Commerce

2004-02-12 Thread Jimmy
Hi all. Is PHP a suitable language for building an online shop? Where would
I go to find out more info on this? Thanks in advance!

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



Re: [PHP] Re: date() funtion language

2004-02-12 Thread Don Read

On 12-Feb-2004 André Cerqueira wrote:
 -BEGIN PGP SIGNED MESSAGE-
 Hash: SHA1
 
 i had problems with locale
 i think its safer to make a dayname and monthname array, and use
 getdate(), than build the string yourself
 

snip

 
 //the follow should, but doesnt seem to work
 //setlocale(LC_ALL, 'pt_BR');
 //echo date('l, j de F de Y');
 ?

date() doesn't format according to locale but strftime() does:

setlocale(LC_ALL, 'pt_BR.ISO8859-1');
echo strftime('%A, %B %e %Y');

// output 'Quinta Feira, Fevereiro 12 2004'



-- 
Don Read [EMAIL PROTECTED]
-- It's always darkest before the dawn. So if you are going to 
   steal the neighbor's newspaper, that's the time to do it.

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



RE: [PHP] E-Commerce

2004-02-12 Thread PHP Email List
Jimmy jimmy jimmy...

Now if your question is, Can PHP be the most versatile languge that one
should use for creating the best online shop ever?  Then yes.

Can PHP interact with MySql and just about every other Database program to
store all your wonderful merchandise, in a nice compact easy to carry
carrying case. Then YES.

And if your also asking if PHP would be a server side scripting language
like CGI/ASP/JAVA/~..  Then YES again.

But if your asking whether or not PHP, would be able to SAY?
Log your client's information
Store your inventory
Display your merchandise
Process orders
Interact with your clients
Keep your client's informed of what's in and what's not
Manipulate your inventory records
Inform you of what's getting low for reordering
Track what's selling and what isn't
Allow online technical support through forums
Allow 24x7 access to your Storefront

And last but not least, Tuck you in at night?

Then no.  It can't tuck you in at night. But PHP does all the rest and SO
MUCH MORERead about it here
http://www.php.net
Best Shopping cart website setup utility you'll ever need. Enjoy!

Wolf

-Original Message-
From: Jimmy [mailto:[EMAIL PROTECTED]
Sent: Thursday, February 12, 2004 10:44 PM
To: [EMAIL PROTECTED]
Subject: [PHP] E-Commerce


Hi all. Is PHP a suitable language for building an online shop? Where would
I go to find out more info on this? Thanks in advance!

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

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



Re: [PHP] E-Commerce

2004-02-12 Thread Philip J. Newman
I just about wet my self laughing.

Just look around the net, PHP is used in about 40% of the online shopping sites.


- Original Message - 
From: PHP Email List [EMAIL PROTECTED]
To: Jimmy [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Sent: Friday, February 13, 2004 6:48 PM
Subject: RE: [PHP] E-Commerce


 Jimmy jimmy jimmy...
 
 Now if your question is, Can PHP be the most versatile languge that one
 should use for creating the best online shop ever?  Then yes.
 
 Can PHP interact with MySql and just about every other Database program to
 store all your wonderful merchandise, in a nice compact easy to carry
 carrying case. Then YES.
 
 And if your also asking if PHP would be a server side scripting language
 like CGI/ASP/JAVA/~..  Then YES again.
 
 But if your asking whether or not PHP, would be able to SAY?
 Log your client's information
 Store your inventory
 Display your merchandise
 Process orders
 Interact with your clients
 Keep your client's informed of what's in and what's not
 Manipulate your inventory records
 Inform you of what's getting low for reordering
 Track what's selling and what isn't
 Allow online technical support through forums
 Allow 24x7 access to your Storefront
 
 And last but not least, Tuck you in at night?
 
 Then no.  It can't tuck you in at night. But PHP does all the rest and SO
 MUCH MORERead about it here
 http://www.php.net
 Best Shopping cart website setup utility you'll ever need. Enjoy!
 
 Wolf
 
 -Original Message-
 From: Jimmy [mailto:[EMAIL PROTECTED]
 Sent: Thursday, February 12, 2004 10:44 PM
 To: [EMAIL PROTECTED]
 Subject: [PHP] E-Commerce
 
 
 Hi all. Is PHP a suitable language for building an online shop? Where would
 I go to find out more info on this? Thanks in advance!
 
 --
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php
 
 -- 
 PHP General Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php
 

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



Re: [PHP] Re: IPTC image comments utility

2004-02-12 Thread Paul Furman
Andy Crain wrote:

This might help:
http://pear.php.net/package/Image_IPTC
Andy
Thanks, I don't know why I didn't find that. No documentation though and 
some unfamiliar stuff with @ and references to other commands which I 
guess this replaces (not sure). If so I can't figure out how to run the 
thing. Below is some snippage from the code trying to get at how to use 
it. I'm still interested in whether I can get the perl module to run 
with PHP, it sounds like it may be a bit more reliable. I've got perl 
loaded but don't know how to use it.

snippage
* This class encapsulates the functions iptcparse() and iptcembed(). It 
provides
* the necessary methods for extracting, modifying, and saving IPTC data with
* image files (JPEG and TIFF files only).

class Image_IPTC

var $_sFilename = null;

var $_aIPTC = array();
* The IPTC fields that were extracted from the image
* or updated by this class.
var $_bIPTCParse = false;
* set to true if the APP header data could be obtained.
iptcparse (places where I saw this)
http://us4.php.net/iptcparse
function Image_IPTC( $sFilename )
   $this-_aIPTC = @iptcparse($aAPP['APP13']);
   $this-_bIPTCParse = true;
function isValid()
return $this-_bIPTCParse;
function getAllTags()
return $this-_aIPTC;
  * An array of IPTC fields as it extracted by iptcparse()
iptcembed (places where I saw this)
http://us4.php.net/iptcembed
one comment refers to the Image::IPTCInfo Perl module
-undocumented, some serious compatibility problems, improper format
function save( $sOutputFile = null )
$sImageData = @iptcembed($sIPTCBlock, $this-_sFilename, 0);
function output()
@iptcembed($sIPTCBlock, $this-_sFilename, 2);


Paul Furman wrote:

OK this looks like the thing:
http://multipart-mixed.com/photo/iptc.html
It's a perl module. Can I use that in PHP?
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] E-Commerce

2004-02-12 Thread Terence
all in one awesome package:

www.oscommerce.com


- Original Message - 
From: PHP Email List [EMAIL PROTECTED]
To: Jimmy [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Sent: Friday, February 13, 2004 1:48 PM
Subject: RE: [PHP] E-Commerce


Jimmy jimmy jimmy...

Now if your question is, Can PHP be the most versatile languge that one
should use for creating the best online shop ever?  Then yes.

Can PHP interact with MySql and just about every other Database program to
store all your wonderful merchandise, in a nice compact easy to carry
carrying case. Then YES.

And if your also asking if PHP would be a server side scripting language
like CGI/ASP/JAVA/~..  Then YES again.

But if your asking whether or not PHP, would be able to SAY?
Log your client's information
Store your inventory
Display your merchandise
Process orders
Interact with your clients
Keep your client's informed of what's in and what's not
Manipulate your inventory records
Inform you of what's getting low for reordering
Track what's selling and what isn't
Allow online technical support through forums
Allow 24x7 access to your Storefront

And last but not least, Tuck you in at night?

Then no.  It can't tuck you in at night. But PHP does all the rest and SO
MUCH MORERead about it here
http://www.php.net
Best Shopping cart website setup utility you'll ever need. Enjoy!

Wolf

-Original Message-
From: Jimmy [mailto:[EMAIL PROTECTED]
Sent: Thursday, February 12, 2004 10:44 PM
To: [EMAIL PROTECTED]
Subject: [PHP] E-Commerce


Hi all. Is PHP a suitable language for building an online shop? Where would
I go to find out more info on this? Thanks in advance!

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

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

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



Re: [PHP] E-Commerce

2004-02-12 Thread John Nichel
Terence wrote:

all in one awesome package:

www.oscommerce.com
I just got finished building a site for a customer who wanted OSCommerce 
(didn't want to pay for a 'real' shopping cart, or for me to build him 
one), and in my 8+ years of web development, they have to be one of the 
worst in most aspects.

First off, it won't install or run if you have register_globals off. 
When I saw this, I said to myself, this isn't so bad if they're writing 
secure code, but it opens up ALL the code on the site.  Then I started 
configuring it (hacking it) to fit the customers wants and desires, and 
found a few areas where it could be compromised.

Second, the code looks like it was written by someone who originaly had 
no intention of releasing this code to the world.  It's sloppy, 
unorganized, and poorly (if at all) commented.  Compare the code from an 
application like phpMyAdmin to OSCommerce to see what I mean.

The only thing I have positive to say about it, is on it's ease of use 
for the end user who wants to run an online store, but doesn't know 
diddly about computers.

Until they fix the first issue, I will continue to recommend against 
OSCommerce.

--
By-Tor.com
It's all about the Rush
http://www.by-tor.com
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


php-general Digest 13 Feb 2004 07:08:21 -0000 Issue 2587

2004-02-12 Thread php-general-digest-help

php-general Digest 13 Feb 2004 07:08:21 - Issue 2587

Topics (messages 177537 through 177572):

PHP with FTP installation
177537 by: rodner.edigitalweb.com
177564 by: Jason Wong

Re: Using date() with the function fileatime() doesn't return accurate timestamp...
177538 by: Scott Fletcher
177539 by: Roger B.A. Klorese

php5beta4 problem
177540 by: Gareth Thomas

PHP License question
177541 by: Ben Ramsey
177547 by: Dan Phiffer
177550 by: Greg Beaver

sql query question
177542 by: tony
177543 by: Ben Ramsey
177551 by: Steve Solomon
177555 by: Hamid Hossain

(retry) [ANN] Kwartz -- a template system for PHP, Ruby and Java
177544 by: maco.letter.or.jp

IMAP/SSL on Windows
177545 by: Dan Phiffer

Re: [Q]PHP not taking input values from forms
177546 by: Philip Olson
177548 by: Vail, Warren

negative impact on session management after turning off trans_id?
177549 by: Chris W. Parker

Mp3 with php?
177552 by: carlos castillo
177553 by: Chris W. Parker
177557 by: Gerard Samuel
177562 by: John Nichel

IPTC image comments utility
177554 by: Paul Furman
177556 by: Paul Furman
177563 by: Andy Crain
177570 by: Paul Furman

Browser Detection another page
177558 by: PETCOL
177559 by: Richard Davey
177560 by: joel boonstra

Re: [SOLVED][PHP] Browser Detection another page
177561 by: PETCOL

E-Commerce
177565 by: Jimmy
177567 by: PHP Email List
177568 by: Philip J. Newman
177569 by: Philip J. Newman
177571 by: Terence
177572 by: John Nichel

Re: date() funtion  language
177566 by: Don Read

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]


--
---BeginMessage---
Hi,
  I just know how to reconfigure php installation with --ftp-enable. I
already did a ./configure --ftp-enable command but when echo the
phpinfo() hust to see if its been updated, its still showing
./configure' '--with-mysql' '--with-apxs=/www/bin/apxs' on the configure
command.

I would appreciate any help. thanks

Rodner
---End Message---
---BeginMessage---
On Friday 13 February 2004 03:19, [EMAIL PROTECTED] wrote:

   I just know how to reconfigure php installation with --ftp-enable. I
 already did a ./configure --ftp-enable command but when echo the
 phpinfo() hust to see if its been updated, its still showing
 ./configure' '--with-mysql' '--with-apxs=/www/bin/apxs' on the configure
 command.

Everytime you use ./configure it 'reconfigures' php from scratch. Meaning you 
have to specify every option you need/don't need. Thus in your case you would 
probably want to do:

  ./configure --with-mysql --with-apxs=/www/bin/apxs --enable-ftp

Then you need to compile:

  make

Then stop your webserver and install the newly compiled php:

  make install

Then start your webserver.

-- 
Jason Wong - Gremlins Associates - www.gremlins.biz
Open Source Software Systems Integrators
* Web Design  Hosting * Internet  Intranet Applications Development *
--
Search the list archives before you post
http://marc.theaimsgroup.com/?l=php-general
--
/*
Rebellion lay in his way, and he found it.
-- William Shakespeare, Henry IV
*/
---End Message---
---BeginMessage---
Oh I understand now.  There is a different between fileatime(), filectime()
and filemtime(), with a letter 'a', 'c' or 'm'...  The one with the m is
what work with Unix/Linux..

Scott F.

Scott Fletcher [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
 I saw the article at http://us2.php.net/manual/en/function.fileatime.php
and
 gave it a shot with the timestamp for the file but it doesn't work
correctly
 because it only returned the current timestamp (as it is from our watch or
 clock) but not the one from the file...

 I had verify that the file is correct and that the date() is working
 correctly and that the timeatime() is working correctly if they are tested
 independantly, so it is just putting them all three together cause them
not
 to work right...

 --snip--
 $current_filename = test.pdf;
 echo (date('F j, Y, h:i a', (fileatime($current_filename;
 --snip--

 What did I do wrong??

 Scott F.
---End Message---
---BeginMessage---
 Oh I understand now.  There is a different between 
 fileatime(), filectime()
 and filemtime(), with a letter 'a', 'c' or 'm'...  The one 
 with the m is
 what work with Unix/Linux..

Um, they all work with Unix/Linux -- they just mean different things.

Atime is the time a file was last accessed.
Mtime is the time the contents of a file were last modified.
Ctime is the time 

RE: [PHP] E-Commerce

2004-02-12 Thread Angelo Zanetti
JOhn, do you have any other recommendations that you might have looked at
after your experience with OS commerce?



-Original Message-
From: John Nichel [mailto:[EMAIL PROTECTED]
Sent: Friday, February 13, 2004 9:10 AM
To: [EMAIL PROTECTED]
Subject: Re: [PHP] E-Commerce


Terence wrote:

 all in one awesome package:

 www.oscommerce.com

I just got finished building a site for a customer who wanted OSCommerce
(didn't want to pay for a 'real' shopping cart, or for me to build him
one), and in my 8+ years of web development, they have to be one of the
worst in most aspects.

First off, it won't install or run if you have register_globals off.
When I saw this, I said to myself, this isn't so bad if they're writing
secure code, but it opens up ALL the code on the site.  Then I started
configuring it (hacking it) to fit the customers wants and desires, and
found a few areas where it could be compromised.

Second, the code looks like it was written by someone who originaly had
no intention of releasing this code to the world.  It's sloppy,
unorganized, and poorly (if at all) commented.  Compare the code from an
application like phpMyAdmin to OSCommerce to see what I mean.

The only thing I have positive to say about it, is on it's ease of use
for the end user who wants to run an online store, but doesn't know
diddly about computers.

Until they fix the first issue, I will continue to recommend against
OSCommerce.

--
By-Tor.com
It's all about the Rush
http://www.by-tor.com

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


Disclaimer 
This e-mail transmission contains confidential information,
which is the property of the sender.
The information in this e-mail or attachments thereto is 
intended for the attention and use only of the addressee. 
Should you have received this e-mail in error, please delete 
and destroy it and any attachments thereto immediately. 
Under no circumstances will the Cape Technikon or the sender 
of this e-mail be liable to any party for any direct, indirect, 
special or other consequential damages for any use of this e-mail.
For the detailed e-mail disclaimer please refer to 
http://www.ctech.ac.za/polic or call +27 (0)21 460 3911

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



Re: [PHP] E-Commerce

2004-02-12 Thread Radwan Aladdin
Okay.. these are for the Shopping Cart..

Can anybody here tell me.. how to build a Payment Gateway?

For example: like 2CheckOut did.. not only applicatios connected with
2CheckOut... I want to know how to build a company like 2CheckOut..

Of course I know it is too hard.. but I must know about that..

Hope any body here knows about that..

Regards..
- Original Message -
From: John Nichel [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Friday, February 13, 2004 11:24 AM
Subject: Re: [PHP] E-Commerce


 Angelo Zanetti wrote:

  JOhn, do you have any other recommendations that you might have looked
at
  after your experience with OS commerce?

 Not that are written in PHP.  Not that I wouldn't recommend any, I just
 haven't looked at any other PHP carts besides OS Commerce.  I'm sure
 there are some good ones, just like there are quite a few good ones
 written in Perl, C, etc.  You can look here...

 http://php.resourceindex.com/Complete_Scripts/Shopping_Carts/

 --
 By-Tor.com
 It's all about the Rush
 http://www.by-tor.com

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


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



Re: [PHP] E-Commerce

2004-02-12 Thread John Nichel
Radwan Aladdin wrote:
Okay.. these are for the Shopping Cart..

Can anybody here tell me.. how to build a Payment Gateway?

For example: like 2CheckOut did.. not only applicatios connected with
2CheckOut... I want to know how to build a company like 2CheckOut..
Of course I know it is too hard.. but I must know about that..

Hope any body here knows about that..

Regards..
*sigh*

http://www.google.com/search?hl=enie=UTF-8oe=UTF-8q=php+payment+gatewaybtnG=Google+Search

http://php.resourceindex.com/Complete_Scripts/Commerce_and_Finance/

--
By-Tor.com
It's all about the Rush
http://www.by-tor.com
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


Re: [PHP] E-Commerce

2004-02-12 Thread Radwan Aladdin
Cool!!!

Do you mean by this I can open a company like PaySystems or
2CheckOut!

Must I contact banks all over the world to make the Credit Card Transaction?
Or must I register in an organization?

What to do now after registratin here
http://www.ospayments.com/001/contact.html what must I do?

Regards..
- Original Message -
From: John Nichel [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Friday, February 13, 2004 11:39 AM
Subject: Re: [PHP] E-Commerce


 Radwan Aladdin wrote:
  Okay.. these are for the Shopping Cart..
 
  Can anybody here tell me.. how to build a Payment Gateway?
 
  For example: like 2CheckOut did.. not only applicatios connected with
  2CheckOut... I want to know how to build a company like 2CheckOut..
 
  Of course I know it is too hard.. but I must know about that..
 
  Hope any body here knows about that..
 
  Regards..

 *sigh*


http://www.google.com/search?hl=enie=UTF-8oe=UTF-8q=php+payment+gatewayb
tnG=Google+Search

 http://php.resourceindex.com/Complete_Scripts/Commerce_and_Finance/

 --
 By-Tor.com
 It's all about the Rush
 http://www.by-tor.com

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