Re: [PHP] Fwd: Is it possible???

2013-06-24 Thread Marco Behnke
*function* when you can also use the echo language construct (better and faster). But read and learn http://de2.php.net/manual/en/function.print.php print is not actually a real function (it is a language construct) -- Marco Behnke Dipl. Informatiker (FH), SAE Audio Engineer Zend Certified Engine

Re: [PHP] Having a problem with clone.

2013-05-11 Thread Marco Behnke
ost -- Marco Behnke Dipl. Informatiker (FH), SAE Audio Engineer Diploma Zend Certified Engineer PHP 5.3 Tel.: 0174 / 9722336 e-Mail: ma...@behnke.biz Softwaretechnik Behnke Heinrich-Heine-Str. 7D 21218 Seevetal http://www.behnke.biz signature.asc Description: OpenPGP digital signature

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

2013-05-03 Thread Marco Behnke
Am 03.05.2013 21:34, schrieb 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 m

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

2013-05-03 Thread Marco Behnke
7; => 'raw', >>>>>'output-encoding' => 'raw', >>>>>'newline' => 'LF', >>>>>'tidy-mark' => false, >>>>>'quiet' => true, >>

Re: [PHP] A little confused

2013-04-23 Thread Marco Behnke
.php.net/manual/en/datetime.createfromformat.php Or try this http://de3.php.net/manual/en/function.strtotime.php $_SESSION['ExpiryDate'] = "2013-04-23"; $int_timestamp = strtotime($_SESSION['ExpiryDate']); echo date('D, \t\h\e jS \o\f M Y', $int_timestamp ); Use SINGLE QUO

Re: [PHP] self operator within a double quoted string

2013-04-17 Thread Marco Behnke
efix_{$this->object_prop}_postfix" . PHP_EOL; >> } >> } >> >> >> $foo = new Foo; >> $foo->printObjectProp(); >> >> >> Foo::printClassProp(); >> >> > Hi, > > This is a bug/feature in php and is just not possible.

Re: [PHP] Lasting syntax error when there's none

2013-04-09 Thread Marco Behnke
I - OS: Ubuntu 12.04 - Software: Ubuntu packages only (updated) - HTTP request handling: nginx load balancer → PHP FPM daemon - Machine: VMware Fusion (managed by Vagrant) hosted on OS X 10.8.3 Thanks, -- Marco Behnke Dipl. Informatiker (FH), SAE Audio Engineer Zend Certified Engineer PHP 5.3

Re: [PHP] Session variable not persisting

2013-03-18 Thread Marco Behnke
x27;in'])<1000){ > $rand = rand(0, 100); > ?> > > } else { > var_dump($_SESSION); > } > > ?> > > ## > > In fact, when I run this on my server I randomly have empty entries in the >

Re: [PHP] mysql custom global defined variable

2013-03-13 Thread Marco Behnke
tages of using constants (which ever) are code completion to avoid spelling errors. I see no possible improvements here. > 2. In the mysql itself, does mysql also has global define functionality (like > the define in php) ? I also want to do kind of SELECT * FROM house WHERE type > = HOUS

Re: [PHP] Re: Generating CRUD code for normalized db

2013-03-13 Thread Marco Behnke
" Yii in a way, that creating models and views with Gii get proper SELECT Boxes and stuff for relations? If I understood you correct, this is what you were looking for? -- Marco Behnke Dipl. Informatiker (FH), SAE Audio Engineer Diploma Zend Certified Engineer PHP 5.3 Tel.: 0174 / 9722336 e-M

Re: [PHP] Mystery foreach error

2013-03-12 Thread Marco Behnke
tches faulty > input and warns people in their browser to go back and re-enter the correct > data, so I'm at a loss as to why this is happening. > > How can I see what's triggering this to happen? I have the following > line in my php.ini: > > error_reporting

Re: [PHP] OOP to run sequential SQL queries?

2013-02-17 Thread Marco Behnke
4/10/who-needs-stored-procedures-anyways.html > > Now we're going to carry on in PHP, and my experience says that > we should write the solution in a procedural-style, instead of OOP. > > Is there any benefit to use OOP in these situations? > > Please share your thoughts.

Re: [PHP] APC opcode cache behavior

2013-02-14 Thread Marco Behnke
gt; php -r "apc_clear_cache();"). This way you'll avoid restarting the webserver > and it will clear all APC cache forcing APC to cache everything again. since apache and cli do not share the same apc, it will not work. -- Marco Behnke Dipl. Informatiker (FH), SAE Audio Engineer Diplom

Re: [PHP] Rewrite Help

2012-12-28 Thread Marco Behnke
On 28.12.2012 17:13, Floyd Resler wrote: On Dec 28, 2012, at 11:09 AM, Marco Behnke wrote: On 28.12.2012 16:30, Floyd Resler wrote: I'm having a perplexing problem with a rewrite rule (it's off topic but it's Friday!). My initial path is piccDetails/index/0/linetypes/201

Re: [PHP] Rewrite Help

2012-12-28 Thread Marco Behnke
On 28.12.2012 16:30, Floyd Resler wrote: I'm having a perplexing problem with a rewrite rule (it's off topic but it's Friday!). My initial path is piccDetails/index/0/linetypes/2012-01-01/2012-12-31/Successful and that works great. However, in my script I want to change the zero in the path

Re: [PHP] Session ?

2012-12-13 Thread Marco Behnke
x27;, >> 'On')? >> Just to be sure that there are no hidden notices or warnings. >> >> > my sub points to a folder within my domain's structure. My session's > store point (?) is \tmp. You asked two different questions. > point taken ;) I will

Re: [PHP] Session ?

2012-12-12 Thread Marco Behnke
Am 12.12.12 15:58, schrieb Jim Giner: > On 12/12/2012 8:08 AM, ma...@behnke.biz wrote: >> >> >> Jim Giner hat am 12. Dezember 2012 um >> 02:53 >> geschrieben: >>> On 12/11/2012 7:27 PM, Marco Behnke wrote: >>>> Am 08.12.12 19:08, schrieb Jim G

Re: [PHP] Session ?

2012-12-11 Thread Marco Behnke
n data is stored? (session_save_path)? -- Marco Behnke Dipl. Informatiker (FH), SAE Audio Engineer Diploma Zend Certified Engineer PHP 5.3 Tel.: 0174 / 9722336 e-Mail: ma...@behnke.biz Softwaretechnik Behnke Heinrich-Heine-Str. 7D 21218 Seevetal http://www.behnke.biz signature.asc Description:

Re: [PHP] Storing passwords in session variables

2012-12-11 Thread Marco Behnke
.http-auth.php -- Marco Behnke Dipl. Informatiker (FH), SAE Audio Engineer Zend Certified Engineer PHP 5.3 Tel.: 0174 / 9722336 e-Mail: ma...@behnke.biz Softwaretechnik Behnke Heinrich-Heine-Str. 7D 21218 Seevetal http://www.behnke.biz smime.p7s Description: S/MIME Kryptografische Unterschrift

Re: [PHP] Question

2012-11-03 Thread Marco Behnke
.4.8# ls /usr/local/bin > php-config phpize > > root:/usr/local/src/php-5.4.8# ls /usr/local/sbin > php-fpm > > Must under bin not be php-cgi and pear, or is my thinking wrong? maybe because of --disable-cgi > > > Thank you for help and Greetings > Silvio > -- Ma

Re: [PHP] TURBOPY cloud framework + IDE beta available NOW

2012-10-31 Thread Marco Behnke
t topic: http://stackoverflow.com/questions/1185605/when-to-use-static-vs-instantiated-classes -- Marco Behnke Dipl. Informatiker (FH), SAE Audio Engineer Diploma Zend Certified Engineer PHP 5.3 Tel.: 0174 / 9722336 e-Mail: ma...@behnke.biz Softwaretechnik Behnke Heinrich-Heine-Str. 7D 21218

Re: [PHP] TURBOPY cloud framework + IDE beta available NOW

2012-10-31 Thread Marco Behnke
he only way. Even > Rasmus has said he leans procedurally: > http://toys.lerdorf.com/archives/38-The-no-framework-PHP-MVC-framework.html Are you serious quoting that post? Posted by Rasmus <http://toys.lerdorf.com/authors/1-Rasmus> on Monday, February 27. 2006 > > Adam > -- M

Re: [PHP] Rest

2012-10-27 Thread Marco Behnke
t; Let us see what you have done so far towards your goal, so we can discuss on how we can improve it. -- Marco Behnke Dipl. Informatiker (FH), SAE Audio Engineer Diploma Zend Certified Engineer PHP 5.3 Tel.: 0174 / 9722336 e-Mail: ma...@behnke.biz Softwaretechnik Behnke Heinrich-Heine-Str. 7D 21

Re: [PHP] TURBOPY cloud framework + IDE beta available NOW

2012-10-27 Thread Marco Behnke
And why PHP 5.2? And I am curious if you have developed a real templating engine or if you are going by eval()? From what I see, it looks a bit like that. But these are only my points. I browsed the pages, had no insight on the code. But I like your concept on the in place editing, that look

Re: [PHP] Differences

2012-10-04 Thread Marco Behnke
Am 04.10.12 02:48, schrieb David McGlone: > Hi everyone, I have been playing around with some code the list helped me > with > a while back and I'm not grasping the concept between return and echo and the > PHP manual doesn't answer this, unless I'm missing something. There is an > example at t

Re: RES: [PHP] fets() escaping some characters

2012-09-11 Thread Marco Behnke
hat string into a variable and outputting but it still doesn't show > the characters between the "<>". > > Any help is highly appreciated. > > Thanks > > -- > Best Regards, > Sunil Meena > > -- Marco Behnke Dipl. Informatiker (FH), SAE

Re: [PHP] How do I do count the occurrence of each word?

2012-08-18 Thread Marco Behnke
C822 is a word or not > (mixed letters and numbers). > > When you've arranged all that, splitting on white space is trivial: > > $words = preg_split('/[[:space:]]+/',$text); > > and then you just run through the words building an associative array > by increm

Re: [PHP] PHP session variables

2012-08-12 Thread Marco Behnke
ll session_write_close() as early as possible to avoid write locks on the users session file. And up from PHP 5.4 you can use http://de2.php.net/manual/de/function.session-status.php to check a session status. -- Marco Behnke Dipl. Informatiker (FH), SAE Audio Engineer Diploma Zend Cert

Re: [PHP] php safe mode no more?

2012-08-04 Thread Marco Behnke
ver setup for PHP appliactions is done with nginx + php-fpm. It is faster and uses less memory. -- Marco Behnke Dipl. Informatiker (FH), SAE Audio Engineer Diploma Zend Certified Engineer PHP 5.3 Tel.: 0174 / 9722336 e-Mail: ma...@behnke.biz Softwaretechnik Behnke Heinrich-Heine-Str. 7D 21218

Re: [PHP] PDO: extend or encapsulate?

2012-07-14 Thread Marco Behnke
n extend from it. If you simply extend PDO to use the PDO methods and add your own stuff, then inheritance is a bad idea. If you think of what you are doing here: You USE Pdo. So it is a component. This way you get the following benefits: - You can extend your class in your system from another cla

Re: [PHP] Exception Handling

2012-06-01 Thread Marco Behnke
ed. Also, can you throw classes > that don't extend Exception? It was always my understanding that > doing so would cause a fatal error. Ah, I guess that is the problem. Your application framework uses namespaces. I guess you should try catch (\Exception $e) instead of catch (Excepti

Re: [PHP] PHP & Database Problems -- Code Snippets - Any more Ideas?

2012-05-04 Thread Marco Behnke
to a query. ?> ?> Double closing tag? echo " $_GLOBALS[mdr] \n"; Quotes. $flag = 1; What's this? You really really should seperate your code from HTML. Please truncate your apache and php error log. Add error_reporting(E_ALL); ini_set('display_errors', &

Re: [PHP] PHP Mailto() - Google now displaying HTML as Plain Text

2012-05-01 Thread Marco Behnke
with my script?? $message .= "Message: ".$m.""; As far as I can see your main html tags are missing? $message = '' . $message . ''; -- Marco Behnke Dipl. Informatiker (FH), SAE Audio Engineer Zend Certified Engineer PHP 5.3 Tel.: 0174 / 9722336 e-Mail:

Re: [PHP] SimpleXML and the Single String (SOLVED)

2012-02-22 Thread Marco Behnke
ion class? > To keep the code readable? $value = $xml->node; vs. $value = (String)$xml->node; I like the first one. Plus you handle it to dynamically to the right type function __get($value) { if is float return float casted value if is boolean ... and so on } -- Marco Behnke D

Re: [PHP] Wrong POSTFIELDS Posted

2012-02-17 Thread Marco Behnke
ess that I use an integer. All > other curl* commands are set. > > > Maybe you could provide a bit more of information. var_dump($_POST); // at the beginning of the script // the code that assembles $string // the target url for your curl request from curl_init or CURLOPT // the o

Re: [PHP] Turning a string into a condition

2012-02-16 Thread Marco Behnke
ile maintaning the flexibility, I'd be happy > to hear it. Marc Is math all you want to use? Parsing will be an easy doing and I am pretty sure there are a lot of examples around the web. E.g.: http://www.phpclasses.org/package/2695-PHP-Safely-evaluate-mathematical-expressions.htm

Re: [PHP] handle file_get_contents timeout including dns lookup time

2012-02-14 Thread Marco Behnke
t think this is possible with file_get_contents, but it should > work if you use cURL and set the CURLOPT_CONNECTTIMEOUT option. > > - Matijn That won't help. When you reach the sleep with your request, the connection is already established. What you want is curl with CURLOPT_T

Re: [PHP] Re: Long Live GOTO

2012-02-06 Thread Marco Behnke
Am 06.02.12 21:55, schrieb Adam Richardson: > On Mon, Feb 6, 2012 at 3:44 PM, Marco Behnke wrote: > >> Am 06.02.12 17:23, schrieb Alain Williams: >> >> many places to see if things should be done. That is just as bad as >> lots of GOTO -- often when having to wr

Re: [PHP] Re: Long Live GOTO

2012-02-06 Thread Marco Behnke
e where some $IsError variable is tested in > many places to see if things should be done. That is just as bad as > lots of GOTO -- often when having to write something like that I will > have a GOTO (in Good code uses Exceptions and try catch for that kind of scenarios. -- Marco Behnke D

Re: [PHP] Typecasting question

2012-02-03 Thread Marco Behnke
x27; => OPENSSL_KEYTYPE_RSA, > 'digest_algorithm' => 'sha256', > 'private_key_bits' => 512, > 'x509_extensions'=> 'usr_cert', > 'encrypt_key_cipher' => 'OPENSSL_CIPHER_3DES'

Re: [PHP] Autoloading

2012-02-01 Thread Marco Behnke
if (file_exists($path)) { require_once $path; } }; spl_autoload_register($callback); -- Marco Behnke Dipl. Informatiker (FH), SAE Audio Engineer Zend Certified Engineer PHP 5.3 Tel.: 0174 / 9722336 e-Mail: ma...@behnke.biz Softwaretechnik Behnke Heinrich-Heine-Str.

Re: [PHP] passing variables to php script

2012-01-10 Thread Marco Behnke
r context? That would > make posting a form pretty pointless. Indeed. But isn't that the point? We are trying to figure out why his posting the form does not work. I say, it can't work as long as long as there is Q:\ ins his form action, no way it will do, because you leave your webserver

Re: [PHP] passing variables to php script

2012-01-10 Thread Marco Behnke
Am 10.01.12 21:28, schrieb Mike Mackintosh: > > On Jan 10, 2012, at 15:12, Marco Behnke wrote: > >> Am 10.01.12 21:07, schrieb Donovan Brooke: >>> David Savage wrote: >>>> OK...I admit I'm new at thisI have this html file: >>>> >>

Re: [PHP] passing variables to php script

2012-01-10 Thread Marco Behnke
action to simply "callrecs.php" and see if that works. -- Marco Behnke Dipl. Informatiker (FH), SAE Audio Engineer Diploma Zend Certified Engineer PHP 5.3 Tel.: 0174 / 9722336 e-Mail: ma...@behnke.biz Softwaretechnik Behnke Heinrich-Heine-Str. 7D 21218 Seevetal http://www.behnke.biz smime.p7s Description: S/MIME Kryptografische Unterschrift

Re: [PHP] re: More Error Reporting Problems

2012-01-02 Thread Marco Behnke
Am 30.12.2011 17:11, schrieb Floyd Resler: On Dec 30, 2011, at 11:05 AM, Matt Graham wrote: I'm still not sure why they aren't displaying. But as long as I have a place to find them I'm cool with that. Maybe anything in your web application overrides display_errors? -- Ma