jaytea commented on a Page, Custom Identifiers  -  Dec 05, 2011

Otherwise, how?

he means something to the effect of:

alias face {
  return $replace($1, eyes, ಠ_ಠ ,jsmile, ( ゚ヮ゚), teehee, ( ¬‿¬), etc,)
}

which is useful in case you want to be able to construct lines by using, for example, $face((eyes)_/ jsmile) = (ಠಠ)/ ( ゚ヮ゚) ... y'know, creating full pictures with combinations of faces and other characters :P

otherwise, the method has a rather obvious shortcoming in that it doesn't validate $1. $1 could equal 'poop' and the alias would just return it. or it could be 'teeheepoop' and the alias would return '( ¬‿¬)poop'. sometimes we can get away with this; other times it requires extra code and becomes slightly more cumbersome to manage.

i've never been a fan of this kind of work since it's basically just data without any real code but then again i know some people come here to see ascii art and such ;)

 Respond  
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.