View Single Post
  #3  
Old 07-19-2011, 04:05 AM
fowlplay4 fowlplay4 is offline
team canada
fowlplay4's Avatar
Join Date: Jul 2004
Location: Canada
Posts: 5,200
fowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond reputefowlplay4 has a reputation beyond repute
You could use substring, but it's so much easier just to use:

extractfilebase(str) - Extracts the base file name from a string. I.e: levels/file.nw would return file.

Usage:

PHP Code:
function onCreated() {
  
temp.filename "fly.gani";
  
temp.gani extractfilebase(temp.filename);
  echo(
temp.gani); // echos: fly

__________________
Quote:
Reply With Quote