Jump to content


Staff Alumni
  • Content Count

  • Joined

  • Last visited


Community Reputation

2 Neutral

About redbullmarky

  • Rank
    Prolific Member
  • Birthday 01/16/1980

Profile Information

  • Gender
  • Location
    Bedfordshire, England
  1. redbullmarky

    FTP Programs

    ...shouldnt really be using an FTP program or building websites anyway
  2. redbullmarky


    an excellent read if you're looking for recommendations for Rails-inspired PHP frameworks: http://www.h3rald.com/articles/view/rails-inspired-php-frameworks/
  3. lol an "Insult" generator and a person that eats animals and chucks up - beats "Hello World" any day
  4. oops. this line: $verbs = array('dislikes', 'sits on', 'licks', 'sucks', 'looks like', 'does', 'discusses the pros and cons of Web 2.0', 'loves', 'caresses', 'slides onto', 'hates', 'kisses', 'learns PHP with', 'has an AJAX interface with'); should be 'discusses the pros and cons of Web 2.0 with'
  5. dirty little sod, aint he?! BTW, can we standardise spaces/tabs? when it gets really tempting to try this out in our fave text editor, it doesnt always work for some reason unless the tabs/spaces are deleted+replaced. no idea why...
  6. <?php $relatives = array('mother', 'father', 'sister', 'brother','uncle', 'auntie'); $verbs = array('dislikes', 'sits on', 'licks', 'sucks', 'looks like', 'does', 'discusses the pros and cons of Web 2.0', 'loves', 'caresses', 'slides onto', 'hates', 'kisses', 'learns PHP with', 'has an AJAX interface with'); $animals = array('dogs', 'cats', 'horses', 'birds', 'giraffes', 'elephants', 'hippos', 'hamsters', 'gerbils', 'monkeys'); function insult($secondary_person) { global $relatives; global $verbs; global $animals; $r_size = sizeof($relatives) - 1; $v_size = sizeof($verbs) - 1; $a_size = sizeof($animals) - 1; $r_rand = rand(0, $r_size); $v_rand1 = rand(0, $v_size); $v_rand2 = rand(0, $v_size); $a_rand = rand(0, $a_size); $insult = "Your {$relatives[$r_rand]} {$verbs[$v_rand1]} $secondary_person and {$verbs[$v_rand1]} {$animals[$a_rand]}"; return $insult; } class Greeting { function Greeting() { echo "Hello World!"; } } interface Actor { public function speak(); public function meet($person); } class Franky implements Actor { private $person; public function meet($person){ $this->person = $person; } public function speak($insult_them = false){ if($this->person == null){ $greet = new Greeting(); echo '<br />'; } else { echo 'Hello '.$this->person.'!<br />'; if ($insult_them) { echo insult($this->person) . '<br />'; } } } } $h = new Franky; $h->speak(); $h->meet('Jesus'); $h->speak(true); ?> edit: i am not responsible for the output of this sample program. if you find it offends, then blame PHP, not me. everything in the above code is clean, non-offensive English.
  7. <?php class Greeting { function Greeting() { echo "Hello World!"; } } $greet = new Greeting(); ?>
  8. redbullmarky


    I'd like to suggest this article from Sitepoint (original version here) as it was the first to properly open my eyes to PHP-based template "engines" and how easy it is to make a lightweight template class using PHP as its native syntax. For those a bit baffled by Smarty and suchlike, with the new set of syntax they introduce, the article is perfect. Cheers Mark
  9. redbullmarky

    Good Programming and Web Design Books

    i like to add 'PHP and MySQL Web Development' by Luke Welling and Laura Thomson to the list of recommendations. It's not lame, neither is it hardcore, but it teaches you things from simple 'Hello World' scripts right through to developing content management systems, email programs, etc. It's pretty much written in 'English' speak too, not programmers speak, so people of all levels will easily find it useful.

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.