Posted By

Scooter on 05/19/08


Tagged

fun


Versions (?)

Finding your Star Wars name


 / Published in: PHP
 

URL: http://reusablecode.blogspot.com/2008/03/finding-your-star-wars-name.html

  1. <?php
  2. /*
  3.   Copyright (c) 2008, reusablecode.blogspot.com; some rights reserved.
  4.  
  5.   This work is licensed under the Creative Commons Attribution License. To view
  6.   a copy of this license, visit http://creativecommons.org/licenses/by/3.0/ or
  7.   send a letter to Creative Commons, 559 Nathan Abbott Way, Stanford, California
  8.   94305, USA.
  9.   */
  10.  
  11. function starwarsname($firstName, $lastName, $maidenName, $city)
  12. {
  13. return substr($firstName, 0, 3) . strtolower(substr($lastName, 0, 2)) . " " . substr($maidenName, 0, 2) . strtolower(substr($city, 0, 3));
  14. }
  15. ?>

Report this snippet  

You need to login to post a comment.