This forum is now read-only. Please use our new forums at

Functions, Part I Forum

View Course

281 points
Submitted by
over 2 years ago

functions part 1 2/8... what's wrong with my code?

I'm getting a flag "Oops, try again. Did you remember to print your name in UPPERCASE?"

Here's my code:

// Get a partial string from within your own name
// and print it to the screen!
$myname = "Lindsay";
$partial = substr($myname, 0, 2);
print $partial;

// Make your name upper case and print it to the screen:
$uppercase = strtoupper($myname);
print $uppercase;

// Make your name lower case and print it to the screen:
$lowercase = strtolower($uppercase);
print $lowercase;

0 votes


try with an echo, your code seems good

688 points
Submitted by
Juan Carlos Aragon
over 2 years ago