php-general Digest 16 May 2007 03:09:57 -0000 Issue 4793

Topics (messages 254976 through 255002):

Re: Bounty, NOW!
        254976 by: Robert Cummings
        254980 by: Daniel Brown

Re: PHP sorting csv array output
        254977 by: Anna Vester

Re: Question
        254978 by: Alister Bulman
        254982 by: Robert Cummings

PHP 5.2 array() == null
        254979 by: dominic.letz.berlin.de
        254981 by: Edward Kay
        254983 by: Robert Cummings

Re: Resources for plugin based frameworks
        254984 by: Guillaume Theoret
        254989 by: Jim Lucas
        254990 by: Jim Lucas
        254992 by: Guillaume Theoret

PHP debugger
        254985 by: Miles Thompson
        254986 by: tg-php.gryffyndevelopment.com
        254993 by: Emil Ivanov

problem with string & floats in PHP
        254987 by: Pablo Luque
        254988 by: Richard Davey
        254996 by: Emil Ivanov

Re: problem with string & floats in PH
        254991 by: Dave Goodchild

error_reporting(E_ALL) doesn't show anything
        254994 by: Afan Pasalic
        254995 by: Stut
        254997 by: Stut
        254998 by: Afan Pasalic
        254999 by: Jim Lucas
        255000 by: André Medeiros

Re: Feisty Fawn and apt-get
        255001 by: Børge Holen

Cannot connect to an MySQL database using Named Pipes
        255002 by: John Comerford

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 ---
On Tue, 2007-05-15 at 09:37 -0300, Martin Marques wrote:
> Brad Sumrall wrote:
> > I got 5 IP breaking Federal Regulations.....
> > Hehehehe
> > Do you think you are not being logged?
> 
> Yeah, and I bet those IP are from Kathmandu. :-D

Did he even post the value of the bounty? I mean we're mostly all
technically inclined people here... we can generally do math and we'd
hardly chase a bounty having the value of his weekly allowance from his
Mummy.

Cheers,
Rob.
-- 
.------------------------------------------------------------.
| InterJinn Application Framework - http://www.interjinn.com |
:------------------------------------------------------------:
| An application and templating framework for PHP. Boasting  |
| a powerful, scalable system for accessing system services  |
| such as forms, properties, sessions, and caches. InterJinn |
| also provides an extremely flexible architecture for       |
| creating re-usable components quickly and easily.          |
`------------------------------------------------------------'

--- End Message ---
--- Begin Message ---
On 5/15/07, Robert Cummings <[EMAIL PROTECTED]> wrote:

On Tue, 2007-05-15 at 09:37 -0300, Martin Marques wrote:
> Brad Sumrall wrote:
> > I got 5 IP breaking Federal Regulations.....
> > Hehehehe
> > Do you think you are not being logged?
>
> Yeah, and I bet those IP are from Kathmandu. :-D

Did he even post the value of the bounty? I mean we're mostly all
technically inclined people here... we can generally do math and we'd
hardly chase a bounty having the value of his weekly allowance from his
Mummy.

Cheers,
Rob.
--
.------------------------------------------------------------.
| InterJinn Application Framework - http://www.interjinn.com |
:------------------------------------------------------------:
| An application and templating framework for PHP. Boasting  |
| a powerful, scalable system for accessing system services  |
| such as forms, properties, sessions, and caches. InterJinn |
| also provides an extremely flexible architecture for       |
| creating re-usable components quickly and easily.          |
`------------------------------------------------------------'

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



   An interesting side note.... it's a federal crime to identify oneself as
a federal employee or to misrepresent current or prior governmental or
military service.  The penalties are pretty stiff, too.

   Which is why, as a government contractor, I'm always DAMN sure not to
say that I am with [unnamed Department of Justice organization], but that I
am a private contractor hired by the agency.

--
Daniel P. Brown
[office] (570-) 587-7080 Ext. 272
[mobile] (570-) 766-8107

--- End Message ---
--- Begin Message ---
Yep, that would be the perfect solution, but, unfortunately, database
is not an option for this project. Thanks for looking! I did get a
solution though from another list.
Here is a working version:

http://veanndesign.com/sorting.php

compare it to the not working one:

http://veanndesign.com/test.php

Anyways, thanks again!

Anna

On 5/13/07, Richard Lynch <[EMAIL PROTECTED]> wrote:
If you are going to sort it by various fields, I'd just throw it into
a database...

That said, http://php.net/usort should be able to do whatever you want.

On Thu, May 10, 2007 2:18 pm, Anna Vester wrote:
> Hello all,
>
> I have a question concerning .CSV array sorting. I have tried googling
> for an answer and have tried different techniques, but nothing seems
> to works as I would like it to work. Here is my situation:
> Test file is located here: http://veanndesign.com/test.php
>
> I would like to be able to sort the output by the Time Zone (or any
> other fields). Here is how my code looks like:
> http://veanndesign.com/test.html
>
> I believe that I need to get all the data from the .csv file dumped
> into 1 array, and I guess I am struggling at that point. I have tried
> using foreach inside of the while loop, but it doesn't seem to work.
> So what is the best and/or right way to sort this type of data?
>
> Hopefully, this email makes sense.
>
> Thanks in advance.
>
> --
> Anna Vester
> Web Designer
> http://www.veanndesign.com
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>


--
Some people have a "gift" link here.
Know what I want?
I want you to buy a CD from some indie artist.
http://cdbaby.com/browse/from/lynch
Yeah, I get a buck. So?




--
Anna Vester
Web Designer
http://www.veanndesign.com

--- End Message ---
--- Begin Message ---
On 13/05/07, Robert Cummings <[EMAIL PROTECTED]> wrote:
On Sat, 2007-05-12 at 23:03 -0500, Richard Lynch wrote:

> You may find this entertaining, and even useful:
> http://richardlynch.blogspoot.com

I'm sure Richard meant
    http://richardlynch.blogspot.com
Unless he's trying to promote bondage and S&M >:)

Well, I found this entertaining.  As for useful?  I'll say no.

Alister

--- End Message ---
--- Begin Message ---
On Tue, 2007-05-15 at 16:57 +0100, Alister Bulman wrote:
> On 13/05/07, Robert Cummings <[EMAIL PROTECTED]> wrote:
> > On Sat, 2007-05-12 at 23:03 -0500, Richard Lynch wrote:
> 
> > > You may find this entertaining, and even useful:
> > > http://richardlynch.blogspoot.com
> >
> > I'm sure Richard meant
> >     http://richardlynch.blogspot.com
> > Unless he's trying to promote bondage and S&M >:)
> 
> Well, I found this entertaining.  As for useful?  I'll say no.

Thanks for the feedback. We'll use the information you've provided that
explains what you didn't find useful to help us improve our free
services for future visitors.

Cheers,
Rob.
-- 
.------------------------------------------------------------.
| InterJinn Application Framework - http://www.interjinn.com |
:------------------------------------------------------------:
| An application and templating framework for PHP. Boasting  |
| a powerful, scalable system for accessing system services  |
| such as forms, properties, sessions, and caches. InterJinn |
| also provides an extremely flexible architecture for       |
| creating re-usable components quickly and easily.          |
`------------------------------------------------------------'

--- End Message ---
--- Begin Message ---
Hi people

i was just curios to ask whether

array() == null should always return true. and then why

i'm testing this with php 5.2.2

greetings

dominic letz

--- End Message ---
--- Begin Message ---
> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
> Sent: 15 May 2007 16:48
> To: [EMAIL PROTECTED]
> Subject: [PHP] PHP 5.2 array() == null
>
>
> Hi people
>
> i was just curios to ask whether
>
> array() == null should always return true. and then why
>
> i'm testing this with php 5.2.2
>
> greetings
>
> dominic letz
>

According to Table Q.2 at
http://www.php.net/manual/en/types.comparisons.php, array() == NULL will
always return TRUE.

Remember == is a loose comparison. I think this is a result of the
following:

      array() == FALSE  is TRUE (because it's empty?)
        FALSE == NULL   is TRUE
thus  array() == NULL   is TRUE

Edward

--- End Message ---
--- Begin Message ---
On Tue, 2007-05-15 at 17:27 +0100, Edward Kay wrote:
> > -----Original Message-----
> > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
> > Sent: 15 May 2007 16:48
> > To: [EMAIL PROTECTED]
> > Subject: [PHP] PHP 5.2 array() == null
> >
> >
> > Hi people
> >
> > i was just curios to ask whether
> >
> > array() == null should always return true. and then why
> >
> > i'm testing this with php 5.2.2
> >
> > greetings
> >
> > dominic letz
> >
> 
> According to Table Q.2 at
> http://www.php.net/manual/en/types.comparisons.php, array() == NULL will
> always return TRUE.
> 
> Remember == is a loose comparison. I think this is a result of the
> following:
> 
>       array() == FALSE  is TRUE (because it's empty?)

Yes, being empty is why it is equivalent to boolean false. It makes it
simple and self explanatory to do code like the following:

<?php

    if( $array )
    {
        // do something since it's not empty
    }
    else
    {
        // sorry nothing was found.
    }

?>

This is preferable to using the count() function since no function
overhead is incurred.

Cheers,
Rob.
-- 
.------------------------------------------------------------.
| InterJinn Application Framework - http://www.interjinn.com |
:------------------------------------------------------------:
| An application and templating framework for PHP. Boasting  |
| a powerful, scalable system for accessing system services  |
| such as forms, properties, sessions, and caches. InterJinn |
| also provides an extremely flexible architecture for       |
| creating re-usable components quickly and easily.          |
`------------------------------------------------------------'

--- End Message ---
--- Begin Message ---
This is mostly for anyone that could later read this thread, (probably
when searching) but I found an excellent article titled Developing a
Plugin Architecture for PHP Applications in the april 2006 issue of
the php|architect magazine.

On 5/14/07, Greg Donald <[EMAIL PROTECTED]> wrote:
On 5/14/07, Guillaume Theoret <[EMAIL PROTECTED]> wrote:
> I'm about to start a project and I'm still in the architectural design
> phase. It's going to be a content management system but for several
> unrelated things such as website management, employee management or
> project management.
>
> I plan on building a module based system where each part can be
> developed as an individual plugin and then just added into the
> portal/main page.
>
> Does anyone know of any php-specific resources (either online or paper
> format, both are fine) that would be helpful?


If PHP is required I would suggest Drupal.  It's a really good CMS
with a solid plugin/module architecture.  The API is very well
documented.



--
Greg Donald
http://destiney.com/

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



--- End Message ---
--- Begin Message ---
Guillaume Theoret wrote:
This is mostly for anyone that could later read this thread, (probably
when searching) but I found an excellent article titled Developing a
Plugin Architecture for PHP Applications in the april 2006 issue of
the php|architect magazine.

On 5/14/07, Greg Donald <[EMAIL PROTECTED]> wrote:
On 5/14/07, Guillaume Theoret <[EMAIL PROTECTED]> wrote:
> I'm about to start a project and I'm still in the architectural design
> phase. It's going to be a content management system but for several
> unrelated things such as website management, employee management or
> project management.
>
> I plan on building a module based system where each part can be
> developed as an individual plugin and then just added into the
> portal/main page.
>
> Does anyone know of any php-specific resources (either online or paper
> format, both are fine) that would be helpful?


If PHP is required I would suggest Drupal.  It's a really good CMS
with a solid plugin/module architecture.  The API is very well
documented.



--
Greg Donald
http://destiney.com/

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



now, since you were just there, why didn't you include a link???

--
Jim Lucas

   "Some men are born to greatness, some achieve greatness,
       and some have greatness thrust upon them."

Unknown

--- End Message ---
--- Begin Message ---
Guillaume Theoret wrote:
This is mostly for anyone that could later read this thread, (probably
when searching) but I found an excellent article titled Developing a
Plugin Architecture for PHP Applications in the april 2006 issue of
the php|architect magazine.

On 5/14/07, Greg Donald <[EMAIL PROTECTED]> wrote:
On 5/14/07, Guillaume Theoret <[EMAIL PROTECTED]> wrote:
> I'm about to start a project and I'm still in the architectural design
> phase. It's going to be a content management system but for several
> unrelated things such as website management, employee management or
> project management.
>
> I plan on building a module based system where each part can be
> developed as an individual plugin and then just added into the
> portal/main page.
>
> Does anyone know of any php-specific resources (either online or paper
> format, both are fine) that would be helpful?


If PHP is required I would suggest Drupal.  It's a really good CMS
with a solid plugin/module architecture.  The API is very well
documented.



--
Greg Donald
http://destiney.com/

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



nm, stupid of me to not search and find out why first  :(

--
Jim Lucas

   "Some men are born to greatness, some achieve greatness,
       and some have greatness thrust upon them."

Unknown

--- End Message ---
--- Begin Message ---
Yeah, sadly it's not free.

When I found it I asked my manager if we could subscribe and it turns
out he already subscribes so we went to his place at lunch and brought
his copies over here. Now we're getting a subscription for the office.

On 5/15/07, Jim Lucas <[EMAIL PROTECTED]> wrote:
Guillaume Theoret wrote:
> This is mostly for anyone that could later read this thread, (probably
> when searching) but I found an excellent article titled Developing a
> Plugin Architecture for PHP Applications in the april 2006 issue of
> the php|architect magazine.
>
> On 5/14/07, Greg Donald <[EMAIL PROTECTED]> wrote:
>> On 5/14/07, Guillaume Theoret <[EMAIL PROTECTED]> wrote:
>> > I'm about to start a project and I'm still in the architectural design
>> > phase. It's going to be a content management system but for several
>> > unrelated things such as website management, employee management or
>> > project management.
>> >
>> > I plan on building a module based system where each part can be
>> > developed as an individual plugin and then just added into the
>> > portal/main page.
>> >
>> > Does anyone know of any php-specific resources (either online or paper
>> > format, both are fine) that would be helpful?
>>
>>
>> If PHP is required I would suggest Drupal.  It's a really good CMS
>> with a solid plugin/module architecture.  The API is very well
>> documented.
>>
>>
>>
>> --
>> Greg Donald
>> http://destiney.com/
>>
>> --
>> PHP General Mailing List (http://www.php.net/)
>> To unsubscribe, visit: http://www.php.net/unsub.php
>>
>>
>
nm, stupid of me to not search and find out why first  :(

--
Jim Lucas

    "Some men are born to greatness, some achieve greatness,
        and some have greatness thrust upon them."

Unknown



--- End Message ---
--- Begin Message ---
I am trying to load a PHP debugger in our most recent build of PHP 5.2.1.

The debugger which I am trying to set up is the free, pre-compiled
Linux version of dbg ( DBG 2.15.5 dbg modules), from
http://dd.cron.ru/dbg/, and all of the instructions have been followed
as posted on the NuSphere site.

Yes, Apache has been stopped and restarted!!

There is no difference in the output from phpinfo(). The line
"with DBG v2.11.30, (C) 2000,2004 by Dmitri Dmitrienko, http://dd.cron.ru";
does not appear.

PHP is compiled without debugging, but I did consider that was for the
purpose of debugging PHP itself, not scripts.

Suggestions will be most welcome. Also, I'm not married to this, so if
anyone thinks there is a better debugger, please jump in.

Regards - Miles Thompson

PS Why are we doing this? Because we are getting tired of debugging
with Javascript alert()  boxes. /mt

PPS And we are using those because of Joomla!  Some things are buried
so deeply we cannot use print() or echo(). /mt

--- End Message ---
--- Begin Message ---
Don't know if it'll do what you want it to do...and if you're using Joomla, it 
might be tricky (or not... havn't messed with Joomla enough to know) to insert 
it into the system in a meaningful way.. but check out this:

FirePHP:
http://www.firephp.org/

Works with Firebug Firefox extension to give some PHP debugging and profiling 
data.

I'm sure there are a dozen other solutions that people will offer up, just 
wanted to get that one in there :)

-TG

= = = Original message = = =

I am trying to load a PHP debugger in our most recent build of PHP 5.2.1.

The debugger which I am trying to set up is the free, pre-compiled
Linux version of dbg ( DBG 2.15.5 dbg modules), from
http://dd.cron.ru/dbg/, and all of the instructions have been followed
as posted on the NuSphere site.

Yes, Apache has been stopped and restarted!!

There is no difference in the output from phpinfo(). The line
"with DBG v2.11.30, (C) 2000,2004 by Dmitri Dmitrienko, http://dd.cron.ru";
does not appear.

PHP is compiled without debugging, but I did consider that was for the
purpose of debugging PHP itself, not scripts.

Suggestions will be most welcome. Also, I'm not married to this, so if
anyone thinks there is a better debugger, please jump in.

Regards - Miles Thompson

PS Why are we doing this? Because we are getting tired of debugging
with Javascript alert()  boxes. /mt

PPS And we are using those because of Joomla!  Some things are buried
so deeply we cannot use print() or echo(). /mt

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


___________________________________________________________
Sent by ePrompter, the premier email notification software.
Free download at http://www.ePrompter.com.

--- End Message ---
--- Begin Message ---
Currently I'm Using PDT/XDebug on daily basis and works just fine.
You can get Xdebug from www.xdebug.org,
PDT from www.eclipse.org/pdt
and the plugin for PDT to add support to the PDT is 
https://bugs.eclipse.org/bugs/show_bug.cgi?id=169408

In the plugin precompiled package you'll find a pdf with instruction how to 
get things working. On the Xdebug site there's a lot of information how to 
setup PHP and XDebug.
Note that the precompiled binary of the support for PDT will work for you, 
as it's written in Java and you don't need to compile it.

Regards,
Emil Ivanov

""Miles Thompson"" <[EMAIL PROTECTED]> wrote in message 
news:[EMAIL PROTECTED]
>I am trying to load a PHP debugger in our most recent build of PHP 5.2.1.
>
> The debugger which I am trying to set up is the free, pre-compiled
> Linux version of dbg ( DBG 2.15.5 dbg modules), from
> http://dd.cron.ru/dbg/, and all of the instructions have been followed
> as posted on the NuSphere site.
>
> Yes, Apache has been stopped and restarted!!
>
> There is no difference in the output from phpinfo(). The line
> "with DBG v2.11.30, (C) 2000,2004 by Dmitri Dmitrienko, http://dd.cron.ru";
> does not appear.
>
> PHP is compiled without debugging, but I did consider that was for the
> purpose of debugging PHP itself, not scripts.
>
> Suggestions will be most welcome. Also, I'm not married to this, so if
> anyone thinks there is a better debugger, please jump in.
>
> Regards - Miles Thompson
>
> PS Why are we doing this? Because we are getting tired of debugging
> with Javascript alert()  boxes. /mt
>
> PPS And we are using those because of Joomla!  Some things are buried
> so deeply we cannot use print() or echo(). /mt 

--- End Message ---
--- Begin Message --- Hello, Im designing a website in which I have to read some data (numbers) from a txt file and then send this data to a function which prints a graphic with them. When I read the data I save it in an array and the numbers are in this format: 5.812E-08. I have read the php documentation about it, and I have use the example given there to check which type is the data saved in the array. The response I got is
$vectorIc[1]== 5.812E-08 type is string

I dont understand why. In the documentation it is clear that this kind of data should be considerer float, or thats what I understood. I cant continue with my web designing if I dont get to turn the vector elements into float numbers, because the function that prints the graphic gives errors when recieving strings. I would be very thankful if you could help me trying to solve this. In using PHP 4.4.7 and Apache 2.0.59.

Thank you very much!

_________________________________________________________________
Descubre la descarga digital con MSN Music. Más de un millón de canciones. http://music.msn.es/
--- End Message ---
--- Begin Message ---
Hi Pablo,

Tuesday, May 15, 2007, 7:44:52 PM, you wrote:

> Hello, Im designing a website in which I have to read some data (numbers)
> from a txt file and then send this data to a function which prints a graphic
> with them. When I read the data I save it in an array and the numbers are in
> this format: 5.812E-08. I have read the php documentation about it, and I
> have use the example given there to check which type is the data saved in
> the array. The response I got is
> $vectorIc[1]== 5.812E-08 type is string

> I dont understand why. In the documentation it is clear that this kind of
> data should be considerer float, or thats what I understood. I cant continue
> with my web designing if I dont get to turn the vector elements into float
> numbers, because the function that prints the graphic gives errors when
> recieving strings. I would be very thankful if you could help me trying to
> solve this. In using PHP 4.4.7 and Apache 2.0.59.

Data stored in text files are ALWAYS strings. If you are reading it in
with something like fgets() then it'll be a string by default, unless
you cast it otherwise.

Cheers,

Rich
-- 
Zend Certified Engineer
http://www.corephp.co.uk

"Never trust a computer you can't throw out of a window"

--- End Message ---
--- Begin Message ---
<?php$var = '5.812E-08';var_dump($var);$var = 
(float)$var;var_dump($var);var_dump($var + 2);?>Outputs:string(9) 
"5.812E-08"
float(5.812E-8)
float(2.00000005812)
All you need is to cast it (float) to float, (int) to int.

Regards,
Emil Ivanov
""Pablo Luque"" <[EMAIL PROTECTED]> wrote in message 
news:[EMAIL PROTECTED]
> Hello, Im designing a website in which I have to read some data (numbers) 
> from a txt file and then send this data to a function which prints a 
> graphic with them. When I read the data I save it in an array and the 
> numbers are in this format: 5.812E-08. I have read the php documentation 
> about it, and I have use the example given there to check which type is 
> the data saved in the array. The response I got is
> $vectorIc[1]== 5.812E-08 type is string
>
> I dont understand why. In the documentation it is clear that this kind of 
> data should be considerer float, or thats what I understood. I cant 
> continue with my web designing if I dont get to turn the vector elements 
> into float numbers, because the function that prints the graphic gives 
> errors when recieving strings. I would be very thankful if you could help 
> me trying to solve this. In using PHP 4.4.7 and Apache 2.0.59.
>
> Thank you very much!
>
> _________________________________________________________________
> Descubre la descarga digital con MSN Music. Más de un millón de canciones. 
> http://music.msn.es/ 

--- End Message ---
--- Begin Message ---
What function(s) are you using to read the file contents? How are you
inserting them into the array? Code examples please...

--- End Message ---
--- Begin Message ---
hi,
in php.ini is error_reporting turned off. and, to see an error have to open error_log. though, for me is much easier to have it on and see the errors on the screen. while developing, of course. I put on the beginning of the file error_reporting(E_ALL) to "overwrite" php.ini but it doesn't work. still can't see anything.

what am I doing wrong?

thanks.

-afan

--- End Message ---
--- Begin Message ---
Afan Pasalic wrote:
in php.ini is error_reporting turned off. and, to see an error have to open error_log. though, for me is much easier to have it on and see the errors on the screen. while developing, of course. I put on the beginning of the file error_reporting(E_ALL) to "overwrite" php.ini but it doesn't work. still can't see anything.

what am I doing wrong?

Check the display_errors setting.

-Stut

--- End Message ---
--- Begin Message ---
Please include the list in replies.

Afan Pasalic wrote:
Stut wrote:
Afan Pasalic wrote:
in php.ini is error_reporting turned off. and, to see an error have to open error_log. though, for me is much easier to have it on and see the errors on the screen. while developing, of course. I put on the beginning of the file error_reporting(E_ALL) to "overwrite" php.ini but it doesn't work. still can't see anything.

what am I doing wrong?

Check the display_errors setting.

-Stut
I'm sorry, my bad. I was thinking one thing and writing other. :-)
error_reporting is "on" (E_ALL & ~E_NOTICE & ~E_STRICT) and display_errors = off
But, the result is the same: blank screen.
:-)

Try ini_set('display_errors', '1');

-Stut

--- End Message ---
--- Begin Message ---
Stut wrote:
Please include the list in replies.
I'm sorry. Clicked on wrong Reply button
:-)



Afan Pasalic wrote:
Stut wrote:
Afan Pasalic wrote:
in php.ini is error_reporting turned off. and, to see an error have to open error_log. though, for me is much easier to have it on and see the errors on the screen. while developing, of course. I put on the beginning of the file error_reporting(E_ALL) to "overwrite" php.ini but it doesn't work. still can't see anything.

what am I doing wrong?

Check the display_errors setting.

-Stut
I'm sorry, my bad. I was thinking one thing and writing other. :-)
error_reporting is "on" (E_ALL & ~E_NOTICE & ~E_STRICT) and display_errors = off
But, the result is the same: blank screen.
:-)

Try ini_set('display_errors', '1');

-Stut
Yup. It works.
Thanks Stut
;-)

-afan

--- End Message ---
--- Begin Message ---
Afan Pasalic wrote:
hi,
in php.ini is error_reporting turned off. and, to see an error have to open error_log. though, for me is much easier to have it on and see the errors on the screen. while developing, of course. I put on the beginning of the file error_reporting(E_ALL) to "overwrite" php.ini but it doesn't work. still can't see anything.

what am I doing wrong?

thanks.

-afan

make sure you have

display_error = On

either in your php.ini

--
Jim Lucas

   "Some men are born to greatness, some achieve greatness,
       and some have greatness thrust upon them."

Unknown

--- End Message ---
--- Begin Message ---
Either that, or

ini_set('display_errors', '1');

On 5/15/07, Jim Lucas <[EMAIL PROTECTED]> wrote:
Afan Pasalic wrote:
> hi,
> in php.ini is error_reporting turned off. and, to see an error have to
> open error_log.
> though, for me is much easier to have it on and see the errors on the
> screen.  while developing, of course.
> I put on the beginning of the file error_reporting(E_ALL) to "overwrite"
> php.ini but it doesn't work. still can't see anything.
>
> what am I doing wrong?
>
> thanks.
>
> -afan
>
make sure you have

display_error = On

either in your php.ini

--
Jim Lucas

    "Some men are born to greatness, some achieve greatness,
        and some have greatness thrust upon them."

Unknown

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



--- End Message ---
--- Begin Message ---
On Tuesday 08 May 2007 00:56, Richard Lynch wrote:
> On Sat, May 5, 2007 9:27 pm, Mike Shanley wrote:
> > Davi wrote:
> >> First: use aptitude instead apt-get... =]
> >> Second: use an debian-list to debian's questions instead an
> >> php-list... =]
> >
> > Third: Go Feisty!!!
>
> Fourth: Go
> http://www.listentofeist.com/

A bit late cuz of the Eco Shell marathon,
but for gods sake make a fifth...
fifth would look like: skip first. Why would anyone use aptitude.

>
> :-)
>
> --
> Some people have a "gift" link here.
> Know what I want?
> I want you to buy a CD from some indie artist.
> http://cdbaby.com/browse/from/lynch
> Yeah, I get a buck. So?

-- 
---
Børge
http://www.arivene.net
---

--- End Message ---
--- Begin Message ---
Hi Folks,

I have a database running on Window XP, that I want to disable network connections to and enable 'named pipes'. I am running MySQL 5.0.27 and my.ini looks like...

[client]
#password    = your_password
port        = 3306
socket        = /tmp/mysql.sock

[mysqld]
#port        = 3306
socket        = /tmp/mysql.sock
#Allow connections via named pipes (Windows NT+ only). Note: you can specify a pipe name on the advanced network page, if required.
enable-named-pipe
#Don't allow connections via TCP/IP.
skip-networking



I can connect to the DB using the MySQL GUI tools if I set my pipe name to '/tmp/mysql.sock' using the login dialog box. However when I try and connect using PHP I get an error. I have tried several variants of the connect command and I get various errors but all are along the lines of:
Unknown MySQL server host '/tmp/mysql.sock' (11004)  or
Can't connect to MySQL server on 'localhost' (10061)

I have tried
$mysqli = new mysqli(null, $username,$password, $database);
$mysqli = new mysqli("localhost:/tmp/mysql.sock", $username,$password, $database); $mysqli = new mysqli("localhost", $username,$password, $database,3306,"/tmp/mysql.sock"); $mysqli = new mysqli("localhost", $username,$password, $database,"/tmp/mysql.sock");
$mysqli = new mysqli("/tmp/mysql.sock", $username,$password, $database);

I have also tried the above commands using mysqli_connect ? I have done a few searches of the web but seem to always come up with something like the above? Anybody have any ideas why it won't connect in PHP ?

TIA,
JC

--- End Message ---

Reply via email to