php-general Digest 31 Dec 2004 04:50:41 -0000 Issue 3200
Topics (messages 205369 through 205410):
Re: what am I doing wrong? PHP5 on Fedora
205369 by: John Nichel
205375 by: Rasmus Lerdorf
205378 by: blackwater dev
205379 by: Rory Browne
205384 by: blackwater dev
205386 by: Bruce Douglas
205387 by: John Nichel
205392 by: tr
205395 by: tr
205402 by: John Nichel
Re: Warnings on the bottom of the pages on Linux
205370 by: John Nichel
205371 by: Jason Barnett
205376 by: John Nichel
205377 by: Marek Kilimajer
205380 by: Rory Browne
205383 by: Curt Zirzow
205396 by: Marek Kilimajer
205398 by: Rory Browne
205403 by: John Nichel
How to argue with ASP people...
205372 by: Tony Di Croce
205382 by: Daniel Schierbeck
205389 by: Ben
205391 by: Jason Barnett
205404 by: mail.pmpa
205405 by: Rasmus Lerdorf
205406 by: Robby Russell
205408 by: John Nichel
205410 by: mail.pmpa
Re: Question: arrays and form elements
205373 by: Brent Baisley
Re: Align pic
205374 by: John Nichel
Re: COM Bug in PHP 4.3.10
205381 by: Andi Gutmans
[suspicious - maybe spam] Static Keyword
205385 by: Paul Higgins
205390 by: Jason Barnett
Quick compile question --with-oci8
205388 by: Brian Duke
205394 by: Marek Kilimajer
205400 by: John Nichel
Why extra slashes???
205393 by: Wiberg
205399 by: John Holmes
205407 by: Zareef Ahmed
Re: Understanding flock()
205397 by: Marek Kilimajer
Re: $_FILE[user][error] = 6 ?
205401 by: Al
Xemacs indentation for php
205409 by: Song Ken Vern-E11804
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]
----------------------------------------------------------------------
--- Begin Message ---
blackwater dev wrote:
I don't seem to have an apxs directory. I don't even have an apache
directory as apachectl resides in /usr/sbin/apachectl
Of course apache was installed from the fedora install.
How do I install this against apache?
I don't know if the rpm install of Apache includes apxs. If it doesn't,
you'll have to install Apache from source.
Look here under "Apache+PHP (DSO Module)"
http://www.blazonry.com/scripting/install_apache.php
--
John C. Nichel
�berGeek
KegWorks.com
716.856.9675
[EMAIL PROTECTED]
--- End Message ---
--- Begin Message ---
John Nichel wrote:
I don't know if the rpm install of Apache includes apxs. If it doesn't,
you'll have to install Apache from source.
Usually apxs is in the apache-dev package on the various distros.
-Rasmus
--- End Message ---
--- Begin Message ---
I just went ahead and installed apache from source with apxs then
recompiled php5. I then created a info.php file which simply prints
out phpinfo but get this error now.
Warning: Unknown: failed to open stream: Permission denied in Unknown on line 0
Warning: Unknown: Failed opening '/usr/local/apache2/htdocs/info.php'
for inclusion (include_path='.:/usr/local/lib/php') in Unknown on line
0
Thanks!
On Thu, 30 Dec 2004 11:55:38 -0500, Rasmus Lerdorf <[EMAIL PROTECTED]> wrote:
> John Nichel wrote:
> > I don't know if the rpm install of Apache includes apxs. If it doesn't,
> > you'll have to install Apache from source.
>
> Usually apxs is in the apache-dev package on the various distros.
>
> -Rasmus
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--- End Message ---
--- Begin Message ---
Sorry if you recieved this twice. Head's wreaked today, and I keep
making mistakes, such as posting to a person instead of to the list.
If you're using apache2 then you need to add something along the lines
of --with-apxs to your ./configure line. With apache1.3 it was
--with-apxs=/path/to/apxs. I'm not sure what whether it's still
--with-apxs, or --with-apxs2, but either way you'll probably be
looking for the path to apxs2. Just for your information apxs is the
APache eXtension System.
If you want to use locate, on recently created files, then you should
schedule locate to run updatedb more often. your locate is only as
recent as your last updatedb.
On Thu, 30 Dec 2004 10:39:50 -0500, blackwater dev
<[EMAIL PROTECTED]> wrote:
> I don't seem to have an apxs directory. I don't even have an apache
> directory as apachectl resides in /usr/sbin/apachectl
>
> Of course apache was installed from the fedora install.
>
> How do I install this against apache?
>
> On Thu, 30 Dec 2004 10:20:01 -0500, John Nichel <[EMAIL PROTECTED]> wrote:
> > blackwater dev wrote:
> > > **First let me say that I am a linux newbie**
> > >
> > > I have installed Fedora 3 on a development box. I then downloaded the
> > > php5 source and followed the php documentation:
> > > # ./configure --with-mysql
> > > # make
> > > # make install
> >
> > What did you build it against? You have no webserver type in your
> > configure line. If I'm not mistaken, all you have above will do is
> > build the cli, and not the loadable module.
> >
> > --
> > John C. Nichel
> > �berGeek
> > KegWorks.com
> > 716.856.9675
> > [EMAIL PROTECTED]
> >
> > --
> > PHP General Mailing List (http://www.php.net/)
> > To unsubscribe, visit: http://www.php.net/unsub.php
> >
> >
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--- End Message ---
--- Begin Message ---
I actually recompiled it all but was getting permission errors. I
then rebooted and now linux seems to want to use the old apache
instead of the new one I compiled with php support so I have to fix my
environment variables to point to the new apache and figure out my
permission errors.
Thanks!
On Thu, 30 Dec 2004 19:00:01 +0000, Rory Browne <[EMAIL PROTECTED]> wrote:
> Sorry if you recieved this twice. Head's wreaked today, and I keep
> making mistakes, such as posting to a person instead of to the list.
>
> If you're using apache2 then you need to add something along the lines
> of --with-apxs to your ./configure line. With apache1.3 it was
> --with-apxs=/path/to/apxs. I'm not sure what whether it's still
> --with-apxs, or --with-apxs2, but either way you'll probably be
> looking for the path to apxs2. Just for your information apxs is the
> APache eXtension System.
>
> If you want to use locate, on recently created files, then you should
> schedule locate to run updatedb more often. your locate is only as
> recent as your last updatedb.
>
> On Thu, 30 Dec 2004 10:39:50 -0500, blackwater dev
> <[EMAIL PROTECTED]> wrote:
> > I don't seem to have an apxs directory. I don't even have an apache
> > directory as apachectl resides in /usr/sbin/apachectl
> >
> > Of course apache was installed from the fedora install.
> >
> > How do I install this against apache?
> >
> > On Thu, 30 Dec 2004 10:20:01 -0500, John Nichel <[EMAIL PROTECTED]> wrote:
> > > blackwater dev wrote:
> > > > **First let me say that I am a linux newbie**
> > > >
> > > > I have installed Fedora 3 on a development box. I then downloaded the
> > > > php5 source and followed the php documentation:
> > > > # ./configure --with-mysql
> > > > # make
> > > > # make install
> > >
> > > What did you build it against? You have no webserver type in your
> > > configure line. If I'm not mistaken, all you have above will do is
> > > build the cli, and not the loadable module.
> > >
> > > --
> > > John C. Nichel
> > > �berGeek
> > > KegWorks.com
> > > 716.856.9675
> > > [EMAIL PROTECTED]
> > >
> > > --
> > > PHP General Mailing List (http://www.php.net/)
> > > To unsubscribe, visit: http://www.php.net/unsub.php
> > >
> > >
> >
> > --
> > PHP General Mailing List (http://www.php.net/)
> > To unsubscribe, visit: http://www.php.net/unsub.php
> >
> >
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--- End Message ---
--- Begin Message ---
if you want to know/have a rough guide on building/compiling php with
mysql/mysqli support, the following link should help you out... although it's
for linux..
http://marc.theaimsgroup.com/?l=php-general&m=109026859726530&w=2
it kind of walks you through what you need to do..
hope it helps...
peace..
-----Original Message-----
From: Rory Browne <[EMAIL PROTECTED]>
Sent: Dec 30, 2004 11:00 AM
To: [email protected]
Subject: Re: [PHP] what am I doing wrong? PHP5 on Fedora
Sorry if you recieved this twice. Head's wreaked today, and I keep
making mistakes, such as posting to a person instead of to the list.
If you're using apache2 then you need to add something along the lines
of --with-apxs to your ./configure line. With apache1.3 it was
--with-apxs=/path/to/apxs. I'm not sure what whether it's still
--with-apxs, or --with-apxs2, but either way you'll probably be
looking for the path to apxs2. Just for your information apxs is the
APache eXtension System.
If you want to use locate, on recently created files, then you should
schedule locate to run updatedb more often. your locate is only as
recent as your last updatedb.
On Thu, 30 Dec 2004 10:39:50 -0500, blackwater dev
<[EMAIL PROTECTED]> wrote:
> I don't seem to have an apxs directory. I don't even have an apache
> directory as apachectl resides in /usr/sbin/apachectl
>
> Of course apache was installed from the fedora install.
>
> How do I install this against apache?
>
> On Thu, 30 Dec 2004 10:20:01 -0500, John Nichel <[EMAIL PROTECTED]> wrote:
> > blackwater dev wrote:
> > > **First let me say that I am a linux newbie**
> > >
> > > I have installed Fedora 3 on a development box. I then downloaded the
> > > php5 source and followed the php documentation:
> > > # ./configure --with-mysql
> > > # make
> > > # make install
> >
> > What did you build it against? You have no webserver type in your
> > configure line. If I'm not mistaken, all you have above will do is
> > build the cli, and not the loadable module.
> >
> > --
> > John C. Nichel
> > �berGeek
> > KegWorks.com
> > 716.856.9675
> > [EMAIL PROTECTED]
> >
> > --
> > PHP General Mailing List (http://www.php.net/)
> > To unsubscribe, visit: http://www.php.net/unsub.php
> >
> >
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
--- End Message ---
--- Begin Message ---
blackwater dev wrote:
I just went ahead and installed apache from source with apxs then
recompiled php5. I then created a info.php file which simply prints
out phpinfo but get this error now.
Warning: Unknown: failed to open stream: Permission denied in Unknown on
line 0
Warning: Unknown: Failed opening '/usr/local/apache2/htdocs/info.php'
for inclusion (include_path='.:/usr/local/lib/php') in Unknown on line
0
Thanks!
*sigh*
http://groups-beta.google.com/groups?hl=en&q=%22Permission+denied+in+Unknown+on+line+0%22&qt_s=Search+Groups
http://www.linuxquestions.org/questions/history/211964
--
John C. Nichel
�berGeek
KegWorks.com
716.856.9675
[EMAIL PROTECTED]
--- End Message ---
--- Begin Message ---
John Nichel wrote / nap�sal (a):
blackwater dev wrote:
I just went ahead and installed apache from source with apxs then
recompiled php5. I then created a info.php file which simply prints
out phpinfo but get this error now.
Warning: Unknown: failed to open stream: Permission denied in Unknown
on line 0
Warning: Unknown: Failed opening '/usr/local/apache2/htdocs/info.php'
for inclusion (include_path='.:/usr/local/lib/php') in Unknown on line
0
Thanks!
*sigh*
http://groups-beta.google.com/groups?hl=en&q=%22Permission+denied+in+Unknown+on+line+0%22&qt_s=Search+Groups
http://www.linuxquestions.org/questions/history/211964
as root switch to htdocs
and chmod 666 info.php
troby
--- End Message ---
--- Begin Message ---
tr wrote / nap�sal (a):
John Nichel wrote / nap�sal (a):
blackwater dev wrote:
I just went ahead and installed apache from source with apxs then
recompiled php5. I then created a info.php file which simply prints
out phpinfo but get this error now.
Warning: Unknown: failed to open stream: Permission denied in
Unknown on line 0
Warning: Unknown: Failed opening '/usr/local/apache2/htdocs/info.php'
for inclusion (include_path='.:/usr/local/lib/php') in Unknown on line
0
Thanks!
*sigh*
http://groups-beta.google.com/groups?hl=en&q=%22Permission+denied+in+Unknown+on+line+0%22&qt_s=Search+Groups
http://www.linuxquestions.org/questions/history/211964
as root switch to htdocs
and chmod 666 info.php
troby
It is also recomended to remove the apache binary rpm packages from
you system as root: rpm -e apache*
Then go to you /etc/init.d/ directory and create a shell script naming
httpd_start: containing: #!/bin/bash
/usr/local/apachectl start
and another shell script naming as httpd_stop containing:
/usr/local/apachectl stop
go to /etc/rc.d/
and create symlink (ln -s /etc/init.d/httpd_start
/etc/rc.d/rc3.d/S27httpd and rc5.d/S27httpd) in dirs rc3.d and rc5.d
pointing to /etc/init.d/httpd_start naming S27httpd
and then restart and it should work.
you can set permissions recursively this way: chmod -R 666
/usr/local/apache/htdocs (to doc root)
hello
troby
--- End Message ---
--- Begin Message ---
tr wrote:
tr wrote / nap�sal (a):
John Nichel wrote / nap�sal (a):
blackwater dev wrote:
I just went ahead and installed apache from source with apxs then
recompiled php5. I then created a info.php file which simply prints
out phpinfo but get this error now.
Warning: Unknown: failed to open stream: Permission denied in
Unknown on line 0
Warning: Unknown: Failed opening '/usr/local/apache2/htdocs/info.php'
for inclusion (include_path='.:/usr/local/lib/php') in Unknown on line
0
Thanks!
*sigh*
http://groups-beta.google.com/groups?hl=en&q=%22Permission+denied+in+Unknown+on+line+0%22&qt_s=Search+Groups
http://www.linuxquestions.org/questions/history/211964
as root switch to htdocs
and chmod 666 info.php
troby
<snip>
you can set permissions recursively this way: chmod -R 666
/usr/local/apache/htdocs (to doc root)
Do NOT do this.
1) You will make all your files world writeable...not good
2) By giving it the -R, you will have effectively taken away execute
permission from not only /usr/local/apache/htdocs, but all the
directories beneath it. Directories need to have execute permission to
be 'seen'.
Take a little time to read and understand your filesystem and it's
permission levels.
--
By-Tor.com
...it's all about the Rush
http://www.by-tor.com
--- End Message ---
--- Begin Message ---
M�rio Gamito wrote:
Hi,
A friend of mine told me that in Windows, PHP shows its warnings at the
bottom of the pages.
Actually, i've never had thought about this issue before.
Better still... i even didn't know PHP for Windows had this behaviour.
In Linux they're shown at the top and now i'm in the mood to make PHP
warnings appear at the bottom too. But...
... i've browsed php.ini and didn't found any way (obvious, at least) to
do the same thing in Linux.
Already googled also, but nothing.
Is it possible to achieve this in Linux ?
Any help would be apreciated.
Warm regards.
http://us4.php.net/manual/en/ref.outcontrol.php
--
John C. Nichel
�berGeek
KegWorks.com
716.856.9675
[EMAIL PROTECTED]
--- End Message ---
--- Begin Message ---
Is it possible to achieve this in Linux ?
Any help would be apreciated.
Warm regards.
http://us4.php.net/manual/en/ref.outcontrol.php
Call me stupid (actually please don't :) ) but how does output buffering
help in this case? Are you suggesting he write an output handler?
--
Teach a person to fish...
Ask smart questions: http://www.catb.org/~esr/faqs/smart-questions.html
PHP Manual: http://php.net/manual/
php-general archives: http://marc.theaimsgroup.com/?l=php-general&w=2
--- End Message ---
--- Begin Message ---
Jason Barnett wrote:
Is it possible to achieve this in Linux ?
Any help would be apreciated.
Warm regards.
http://us4.php.net/manual/en/ref.outcontrol.php
Call me stupid (actually please don't :) ) but how does output buffering
help in this case? Are you suggesting he write an output handler?
If he wants to go that far, yes, but he doesn't have too. If all the OP
wants to achieve is have his error messages appear at the bottom of the
output instead of inline....
<?php
ob_start();
include ( "nofile.inc.php" );
// Some more PHP stuff
// Capture stuff before display
$possible_errors = ob_get_clean();
ob_end_clean();
// What I want to display first
echo ( "This is the output of my script<br /><br />" );
// Display Errors if exist
if ( ! empty ( $possible_errors ) ) {
echo ( $possible_errors );
}
?>
--
John C. Nichel
�berGeek
KegWorks.com
716.856.9675
[EMAIL PROTECTED]
--- End Message ---
--- Begin Message ---
M�rio Gamito wrote:
Hi,
A friend of mine told me that in Windows, PHP shows its warnings at the
bottom of the pages.
Actually, i've never had thought about this issue before.
Better still... i even didn't know PHP for Windows had this behaviour.
In Linux they're shown at the top and now i'm in the mood to make PHP
warnings appear at the bottom too. But...
... i've browsed php.ini and didn't found any way (obvious, at least) to
do the same thing in Linux.
Already googled also, but nothing.
Is it possible to achieve this in Linux ?
Any help would be apreciated.
Warm regards.
Neither one is true. Error messages show up where they occur. HTML
markup might influence where they visualy appear in the browser, but you
can look at the source code to find out the exact place.
Example 1:
echo 'Hello ';
$i = 1 / 0;
echo 'World';
Example 2:
echo '<table><tr><td>First Row</td></tr>';
$i = 1 / 0;
echo '<tr><td>Second Row</td></tr><table>';
--- End Message ---
--- Begin Message ---
Apologies Marek if you recieved this twice, I mailed you instead of
the list first time around.
me.is_confused() == true;
What does it matter whether errors show at the top or bottom of the
page. They are probably different errors that show up, some of which
show at the top, and others of which show up at the bottom.
But all that aside, wouldn't it be better to remove/debug these
errors, instead of moving them around the page. Am I missing something
here?
Rory
On Thu, 30 Dec 2004 15:58:24 +0000, M�rio Gamito <[EMAIL PROTECTED]> wrote:
> Hi,
>
> A friend of mine told me that in Windows, PHP shows its warnings at the
> bottom of the pages.
>
> Actually, i've never had thought about this issue before.
> Better still... i even didn't know PHP for Windows had this behaviour.
>
> In Linux they're shown at the top and now i'm in the mood to make PHP
> warnings appear at the bottom too. But...
>
> ... i've browsed php.ini and didn't found any way (obvious, at least) to
> do the same thing in Linux.
>
> Already googled also, but nothing.
>
> Is it possible to achieve this in Linux ?
>
> Any help would be apreciated.
>
> Warm regards.
> --
> M�rio Gamito
> Administra��o de sistemas e desenvolvimento
> Netual - Multim�dia e Telecomunica��es, Lda.
> Rua Jo�o Afonso, N�1
> 3800-198 Aveiro - Portugal
> Tel. +351 234 371 431 / Fax. +351 234 371 438
> E-mail: [EMAIL PROTECTED]
> www.netual.pt
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--- End Message ---
--- Begin Message ---
* Thus wrote Jason Barnett:
> I haven't done it (what's the point since I'm a Windows user lol), but
> you can change the default error handler. If it's error messages at the
> bottom of HTML pages you want then just choose appropriate HTML elements
> you need to align a message at the bottom of your page.
>
> http://php.net/function.set-error-handler
And to demonstrate this:
class EHandler {
// the method to collect the errors
public function accept(...) {}
// the method to show the errors
public function display() {}
}
$eh = new EHandler();
set_error_handler(array($eh, 'accept'));
// do stuff that causes errors, notices or warnings
// ...
$eh->display();
Curt
--
Quoth the Raven, "Nevermore."
--- End Message ---
--- Begin Message ---
Rory Browne wrote:
Apologies Marek if you recieved this twice, I mailed you instead of
the list first time around.
me.is_confused() == true;
What does it matter whether errors show at the top or bottom of the
page. They are probably different errors that show up, some of which
show at the top, and others of which show up at the bottom.
I think it is important to understand that errors show up where they
occur, it helps "remove/debug these errors".
And I don't know of any kinds of errors that would relocate their
messages around the output. So there are no /different errors that show
up, some of which show at the top, and others of which show up at the
bottom/
But all that aside, wouldn't it be better to remove/debug these
errors, instead of moving them around the page. Am I missing something
here?
--- End Message ---
--- Begin Message ---
That Marek seems to be my point exactly.
Aparently Mario would perfer his errors to show on the bottom instead
of on the top. I trying to figure out why this is, and why he wants
errors in his script at all?
me.level_of_confusion = CONFUSION_LEVEL_MAX;
On Fri, 31 Dec 2004 01:13:33 +0100, Marek Kilimajer <[EMAIL PROTECTED]> wrote:
> Rory Browne wrote:
> > Apologies Marek if you recieved this twice, I mailed you instead of
> > the list first time around.
> >
> > me.is_confused() == true;
> >
> > What does it matter whether errors show at the top or bottom of the
> > page. They are probably different errors that show up, some of which
> > show at the top, and others of which show up at the bottom.
>
> I think it is important to understand that errors show up where they
> occur, it helps "remove/debug these errors".
>
> And I don't know of any kinds of errors that would relocate their
> messages around the output. So there are no /different errors that show
> up, some of which show at the top, and others of which show up at the
> bottom/
>
> >
> > But all that aside, wouldn't it be better to remove/debug these
> > errors, instead of moving them around the page. Am I missing something
> > here?
>
--- End Message ---
--- Begin Message ---
Rory Browne wrote:
That Marek seems to be my point exactly.
Aparently Mario would perfer his errors to show on the bottom instead
of on the top. I trying to figure out why this is, and why he wants
errors in his script at all?
me.level_of_confusion = CONFUSION_LEVEL_MAX;
See, there's your problem. It's not healthy to try and figure out why
some people want to do things a certain way. ;)
--
By-Tor.com
...it's all about the Rush
http://www.by-tor.com
--- End Message ---
--- Begin Message ---
I am fairly new to PHP, but I am loving it... I have recently gotten
involved in a business venture and I have been using PHP so far...
Recently I have taken on a partner, and he is a big ASP guy...
I am not totally against ASP, but it would have to be pretty good to
get me to switch at this point (PHP seems to do everything I need)...
But I will need to convince him of this...
What points can I bring up in PHP's favor? In what areas does PHP trounce ASP?
--
td
--- End Message ---
--- Begin Message ---
Tony Di Croce wrote:
I am fairly new to PHP, but I am loving it... I have recently gotten
involved in a business venture and I have been using PHP so far...
Recently I have taken on a partner, and he is a big ASP guy...
I am not totally against ASP, but it would have to be pretty good to
get me to switch at this point (PHP seems to do everything I need)...
But I will need to convince him of this...
What points can I bring up in PHP's favor? In what areas does PHP trounce ASP?
First of all, ASP doesn't run on anything but Windows servers (unless
you're willing to use ChiliASP... *hiss*)
--- End Message ---
--- Begin Message ---
Daniel Schierbeck wrote:
Tony Di Croce wrote:
What points can I bring up in PHP's favor? In what areas does PHP
trounce ASP?
First of all, ASP doesn't run on anything but Windows servers (unless
you're willing to use ChiliASP... *hiss*)
Exactly! Portability is key. Not being locked into a particular OS or
web server allows for much more flexibility as you go forward.
- Ben
--- End Message ---
--- Begin Message ---
Ben wrote:
Daniel Schierbeck wrote:
Tony Di Croce wrote:
What points can I bring up in PHP's favor? In what areas does PHP
trounce ASP?
First of all, ASP doesn't run on anything but Windows servers (unless
you're willing to use ChiliASP... *hiss*)
Exactly! Portability is key. Not being locked into a particular OS or
web server allows for much more flexibility as you go forward.
- Ben
Flexibility of usage is another one. Most PHP code out there has a
license agreement that is pretty flexible (e.g. PHP license) and will
allow you to sell the code, build commercial projects derived from the
code, or use the code for your own personal (read: free) usage.
Most importantly: most PHP code out there is open source and plain text.
So if you want to change something you can usually do it with ease.
Or you can at least see how it works and build something on your own
that fits your purposes better. I have learned a *tremendous* amount
about how things work in the web by just looking at what other people
have done in their projects (e.g. PEAR projects) and reading their
comments (if the author bothered to comment the code :) ).
--
Teach a person to fish...
Ask smart questions: http://www.catb.org/~esr/faqs/smart-questions.html
PHP Manual: http://php.net/manual/
php-general archives: http://marc.theaimsgroup.com/?l=php-general&w=2
--- End Message ---
--- Begin Message ---
Don't mean to start a discussion whatsoever, I love php, but one thing i
can't do in php is Response.Redirect .
Apart from that no complains so far :)
* Happy New Year *
Pedro Almeida.
-----Mensagem original-----
De: Tony Di Croce [mailto:[EMAIL PROTECTED]
I am fairly new to PHP, but I am loving it... I have recently gotten
involved in a business venture and I have been using PHP so far...
Recently I have taken on a partner, and he is a big ASP guy...
(...)
--- End Message ---
--- Begin Message ---
mail.pmpa wrote:
Don't mean to start a discussion whatsoever, I love php, but one thing i
can't do in php is Response.Redirect .
Apart from that no complains so far :)
header("Location: $url");
which, by the way, makes a hell of a lot more sense. It's just an HTTP
response header like any other response header and it is called
Location, not Redirect.
-Rasmus
--- End Message ---
--- Begin Message ---
On Fri, 2004-12-31 at 02:49 +0000, mail.pmpa wrote:
> Don't mean to start a discussion whatsoever, I love php, but one thing i
> can't do in php is Response.Redirect .
> Apart from that no complains so far :)
>
> * Happy New Year *
>
> Pedro Almeida.
>
Sure you can..
class Response
{
function redirect($location)
{
header("Location: " . $location);
}
function write($text)
{
print $text;
}
}
Response::Redirect("http://www.planetargon.com/");
Response::Write("bar");
There, now we can compete with ASP.
;-)
--
/***************************************
* Robby Russell | Owner.Developer.Geek
* PLANET ARGON | www.planetargon.com
* Portland, OR | [EMAIL PROTECTED]
* 503.351.4730 | blog.planetargon.com
* PHP/PostgreSQL Hosting & Development
* --- Now supporting PHP5 ---
****************************************/
--- End Message ---
--- Begin Message ---
mail.pmpa wrote:
Don't mean to start a discussion whatsoever, I love php, but one thing i
can't do in php is Response.Redirect .
Apart from that no complains so far :)
http://us4.php.net/header
--
By-Tor.com
...it's all about the Rush
http://www.by-tor.com
--- End Message ---
--- Begin Message ---
Can I do any session handling before calling header("Location: $url"); ?
Pedro Almeida.
-----Mensagem original-----
De: Rasmus Lerdorf [mailto:[EMAIL PROTECTED]
mail.pmpa wrote:
> Don't mean to start a discussion whatsoever, I love php, but one thing i
> can't do in php is Response.Redirect .
> Apart from that no complains so far :)
header("Location: $url");
which, by the way, makes a hell of a lot more sense. It's just an HTTP
response header like any other response header and it is called
Location, not Redirect.
-Rasmus
--- End Message ---
--- Begin Message ---
Nope. Is there a problem you are having with using that syntax?
If you are having trouble with referencing the fields with javascript,
you can't use the "regular" syntax you are used to.:
document.formname.fieldname[]
That will give you an error because of the brackets.
In javascript you'll need to reference field names with brackets like
this:
document.formname.elements["fieldname[]"]
On Dec 30, 2004, at 6:48 AM, Stuart Felenstein wrote:
Generally, when I set up a form where, for example,
I'll be taking multiple selections from a list I would
set the variable / element name as "myvar[]". So I
have the brackets [] after the variable name to make
it an array.
What I want to know is there a way to get around the
use of this syntax ? If the variable name was just
"myvar" (no brackets) is there a way for me to still
grab all the selections and put them into an array ?
Hope this question is clear.
Thank you
Stuart
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
--
Brent Baisley
Systems Architect
Landover Associates, Inc.
Search & Advisory Services for Advanced Technology Environments
p: 212.759.6400/800.759.0577
--- End Message ---
--- Begin Message ---
Reply to the list please.
Gleb Belov wrote:
Sorry for posting it here as well, but can anybody please tell me
about these? I mean, the HTML and CSS newsgroups as I really need them
too.
Thanks and sorry.
http://webstandardsgroup.org/mail/
--
John C. Nichel
�berGeek
KegWorks.com
716.856.9675
[EMAIL PROTECTED]
--- End Message ---
--- Begin Message ---
We are looking into it right now. Hopefully we will have a new version or
at least a release candidate within 2 weeks.
At 11:08 AM 12/30/2004 +0200, Tohar Trabinovitch wrote:
-->
Hi,
I need to know when will be the next PHP 4.3.x release with the fix for
the COM bug which was in 4.3.10.
This is CRITICAL for us, because we run our application over windows using
COM object and we use earlier version of PHP which has security bugs.
COM Bug URL:
<http://bugs.php.net/bug.php?id=31159>http://bugs.php.net/bug.php?id=31159
Thanks,
Tohar Trabinovitch
Software Engineer
E: [EMAIL PROTECTED]
T: 972-3-9008269
C: 054-777 30 43
====================
This message is intended only for the person(s) to which it is addressed
and may contain Sphera Corporation privileged, confidential and/or
proprietary information. If you have received this communication in error,
please notify us immediately by replying to the message and deleting it
from your computer. Any disclosure, copying, distribution, or the taking
of any action concerning the contents of this message and any
attachment(s) by anyone other than the named recipient(s) is strictly
prohibited.
--- End Message ---
--- Begin Message ---
Hi,
I was reading this article:
http://www.phppatterns.com/index.php/article/articleview/6/1/1/ .
I have a question about it. If you create this static Singleton object,
does it persist in memory globally? Or is it recreated each time a .php
page is requested?
Thanks
Paul
_________________________________________________________________
Express yourself instantly with MSN Messenger! Download today - it's FREE!
hthttp://messenger.msn.click-url.com/go/onm00200471ave/direct/01/
--- End Message ---
--- Begin Message ---
Paul Higgins wrote:
Hi,
I was reading this article:
http://www.phppatterns.com/index.php/article/articleview/6/1/1/ .
I have a question about it. If you create this static Singleton object,
does it persist in memory globally? Or is it recreated each time a .php
page is requested?
AFAIK singletons are used so that you only have one object of that type
*for a request*. The singleton is created and destroyed on every
request (as are all objects).
--
Teach a person to fish...
Ask smart questions: http://www.catb.org/~esr/faqs/smart-questions.html
PHP Manual: http://php.net/manual/
php-general archives: http://marc.theaimsgroup.com/?l=php-general&w=2
--- End Message ---
--- Begin Message ---
This has been going on for about a week now. I have an oracle client
installed. I have php4 source installed all on a stripped down fedora
server. We get various errors. Like the infamous ld can find XXX in
-lclntsh.
Correct me if I'm wrong but we will have to install oracle8 || 9i before we
can compile php --with-oci8. I don't really want to run oracle. Our local
server only needs to use the oci8 functions to log into the datawarehouse
and update our local mysql database but after a week of frustration I think
that's what we have to do.
Thanks all.
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
--- End Message ---
--- Begin Message ---
Please, don't hijack threads.
Brian Duke wrote:
This has been going on for about a week now. I have an oracle client
installed. I have php4 source installed all on a stripped down fedora
server. We get various errors. Like the infamous ld can find XXX in
-lclntsh.
Correct me if I'm wrong but we will have to install oracle8 || 9i before we
can compile php --with-oci8. I don't really want to run oracle. Our local
server only needs to use the oci8 functions to log into the datawarehouse
and update our local mysql database but after a week of frustration I think
that's what we have to do.
Thanks all.
I think you need to install only the client libraries.
--- End Message ---
--- Begin Message ---
Brian Duke wrote:
This has been going on for about a week now. I have an oracle client
installed. I have php4 source installed all on a stripped down fedora
server. We get various errors. Like the infamous ld can find XXX in
-lclntsh.
Correct me if I'm wrong but we will have to install oracle8 || 9i before we
can compile php --with-oci8. I don't really want to run oracle. Our local
server only needs to use the oci8 functions to log into the datawarehouse
and update our local mysql database but after a week of frustration I think
that's what we have to do.
Thanks all.
You only need the client libraries, not the db itself. If you have the
Oracle CD's, the libraries will be on there (you can also download this
from Oracle).
--
By-Tor.com
...it's all about the Rush
http://www.by-tor.com
--- End Message ---
--- Begin Message ---
Hi there!
Right now I'm creating a form that saves the text from a textarea to an
array. That doesn't seem to be any problem.
But when I save the contents, I get extra / ?
The code looks like this:
-------------------------
//Which main product category is to treat?
//
if (isset($_REQUEST["reqIDKategori"])) {
$streqIDKategori = $_REQUEST["reqIDKategori"];
}
//Save current main category to file
//
if (isset($_REQUEST["saveCategory"])) {
//Open file for writing
//
$handle = fopen("../maincategorypages/" . $streqIDKategori .
".html","wb");
//Get contents of textarea
//
$textArea = $_REQUEST["frmSaveArea"];
//Save all info in textarea into file
//
fwrite($handle, $textArea);
//Close file
//
fclose($handle);
}
//Read maincategory html-file
//
function readFileCategory($ID) {
//Load file into array
//
$returnfile = file("../maincategorypages/" . $ID . ".html");
//Send back array with fileinfo
//
return $returnfile;
}
//Show specific array to screen
//
function showArray($array) {
for ($i=0;$i<count($array);$i++) {
echo $array[$i];
}
}
?>
<html>
<head>
<title>main</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body bgcolor="#FFFFFF" text="#000000" background="../bkg/mainfyll.jpg"
link="#000000" vlink="#000000" alink="#000000">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td>
<table width="100%" border="0" cellspacing="2"
cellpadding="2"><tr><td>
<form
action="maincategory.php?saveCategory=yes&reqIDKategori=<?=$streqIDKategori?
>" method="post" name="frmSaveCatPage">
<textarea cols="50" rows="25"
name="frmSaveArea"><?=showArray(readFileCategory($streqIDKategori))?></texta
rea>
<input type="submit" value="Spara html f�r huvudkategori">
</form>
</td></tr>
</table>
</td>
<!--Visa annonser i h�gerspalt-->
<?require("advertise.php");?>
</tr>
</table>
</td>
</tr>
</table>
<p> </p>
<p> </p>
</body>
</html>
/G
@varupiraten.se
--
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.296 / Virus Database: 265.6.6 - Release Date: 2004-12-28
--- End Message ---
--- Begin Message ---
Wiberg wrote:
Right now I'm creating a form that saves the text from a textarea to an
array. That doesn't seem to be any problem.
But when I save the contents, I get extra / ?
http://us4.php.net/manual/en/ref.info.php#ini.magic-quotes-gpc
--
---John Holmes...
Amazon Wishlist: www.amazon.com/o/registry/3BEXC84AB3A5E/
php|architect: The Magazine for PHP Professionals – www.phparch.com
--- End Message ---
--- Begin Message ---
Hi,
You can user stripslashes() function to remove them if gpc quotes
is creating some kind of confusion in your mind. BTW these quotes are
important in some security related situations.
zareef ahmed.
On Thu, 30 Dec 2004 20:15:06 -0500, John Holmes
<[EMAIL PROTECTED]> wrote:
> Wiberg wrote:
> > Right now I'm creating a form that saves the text from a textarea to an
> > array. That doesn't seem to be any problem.
> > But when I save the contents, I get extra / ?
>
> http://us4.php.net/manual/en/ref.info.php#ini.magic-quotes-gpc
>
> --
>
> ---John Holmes...
>
> Amazon Wishlist: www.amazon.com/o/registry/3BEXC84AB3A5E/
>
> php|architect: The Magazine for PHP Professionals â www.phparch.com
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
--
Zareef Ahmed :: A PHP Developer in India ( Delhi )
Homepage :: http://www.zareef.net
--- End Message ---
--- Begin Message ---
Gerard Samuel wrote:
Im trying to simulate conditions, to see how flock works.
Can anyone verify with the example code below,
that data, never gets written to the file.
//1 & //2 are supposed to be processes???
For me, the var_dump() reports ->
int(7) bool(false)
Thanks
$fp = fopen('foo.txt', 'w'); //1
flock($fp, LOCK_EX) or die('Unable to lock'); //1
unlink('foo.txt') or die('Unable to remove foo.txt'); //2
$bytes = fwrite($fp, 'testing'); //1
fclose($fp); //1
var_dump($bytes, file_get_contents('foo.txt')); //1
To my knowledge (and might apply to unices only) unlink only "unlinks"
file, it does not delete it. Unlinking removes link (reference,
filename) to an inode that holds the file. Inode is deleted by the
kernel once the link count referencing the inode reaches zero and the
inode is no longer opened by any process. I hope I did not confuse you :-)
So the result is that even if process 2 unlinked the filename link,
process 1 had opened the file (inode) so it's not removed untill it's
closed and process 1 can write to it. file_get_contents() failed because
the link no longer exists.
--- End Message ---
--- Begin Message ---
You nailed it Curt.
Virtual Host "Powweb" removed the system default tmp directory without telling
anyone. All file uploading services were broken.
I fixed the problem in php.ini
Thanks everyone.
Curt Zirzow wrote:
* Thus wrote Al:
What is a $_FILE[user][error]=> 6
I can't find Error level 6 in the manual or on Google.
Here is my files array:
[userfile] => Array
(
[name] => Readme.txt
[type] =>
[tmp_name] =>
[error] => 6
[size] => 0
)
Doesn't make sense. Readme.txt is simply a small text file on my local HD.
6 == Missing /tmp or similar directory.
Which means that your php.ini's upload_tmp_dir isn't set properly.
Curt
--- End Message ---
--- Begin Message ---
Hi,
I would like the behaviour of turning on the cc-mode indentation in the <?php
?> tags
but turning off when escaping and doing html.
I have been looking at the cc-engine.el source and can't seem to find the place
where I should change.
Is this behaviour possible?
thanx
--- End Message ---