News Feed
Sections




News Archive
feed this:

Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

Alex Inführ:
PHP non alpha numeric 7 and 6 char code
December 17, 2012 @ 09:32:02

Following along with the non-alpha PHP code that Gareth Heyes recently posted about, Alex Inführ has created some of his own using only dollar signs, underscores, equals, plus and parentheses.

I used the following charset: $_=+(); As you can see only 7 chars. In the end the function log will be created,because this won't exceed the memory limit. In the beginning I created the php function assert and it was 99 mb large php file, way too big to get executed.

He uses a few tricks to get the language to create strings (counting to infinity), changing the letters in the resulting string, He includes the steps in the process and a large block of the non-alpha PHP code at the end of the post, a 46KByte block that echoes "log(12)".

0 comments voice your opinion now!
nonalpha code characters six seven tutorial


Gareth Heyes:
Tweetable PHP-Non Alpha
December 13, 2012 @ 09:40:25

Gareth Heyes has a new post that shares some of his efforts to write "non-alpha PHP", using characters other than the alpha-numeric ones to write executable PHP scripts. In his case, this involves a lot of pluses, underscores and square brackets.

I started to try and break the 10 charset limit of PHP non-alpha after @InsertScript showed me that PHP Dev supports [] syntax for arrays. I wondered if it would be possible to break the limit within production PHP. At first I thought you could but then after some testing I found that there was no way to concat without "." and no way to call a string as a function without $ and =. However since I got into PHP Non-alpha again I thought why not try and improve it and make the code tweetable.

He works through the whole process of his discovery - starting with the creation of a non-alpha version of "0" (zero), moving into letter creation and finally all the way up to a full word..."assert". The result is tweetable code that echoes that string and contains more symbols than letters. If you're interested in more of this non-alpha kind of coding, check out some of the other posts on his blog.

0 comments voice your opinion now!
nonalpha code tweet plus underscore squarebracket


Gareth Heyes:
PHP nonalpha tutorial
August 22, 2012 @ 08:53:02

Gareth Heyes has another post to his site on the topic of "non-alpha PHP code", this time getting a bit more into the process and how his examples are parsed by PHP into more familiar functionality.

My first post on PHP non-alpha numeric code was a bit brief, in the excitement of the discovery I failed to detail in depth the process. I've decided to follow up with a tutorial and hopefully explain the process better for anyone wanting to learn or improve the technique. The basis of PHP non-alphanumeric code is to take advantage of the fact that PHP automatically converts Arrays into a string "Array" when using in a string context.

He includes some basic examples showing how, with just a combination of things like "+", "_" and "[" or "]" you can reproduce similar output to echoing out an array and use that "Array" output string to get to other strings (like the letter "B"). There's also a more lengthy example showing how to build up the string "print 1+1" and have it execute using this technique.

0 comments voice your opinion now!
interpretation nonalpha tutorial special character



Community Events





Don't see your event here?
Let us know!


language version application library release laravel opinion voicesoftheelephpant community composer update framework interview package symfony series security introduction podcast tool

All content copyright, 2014 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework