php-general Digest 2 Feb 2001 13:01:55 -0000 Issue 488

Topics (messages 37764 through 37827):

Re: What version of Linux?
        37764 by: Michael Hall

Re: encode string with spaces
        37765 by: David Robley
        37768 by: David Robley

Win2000 TCP/IP failure
        37766 by: Toby Butzon
        37827 by: Alain Fontaine

Re: C++ integration with PHP
        37767 by: Toby Butzon

Re: contracting & consulting (was "[PHP] Pricing for PHP pr ogramming???")
        37769 by: Dave VanAuken
        37770 by: Ben Peter
        37771 by: Maxim Maletsky
        37775 by: Steve Werby
        37826 by: Robin Vickery

Re: Java variables - PHP varialbles
        37772 by: Nold, Mark

Php Database
        37773 by: Vinicius Garcia Mommensohn

Re: Why?? SPRINTF("SELECT sequence,prodnum,childdesc....);
        37774 by: Steve Werby

Re: PHP a lightweight language?
        37776 by: Nold, Mark
        37783 by: John Hinsley
        37784 by: Josh G

How do I get last inserted ID?
        37777 by: Sandeep Hundal
        37778 by: Maxim Maletsky
        37779 by: David Robley
        37821 by: Andrew Golovin

Re: Pricing for PHP programming???
        37780 by: Steve Werby
        37781 by: Josh G
        37786 by: Josh G
        37797 by: Angus Mann

Re:What version of Linux?
        37782 by: John Hinsley

Re: Message status - undeliverable
        37785 by: Josh G

OT mod_rewrite says goodbye to POST vars (but interesting)
        37787 by: Matt Friedman

Re: 404 error checker
        37788 by: Louis LeBlanc

Automatic incoming mail notification
        37789 by: Ankur Verma
        37790 by: Josh G
        37791 by: David Robley
        37792 by: Ankur Verma
        37793 by: Steve Werby
        37802 by: Nicolas Windpassinger - Sun

how do I subscribe?
        37794 by: David VanHorn
        37795 by: Maxim Maletsky

Re: Variables within functions, out?
        37796 by: Steve Werby

configuring headers in mail() ...
        37798 by: Maxim Maletsky

PGP
        37799 by: Martin Thoma
        37801 by: Adrian Teasdale

Mysql Question
        37800 by: Giancarlo

Re: Recommended Job Posting sites? Need to hire someone w/ PHP exp.
        37803 by: Boaz Yahav

Apache won't start after installing php4
        37804 by: Frank Passek

Zend IDE
        37805 by: Alain Fontaine
        37811 by: Andi Gutmans
        37813 by: Alain Fontaine
        37816 by: Zeev Suraski
        37817 by: Alain Fontaine

Re: reload help!!!
        37806 by: Wen Ni Leong

passing parameters
        37807 by: Stinie Steinbach
        37808 by: Alain Fontaine

Could PHP connect to Perl Program
        37809 by: kn4279

Re: [Q] Domxml: unlink() method?
        37810 by: Peter Sabaini

JavaScript, PHP and HTML
        37812 by: Augusto Cesar Castoldi
        37815 by: Juan
        37819 by: kaab kaoutar

Re: Tab character
        37814 by: Martin A. Marques

Re: Include " quotes inside textbox
        37818 by: Christian Reiniger

PHP configure commandline
        37820 by: indrek siitan

For My Information
        37822 by: Dan Malcolm
        37823 by: Jon Haworth

Re: [PHP-WIN] For My Information
        37824 by: Tom Mathews
        37825 by: Dan Malcolm

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]


----------------------------------------------------------------------



Almost any distribution should work OK. I use Red Hat on one of my old
486 machines ... it is slow but it works. Given the machine
you're  working with, the main issue is I think optimising or customising
whatever distribution you do use to improve performance.

Mick

On Thu, 1 Feb 2001, Andrés de la Varga wrote:

> I want to install my personal server on a old Intel 486 machine, 36 Mb RAM,
> 2 Gb HardDisk, VGA, to develop in PHP. What version of Linux do I need to
> install?
> 
> Andrés de la Varga.
> 
> 
> 
> -- 
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
> 
> 





On Fri,  2 Feb 2001 11:22, Kevin McCarthy wrote:
> All -
>
> Any easy way to take a string and fill the spaces in it? Say like a
> URLencoding:
>
> This is my dog, Jack
> becomes
> This%20is%20my%20dog,%20Jack
>
> I ask this as I would like to send a string to a perl function that can
> parse the string and create a hash from it based on delimiters I define.
> But if there are spaces in the string in between defined fields, it is
> thrown off.
>
> BTW, I tried both ereg_replace() and str_replace() with no luck as below:
>
> $my_string = "This is my dog, Jack";
> str_replace(" ", "%20", $my_string);
>
> $my_string remains with spaces, not %20s.
>
> Thanks.
>
>
>
> Kevin McCarthy

rawurlencode seems to be what you want if you want %20; or see urlencode 
which uses + for space character.

-- 
David Robley                        | WEBMASTER & Mail List Admin
RESEARCH CENTRE FOR INJURY STUDIES  | http://www.nisu.flinders.edu.au/
AusEinet                            | http://auseinet.flinders.edu.au/
            Flinders University, ADELAIDE, SOUTH AUSTRALIA




On Fri,  2 Feb 2001 11:36, David Robley wrote:
> On Fri,  2 Feb 2001 11:22, Kevin McCarthy wrote:
> > All -
> >
> > Any easy way to take a string and fill the spaces in it? Say like a
> > URLencoding:
> >
> > This is my dog, Jack
> > becomes
> > This%20is%20my%20dog,%20Jack
> >
> > I ask this as I would like to send a string to a perl function that can
> > parse the string and create a hash from it based on delimiters I
> > define. But if there are spaces in the string in between defined
> > fields, it is thrown off.
> >
> > BTW, I tried both ereg_replace() and str_replace() with no luck as
> > below:
> >
> > $my_string = "This is my dog, Jack";
> > str_replace(" ", "%20", $my_string);
> >
> > $my_string remains with spaces, not %20s.

And that is because you need to do

$my_string = str_replace(" ", "%20", $my_string);

You have to assign the result of the function to something to see it :-)


-- 
David Robley                        | WEBMASTER & Mail List Admin
RESEARCH CENTRE FOR INJURY STUDIES  | http://www.nisu.flinders.edu.au/
AusEinet                            | http://auseinet.flinders.edu.au/
            Flinders University, ADELAIDE, SOUTH AUSTRALIA




Greetings,

I've run into a problem on my Win2k computer running IIS5 and PHP
404pl1. I've got a page set up to pull a page from CNN.com, parse it for
headlines, and print the results in an organized table of links.
Everything's been working fine since the beginning of January, but
suddenly it dies with a PHP warning and my die() message:

<PHP WARNING>
Warning: fopen("http://www.cnn.com/desktop/content.html","r") - No error
in _file_extract.php on line 5
<MY DIE() MESSAGE>
Unable to open http://www.cnn.com/desktop/content.html

The line that's generating the error looks like this:
$file = fopen($url, "r") or die("Unable to open $url");

So I figured maybe something was up with my fopen()... but apparently
not. I also have the same page connecting to the mysql server on
localhost to request a list of my reminders & tasks that need to be
done. However, connecting to the db server (on localhost) also dies with
the following:

<PHP WARNING>
Warning: MySQL Connection Failed: Can't create TCP/IP socket (10091) in
basic_functions.php on line 9
<MY DIE() MESSAGE>
Error: basic_functions.php:9 

Unable to connect to database

So now I'm completely stumped. I haven't changed anything as far as the
scripting on the page goes. I've tried rebooting (seems a likely
solution for windows, but it didn't work :/), I upgraded to the latest
PHP (I had been running 403), and even using the ISAPI module instead of
the CGI...

My apologies if it's obvious and I'm just not seeing it. Any ideas?

--Toby Butzon




Hi,

This looks rather like a problem with your TCP/IP stack. Any changes made to
the w2k network configuration recently?


"Toby Butzon" <[EMAIL PROTECTED]> a écrit dans le message news:
[EMAIL PROTECTED]
> Greetings,
>
> I've run into a problem on my Win2k computer running IIS5 and PHP
> 404pl1. I've got a page set up to pull a page from CNN.com, parse it for
> headlines, and print the results in an organized table of links.
> Everything's been working fine since the beginning of January, but
> suddenly it dies with a PHP warning and my die() message:
>
> <PHP WARNING>
> Warning: fopen("http://www.cnn.com/desktop/content.html","r") - No error
> in _file_extract.php on line 5
> <MY DIE() MESSAGE>
> Unable to open http://www.cnn.com/desktop/content.html
>
> The line that's generating the error looks like this:
> $file = fopen($url, "r") or die("Unable to open $url");
>
> So I figured maybe something was up with my fopen()... but apparently
> not. I also have the same page connecting to the mysql server on
> localhost to request a list of my reminders & tasks that need to be
> done. However, connecting to the db server (on localhost) also dies with
> the following:
>
> <PHP WARNING>
> Warning: MySQL Connection Failed: Can't create TCP/IP socket (10091) in
> basic_functions.php on line 9
> <MY DIE() MESSAGE>
> Error: basic_functions.php:9
>
> Unable to connect to database
>
> So now I'm completely stumped. I haven't changed anything as far as the
> scripting on the page goes. I've tried rebooting (seems a likely
> solution for windows, but it didn't work :/), I upgraded to the latest
> PHP (I had been running 403), and even using the ISAPI module instead of
> the CGI...
>
> My apologies if it's obvious and I'm just not seeing it. Any ideas?
>
> --Toby Butzon
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>






Yes, system() waits for the called program to terminate before PHP
execution continues, so that should work.

However, you may also want to look into building a custom module for PHP
so you can call your C functions directly from PHP. Info on the Zend
API, building PHP modules in C, etc., is available at Zend.com.

--Toby

Zhu George-CZZ010 wrote:
> 
> Does anyone know how to integrate C++ and PHP if there are some data changes between 
>PHP program and C++ program?
> 
> What I can think about is: in PHP, put the data in a file, and use "system" call to 
>activate the c++ program. After that, let the c++ program to read the data file, and 
>output the result into another file, and let the PHP to read the result file.
> But there is one question: will php wait until C++ program finish if I use "system" 
>function from PHP?
> 
> Is there any better way to do the integration?
> 
> Thanks,
> G.Z.
> 
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]




or cname the main PHP site that way we don't have to bog down/rely on
the primary PHP servers.  jobs.php.net

Further to the other conversations on this topic:
        We always investiate any companies that are looking for CGI, Perl,
and ASP solutions since many of them are just going off of whatever
hype or pop phrases they have heard...    many times we have waltzed
in and taken the NT/IIS/ASP proposed project that some small to mid
sized company wanted to hire for and offer a FreeBSD/Apache/PHP based
solution that cost them thousands less in licensing, still nets us
profit on the server implementation (not just web dev folks), and gets
us so close to the customer that it would cost twice as much for them
to move their business elsewhere and have anyone sit down and figure
out what the code logic is.
        Recruiters and HR staff are usually the last people that you want to
try and deal with...  they are busy looking for people with 5+ years
of Windows 2000 administration, 5 different programming languages, and
5 years in marketing for a 50k a year position...  and have no idea
what the job actually entails or the project goals are.
        Personal opinion, as always.

Dave

-----Original Message-----
From: Jonathan Sharp [mailto:[EMAIL PROTECTED]]
Sent: Thursday, February 01, 2001 5:49 PM
To: [EMAIL PROTECTED]; [EMAIL PROTECTED]; [EMAIL PROTECTED]
Subject: RE: [PHP] contracting & consulting (was "[PHP] Pricing for
PHP
pr ogramming???")


because that's too easy! Why would we want to use a system that's
already in
place? hehehe...looks good! I think it'd be best to have PHP jobs
listed at
THE PHP.NET site...got my vote!

-Jonathan

> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, February 01, 2001 2:47 PM
> To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
> Subject: Re: [PHP] contracting & consulting (was "[PHP] Pricing for
PHP
> pr ogramming???")
>
>
> On Thu, Feb 01, 2001 at 04:47:31PM -0600, [EMAIL PROTECTED] wrote:
> > I have implemented a PHP Developer's directory at
> > http://www.phpusergroups.org where you can sign up to the
directory
> > and wehen people are looking for spot jobs you will receive a RFG
> > (request for quotes).
>
> Why do you not contact Brian Schaffner? On http://php.net/links.php
there
> is a link to his "PHP Employment List".
>
> Another suggestion, why not jobs.php.net?  I think Rasmus doesn't
have
> other opinions.
>
> -Egon
>
> --
> http://www.linuxtag.de/
> http://php.net/books.php
> http://www.concert-band.de/
> http://www.php-buch.de/
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail:
[EMAIL PROTECTED]
>
>
>
>


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






Hi Ben,

> I know that that Java/EJB/JSP and COM/ASP is in MUCH more demand, and
> therefore command a higher wage.  Demand vs supply, right?.  A search today
> on monster.com for ASP in LA yields 142 listings, Java yields 262, JSP
> yields 32, Perl yields 105, PHP yields 16, cold fusion yields 16.

Take into account that you need 5 Java programmers where one PHP
programmer would do the job (this is not blind rage against Java; we
have recently completed a Java [ATG Dynamo] project and it has taken 10
times the resources the same solution in PHP would have needed).

> -Has the demand changed much in your city since middle of last year?
Can't tell.

> -Also, for developers who are proficient in several web dev environments, is
> it mostly true that you use PHP for your own personal projects, but some
> other language for big corporate clients.
This is true for our major client; they have decided to go to Java,
leaving us no choice but to follow. They might yet make up their mind,
as ATG Dynamo and Oracle bring in licensing costs of ~ $1m.

> -What is the perception of PHP for mid/large organizations with more to
> risk?
A lot of IT consultants will recommend something expensive so that they
can claim they wanted a 'bussiness standard' if there are problems. Get
more trouble when you have recommended Open Source [*sigh*]. I still
wouldn't, though.

> -What can we as a developer community do to change this?
Prove that Open Source is working, and better than many commercial
solutions, too.

Regards,
Ben





>> -What can we as a developer community do to change this?
>Prove that Open Source is working, and better than many commercial
>solutions, too.

This is something I like to do within my company: they used to buy software
online saying that it is still cheaper then develop it ourselves. Hmm.. I
always agreed, BUT in a different way -- sending them a link to Source Forge
- "Look guys, they have done a similar soft already and even in a similar
language, but, 4 FREE !!!!"  Gezz,, when will they ever understand that
Phorum runs better then some $200 cgi-perl application easier to find for a
manager on AltaVista.

This is how we have to teach them.

Cheers,
Maxim Maletsky




"Benjamin Munoz" <[EMAIL PROTECTED]> wrote:
> Great thread. When I was changing jobs in April of 2000, a recruiter told
me
> that PHP is "cool and all", but there is zero demand for developers of PHP
> web apps (in Los Angeles).

Interesting.  We're located in [not very large, but high tech/internet
concentration] Charlottesville, Virginia and there's a pretty significant
demand for PHP-based apps and websites.  Then again, our target market is
small/medium businesses and small internet startups and after assessing a
client's needs, working with them to define a solution and developing a
proposal that nearly always uses LAMP the clients rarely care what we use as
long as we deliver.  Sure, larger, stodgier corportate clients with IT
departments are more resistent to utilizing PHP and open source technology
for their enterprise solutions, but they aren't the only customers out
there.

> therefore command a higher wage.  Demand vs supply, right?.  A search
today
> on monster.com for ASP in LA yields 142 listings, Java yields 262, JSP
> yields 32, Perl yields 105, PHP yields 16, cold fusion yields 16.

Odd.  My search on monster.com for "php" turned up 324 listings.  I *wish*
there were less - we have listings 135 and 136 and have not found the right
candidate yet.

--
Steve Werby
COO
24-7 Computer Services, LLC
Tel: 804.817.2470
http://www.247computing.com/





>>>>> "SW" == "Steve Werby" <[EMAIL PROTECTED]> writes:
 > "Benjamin Munoz" <[EMAIL PROTECTED]> wrote:
 >> Great thread. When I was changing jobs in April of 2000, a
 >> recruiter told  me
 >> that PHP is "cool and all", but there is zero demand for
 >> developers of PHP web apps (in Los Angeles).

 > Interesting.  We're located in [not very large, but high
 > tech/internet concentration] Charlottesville, Virginia and there's
 > a pretty significant demand for PHP-based apps and websites.

 >> A search today
 >> on monster.com for ASP in LA yields 142 listings, Java yields 262,
 >> JSP yields 32, Perl yields 105, PHP yields 16, cold fusion yields
 >> 16.

 > Odd.  My search on monster.com for "php" turned up 324 listings.  I
 > *wish* there were less - we have listings 135 and 136 and have not
 > found the right candidate yet.

OK, a quick search on jobserve.com (mainly UK based jobs) threw up
52 contract and 282 permanent job postings mentioning PHP within the
last five days.

I've not noticed any problem at all in getting PHP jobs in London.
Although I've not tried contracting yet.

ContractorUK (http://www.contractoruk.co.uk/data-web.html) has a
table of contractor rates which ranks PHP at number 15 in order
of earning power at 44.31 GBP/hour (approx $65). Perl is number 6
at 52.66 GBP/hour (approx $78), just below Java at 54.32 GBP/hour.

Talking to the Perl and PHP Contractors that I know, they tell me
these rates are at the lower/middle end of the range. And speaking
from personal experience, previous companies I've worked for have
regularly charged out my time at over double those rates (not that
I see anything near that money myself). London rates tend to be
higher than in civilized places, as with all things.

(Brief history: 
 I learnt various fun, but not particularly commercial languages at Uni. 
 Picked up Perl while working in a Sysadmin role, then PHP/FI when roped 
 into developing a website. I converted to PHP3 with some relief as soon 
 as it came out and now most of my work is in PHP4 and Perl.)


        -robin

-- 
Robin Vickery.................................................
BlueCarrots, 14th Floor, 20 Eastbourne Terrace, London, W2 6LE




----------------------------------------------------------------------------
----------------- 
Disclaimer: The information contained in this email is intended only for the
use of the person(s) to whom it is addressed and may be confidential or
contain legally privileged information. If you are not the intended
recipient you are hereby notified that any perusal, use, distribution,
copying or disclosure is strictly prohibited. If you have received this
email in error please immediately advise us by return email at
[EMAIL PROTECTED] and delete the email document without making a
copy. 
----------------------------------------------------------------------------
-----------------

If it is the Java PHP module i assume you are talking about and not
Javascript or Java Applets have a look at
http://www.phpbuilder.com/columns/marknold20001221.php3 for an introduction
to PHP and Java.




Mark Nold
[EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]> 
Senior Consultant
 
Change is inevitable, except from vending machines. 



-----Original Message-----
From: Claude Cormier [mailto:[EMAIL PROTECTED]]
Sent: Friday, February 02, 2001 2:42 AM
To: [EMAIL PROTECTED]
Subject: Java variables - PHP varialbles


Hi!,

I am rather a newbie with PHP.

Can someone tell me how we can assign the content of a PHP 
variable to a Java variables in a script (and vice versa).

Thanks

Claude




Muito obrigado pela ajuda Michael!

Hi everyone!
To use de DBA database format, first i had to configurate php with
--with-db2 option. All works (configure, make and make install). But the
php script still not works. The line of the script that has a problem
is:

$id = dba_open ("/home/httpd/html/testes/test.db", "n", "db2");

Fatal error: Call to undefined function: dba_open() in
/home/httpd/html/testes/teste.php on line 5

That's the error. But, when i looks at phpinfo(), it shows that the php
wasn't configurated with --with-db2.

I wanna know, how to upgrate the configurations of php... I already
tried to delete the config.cache file, but still not working.

Anyone knows it?

Tks,
Sorry for the English... /me from Brazil
Scratch





"Karl J. Stubsjoen" <[EMAIL PROTECTED]> wrote:
> What is the purpose of the SPRINTF in this instance?
> SPRINTF("SELECT
>
equence,prodnum,childdesc,onhand,openorders,avlallocate,bakorder,webpricing
> FROM prodaval");

It appears as though the sprintf() function is being misused.  There's no
advantage to using it to wrap around an SQL statement.

--
Steve Werby
COO
24-7 Computer Services, LLC
Tel: 804.817.2470
http://www.247computing.com/





----------------------------------------------------------------------------
----------------- 
Disclaimer: The information contained in this email is intended only for the
use of the person(s) to whom it is addressed and may be confidential or
contain legally privileged information. If you are not the intended
recipient you are hereby notified that any perusal, use, distribution,
copying or disclosure is strictly prohibited. If you have received this
email in error please immediately advise us by return email at
[EMAIL PROTECTED] and delete the email document without making a
copy. 
----------------------------------------------------------------------------
-----------------

Mmmmm, i really think that PHP is considered lightweight by some becuase:

1. Its easy. (Compare to C, Java, and the inconsistancies of VB)
We all know that real programmers only program in **** (insert the hardest
thing you know eg: Machine Code, Fortran, C++ or Basic if you're pretty sad)
with VI installed on on an Commodore 64 with a tape drive...

2. It's a scripting language.
This does make PHP seem less like a "real language", even though a compiled
Java class file still needs an interpreter.


But of course any comments like "PHP a lightweight language?" are typically
flamebait, and i would ignore them (well i will next time)

mn

Mark Nold
[EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]> 
Senior Consultant
 
Change is inevitable, except from vending machines. 



-----Original Message-----
From: Michael Hall [mailto:[EMAIL PROTECTED]]
Sent: Friday, February 02, 2001 6:49 AM
To: [EMAIL PROTECTED]
Subject: PHP a lightweight language?



I'm interested in the proposition made recently on this list that PHP is
somehow a 'lightweight' language that some people don't take seriously. I
am relatively new to Linux and open source programming and only really
know PHP and some shell scripting, though I am now starting to explore
Python.

I have had a quick overview of several languages and it seems to me that
they all deal with the same basic components and logic:

variables
statements
flow control
functions
classes
etc
etc
etc

So I'm wondering, apart from the fact that PHP is web centric, what
features does the language lack that prevent some from taking it
seriously? It appears to me to use the same basic elements and logic as
any other programming language. Maybe it doesn't have tedious requirements
for memory management like C, but so what? Neither does Python.

Any comments appreciated.

Mick






>         Michael Hall <[EMAIL PROTECTED]> wrote
 

> 
> I'm interested in the proposition made recently on this list that PHP is
> somehow a 'lightweight' language that some people don't take seriously. I
> am relatively new to Linux and open source programming and only really
> know PHP and some shell scripting, though I am now starting to explore
> Python.

Seems to me that most languages can be considered "lightweight" in some
respects. After all, couldn't C be considered lightweight compared with
machine code?

And then, most languages are written in something else (something
heavier?): if I remember correctly, Squeak is about the only thing that
really eats its own dog food. And, from what I remember, such recursion
wasn't straightforward!

It's really a silly discussion. PHP does what it does exceptionally
well. You'd be barking mad to write an operating system in it, but you'd
be equally crazy to write a C application to do what a shell script does
or to use Java to run a regex on a text file. 

The reason, I think, that there are so many languages out there is that
each has its advantages when used in a particular context. It may be
able to work out of context, but the overheads in development and/or
compilation or run time build up.

-- 
******************************************************************************
Marx: "Why do Anarchists only drink herbal tea?"
Proudhon: "Because all proper tea is theft."
******************************************************************************




most c compilers are self-hosting. iirc it's one of the best tests of
your compiler.

Gfunk         -          http://www.gfunk007.com/

I sense much beer in you. Beer leads to intoxication, intoxication to
hangovers, and hangovers to... suffering.


----- Original Message -----
From: "John Hinsley" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, February 02, 2001 3:32 PM
Subject: [PHP] Re: PHP a lightweight language?


>
> >         Michael Hall <[EMAIL PROTECTED]> wrote
>
>
> >
> > I'm interested in the proposition made recently on this list that PHP is
> > somehow a 'lightweight' language that some people don't take seriously.
I
> > am relatively new to Linux and open source programming and only really
> > know PHP and some shell scripting, though I am now starting to explore
> > Python.
>
> Seems to me that most languages can be considered "lightweight" in some
> respects. After all, couldn't C be considered lightweight compared with
> machine code?
>
> And then, most languages are written in something else (something
> heavier?): if I remember correctly, Squeak is about the only thing that
> really eats its own dog food. And, from what I remember, such recursion
> wasn't straightforward!
>
> It's really a silly discussion. PHP does what it does exceptionally
> well. You'd be barking mad to write an operating system in it, but you'd
> be equally crazy to write a C application to do what a shell script does
> or to use Java to run a regex on a text file.
>
> The reason, I think, that there are so many languages out there is that
> each has its advantages when used in a particular context. It may be
> able to work out of context, but the overheads in development and/or
> compilation or run time build up.
>
> --
>
****************************************************************************
**
> Marx: "Why do Anarchists only drink herbal tea?"
> Proudhon: "Because all proper tea is theft."
>
****************************************************************************
**
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>





Hi All,

just a quick question. Say my script is inserting values into a
database, which has an autoincremental id. Now I usually send out a
mail also with the contents of the inserted stuff. The only problem
is that of the ID field. How can I get the script to determine what
id number was given to that row?

thanks

/sunny

__________________________________________________
Get personalized email addresses from Yahoo! Mail - only $35 
a year!  http://personal.mail.yahoo.com/




mysql_insert_id() is a PHP function for it.
however I recommend you using a build-in SQL function LAST_INSERT_ID().

i.e: INSERT INTO table SET name='$name', surname='$surname';
UPDATE table SET name='$name', surname='$surname' WHERE id=LAST_INSERT_ID()

Cheers,
Maxim Maletsky

-----Original Message-----
From: Sandeep Hundal [mailto:[EMAIL PROTECTED]]
Sent: Friday, February 02, 2001 12:44 PM
To: PHP General
Subject: [PHP] How do I get last inserted ID?


Hi All,

just a quick question. Say my script is inserting values into a
database, which has an autoincremental id. Now I usually send out a
mail also with the contents of the inserted stuff. The only problem
is that of the ID field. How can I get the script to determine what
id number was given to that row?

thanks

/sunny

__________________________________________________
Get personalized email addresses from Yahoo! Mail - only $35 
a year!  http://personal.mail.yahoo.com/

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




On Fri,  2 Feb 2001 14:13, Sandeep Hundal wrote:
> Hi All,
>
> just a quick question. Say my script is inserting values into a
> database, which has an autoincremental id. Now I usually send out a
> mail also with the contents of the inserted stuff. The only problem
> is that of the ID field. How can I get the script to determine what
> id number was given to that row?
>
> thanks
>
> /sunny

If you are using mysql, mysql_insert_id will do that for you.

-- 
David Robley                        | WEBMASTER & Mail List Admin
RESEARCH CENTRE FOR INJURY STUDIES  | http://www.nisu.flinders.edu.au/
AusEinet                            | http://auseinet.flinders.edu.au/
            Flinders University, ADELAIDE, SOUTH AUSTRALIA




Hello, Sandeep!

Friday, February 02, 2001, 08:43:41, you wrote:

SH> just a quick question. Say my script is inserting values into a
SH> database, which has an autoincremental id. Now I usually send out a
SH> mail also with the contents of the inserted stuff. The only problem
SH> is that of the ID field. How can I get the script to determine what
SH> id number was given to that row?
    for mysql there is a function called mysql_insert_id(). that
    function returns the ID generated for an AUTO_INCREMENT column by
    the previous INSERT query.

    try to dig documentation if you using another db.

Best regards!
Andrew Golovin
PGP Fingertip 24FD A0CD 667C 1FC7 C2F7  A2EA 9742 D484 FD3C 598D
http://exper.ural.ru/ 






"Shane McBride" <[EMAIL PROTECTED]> wrote:
> I was wondering what other PHP people charge to write PHP?

There's no magic answer.  And no offense, but if you categorize building
business solutions delivered via the internet as "writing PHP" then your
services probably shouldn't be priced at the higher end of the spectrum.
There are so many factors - size of project, complexity, reusability of
project components, turnaround time, your reputation, your speed, geography,
etc.  And there are many ways to price a project.  We use a combination of
flat rate pricing, estimates with a cap, hourly rates, retainer arrangements
and some more creative terms depending on another long list of factors.

As a PHP programmer and COO of a development and consulting shop, the
emphasis on hourly rate is something that really amazes me.  Not all
programmers are created equal.  A lot of clients don't recognize that.  Some
mistakenly believe that a $120/hr. programmer is 20% more productive than a
$100/hr. programmer.  Yet others think that a $200/hr. programmer must be
twice as good as a $100/hr. programmer.  I find that there is *no*
correlation between hourly rate and the quality, productivity and value of a
programmer.  Sure, in other non_knowledge_based occupations, there may be a
correlation, but in our biz I don't see one.  Some say "you get what you pay
for", but b/c this industry is new there are a lot of unscrupulous
developers out there talking with naive uneducated clients.  This is a
dangerous mix.  We've talked to a number of prospective clients who were
charged $100,000+ for projects we could have done for $5,000.  I couldn't
sleep at night if we gouged clients like that and in the long run I think
gouging clients will come back to bite you.  We try to emphasize the total
cost to the client along with the benefits of our proposed solutions.  We
try to state these benefits in terms of time savings, exposure, value-added
capabilities, revenue and process improvement.  When you can put what you
can bring to the table in these terms the hourly rate becomes less critical
and it makes it easier to compete with inferior competitors that compete on
price alone.

So, in general what should you charge based on your skills, experience and
the types of things you are building?  At a mimimum you should charge enough
to cover the cost of your operation taking into account the risk of not
staying fully utlized and adding on enough to make an acceptable amount of
profit.  If after arriving at that number it seems that your target market
can't support that rate, reassess your strategy.  As a rule of thumb, a
consulting biz needs to charge 2.5 - 3 times the hourly rate payed to its
employees.  If you're a one person operation, you might think you need to
charge less, but I wouldn't look at it that way.  Unless you have clients
breaking your door down and your clients aren't aware that there *are*
others like you, you'll probably have to spend a significant amount of
non-billable time dealing with running the business, doing marketing, sales
and other business functions.  And if you're alternative is working as an
employee of another company and earning a steady paycheck (unless you just
don't want to work for anyone else) you should plan on at least making
enough to earn more than this alternative.

If I was trying to gauge my value I would probably start low, build up word
of mouth, client referrals and long term relationships and then increase my
rates gradually over time if the market allows you to do so.  In my area a
green PHP programmer working part time might be able do contract work for
$15 an hour while a seasoned guru might be able to command $150 an hour.
Over time your programming skills, productivity and business knowledge
should continuously increase.  As a result your margins should increase,
even if your so called "hourly rate" remains flat.  Unless of course you
hire other people.  That may make your operation much more complex and
difficult to manage than you may think.  Plus, any development firm that
hires a PHP programmer is reducing the pool of PHP programmers available to
my company and I just can't have that.  <grin>

--
Steve Werby
COO
24-7 Computer Services, LLC
Tel: 804.817.2470
http://www.247computing.com/





<rant>

It comes down to one simple thing:
You cannot know how much a project is worth to a client. If they're
willing to pay you $5000, it's worth $5000, wether you think it's worth
$500 or $50000. If I buy a pack of basketball cards for $2 that has
ten cards in it, then they're worth 20c each. If suddenly some
collecter says "ohmigod you have a jordan rookie card in there, i'll
give you $3000", it's now worth $3000, because that's what
he is willing to part with to own it.

In short, any skill, service, or product, is "worth" the amount of money
you can exchange it for" this is how the stock market works
(sometimes), it's how just about everything works. If they're willing
to pay it, you should charge it. They can go somewhere else, noone
is holding a gun to their heads.

Everything is a game. You want the most money possible for it, they
want it for the least amount of money, you compromise on something
you can both live with, or you don't do business, and next job, you
have to start over.

Some people won't look at you if you charge less than $150/hr, some
people won't look at you if you chargre more than 40.... it's just the
way it is.

</rant>

Gfunk         -          http://www.gfunk007.com/

I sense much beer in you. Beer leads to intoxication, intoxication to
hangovers, and hangovers to... suffering.


----- Original Message -----
From: "Steve Werby" <[EMAIL PROTECTED]>
To: "Shane McBride" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Friday, February 02, 2001 3:20 PM
Subject: Re: [PHP] Pricing for PHP programming???


> "Shane McBride" <[EMAIL PROTECTED]> wrote:
> > I was wondering what other PHP people charge to write PHP?
>
> There's no magic answer.  And no offense, but if you categorize building
> business solutions delivered via the internet as "writing PHP" then your
> services probably shouldn't be priced at the higher end of the spectrum.
> There are so many factors - size of project, complexity, reusability of
> project components, turnaround time, your reputation, your speed,
geography,
> etc.  And there are many ways to price a project.  We use a combination of
> flat rate pricing, estimates with a cap, hourly rates, retainer
arrangements
> and some more creative terms depending on another long list of factors.
>
> As a PHP programmer and COO of a development and consulting shop, the
> emphasis on hourly rate is something that really amazes me.  Not all
> programmers are created equal.  A lot of clients don't recognize that.
Some
> mistakenly believe that a $120/hr. programmer is 20% more productive than
a
> $100/hr. programmer.  Yet others think that a $200/hr. programmer must be
> twice as good as a $100/hr. programmer.  I find that there is *no*
> correlation between hourly rate and the quality, productivity and value of
a
> programmer.  Sure, in other non_knowledge_based occupations, there may be
a
> correlation, but in our biz I don't see one.  Some say "you get what you
pay
> for", but b/c this industry is new there are a lot of unscrupulous
> developers out there talking with naive uneducated clients.  This is a
> dangerous mix.  We've talked to a number of prospective clients who were
> charged $100,000+ for projects we could have done for $5,000.  I couldn't
> sleep at night if we gouged clients like that and in the long run I think
> gouging clients will come back to bite you.  We try to emphasize the total
> cost to the client along with the benefits of our proposed solutions.  We
> try to state these benefits in terms of time savings, exposure,
value-added
> capabilities, revenue and process improvement.  When you can put what you
> can bring to the table in these terms the hourly rate becomes less
critical
> and it makes it easier to compete with inferior competitors that compete
on
> price alone.
>
> So, in general what should you charge based on your skills, experience and
> the types of things you are building?  At a mimimum you should charge
enough
> to cover the cost of your operation taking into account the risk of not
> staying fully utlized and adding on enough to make an acceptable amount of
> profit.  If after arriving at that number it seems that your target market
> can't support that rate, reassess your strategy.  As a rule of thumb, a
> consulting biz needs to charge 2.5 - 3 times the hourly rate payed to its
> employees.  If you're a one person operation, you might think you need to
> charge less, but I wouldn't look at it that way.  Unless you have clients
> breaking your door down and your clients aren't aware that there *are*
> others like you, you'll probably have to spend a significant amount of
> non-billable time dealing with running the business, doing marketing,
sales
> and other business functions.  And if you're alternative is working as an
> employee of another company and earning a steady paycheck (unless you just
> don't want to work for anyone else) you should plan on at least making
> enough to earn more than this alternative.
>
> If I was trying to gauge my value I would probably start low, build up
word
> of mouth, client referrals and long term relationships and then increase
my
> rates gradually over time if the market allows you to do so.  In my area a
> green PHP programmer working part time might be able do contract work for
> $15 an hour while a seasoned guru might be able to command $150 an hour.
> Over time your programming skills, productivity and business knowledge
> should continuously increase.  As a result your margins should increase,
> even if your so called "hourly rate" remains flat.  Unless of course you
> hire other people.  That may make your operation much more complex and
> difficult to manage than you may think.  Plus, any development firm that
> hires a PHP programmer is reducing the pool of PHP programmers available
to
> my company and I just can't have that.  <grin>
>
> --
> Steve Werby
> COO
> 24-7 Computer Services, LLC
> Tel: 804.817.2470
> http://www.247computing.com/
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>





Ok, you got me on a technicality :)

Of course, every rule has an exception. Even the rule that
says every rule has an exception ;-)

Gfunk         -          http://www.gfunk007.com/

I sense much beer in you. Beer leads to intoxication, intoxication to
hangovers, and hangovers to... suffering.


----- Original Message -----
From: "Michael Kimsal" <[EMAIL PROTECTED]>
To: "Josh G" <[EMAIL PROTECTED]>
Sent: Friday, February 02, 2001 4:12 PM
Subject: Re: [PHP] Pricing for PHP programming???


>
>
> Josh G wrote:
>
> > <rant>
> >
> > It comes down to one simple thing:
> > You cannot know how much a project is worth to a client. If they're
> > willing to pay you $5000, it's worth $5000, wether you think it's worth
> > $500 or $50000.
>
> I hear you, but have to disagree a bit - I think you CAN sometimes know
> what something is objectively worth.  Not always, but sometimes.
> We wrote an ordering system for a client that, when implemented,
> would make 8 people redundant.  Even on the low end of ~$20k/person,
> plus admin overhead, that project would be saving them ~$200k/year, plus
> the other benefits of having their data faster and with fewer errors.
> That was a no brainer, imo.  They knew they'd save a MINIMUM of $x/year,
> perhaps more.  We knew what the project was worth to them.  If they
> didn't pay our price, yes, in the abstract it wasn't "worth" it to them,
> but that's on an emotional level at that point (worth) not a paper
> figure level.  :)
>
>
>
>
> > If I buy a pack of basketball cards for $2 that has
> > ten cards in it, then they're worth 20c each. If suddenly some
> > collecter says "ohmigod you have a jordan rookie card in there, i'll
> > give you $3000", it's now worth $3000, because that's what
> > he is willing to part with to own it.
> >
> > In short, any skill, service, or product, is "worth" the amount of money
> > you can exchange it for" this is how the stock market works
> > (sometimes), it's how just about everything works. If they're willing
> > to pay it, you should charge it. They can go somewhere else, noone
> > is holding a gun to their heads.
> >
> > Everything is a game. You want the most money possible for it, they
> > want it for the least amount of money, you compromise on something
> > you can both live with, or you don't do business, and next job, you
> > have to start over.
> >
> > Some people won't look at you if you charge less than $150/hr, some
> > people won't look at you if you chargre more than 40.... it's just the
> > way it is.
> >
> > </rant>
> >
> > Gfunk         -          http://www.gfunk007.com/
>





At 11:54 1/02/2001 -0800, Terrence Chay wrote:
>     We should be prudent when discussing how much we charge for programming.
>I'm no lawyer but I believe it's okay to discuss hypotheticals, histories,
>and such, but remember that discussing wage rates may run against anti-trust
>regulation as evidence of collusion (at least in the United States).

You'd better tell the unions that.






>         "Andrés de la Varga" <[EMAIL PROTECTED]> wrote:

> 
> I want to install my personal server on a old Intel 486 machine, 36 Mb RAM,
> 2 Gb HardDisk, VGA, to develop in PHP. What version of Linux do I need to
> install?

Stay clear of any version built specifically for 586 machines. This
certainly means Mandrake, but may include late versions of other
distributions, so check with their home site.

But I'm unsure of what you "really" intend using this machine for. Do
you really want a home network (in which case conventional wisdom
suggests that the server should be the most powerful box on site) or
just something to run php or CGI scripts on with Apache or whatever?

If you can get back with details of what you want to do with that little
old box (and what other machines and Operating Systems you have) I can
maybe be of more help. Personally, I like SuSE.
-- 
******************************************************************************
Marx: "Why do Anarchists only drink herbal tea?"
Proudhon: "Because all proper tea is theft."
******************************************************************************




Sorry about this, but can somebody please remove this guy from
the list? I'm tired of getting this email every time I contribute.

Cheers,
Gfunk         -          http://www.gfunk007.com/

I sense much beer in you. Beer leads to intoxication, intoxication to
hangovers, and hangovers to... suffering.


----- Original Message -----
From: <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, February 02, 2001 3:34 PM
Subject: Message status - undeliverable


> The message that you sent was undeliverable to the following:
> JMARTINEZ
>


----------------------------------------------------------------------------
----


> Information about your message:
> Subject: Re: [PHP] Re: PHP a lightweight language?
>





Well, not being able to find much help on mod_rewrite, I hoped some guru
here might be able to help me.

I'm using mod rewrite to do a pretty simple redirect (or rewrite that it) to
a php page that parses the original url and allows for the output of all
sorts of content.

Works great apart from the fact that the POST vars are lost along the way.
And I believe the cookie vars too, but get seems to be ok.

So, does anyone know how to do url redirection or rewriting or whatever that
allows the post vars to be maintained? Please don't refer me to tim's
article on phpbuilder on the subject as I've read every word twice and all
the annotations to no avail.

Many thanks as always.

Matt Friedman
Spry New Media






You may be getting emails, but for some reason, when I try the links
provided as a demo:

BAD LINK--
http://www.social-ecology.org/new/indexbog.html


PAGE WITH BAD LINK--
http://www.social-ecology.org/indexbogus.html

My browser pops up the save as dialog.  I do have javascript enabled, so
I don't understand it.

I have been working on a similar 404 - actually just trying to modify
the one at phpbuilder.com to work with my system (PHP mail() won't work
because user nobody does not have permissions to execute the deliver
daemon in the Cyrus Imap server).

Are you seeing the page itself?  I can't bring it up.

Lou

John Huggins wrote:
> 
> Ah yes, this seems to stem from the fact the "ErrorDocument 404 /404.php" is
> really a kind if redirect.  What's weird about this is if you use it one way
> (in the .htaccess) the PHP variables that appear are pre-redirect.  If you
> put "Errordocument 404 /404.php" into the httpd.conf the PHP variables are
> post-redirect and are just as if you went straight to the 404.php page.  I
> am sure I am missing some kind of Apache "point-of-view," but is it working
> for most of my URLs now.  Some ancient CGI accesses come in now and again
> and they show this problem.
> 
> However, thanks for the idea and code.  Even as just a 404 trigger, this is
> very useful.  The emails are starting to show just how many old URLs exist
> on my servers.
> 
> John
> 
> > -----Original Message-----
> > From: Institute for Social Ecology [mailto:[EMAIL PROTECTED]]
> > Sent: Thursday, February 01, 2001 2:32 PM
> > To: John Huggins
> > Cc: [EMAIL PROTECTED]
> > Subject: RE: [PHP] 404 error checker
> >
> >
> > John,
> >
> > I had the same problem, but it was a matter of how I was refering the teh
> > 404 file in htaccess.  It is working fine for me now.  An example of my
> > output is below.  I wish I knew more about appache and htaccess to help
> > you out, but I don't.
> >
> > michael
> >
> 
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]

-- 
Louis LeBlanc
Fully Funded Hobbyist, KeySlapper Extrordinaire :)
[EMAIL PROTECTED]
http://acadia.ne.mediaone.net




Hello All!

Sorry for this off-topic posting but this is extremely important for me. 

I need a php script to be called each time my email mailbox recieves a new email 
message. One way is to have a cron job running and get the php script to check my 
mailbox every few minutes to see if there are any new emails and do the needfull if 
there is one.

But I guess that there should be a way for the mail server to initiate some action 
based on the reciept of a new mail in a particular mailbox. I don't think trhat sites 
like Yahoo and Hotmail use cron jobs to sense new emails in a user's mailbox. Another 
possibility might be that the checking is being done every few minutes by the client 
application.

if anyone has any idea about the methodology being followed by Yahoo and Hotmail, 
please be kind enough to pass it on. If anyone is aware of a mail server otr a 
mailserver addin which would enable automatic notification and initiaition of script 
on the reciept of a new email, please pass the info on.

I am on Redhat 6.2 with cyrus as my mail server and am using PHP4.

Thanks in advance

Ankur Verma
HCL Technologies
A1CD, Sector 16,
Noida






Depends on your mailserver. Most mail servers can redirect incoming
mail to a program, I know sendmail can. In your case just make the first
line of your script #!/path/to/php/bin/php and that should do the trick.

Sorry I don't know how to make sendmail do it, only that you can.
Check the man pages tho, shouldn't be too hard.

Gfunk         -          http://www.gfunk007.com/

I sense much beer in you. Beer leads to intoxication, intoxication to
hangovers, and hangovers to... suffering.


----- Original Message -----
From: "Ankur Verma" <[EMAIL PROTECTED]>
To: "PHP User Group" <[EMAIL PROTECTED]>
Sent: Saturday, February 03, 2001 5:51 AM
Subject: [PHP] Automatic incoming mail notification


Hello All!

Sorry for this off-topic posting but this is extremely important for me.

I need a php script to be called each time my email mailbox recieves a new
email message. One way is to have a cron job running and get the php script
to check my mailbox every few minutes to see if there are any new emails and
do the needfull if there is one.

But I guess that there should be a way for the mail server to initiate some
action based on the reciept of a new mail in a particular mailbox. I don't
think trhat sites like Yahoo and Hotmail use cron jobs to sense new emails
in a user's mailbox. Another possibility might be that the checking is being
done every few minutes by the client application.

if anyone has any idea about the methodology being followed by Yahoo and
Hotmail, please be kind enough to pass it on. If anyone is aware of a mail
server otr a mailserver addin which would enable automatic notification and
initiaition of script on the reciept of a new email, please pass the info
on.

I am on Redhat 6.2 with cyrus as my mail server and am using PHP4.

Thanks in advance

Ankur Verma
HCL Technologies
A1CD, Sector 16,
Noida








On Fri,  2 Feb 2001 15:53, Josh G wrote:
> Depends on your mailserver. Most mail servers can redirect incoming
> mail to a program, I know sendmail can. In your case just make the first
> line of your script #!/path/to/php/bin/php and that should do the trick.
>
> Sorry I don't know how to make sendmail do it, only that you can.
> Check the man pages tho, shouldn't be too hard.
>
> Gfunk         -          http://www.gfunk007.com/
>
> I sense much beer in you. Beer leads to intoxication, intoxication to
> hangovers, and hangovers to... suffering.
>
>
> ----- Original Message -----
> From: "Ankur Verma" <[EMAIL PROTECTED]>
> To: "PHP User Group" <[EMAIL PROTECTED]>
> Sent: Saturday, February 03, 2001 5:51 AM
> Subject: [PHP] Automatic incoming mail notification
>
>
> Hello All!
>
> Sorry for this off-topic posting but this is extremely important for me.
>
> I need a php script to be called each time my email mailbox recieves a
> new email message. One way is to have a cron job running and get the php
> script to check my mailbox every few minutes to see if there are any new
> emails and do the needfull if there is one.
>
> But I guess that there should be a way for the mail server to initiate
> some action based on the reciept of a new mail in a particular mailbox. I
> don't think trhat sites like Yahoo and Hotmail use cron jobs to sense new
> emails in a user's mailbox. Another possibility might be that the
> checking is being done every few minutes by the client application.
>
> if anyone has any idea about the methodology being followed by Yahoo and
> Hotmail, please be kind enough to pass it on. If anyone is aware of a
> mail server otr a mailserver addin which would enable automatic
> notification and initiaition of script on the reciept of a new email,
> please pass the info on.
>
> I am on Redhat 6.2 with cyrus as my mail server and am using PHP4.
>
> Thanks in advance
>
> Ankur Verma
> HCL Technologies
> A1CD, Sector 16,
> Noida

There is a nice program called procmail, which may already be on your 
system. Alternatively, under sendmail you can use entries in /etc/aliases 
to play around with redirecting emails.

-- 
David Robley                        | WEBMASTER & Mail List Admin
RESEARCH CENTRE FOR INJURY STUDIES  | http://www.nisu.flinders.edu.au/
AusEinet                            | http://auseinet.flinders.edu.au/
            Flinders University, ADELAIDE, SOUTH AUSTRALIA




Dear Josh,

Thanks for your prompt reply

I will surely look around on the web for info on this pathy of action.

thanks once again

regards

Ankur Verma

----- Original Message -----
From: "Josh G" <[EMAIL PROTECTED]>
To: "PHP User Group" <[EMAIL PROTECTED]>
Sent: Friday, February 02, 2001 10:53 AM
Subject: Re: [PHP] Automatic incoming mail notification


> Depends on your mailserver. Most mail servers can redirect incoming
> mail to a program, I know sendmail can. In your case just make the first
> line of your script #!/path/to/php/bin/php and that should do the trick.
>
> Sorry I don't know how to make sendmail do it, only that you can.
> Check the man pages tho, shouldn't be too hard.
>
> Gfunk         -          http://www.gfunk007.com/
>
> I sense much beer in you. Beer leads to intoxication, intoxication to
> hangovers, and hangovers to... suffering.
>
>
> ----- Original Message -----
> From: "Ankur Verma" <[EMAIL PROTECTED]>
> To: "PHP User Group" <[EMAIL PROTECTED]>
> Sent: Saturday, February 03, 2001 5:51 AM
> Subject: [PHP] Automatic incoming mail notification
>
>
> Hello All!
>
> Sorry for this off-topic posting but this is extremely important for me.
>
> I need a php script to be called each time my email mailbox recieves a new
> email message. One way is to have a cron job running and get the php
script
> to check my mailbox every few minutes to see if there are any new emails
and
> do the needfull if there is one.
>
> But I guess that there should be a way for the mail server to initiate
some
> action based on the reciept of a new mail in a particular mailbox. I don't
> think trhat sites like Yahoo and Hotmail use cron jobs to sense new emails
> in a user's mailbox. Another possibility might be that the checking is
being
> done every few minutes by the client application.
>
> if anyone has any idea about the methodology being followed by Yahoo and
> Hotmail, please be kind enough to pass it on. If anyone is aware of a mail
> server otr a mailserver addin which would enable automatic notification
and
> initiaition of script on the reciept of a new email, please pass the info
> on.
>
> I am on Redhat 6.2 with cyrus as my mail server and am using PHP4.
>
> Thanks in advance
>
> Ankur Verma
> HCL Technologies
> A1CD, Sector 16,
> Noida
>
>
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]





"Josh G" <[EMAIL PROTECTED]> wrote:
> Depends on your mailserver. Most mail servers can redirect incoming
> mail to a program, I know sendmail can. In your case just make the first
> line of your script #!/path/to/php/bin/php and that should do the trick.

To actually read from the message piped to the PHP script, you'll need to
use the following to read from STDIN:

fopen( 'php://stdin', 'r' );

The above isn't widely documented, but it works.  With all this said, if the
original poster simply wants to let a web-based user know that there is a
new message in the user's email box, a better strategy may be to store all
of the messages in a database like MySQL and compare the timestamp on the
most recent message to the timestamp in a session variable from the previous
page access.  It wasn't clear what the poster was attempting, but with some
more details someone (maybe me) could provide a good solution.  Also, PHP
has functions for accessing IMAP accounts which could prove useful.

> Sorry I don't know how to make sendmail do it, only that you can.

Using sendmail you add an alias to pipe incoming email to a program (your
PHP script).  You may also need to create a symbolic link in a directory
utilized by smrsh (sendmail restricted shell) to allow sendmail to execute
your script (this is done for security reasons).  "man smrsh" for details.

--
Steve Werby
COO
24-7 Computer Services, LLC
Tel: 804.817.2470
http://www.247computing.com/





Hi guys,

ok I have had the same problem,
what you need to do, If i correctly understood,
is go in the /etc/mail/aliases file,
then write there:


you: "| /path/to/your/script.php"

and your script will begin by:


#!/path/to/php/as/a/shell  

<?
etc.....

?>


How this works is: send an email to [EMAIL PROTECTED]
then this mail will be piped into your script.php

et voila !!

take care,
have fun,
take php,

nicolas.




subscribe
--
Where's dave? http://www.findu.com/cgi-bin/find.cgi?kc6ete-9






send an email at [EMAIL PROTECTED]

you will be asked for the confirmation..

Cheers,
Maxim Maletsky

-----Original Message-----
From: David VanHorn [mailto:[EMAIL PROTECTED]]
Sent: Friday, February 02, 2001 2:52 PM
To: [EMAIL PROTECTED]
Subject: [PHP] how do I subscribe?


subscribe
--
Where's dave? http://www.findu.com/cgi-bin/find.cgi?kc6ete-9



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




"David Robley" <[EMAIL PROTECTED]> wrote:
> The specific answer to your question is that the variable $birthday is
> local to the function - check out variable scope in the manual.
>
> But in fact there is another way of doing it - pass the values to check as
> parameters to the function and have it return a result, thus:
>
> function CheckBirthday($year,$month,$day) {

This is a good solution for something this simple.  [to original poster:] If
you're comfortable jumping into learning OOP (object oriented programming)
you can use classes.  There are plenty of good tutorials on classes (b/w
phpbuilder.com, devshed and zend you should be set).  Classes have a lot of
benefits which I won't go into, but one benefit is that it easy to use
related functions seamlessly and it's easy to create variables which are
accessible by all functions within the class (a class is essentially a
collection of functions that can talk with one another).

--
Steve Werby
COO
24-7 Computer Services, LLC
Tel: 804.817.2470
http://www.247computing.com/





Hello Guys,
to be short:
 
1. what I'm doing:
 
I need to send some email recipients of which are some users from a
database. (this part perfectly works)
What I care about is that when they receive the email they see 'J-Door
Newsletter' in their from field, not our email address (
'[EMAIL PROTECTED]' <mailto:'[EMAIL PROTECTED]'> )
 
3. how I'm doing it:
below is the PHP code followed by what message header looks like on received
email.
 
 
<snip>
  $from = '"' . $POSTED['from_name'] . '" <' . $POSTED['from_email'] . '>';
 
   mail( $rec['email'],
    stripslashes($POSTED['subject']),
    stripslashes(str_replace('%name%', $rec['name'], $POSTED['body'])),
"FROM: $from
    \nContent-Type: text/plain; charset=$encode
    \nContent-Transfer-Encoding: 8bit"
   );
</snip>
 
</snip>
 
Received: from japaninc.net ([210.229.233.105]) by
exc-tyo-01.lincmedia.co.jp with SMTP (Microsoft Exchange Internet Mail
Service Version 5.5.2650.21)
 id DZ8G4JTZ; Fri, 2 Feb 2001 16:10:11 +0900
Received: (from nobody@localhost)
 by japaninc.net (8.9.3/8.9.3) id QAA10798;
 Fri, 2 Feb 2001 16:01:03 +0900
Date: Fri, 2 Feb 2001 16:01:03 +0900
Message-Id: < [EMAIL PROTECTED]
<mailto:[EMAIL PROTECTED]> >
To: [EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]> 
Subject: Message Body [Will be sent exactly as you see it in this box]:
FROM: "J-Door Newsletter" < [EMAIL PROTECTED]
<mailto:[EMAIL PROTECTED]> >
Content-Type: text/plain; charset=iso-8859-1
    
Content-Transfer-Encoding: 8bit
 
</snip>
 
 
 
It all looks alright to me, however in from field of my email client I still
see ' [EMAIL PROTECTED]' <mailto:[EMAIL PROTECTED]'>  instead of
'J-Door Newsletter' ,
 
What am doing wrong?
 
Cheers,

Maxim Maletsky - [EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]> 
Webmaster, J-Door.com / J@pan Inc.
LINC Media, Inc.
TEL: 03-3499-2175 x 1271
FAX: 03-3499-3109

http://www.j-door.com <http://www.j-door.com/> 
http://www.japaninc.net <http://www.japaninc.net/> 
http://www.lincmedia.co.jp <http://www.lincmedia.co.jp/> 


 




Hello !

I want to send a PGP-encrypted EMail out of a php-script. I'm a very
newbee in PGP and actual know nothing. Could someone please give me some
hints how to do it ?

Regards

Martin








You should find this useful :) ........

http://www.phpuk.org/code.php

All the best

Ade

---  i n o v i c a . c o m  ------------------------
e:     [EMAIL PROTECTED]
w:     http://www.inovica.com

Web Apps, virtual communities and vertical portals
Hosting and dedicated servers just around the corner
Contact us for low-cost domain name registration
----------------------------------------------------



----- Original Message ----- 
From: "Martin Thoma" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, February 02, 2001 8:43 AM
Subject: [PHP] PGP


> Hello !
> 
> I want to send a PGP-encrypted EMail out of a php-script. I'm a very
> newbee in PGP and actual know nothing. Could someone please give me some
> hints how to do it ?
> 
> Regards
> 
> Martin
> 
> 
> 
> 
> 
> -- 
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
> 





Can i know the date of the last table update in a Mysql database?
Thank you!!




http://www.weberdev.com

-----Original Message-----
From: Brian Tully [mailto:[EMAIL PROTECTED]]
Sent: Friday, February 02, 2001 12:19 AM
To: PHP
Subject: [PHP] Recommended Job Posting sites? Need to hire someone w/ PHP
exp.


Hey there - 

I was wondering what the recommended sites are to post/find jobs related to
web development - especially PHP.  The sites I've visited list mostly ASP
and Java related jobs so I'm wondering where do the PHP folks go to find
opportunities. While I'm not looking for a PHP expert, I'm looking for
someone with good web skills and has at least some PHP experience (as well
as the desire to learn more!). I'd appreciate any recommendations/advice.

Thanks in advance,
brian


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




Hi all,

I just downloaded php4.0.4 and tried to get it running on my linux-box
(SUSE6.3 Distribution).
Configuring with  ./configure --with-mysql --with-apxs --with-oracle
--with-oci8 --with-gd         
and then making and installing worked fine, but whenever I restart
apache with the php4-module enabled,
it crashes with a segmentation fault.

Any Ideas about this?
Please let me know if you need further information.

Thanks a lot 
Frank




Hi,

Does anyone know how I can 'tell' the Zend IDE to actually use Swiss-French
keyboard layout instead of french? I know it's related to Java thinking as
I'm living in Belgium, I must have a french keyboard layout. Yet, I don't,
and I can't type correctly now :)

Oh, by the way... Zend IDE for Windows is written in Java. Microsoft is
dumping Java completely. Find the mistake.

Thanks for helping me out.






Alain,

Have you tried changing your keyboard layout in the Windows Control-Panel 
to Swiss-French?
As far as I know, Java uses your systems keyboard layout.

Java will be supported by other vendors such as Sun & IBM on Windows so I 
wouldn't worry about it ;)
And of course our aim is to support UNIX platforms such as Linux which also 
have Java support.

Andi

At 10:43 AM 2/2/2001 +0100, Alain Fontaine wrote:
>Hi,
>
>Does anyone know how I can 'tell' the Zend IDE to actually use Swiss-French
>keyboard layout instead of french? I know it's related to Java thinking as
>I'm living in Belgium, I must have a french keyboard layout. Yet, I don't,
>and I can't type correctly now :)
>
>Oh, by the way... Zend IDE for Windows is written in Java. Microsoft is
>dumping Java completely. Find the mistake.
>
>Thanks for helping me out.
>
>
>
>--
>PHP General Mailing List (http://www.php.net/)
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, e-mail: [EMAIL PROTECTED]
>To contact the list administrators, e-mail: [EMAIL PROTECTED]





Hi Andi,

Yes, of course my keyboard layout is set to swiss-french in Windows, or I
couldn't use my keyboard at all. The problem only applies to Java software,
actually, and not only to Zend IDE as far as I can see. Fact is, however,
that my "Regional Settings" are set to "French". I guess the JRE is looking
for that setting and deducts the keyboard layout from it, instead of
actually using the "keyboard layout" setting, which -is- set to SF.

Maybe there is some config file or so that allows me to manually set the
keyboard layout to be used by the Java runtime environment ?

> -----Message d'origine-----
> De : Andi Gutmans [mailto:[EMAIL PROTECTED]]
> Envoye : vendredi 2 fevrier 2001 12:08
> A : Alain Fontaine; [EMAIL PROTECTED]
> Objet : Re: [PHP] Zend IDE
>
>
> Alain,
>
> Have you tried changing your keyboard layout in the Windows Control-Panel
> to Swiss-French?
> As far as I know, Java uses your systems keyboard layout.
>
> Java will be supported by other vendors such as Sun & IBM on Windows so I
> wouldn't worry about it ;)
> And of course our aim is to support UNIX platforms such as Linux
> which also
> have Java support.
>
> Andi
>
> At 10:43 AM 2/2/2001 +0100, Alain Fontaine wrote:
> >Hi,
> >
> >Does anyone know how I can 'tell' the Zend IDE to actually use
> Swiss-French
> >keyboard layout instead of french? I know it's related to Java
> thinking as
> >I'm living in Belgium, I must have a french keyboard layout.
> Yet, I don't,
> >and I can't type correctly now :)
> >
> >Oh, by the way... Zend IDE for Windows is written in Java. Microsoft is
> >dumping Java completely. Find the mistake.
> >
> >Thanks for helping me out.
> >
> >
> >
> >--
> >PHP General Mailing List (http://www.php.net/)
> >To unsubscribe, e-mail: [EMAIL PROTECTED]
> >For additional commands, e-mail: [EMAIL PROTECTED]
> >To contact the list administrators, e-mail: [EMAIL PROTECTED]
>
>






At 11:43 2/2/2001, Alain Fontaine wrote:
>Oh, by the way... Zend IDE for Windows is written in Java. Microsoft is
>dumping Java completely. Find the mistake.

The Zend IDE is written in Java, period;  You may consider this a mistake 
if you're not fond of Java, but this has nothing to do with Microsoft 
dumping Java (and switching to a Java clone called C#) for marketing and 
courtroom reasons.

The same binaries are used for the Windows version and the Linux version, 
and it actually delivers Java's promise of platform independence.

Zeev





Hi again,


I just checked the Sun "bugParade", and this is a known bug (for over three
releases now). Swing components don't get the correct keyboard layout; they
assume that the keyboard layout matches the locale setting, which is,
obviously, utter nonsense.

I guess this means that the Zend IDE is not useable by anyone who uses a
keyboard layout that is a bit "special", e.g.:

* Luxembourg: most of them use french locale, but swiss-french or german
keyboard layout
* Belgium: some use french locale, some use dutch locale, some with french
layout, some with american layout, even some with UK layout.
* etc.

"Java - write once, run anywhere". Shouldn't this rather be: "Java - be sure
to use an US keyboard!" ? ;)

> -----Message d'origine-----
> De : Andi Gutmans [mailto:[EMAIL PROTECTED]]
> Envoye : vendredi 2 fevrier 2001 12:08
> A : Alain Fontaine; [EMAIL PROTECTED]
> Objet : Re: [PHP] Zend IDE
>
>
> Alain,
>
> Have you tried changing your keyboard layout in the Windows Control-Panel
> to Swiss-French?
> As far as I know, Java uses your systems keyboard layout.
>
> Java will be supported by other vendors such as Sun & IBM on Windows so I
> wouldn't worry about it ;)
> And of course our aim is to support UNIX platforms such as Linux
> which also
> have Java support.
>
> Andi
>
> At 10:43 AM 2/2/2001 +0100, Alain Fontaine wrote:
> >Hi,
> >
> >Does anyone know how I can 'tell' the Zend IDE to actually use
> Swiss-French
> >keyboard layout instead of french? I know it's related to Java
> thinking as
> >I'm living in Belgium, I must have a french keyboard layout.
> Yet, I don't,
> >and I can't type correctly now :)
> >
> >Oh, by the way... Zend IDE for Windows is written in Java. Microsoft is
> >dumping Java completely. Find the mistake.
> >
> >Thanks for helping me out.
> >
> >
> >
> >--
> >PHP General Mailing List (http://www.php.net/)
> >To unsubscribe, e-mail: [EMAIL PROTECTED]
> >For additional commands, e-mail: [EMAIL PROTECTED]
> >To contact the list administrators, e-mail: [EMAIL PROTECTED]
>
>






Can you please explain more detail because I'm new in Javascript and
PHP?  How should I write my coding in order to target the parent
window?  I am trying so many ways but I'm still can't manage to do it.

Please help me again.

This is in Parent window.  The delete buttons are looping buttons.

#### Delete button in parent window########
      print "<TD><input name=\"delbutton$count\" type=\"button\"
value=\"del\"
onclick=\"NewWin=window.open('URL?count=$count&doc_var=$doc_var&doc_no=$doc_no&doc_rev=$doc_rev&flow_no=$flow_no','NewWin','toolbar=no,status=no,scrollbars=yes,width=400,height=200')\"></TD>\n";
      


#########################
In child window have two delete buttons:

###############################
function delopt()
###############################
{
global $h,$newbutton,$doc_var,$count,$doc_no,$doc_rev,$flow_no;

$db = mysql_select_db("tkenet_db");

print "<HTML>
         <HEAD>
            <TITLE>PMP Document Approval</TITLE>
         </HEAD>
         <BODY background=images/bg_tkenet.gif >\n";
  print "<SCRIPT LANGUAGE =\"JavaScript\"> \n";
         print "function confirm_del()
           {
             if(confirm('Are you sure you want to delete!'))
               {self.location.href=\"URL\"}
           else
             {return false;}
             
            }\n";
print "</SCRIPT>\n";

        print" <form method=\"Post\" name=\"deleteform\"
action=\"newwin.php\" onSubmit=\"return confirm_del(); window.close\">
         <center>
         <H1>Delete Option</H1>
         </center>
         <UL>
           <LI>Delete Link = Delete the document number in the textbox
           <LI>Delete All = Delete the document number in all tables
         </UL>
         <center>
         <input name=\"newbutton\" type=\"submit\" value=\"Delete
Link\">
         <input name=\"newbutton\" type=\"submit\" value=\"Delete All\">
         </center>
         <INPUT TYPE=hidden NAME=\"doc_no\" VALUE=\"$doc_no\">
           <INPUT TYPE=hidden NAME=\"doc_rev\" VALUE=\"$doc_rev\">
           <INPUT TYPE=hidden NAME=\"flow_no\" VALUE=\"$flow_no\">
         <INPUT TYPE=hidden NAME=\"doc_var\" VALUE=\"$doc_var\">
           <INPUT TYPE=hidden NAME=\"count\" VALUE=\"$count\">
        
</center></form></body>
</HTML>\n";
}


####################################################################

John Luxford wrote:
> 
> Could you not just set the target in the new window form to the name of
> the parent window, and use an onsubmit="window.close ()" to lose the
> popup as well?
> 
> Lux
> 
> Wen Ni Leong wrote:
> 
> > I am not sure whether this is related to PHP.  I'm using PHP and
> >
> > Javascript to do my program.
> >
> > I have some problem with my reloading parent window.
> >
> >
> >
> > In my program, I have a delete button which will pop up a child window
> >
> > once the user clicked the button.  In the child window will have two
> >
> > option of delete buttons.
> >
> > Once the user clicked either one button, i want the child window to be
> >
> > close and at the same time the parent window will reload.  How should I
> >
> > do this.
> >
> > Please give some advise or tips to me.
> >
> >
> >
> > thanks.




does anyone know what's wrong with this files?
i want to pass the parameter $module_id from one file tot the next so
that i can extract all records from my tables in the mysql database that
have this parameter... the queries that i used are tested and are
working correctly... at this moment i cant see waht i do wrong.. does
anyone know an answer tot my problem? if you need tot know more about
the result look at my url.. please help me....

http://stuwww.kub.nl/~s695645/TIAS/

file test_blok_array.php3

<? include("connect.php3") ?>

<?
$result = mysql_query ("select m.module_id,m.module_nummer
   from module m, leergang l where m.leergang_afkorting =
l.leergang_afkorting
   and m.leergang_afkorting = 'EDP16' order by m.module_nummer");
while (list ($module_id,$module_nummer) = mysql_fetch_row ($result)) {

 echo "<a href=\"test_list.php3?module_id=$module_id\"> BLOK
0$module_nummer | </a>";
}
?>

file test_list.php3

<? include("test_blok_array.php3") ?>

<table>
<form action="_url_" method="post">

 <table border=1>
 <tr>
  <th>submodule</th>
  <th>onderdeel</th>
  <th>docent</td>
  <th>datum</th>
  <th>dagdeel</th>
  <th>edit</th>
  <th>delete</th>
 </tr>

<?php
mysql_connect ("kubstu.kub.nl","s695645","BikHuis");
mysql_select_db ("s695645");
$result = mysql_query ("SELECT
u.module_id,u.submodule_nummer,u.submodule_naam,d.docent_naam,s.dagdeel,s.datum,u.submodule_id,u.submodule_id

   FROM submodule u, sessie s, docent d, module m
   WHERE u.module_id = '$module_id'
   AND d.docent_nummer = s.docent_nummer
   AND u.submodule_id = s.submodule_id
   AND m.module_id = u.module_id
   AND m.leergang_afkorting = 'EDP16'
   ORDER BY s.datum, u.submodule_nummer");
while (list ($module_id, $submodule_nummer, $submodule_naam,
$docent_naam, $dagdeel, $datum, $submodule_id, $submodule_id) =
mysql_fetch_row ($result)) {
    echo   " <tr>
             <td><small>$submodule_nummer</small></td>
             <td><small>$submodule_naam</small></td>
             <td><small>$docent_naam</small></td>
             <td><small>$datum</small></td>
             <td><small>$dagdeel</small></td>
      <td><a href=\"edit.php3?submodule_id=$submodule_id\"><small> edit
</small></a></td>
             <td><a
href=\"delete.php3?submodule_id=$submodule_id\"><small> delete
</small></a></td>
             </tr>\n";
}




Rule #1:
Do not post your database credentials into newsgroups.
Rule #2:
See Rule #1



"Stinie Steinbach" <[EMAIL PROTECTED]> a écrit dans le message news:
[EMAIL PROTECTED]
> does anyone know what's wrong with this files?
> i want to pass the parameter $module_id from one file tot the next so
> that i can extract all records from my tables in the mysql database that
> have this parameter... the queries that i used are tested and are
> working correctly... at this moment i cant see waht i do wrong.. does
> anyone know an answer tot my problem? if you need tot know more about
> the result look at my url.. please help me....
>
> http://stuwww.kub.nl/~s695645/TIAS/
>
> file test_blok_array.php3
>
> <? include("connect.php3") ?>
>
> <?
> $result = mysql_query ("select m.module_id,m.module_nummer
>    from module m, leergang l where m.leergang_afkorting =
> l.leergang_afkorting
>    and m.leergang_afkorting = 'EDP16' order by m.module_nummer");
> while (list ($module_id,$module_nummer) = mysql_fetch_row ($result)) {
>
>  echo "<a href=\"test_list.php3?module_id=$module_id\"> BLOK
> 0$module_nummer | </a>";
> }
> ?>
>
> file test_list.php3
>
> <? include("test_blok_array.php3") ?>
>
> <table>
> <form action="_url_" method="post">
>
>  <table border=1>
>  <tr>
>   <th>submodule</th>
>   <th>onderdeel</th>
>   <th>docent</td>
>   <th>datum</th>
>   <th>dagdeel</th>
>   <th>edit</th>
>   <th>delete</th>
>  </tr>
>
> <?php
> mysql_connect ("kubstu.kub.nl","s695645","BikHuis");
> mysql_select_db ("s695645");
> $result = mysql_query ("SELECT
>
u.module_id,u.submodule_nummer,u.submodule_naam,d.docent_naam,s.dagdeel,s.da
tum,u.submodule_id,u.submodule_id
>
>    FROM submodule u, sessie s, docent d, module m
>    WHERE u.module_id = '$module_id'
>    AND d.docent_nummer = s.docent_nummer
>    AND u.submodule_id = s.submodule_id
>    AND m.module_id = u.module_id
>    AND m.leergang_afkorting = 'EDP16'
>    ORDER BY s.datum, u.submodule_nummer");
> while (list ($module_id, $submodule_nummer, $submodule_naam,
> $docent_naam, $dagdeel, $datum, $submodule_id, $submodule_id) =
> mysql_fetch_row ($result)) {
>     echo   " <tr>
>              <td><small>$submodule_nummer</small></td>
>              <td><small>$submodule_naam</small></td>
>              <td><small>$docent_naam</small></td>
>              <td><small>$datum</small></td>
>              <td><small>$dagdeel</small></td>
>       <td><a href=\"edit.php3?submodule_id=$submodule_id\"><small> edit
> </small></a></td>
>              <td><a
> href=\"delete.php3?submodule_id=$submodule_id\"><small> delete
> </small></a></td>
>              </tr>\n";
> }
>






Dear Sir,
  Would you mind solving my problem?
  I would like to use a Perl Program to call PHP to do sth. Could I do that?
  Also, could I use PHP program to call a Perl Program?

Thank you very much,
Kevin


===================================================================
·s®ö§K¶O¹q¤l¶l½c http://sinamail.sina.com.hk 





On Thu, Feb 01, 2001 at 09:13:34PM +0200, Teodor Cimpoesu wrote:
> 
> 
> Peter Sabaini wrote:
> > 
> > hello,
> > 
> > i am rather desperately trying to figure out how to delete a node
> > object from the DOM.
> > 
> > say i have a node $node by manually traversing the DOM tree or by an
> > xpath_eval() function call. i can access the children
> > ($node->children()) or the parent ($node->parent()) or add a sub-node
> > ($node->new_child()) but there seems to be no $node->unlink() or
> > something like that to remove $node from my DOM tree.
> > 
> > in libxml which the php domxml extension is built upon there's a
> > function xmlUnlinkNode() which seems to do just that, but there is no
> > binding for this function in php (or i didn't find it. i looked in
> > ext/domxml/php_domxml.c).
> > 
> > any solutions / workarounds / patches anyone? or am i being plain
> > dumb -- i am pretty a php novice so chances are i overlooked the very
> > very obvious.
> > 
> I've been playing w/ DOM XML extension for my documentation catalog 
> (docs.digiro.net still work in progress ;), and my first shot would be
> to unset the node from the children list of its parent. I also dig for
> what
> methods a DomNode, DomAttribute etc. have and figured out some. I would
> like 
> to see them documented somewhere ...
> 
> -- teodor

hi teodor && all, 

thanks but i am not sure how to accomplish this. 

eg. if i do:

        $kids = $parent->children();
        $node_to_delete = $kids[0];
        unset($node_to_delete);

 -- this won't cut it because i would just unset $node_to_delete,
right?

i am not entirely sure what the children() method returns but i guess
it is a reference into the tree and unset()ting the reference wont buy
me anything. as far as i understand php and references, that is. this
would only work if children() would return a true pointer, i think.

any further suggestions? i really need this; if i wasnt such a poor c
programmer i'd implement it myself...

tia,
peter. 

-- 
Peter Sabaini [EMAIL PROTECTED]
NETCONOMY Onlineberatungs- und -management Gmbh & Co KG
www.netconomy.net - Schoenaugasse 64, 8010 Graz
Tel. +43-(0)316 875-3081.






I have a .html page, that is "called" (openfile)  by .php script. I did
that to the designer have more freedon.

But know I want to but an JavaScript to verify if a date/hour is a valid
format for MySQL.

Where should I put the JavaScript? In .php or .html?

Or I should check the date and hour on .php script?

thanks,

Augusto Cesar Castoldi





ACC> But know I want to but an JavaScript to verify if a date/hour is a valid
ACC> format for MySQL.
ACC> Where should I put the JavaScript? In .php or .html?
Well you could actually put it in both, although it is easier to put
it the html since it avoids too much embeding.

ACC> Or I should check the date and hour on .php script?
It also depends.
The good thing about checking it with javascript is
that you are on the client side, therefore there are no query sent to
your server. If you use Javascript that also means the user doesn't
get sent to a page checking validity.
If you check it with Php that means the information is submitted to
the page and you treat it afterwards.

_______________________________________
Massuelles Jean-Baptiste([EMAIL PROTECTED])
Société A Comme...
Tel : 03 80 700 702







hi!
if u wanna use javascript the code should be added in html!
but it's better to use php for checking date and hour !
As long  as u use php technologie get rid of these client side stuff till 
it's necessary!

cheers

>From: Augusto Cesar Castoldi <[EMAIL PROTECTED]>
>To: [EMAIL PROTECTED]
>Subject: [PHP] JavaScript, PHP and HTML
>Date: Fri, 2 Feb 2001 09:16:00 -0200 (EDT)
>
>I have a .html page, that is "called" (openfile)  by .php script. I did
>that to the designer have more freedon.
>
>But know I want to but an JavaScript to verify if a date/hour is a valid
>format for MySQL.
>
>Where should I put the JavaScript? In .php or .html?
>
>Or I should check the date and hour on .php script?
>
>thanks,
>
>Augusto Cesar Castoldi
>
>
>--
>PHP General Mailing List (http://www.php.net/)
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, e-mail: [EMAIL PROTECTED]
>To contact the list administrators, e-mail: [EMAIL PROTECTED]
>

_________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.





El Jue 01 Feb 2001 13:49, Alexander Skwar escribió:
> So sprach Martin A. Marques am Thu, Feb 01, 2001 at 12:20:54PM -0300:
> > yes (depending)
>
> On what?

It depends on the charset you use.

Saludos... :-)

-- 
System Administration: It's a dirty job, 
but someone told I had to do it.
-----------------------------------------------------------------
Martín Marqués                  email:  [EMAIL PROTECTED]
Santa Fe - Argentina            http://math.unl.edu.ar/~martin/
Administrador de sistemas en math.unl.edu.ar
-----------------------------------------------------------------




On Thursday 01 February 2001 19:07, Karl J. Stubsjoen wrote:

> I'm trying to pass back a link to the user in a textbox (so they can
> copy and paste it elsewhere), however my textbox is being parsed
> incorrectly by the browser because of the " quotes which happen in the
> link I'm passing - basically the HTML for the text box is getting
> parsed together with the HTML for the passed link and .... the results
> are messed up.

I think you want to use htmlentities ():

echo "<textarea name='foo' rows='20' cols='50'>" . 
  htmlentities ($Content) . "</textarea>";

-- 
Christian Reiniger
LGDC Webmaster (http://sunsite.dk/lgdc/)

The most exciting phrase to hear in science, the one that heralds new
discoveries, is not "Eureka", but "That's funny..."

- Isaac Asimov




Hi,

is there a way to find out what configure command-line was used to
compile the PHP module, if the apache is not running? if it was
running, phpinfo() would show that.

but currently the case is to try to re-compile the PHP with same
settings and see if it would start working. :)


Rgds,
  Tfr

  --==< [EMAIL PROTECTED] >==< http://tfr.cafe.ee/ >==< +372-50-17621 >==-- 




I see in the posts, that a lot of people are using Apache on NT instead of the built 
in IIS.  Is there a reason?  I have PHP up and running with dBase tables converted to 
MySQL and ODBC connected to Access 2000, on an NT 4 box with IIS 4 and it runs very 
well.  Performance is great.  My only problem is automating the conversion to update 
tables in MySQL.  I would like like to convert the Access 2000 tables also but the 
converters either don't seem to work with Access 2k, or not much at all, or are not 
such that a timed batch file can be generated using them.  I just looked at what I've 
written and it's a little jumbled.  Mega-Sigh.  Let me summarize.

  1.. Why Apache on NT 4.0?
  2.. Is there a good way to automatically convert Access 2000 to MySQL to keep MySQL 
data up to date?  The data needs to be updated several times a week.  No I can't just 
switch everything over and not have to convert again.
  3.. A way to do #2 for dBase would be good too, but less critical because the data 
only gets updated every couple months.
Thanks in advance.

Dan Malcolm
[EMAIL PROTECTED]
[EMAIL PROTECTED]





Over 60% of websites use Apache. Many people using MySQL and PHP also run
Apache for the complete open source solution. This is cheap to set up, and
easy to get support for (there's even a mailing list called AMP -
Apache/MySQL/PHP). And, IIRC, those on NT 4.0 Workstation don't *have* IIS.

It's easy to configure and maintain, is constantly being upgraded and
bug-fixed, and has tons of support and reference online.
        
Just my 0.02 euros, obviously.

Cheers
Jon


-----Original Message-----
From: Dan Malcolm [mailto:[EMAIL PROTECTED]]
Sent: 02 February 2001 11:49
To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
Subject: [PHP] For My Information


I see in the posts, that a lot of people are using Apache on NT instead of
the built in IIS.  Is there a reason?  I have PHP up and running with dBase
tables converted to MySQL and ODBC connected to Access 2000, on an NT 4 box
with IIS 4 and it runs very well.  Performance is great.  My only problem is
automating the conversion to update tables in MySQL.  I would like like to
convert the Access 2000 tables also but the converters either don't seem to
work with Access 2k, or not much at all, or are not such that a timed batch
file can be generated using them.  I just looked at what I've written and
it's a little jumbled.  Mega-Sigh.  Let me summarize.

  1.. Why Apache on NT 4.0?
  2.. Is there a good way to automatically convert Access 2000 to MySQL to
keep MySQL data up to date?  The data needs to be updated several times a
week.  No I can't just switch everything over and not have to convert again.
  3.. A way to do #2 for dBase would be good too, but less critical because
the data only gets updated every couple months.
Thanks in advance.

Dan Malcolm
[EMAIL PROTECTED]
[EMAIL PROTECTED]





1) I think that people use Apache as old versions of IIS were crap. In addition, it is 
about the widest used server out there in the commercial world (Linux running Apache 
with PHP3 is I believe the most common config at the moment) so if you're developing 
something to put on such a site, it's more likely to work if you develop with 
something close to that setup (note probs with case sensititivity and so on on with 
Apache that won't necesarily be exposed on IIS)

2) Check out the MySQL (www.mysql.com) site and look to download myaccess2000_1_4.zip, 
this is an Access plug-in that someone has kindly written to convert data and 
structure from Access 2000 MDB to MySQL (I've not tried them, but I think it also 
allows dbase conversion and a few others).

Tom

Dan Malcolm wrote:

> I see in the posts, that a lot of people are using Apache on NT instead of the built 
>in IIS.  Is there a reason?  I have PHP up and running with dBase tables converted to 
>MySQL and ODBC connected to Access 2000, on an NT 4 box with IIS 4 and it runs very 
>well.  Performance is great.  My only problem is automating the conversion to update 
>tables in MySQL.  I would like like to convert the Access 2000 tables also but the 
>converters either don't seem to work with Access 2k, or not much at all, or are not 
>such that a timed batch file can be generated using them.  I just looked at what I've 
>written and it's a little jumbled.  Mega-Sigh.  Let me summarize.
>
>   1.. Why Apache on NT 4.0?
>   2.. Is there a good way to automatically convert Access 2000 to MySQL to keep 
>MySQL data up to date?  The data needs to be updated several times a week.  No I 
>can't just switch everything over and not have to convert again.
>   3.. A way to do #2 for dBase would be good too, but less critical because the data 
>only gets updated every couple months.
> Thanks in advance.
>
> Dan Malcolm
> [EMAIL PROTECTED]
> [EMAIL PROTECTED]




Tom,
Thanks.  I believe myaccess2000_1_4 is one of the ones I've tried.  I'll try
again to make sure I didn't miss anything. I used dbtools to do the dBase
conversion.


Agree that the older versions of IIS were crap, but newer one (version 3 and
4) seems to be pretty good.

Dan
----- Original Message -----
From: "Tom Mathews" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Friday, February 02, 2001 6:09 AM
Subject: Re: [PHP-WIN] For My Information


> 1) I think that people use Apache as old versions of IIS were crap. In
addition, it is about the widest used server out there in the commercial
world (Linux running Apache with PHP3 is I believe the most common config at
the moment) so if you're developing something to put on such a site, it's
more likely to work if you develop with something close to that setup (note
probs with case sensititivity and so on on with Apache that won't necesarily
be exposed on IIS)
>
> 2) Check out the MySQL (www.mysql.com) site and look to download
myaccess2000_1_4.zip, this is an Access plug-in that someone has kindly
written to convert data and structure from Access 2000 MDB to MySQL (I've
not tried them, but I think it also allows dbase conversion and a few
others).
>
> Tom
>
> Dan Malcolm wrote:
>
> > I see in the posts, that a lot of people are using Apache on NT instead
of the built in IIS.  Is there a reason?  I have PHP up and running with
dBase tables converted to MySQL and ODBC connected to Access 2000, on an NT
4 box with IIS 4 and it runs very well.  Performance is great.  My only
problem is automating the conversion to update tables in MySQL.  I would
like like to convert the Access 2000 tables also but the converters either
don't seem to work with Access 2k, or not much at all, or are not such that
a timed batch file can be generated using them.  I just looked at what I've
written and it's a little jumbled.  Mega-Sigh.  Let me summarize.
> >
> >   1.. Why Apache on NT 4.0?
> >   2.. Is there a good way to automatically convert Access 2000 to MySQL
to keep MySQL data up to date?  The data needs to be updated several times a
week.  No I can't just switch everything over and not have to convert again.
> >   3.. A way to do #2 for dBase would be good too, but less critical
because the data only gets updated every couple months.
> > Thanks in advance.
> >
> > Dan Malcolm
> > [EMAIL PROTECTED]
> > [EMAIL PROTECTED]
>
>


----------------------------------------------------------------------------
----


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



Reply via email to