Re: [PHP] Static methods vs. plain functions

2013-09-19 Thread Sebastian Krebs
thod > > Personally in my projects - specifically if I use a framework, I try to > stay away from making standalone functions unless absolutely necessary. > > > > On Thu, Sep 19, 2013 at 12:44 PM, Sebastian Krebs wrote: > >> 2013/9/19 Simon Dániel >> >>

Re: [PHP] Static methods vs. plain functions

2013-09-19 Thread Sebastian Krebs
2013/9/19 Simon Dániel > Hi, > > I am working on an OOP project, and cannot decide which way to follow when > I have to write a simple function. > > For example, I want to write a function which generates a random string. In > an OOP environtment, it is a matter of course to create a static class

Re: [PHP] high traffic websites

2013-09-18 Thread Sebastian Krebs
>>> HTTtrack and others. > >>> I have searched through php list in my email too before asking this > >>> question. it is kind of beneficial for all people and not has been > asked > >>> directly. > >>> > >>> > >>> S

Re: [PHP] high traffic websites

2013-09-18 Thread Sebastian Krebs
Yes, and I may fail to handle it that's why I asked for guidance. >> > I wanted some tidbits to start over. I have searched through yslow, >> > HTTtrack and others. >> > I have searched through php list in my email too before asking this >> > question. it is kind

Re: [PHP] high traffic websites

2013-09-18 Thread Sebastian Krebs
2013/9/18 Negin Nickparsa > In general, what are the best ways to handle high traffic websites? > > VPS(clouds)? > web analyzers? > dedicated servers? > distributed memory cache? > Yes :) But seriously: That is a topic most of us spent much time to get into it. You can explain it with a bunch o

Re: [PHP] Resolving a PHP Notice Error

2013-09-17 Thread Sebastian Krebs
2013/9/17 Ron Piggott > > I am wanting to establish a default sort by preference when the user > hasn’t specified one. I setup to test this with: > > > if ( !is_set( $sort_by_preference ) ) { > > $sort_by_preference = "government_wording"; > > } > > ?> > > But I am receiving a Notice error:

Re: [PHP] Alternate list for eclipse ide support?

2013-08-24 Thread Sebastian Krebs
2013/8/24 Lester Caine > Sebastian Krebs wrote: > >> With composer being pushed as the 'in way to go' and not being able to see >>> >how to get some code relating to bootstrap and smarty development >>> because >>> >the links only show com

Re: [PHP] Alternate list for eclipse ide support?

2013-08-24 Thread Sebastian Krebs
2013/8/24 Lester Caine > With composer being pushed as the 'in way to go' and not being able to see > how to get some code relating to bootstrap and smarty development because > the links only show composer I've downloaded a plug-in for eclipse that is > supposed to handle that. But it's not work

Re: [PHP] Re: PHP vs JAVA

2013-08-22 Thread Sebastian Krebs
2013/8/22 David Harkness > On Wed, Aug 21, 2013 at 7:56 PM, Curtis Maurand wrote: > >> Sebastian Krebs wrote: > > > Actually the problem is, that the dot "." is already in use. With > > > $foo.bar() you cannot tell, if you want to call the method "b

Re: [PHP] Re: PHP vs JAVA

2013-08-21 Thread Sebastian Krebs
2013/8/21 Curtis Maurand > > > > Sorry in advance for the top post. > > Use the right tool for > the Job. I've use Java, C# and PHP. > > 1. I hate the > Perl-like object calls in PHP. I'd rather use "." notation > in C# and Java. It saves a lot of wear and tear on my left pinky > finger. > A

Re: [PHP] Re: PHP vs JAVA

2013-08-21 Thread Sebastian Krebs
2013/8/21 georg chambert > Hi, > > my I shake the subject a little; Ive been doing some PHP and found it "ok" > to work with > not so much fuss, but that was PHP4, what about PHP5 ? > Dont really checked the difference but made a short-scan and found that it > had be > screwed around with ? > > A

Re: [PHP] PHP vs JAVA

2013-08-20 Thread Sebastian Krebs
2013/8/20 Steven Staples > > My recent question was simply an attempt to get documentation to support > > which server-side Web Language is the most popular. Both PHP and Java can > > be used server-side. > > > > I also realize that Java is used for native Android because I also teach > > Mobile

Re: [PHP] PHP vs JAVA

2013-08-20 Thread Sebastian Krebs
2013/8/20 Andy McKenzie > On Tue, Aug 20, 2013 at 3:18 PM, Dan Munro wrote: > > > > 1. There are no statement terminators. Lose your indentation for ANY > > > reason and your program is well and truly screwed, in ways you can't > > > imagine. > > > > > > 2. Python programs fail in the most ungra

Re: [PHP] PHP vs JAVA

2013-08-20 Thread Sebastian Krebs
2013/8/20 Andy McKenzie > I'll chime in on this one. > > I've been job hunting recently, and I can say that while I've seen a lot of > people asking for Java experience, I'm not sure I've seen a single posting > asking specifically for PHP. There've been a few looking for Drupal, or > Wordpress,

Re: [PHP] PHP vs JAVA

2013-08-20 Thread Sebastian Krebs
2013/8/20 Lester Caine > Sebastian Krebs wrote: > >> 1. He's not my teacher -- he is a fellow teacher AND a smart one! He knows >>> >the difference between Java and JavaScript. >>> > >>> >> OKOK, sorry -_- >> But @topic:

Re: [PHP] PHP vs JAVA

2013-08-20 Thread Sebastian Krebs
2013/8/20 Tedd Sperling > On Aug 20, 2013, at 10:29 AM, Sebastian Krebs wrote: > > Just tell your teacher: Java isn't more popular than PHP as > _web_-language ;) > > I think too, that he actually meant javascript, which is indeed a very > popular client-side langua

Re: [PHP] PHP vs JAVA

2013-08-20 Thread Sebastian Krebs
2013/8/20 Tedd Sperling > On Aug 20, 2013, at 10:04 AM, Ashley Sheridan > wrote: > > Is he possibly getting confused with Javascript? > > > > Thanks, > > Ash > > No, this guy is smarter than that -- he's pretty sharp -- so I listen to > what he has to say. > > Here's an interesting link: > > htt

Re: [PHP] how old is this version of PHP?

2013-08-19 Thread Sebastian Krebs
2013/8/19 Jeff Burcher > > I apologize if this is off topic, but this raises a question for me. Why > can't new versions be backwards compatible? Is it really that difficult to > accomplish? This has been a complaint of mine for years with Windows ever > since we went from 95 to 98. I am an AS400

Re: [PHP] Class Auto-Assigning to Variable

2013-08-07 Thread Sebastian Krebs
2013/8/7 Brian Smither > I have a situation where, for some unknown reason, where each class that > finishes its __contruct{} function, that class gets automatically assigned > to a variable - other than the variable I specify. > > Conceptually: > > class Hello { private $_world = 'World'; __cons

Re: [PHP] Fwd: What wrong am I doing now?

2013-07-24 Thread Sebastian Krebs
Hi, Just want to mention: ext/mysel is deprecated. Use MySQLi, or PDO_MYSQL instead. :) Regards, Sebastian 2013/7/24 Karl-Arne Gjersøyen > http://www.php.net/manual/en/datetime.format.php have the solution. Sorry > for asking before I look at php.net!!! > > Karl > > -- Forwarded messa

Re: [PHP] I am completely lost and need an advice (beginner)

2013-07-18 Thread Sebastian Krebs
2013/7/18 Carsten Jensen > On 07/18/2013 09:08 PM, php colos wrote: > > Hello world! > > > > I'm trying to learn PHP ( first programming language that I learn) and > > I feel kinda lost. I've read PHP programming 3rd edition( O'reilly), > > 'getting good with PHP' by Andrew Burgees and some tutor

Re: [PHP] phpdocumentor with PHP5.4

2013-07-07 Thread Sebastian Krebs
You can submit a pull request for that 2013/7/7 Lester Caine > Sebastian Krebs wrote: > >> I meant: PhpDocumentor 2 >> > Problem solved ... > Notes on > https://github.com/**phpDocumentor/phpDocumentor2<https://github.com/phpDocumentor/phpDocumentor2>need

Re: [PHP] phpdocumentor with PHP5.4

2013-07-07 Thread Sebastian Krebs
I meant: PhpDocumentor 2 Am 07.07.2013 17:44 schrieb : > It's a clean install via PEAR a couple of hours ago! > > Sent from my android device. > > -Original Message----- > From: Sebastian Krebs > To: Lester Caine > Cc: PHP General List > Sent: Sun, 07 Ju

Re: [PHP] phpdocumentor with PHP5.4

2013-07-07 Thread Sebastian Krebs
You can simply update phpdocumentor Am 07.07.2013 17:10 schrieb "Lester Caine" : > Anybody have phpdocumentor running with PHP5.4? > I'm convinced that the errors my copy is throwing are due to e_strict, but > I've confirmed that I have the right ini file ( all the needed extensions > load ) and I

Re: [PHP] Re: need some regex help to strip out // comments but not http:// urls

2013-05-30 Thread Sebastian Krebs
2013/5/29 Matijn Woudt > > > On Wed, May 29, 2013 at 10:51 PM, Sebastian Krebs wrote: > >> >> >> >> 2013/5/29 Matijn Woudt >> >>> On Wed, May 29, 2013 at 6:08 PM, Sean Greenslade >> >wrote: >>> >>> > On Wed, M

Re: [PHP] Re: need some regex help to strip out // comments but not http:// urls

2013-05-29 Thread Sebastian Krebs
2013/5/29 Matijn Woudt > On Wed, May 29, 2013 at 6:08 PM, Sean Greenslade >wrote: > > > On Wed, May 29, 2013 at 9:57 AM, Jonesy wrote: > > > On Tue, 28 May 2013 14:17:06 -0700, Daevid Vincent wrote: > > >> I'm adding some minification to our cache.class.php and am running > into > > an > > >> e

Re: [PHP] Header Keep-Alive

2013-05-27 Thread Sebastian Krebs
2013/5/27 Al > I'm trying to increase the connection timeout; but can't get it to work. > Note: Keep-Alive gets repeated. > > I'm using: > header("Connection: Keep-Alive"); > header("Keep-Alive: timeout=9, max=100"); > Set the second optional argument to "true" See http://de.php.net/manual/en/fu

Re: [PHP] A Good OOP Tutorial/Read?

2013-05-17 Thread Sebastian Krebs
2013/5/17 Tedd Sperling > Nick: > > I thank you for your addition, but what you provided did nothing to > explain the difference between abstract and interface. > > In your example: > > An abstract Shape with Circle and Square inheriting. > > OR > > An interface Shape with Circle and Squa

Re: [PHP] A Good OOP Tutorial/Read?

2013-05-16 Thread Sebastian Krebs
2013/5/16 Tedd Sperling > -Dan: > > I teach this stuff and still don't fully understand the why/when for > interfaces. > > Even the guru's I talk with can't give me a good explanation as to what > the advantages are in using them. I've done a lot of experimenting and > can't see any advantage for

Re: [PHP] Need a tool to minimize HTML before storing in memecache

2013-05-03 Thread Sebastian Krebs
2013/5/3 Daevid Vincent > > > -Original Message- > > From: Marco Behnke [mailto:ma...@behnke.biz] > > Sent: Friday, May 03, 2013 12:01 PM > > To: Daevid Vincent; php >> "php-general@lists.php.net" > > Subject: Re: [PHP] Need a tool to minimize HTML before storing in > memecache > > > > If

Re: [PHP] Newbie Question - Parse XML with PHP...

2013-04-19 Thread Sebastian Krebs
A "webpage" is a file, that (usually) a browser downloads and parses. You'll do exactly the same :-) I don't know exactly, but you can try to pass the URL directly to simplexml_load_file(). If this doesn't work, download the content (for example with file_get_contents()) and pass it to simplexml_lo

Re: [PHP] Detecting massive web hits

2013-04-12 Thread Sebastian Krebs
Nginx has builtin support for this and I assume, that there is something similar for Apache. I don't think PHP is the right tool. Am 12.04.2013 17:24 schrieb "Angela Barone" : > Does anyone know if there's a ready-made script that detects if > someone hits multiple web pages within seconds

Re: [PHP] application level variable file

2013-03-22 Thread Sebastian Krebs
2013/3/22 > I am very new to the PHP application and would like to create a new > project. > I would like to have a file to save my application level variable and > functions. > > I would like to know does PHP have any default file name and file path for > this file like Web.config file for ASP.N

Re: [PHP] significance of escape character in string in PHP

2013-03-18 Thread Sebastian Krebs
2013/3/18 Ken Robinson > > > On 18.03.2013 09:10, Norah Jones wrote: > >> I am having an string which was have few ' (single quote) and few " >> (double quotes) and was not able to insert into the mysql database. I >> have replaced them with \' and \" and everything is fine. >> Though this are fi

Re: [PHP] variable type - conversion/checking

2013-03-15 Thread Sebastian Krebs
2013/3/16 Andrew Ballard > I suppose one could try something like this: > > if (is_string($val) && $val === (string)(int)$val) > > If $val is an integer masquerading as a string, it should be identical to > the original string when cast back to a string, shouldn't it? (I can't try > it right

Re: [PHP] variable type - conversion/checking

2013-03-15 Thread Sebastian Krebs
2013/3/16 Ashley Sheridan > > > tamouse mailing lists wrote: > > >On Fri, Mar 15, 2013 at 4:00 PM, Ashley Sheridan > >wrote: > > > >> ** > >> On Fri, 2013-03-15 at 04:57 -0500, tamouse mailing lists wrote: > >> > >> On Fri, Mar 15, 2013 at 3:55 AM, Peter Ford > >wrote: > >> > On 15/03/13 06:21,

Re: [PHP] PHP context editor

2013-03-15 Thread Sebastian Krebs
2013/3/15 Karim Geiger > Hi Georg, > > On Thu, 2013-03-14 at 23:10 +0100, georg wrote: > > hello, > > annyone knows of some good PHP context editor freeware ? > > (tired of missing out on trivials like ; ) > > I don't know exactly what you mean by a context editor but if you want > an editor with

Re: [PHP] Type of a variable in PHP

2013-03-15 Thread Sebastian Krebs
2013/3/15 Kevin Peterson > Have two questions - > 1. How to find type of a variable in PHP. > gettype(), or one of the is_*()-functions. But for me more interesting for me: Why do you _need_ this? > 2. How to find the type of an array in PHP. > An array is of type array :) is_array() or again

Re: [PHP] Mystery foreach error

2013-03-13 Thread Sebastian Krebs
2013/3/14 David Harkness > > On Wed, Mar 13, 2013 at 5:10 PM, Sebastian Krebs wrote: > >> Because 'null' is the representation of "nothing" array_key_exists() and >> isset() can be treated as semantically equivalent. > > > As I said, these func

Re: [PHP] Mystery foreach error

2013-03-13 Thread Sebastian Krebs
2013/3/14 David Harkness > On Wed, Mar 13, 2013 at 4:44 PM, Angela Barone > wrote: > > > I ran across if(array_key_exists) and it seems to work. How does that > > differ from if(isset($states[$state]))? > > > Hi Angela, > > isset() will return false for an array key 'foo' mapped to a null value

Re: [PHP] Re: UNLESS Statement Equivalent

2013-03-12 Thread Sebastian Krebs
2013/3/12 Ford, Mike > > -Original Message- > > From: Maciek Sokolewicz [mailto:tula...@gmail.com] On Behalf Of > > Maciek Sokolewicz > > Sent: 11 March 2013 22:44 > > > > > unless ( $a and $b ) > > = > > if ( ! ($a and $b) ) > > > > So in simple terms, just stick a ! (or the keyword not)

Re: [PHP] Holding "datetimes" in a DB.

2013-03-01 Thread Sebastian Krebs
2013/3/2 tamouse mailing lists > On Fri, Mar 1, 2013 at 11:53 AM, Matijn Woudt wrote: > > On Fri, Mar 1, 2013 at 11:49 AM, Richard Quadling >wrote: > > > >> Hi. > >> > >> My heads trying to remember something I may or may not have known to > start > >> with. > >> > >> If I hold datetimes in a D

Re: [PHP] Stupid question

2013-02-27 Thread Sebastian Krebs
2013/2/27 tamouse mailing lists > On Tue, Feb 26, 2013 at 4:41 PM, Jim Lucas wrote: > > On 02/26/2013 01:27 PM, Curtis Maurand wrote: > >> > >> I have the following: > >> > >> $dsn = "mysqli://$username:$password@$hostname2/$database"; > >> $options = array( > >> 'debug' => 3, > >> 'result_buffe

Re: [PHP] Very Large File Splatter

2013-02-22 Thread Sebastian Krebs
2013/2/22 Brian Smither > PHP 5.4.4-TS-VC9 on Windows XP SP3 NTFS non-system drive with 18GB free. > > I dare not try to replicate this. As such, I cannot firmly place the blame > on PHP. > > I have peppered a PHP application with a call to a function which > appends-only to a logfile the paramet

Re: [PHP] same php file, different day...worked 3-4 times in the past in the past

2013-01-20 Thread Sebastian Krebs
2013/1/20 Fred Silsbee > Fatal error: Call to undefined function mysqli__connect() in > /var/www/html/log_book_MySQLnew_i.php on line 116 > There is an underscore "_" to much: 'mysqli_connect()' > > phpinfo.php shows mysqli > > Additional .ini files parsed > > /etc/php.d/curl.ini, > /etc/php.

Re: [PHP] Expansion of Apache definitions

2013-01-10 Thread Sebastian Krebs
2013/1/10 John Iliffe > I recently made a posting on the Apache users group regarding recovering > the client IP address using the $_SESSION['REMOTE_ADDR'] function in PHP. > > I received the following caveat from another developer: > > -start quote > You may want

Re: [PHP] Some date() oddities

2013-01-08 Thread Sebastian Krebs
Hi, Workaround for what? The 31st of december is the first week of the ISO8601-year 2013. That has nothing to do with PHP, date(), or any warnings somebody left in the comments. Thats the way ISO8601 is defined: http://en.wikipedia.org/wiki/ISO_8601#Week_dates Regards, Sebastian 2013/1/8 Arno K

Re: [PHP] Boolean type forced on string assignment inside if statement

2013-01-04 Thread Sebastian Krebs
2013/1/4 tamouse mailing lists > On Fri, Jan 4, 2013 at 1:56 AM, Sebastian Krebs > wrote: > > 2013/1/4 tamouse mailing lists > >> Bit operators are not comparing values, they're COMBINING values. > > > > Technically spoken they're comparing bits,

Re: [PHP] Boolean type forced on string assignment inside if statement

2013-01-03 Thread Sebastian Krebs
2013/1/4 tamouse mailing lists > Bit operators & and | are NOT and should NEVER be confused with > Logical operators && and ||: > > > /** > * Bit operators in PHP > */ > > $format = "Decimal: %2d Binary: %4b\n"; > > > $a = 4; > $b = 6; > > > echo "Variable \$a:\n"; > printf($format, $a, $a);

Re: [PHP] Noobie starting to learn OOP for databases needs help

2012-12-16 Thread Sebastian Krebs
2012/12/17 dealTek > > On Dec 16, 2012, at 10:08 AM, Sebastian Krebs wrote: > > > 2012/12/16 dealTek > > > >> Hi all, > >> > >> Noobie starting to learn oop for databases from here: > >> > >> > >> > https://github.

Re: [PHP] Noobie starting to learn OOP for databases needs help

2012-12-16 Thread Sebastian Krebs
2012/12/16 dealTek > Hi all, > > Noobie starting to learn oop for databases from here: > > > https://github.com/JeffreyWay/PHP-MySQL-Database-Class/blob/master/MysqlDb.php > > I've got lots working but have a few issues: > > 1 - after an insert I'd like to get the id of the new record and I'm not

Re: [PHP] Compile APC in PHP 5.2

2012-12-12 Thread Sebastian Krebs
Hi, You should definitely not use PHP5.2 anymore. Regards, Sebastian 2012/12/12 Alexander Diedler > Hello, > I try to get APC working for a compiled PHP 5.2.17. > On this Ubuntu, we have an PHP 5.3 installed with APT-GET and a PHP 5.2 as > CGI module compiled with make etc. > In the PHP 5.3 I

Re: [PHP] Session ?

2012-12-07 Thread Sebastian Krebs
2012/12/7 Daniel Brown > On Fri, Dec 7, 2012 at 3:04 PM, Jim Giner > wrote: > > > > OK - now that I've messed us all up, help me to understand your proposed > > solution. I added the ini-set line to my first script. Then I called my > > second one and still had the same problem with a missing

Re: [PHP] Session ?

2012-12-07 Thread Sebastian Krebs
2012/12/7 Jim Giner > On 12/7/2012 2:41 PM, Daniel Brown wrote: > >> On Fri, Dec 7, 2012 at 2:38 PM, Jim Giner >> wrote: >> >>> On 12/7/2012 2:36 PM, Daniel Brown wrote: >>> On Fri, Dec 7, 2012 at 2:33 PM, Jim Giner >>> > wrote: > > Something new for me - working with

Re: [PHP] Unset and __destruct

2012-12-07 Thread Sebastian Krebs
2012/12/6 Pierre du Plessis > Hi all > > I searched the internet (probably not hard enough), and couldn't find a > decent answer. > > I was wondering why, when calling unset on an object, it doesn't > automatically call the __destruct method (if it exists) on the object. > Thats because it was n

Re: [PHP] Re: shared memory on php servers?

2012-12-04 Thread Sebastian Krebs
2012/12/4 Stuart Dallas > On 4 Dec 2012, at 10:51, rene7705 wrote: > > > I would also like to hear any thoughts on how to efficiently add, > > delete and edit data in this large and deep array structure from > > multiple sessions at nearly the same time.. > > > > On Tue, Dec 4, 2012 at 11:49 AM,

Re: [PHP] Re: shared memory on php servers?

2012-12-04 Thread Sebastian Krebs
Hi, Why don't you use a database? Seems more appropiate here. At least SQLite should fit ;) Regards, Sebastian 2012/12/4 rene7705 > I would also like to hear any thoughts on how to efficiently add, > delete and edit data in this large and deep array structure from > multiple sessions at nearl

Re: [PHP] Re: Switch - Case Statement Questions

2012-11-19 Thread Sebastian Krebs
2012/11/19 Tim Streater > On 18 Nov 2012 at 14:44, Jim Giner wrote: > > > 2. Using Switch {ALWAYS FIRST CASE!!!} > > > > //$boxes = 1; > > //switch ($count) { > > //case ($count > 14): > > //$boxes = 3; > > //

Re: [PHP] Re: Switch - Case Statement Questions

2012-11-17 Thread Sebastian Krebs
2012/11/17 Andrew Ballard > On Nov 16, 2012 10:24 PM, "tamouse mailing lists" > wrote: > > > > On Fri, Nov 16, 2012 at 12:41 PM, Sebastian Krebs > wrote: > > > Beside this it can be rewritten as > > > > > > switch ((int) (($count-

Re: [PHP] Re: Switch - Case Statement Questions

2012-11-17 Thread Sebastian Krebs
2012/11/17 Tim Streater > On 17 Nov 2012 at 01:33, Iñigo Medina wrote: > > > On Fri, 16 Nov 2012, Jim Giner wrote: > > >> Maybe I'm way out of touch, but when I look at php.net for the syntax > of the > >> switch statement I see: > >> switch($var){ > >> case (value): > >> (do s

Re: [PHP] Re: Switch - Case Statement Questions

2012-11-16 Thread Sebastian Krebs
2012/11/16 Tim Streater > On 16 Nov 2012 at 12:10, Omar Muhsin wrote: > > > Hello, > > > > I was just wondering after writting the code in version 2 here below, it > turns > > out in testing that it actually PHP is not validating the expressions > instead > > always I get the first case. > > > >

Re: [PHP] base64_decode

2012-10-02 Thread Sebastian Krebs
Am 02.10.2012 19:27, schrieb John Taylor-Johnston: Without anyone infecting their machines, can someone tell me what this is? I found a phishing site on my DreamHost server. DreamHost has been very helpful. We found a file containing this code. What is it? What does it contain? http://codep

Re: [PHP] Basic Statistics

2012-10-01 Thread Sebastian Krebs
Hi, Something like http://php.net/ref.stats ? Regards, Sebastian Am 01.10.2012 18:37, schrieb George R Smith: Can anyone recommend a basic php stat package, easy to install and use. Just basic stuff like mean, median, range std dev etc thanks george -- PHP General Mailing List (http://w

Re: [PHP] Re: PHP as Application Server

2012-09-27 Thread Sebastian Krebs
Hi, Once again I didn't read it completely (maybe I will do so), but my 2ct: I recently played with Ruby and Python and of course with their application server (at least a little bit). My experience was, that it is less fun as it sounds in the first place compared to a well designed webserver-int

Re: [PHP] Static constructor support

2012-09-26 Thread Sebastian Krebs
2012/9/26 Stuart Dallas > On 26 Sep 2012, at 22:29, Yves Goergen > wrote: > > > On 26.09.2012 23:20 CE(S)T, Stuart Dallas wrote: > >> If you mean what C# calls a static constructor, no that does not > >> exist in PHP, but you can fake it. > > > > Okay, thank you for the quick info. > > > > How d

Re: [PHP] Static constructor support

2012-09-26 Thread Sebastian Krebs
2012/9/27 Yves Goergen > On 26.09.2012 23:38 CE(S)T, Stuart Dallas wrote: > > On 26 Sep 2012, at 22:29, Yves Goergen > > wrote: > >> My class is a debug helper class, that can write trace messages and > >> so on. I have added a random per-request tag to distinguish > >> concurrent requests in th

Re: [PHP] about PHP's filter_var function

2012-09-21 Thread Sebastian Krebs
Am 20.09.2012 19:54, schrieb Jim Lucas: On 09/20/2012 10:00 AM, Matijn Woudt wrote: On Thu, Sep 20, 2012 at 6:03 PM, Jim Lucas wrote: On 09/20/2012 02:35 AM, Sebastian Krebs wrote: Plaseplease update... 5.1.6 is from 2006! I read the "it's required", but I can't imagine

Re: [PHP] about PHP's filter_var function

2012-09-20 Thread Sebastian Krebs
Am 20.09.2012 18:17, schrieb Maciek Sokolewicz: On 20-09-2012 18:03, Jim Lucas wrote: On 09/20/2012 02:35 AM, Sebastian Krebs wrote: Plaseplease update... 5.1.6 is from 2006! I read the "it's required", but I can't imagine _anything_ that it's worth it to use s

Re: [PHP] about PHP's filter_var function

2012-09-20 Thread Sebastian Krebs
Am 20.09.2012 18:03, schrieb Jim Lucas: On 09/20/2012 02:35 AM, Sebastian Krebs wrote: Plaseplease update... 5.1.6 is from 2006! I read the "it's required", but I can't imagine _anything_ that it's worth it to use such an extremely outdated, unsupported and therefore

Re: [PHP] about PHP's filter_var function

2012-09-20 Thread Sebastian Krebs
Plaseplease update... 5.1.6 is from 2006! I read the "it's required", but I can't imagine _anything_ that it's worth it to use such an extremely outdated, unsupported and therefore insecure and inefficient version... You know: There are 3 (!) new minor versions available right now (5.2, 5.3 and

Re: [PHP] PHP array unions

2012-09-12 Thread Sebastian Krebs
Hi, In PHP the array is in fact a hash map, but especially it is _used_ for nearly everything map-, set-, ...-like thing. So in short: The is no operator or built-in function, that merges two arrays _and_ treat them as set (instead of the hashmap, what they are). Your solution is the way to g

Re: [PHP] A quick ereg translation

2012-08-25 Thread Sebastian Krebs
Am 25.08.2012 23:06, schrieb Lester Caine: ereg('(.*)', $phpinfo, $regs); Pulls the body of phpinfo() to use with a tidy header of other system information, but I'm struggling to get a pcre alternative. Anybody already cracked this one? usually it's just fine to wrap the pattern into delimite

Re: [PHP] away from Fedora linux for a while and now this ...HELP

2012-08-25 Thread Sebastian Krebs
Am 25.08.2012 13:04, schrieb Matijn Woudt: On Sat, Aug 25, 2012 at 1:54 AM, Sebastian Krebs wrote: Am 25.08.2012 01:41, schrieb Fred Silsbee: Warning: Unknown: failed to open stream: Permission denied in Unknown on line 0 Fatal error: Unknown: Failed opening required '/var/www

Re: [PHP] away from Fedora linux for a while and now this ...HELP

2012-08-24 Thread Sebastian Krebs
Am 25.08.2012 01:41, schrieb Fred Silsbee: Warning: Unknown: failed to open stream: Permission denied in Unknown on line 0 Fatal error: Unknown: Failed opening required '/var/www/html/log_book_MySQL.php' (include_path='.:/usr/share/pear:/usr/share/php') in Unknown on line 0 had to use Fed

Re: [PHP] Cost of redirect and site domain switch? Good Practice/ Bad Practice / Terrible Practice

2012-08-20 Thread Sebastian Krebs
2012/8/20 Jim Giner > > On 8/20/2012 12:19 AM, Jim Lucas wrote: > >> On 8/17/2012 6:35 PM, Jim Giner wrote: >> >>> On 8/17/2012 7:16 PM, Jim Lucas wrote: >>> You could simply remove all full domain+path URL links and replace them with absolute path urls only. turn h

Re: [PHP] Cost of redirect and site domain switch? Good Practice / Bad Practice / Terrible Practice

2012-08-17 Thread Sebastian Krebs
If you need to change the domain completely, choose "301". - Crawler will recognize it and will update their indexes quite soon. Especially you avoid "duplicate content"-punishments, because you say yourself, that the content originally comes from another domain, that isn't anymore (Like "It's

Re: [PHP] Two ways to obtain an object property

2012-08-15 Thread Sebastian Krebs
Hi, 2012/8/15 phplist > This relates to a minor dilemma I come across from time and time, and I'm > looking for advice on pros and cons and best practice. Last night I > encountered it again. > > Within a site I have a User object, and within page code would like to have > if ($crntUser->isASubs

Re: [PHP] PHP Stats

2012-07-31 Thread Sebastian Krebs
Hi, http://w3techs.com/technologies/details/pl-php/all/all For example. Click around, nice stats there. Regards, Sebastian Am 31.07.2012 20:31, schrieb Tedd Sperling: Hi gang: Do we have anything a bit more up to date than this? http://php.net/usage.php That's five years out of date! Als

Re: [PHP] Regex

2012-07-27 Thread Sebastian Krebs
Am 27.07.2012 19:54, schrieb shiplu: #[0-9a-zA-Z,\.]# You should escape out that period as it will match any character otherwise. Thanks, Ash Ash, Thats not true. In character class only meta-characters are \ ^ - [ And the dash only when it's not the first, or the last in the class. an

Re: [PHP] Regex

2012-07-27 Thread Sebastian Krebs
Hi, Am 27.07.2012 19:07, schrieb Ethan Rosenberg: Dear list - I've tried everything and am still stuck. A regex that will accept numbers, letters, comma, period and no other characters This? /^[0-9a-zA-Z,.]$/ Regards, Sebastian Thanks. Ethan Rosenberg -- PHP General Mailing Lis

Re: [PHP] E_STRICT safe PEAR

2012-07-24 Thread Sebastian Krebs
Am 24.07.2012 22:41, schrieb Lester Caine: Sebastian Krebs wrote: The question is - Is the result E_STRICT safe? Would say: Depends on the package you use. I don't use PEAR-packages myself, thus I don't really know. I would say: Try it out :) Test it on your dev-machine, or withi

Re: [PHP] E_STRICT safe PEAR

2012-07-24 Thread Sebastian Krebs
Am 24.07.2012 18:46, schrieb Lester Caine: Sebastian Krebs wrote: Hi, I'm using Ubuntu, but here you can update the "system packages" with the pear executable too $ sudo pear update-channels && sudo pear upgrade --alldeps The question is - Is the result E_STRICT saf

Re: [PHP] E_STRICT safe PEAR

2012-07-24 Thread Sebastian Krebs
Hi, I'm using Ubuntu, but here you can update the "system packages" with the pear executable too $ sudo pear update-channels && sudo pear upgrade --alldeps Regards, Sebastian Am 24.07.2012 17:05, schrieb Lester Caine: Not sure the best place to ask this ... I've worked through all of my ow

[PHP] Bazar behavior w/ private member variables

2012-07-13 Thread Sebastian Krebs
Should go to the mailinlist :> -- Forwarded message -- From: Sebastian Krebs Date: 2012/7/13 Subject: Re: [PHP] Bazar behavior w/ private member variables To: Nathan Nobbe Hi, Private properties are only accessable from within an object of the class, where it's def

Re: [PHP] Contribute to PHP

2012-07-12 Thread Sebastian Krebs
Hi, Nowadays contributing to an OSS-project is (thankfully) often just a matter of creating a github account and sending a pull request. Because you mentioned the ZF, have a look at it's github mirror [1]. There is also a section about contributing in the readme-file. Other projects have similar d

Re: [PHP] Is this list less busy than it used to be?

2012-07-04 Thread Sebastian Krebs
Hi, Just realize, that this is _not_ the internals list. :X There I only read. Yes, I could send mails here :) We'll see My guess: The ecosystem has grown. Now much stuff, that were former (probably) asked here, is gone to more specific lists, like ZFs, Symfony, and so on. Maybe it's even already

Re: [PHP] Searching IDE.

2012-06-13 Thread Sebastian Krebs
Hi, 2012/6/13 David Arroyo > Hi Folks, > > I am searching an IDE for php and web development, my options are > Aptana or Eclipse+PDT. > What is your opinion? > PhpStorm > > Thanks. > Regards. > > -- > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php

Re: [PHP] Re: Function size

2012-05-30 Thread Sebastian Krebs
Hi, Just want to throw my 2 cent in :) 2012/5/30 Tony Marston > > "Ashley Sheridan" wrote in message > news:1338326229.2616.31.camel@localhost.localdomain... > > On Tue, 2012-05-29 at 17:06 -0400, Paul M Foster wrote: > > > >> On Tue, May 29, 2012 at 08:52:46AM +0100, Tony Marston wrote: > >>