Skip to content

Instantly share code, notes, and snippets.

@alexzhan
Created July 31, 2013 08:06
Show Gist options
  • Save alexzhan/6120209 to your computer and use it in GitHub Desktop.
Save alexzhan/6120209 to your computer and use it in GitHub Desktop.
<?php
class Foo {
function myFoo() {
return $this->myBar();
}
function myBar() {
return "Foo";
}
}
class Bar extends Foo {
function myBar() {
return "Bar";
}
}
$foo = new Foo;
echo($bar->myFoo()); //Bar
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment