Thread: Insert()?
View Single Post
  #2  
Old 05-23-2007, 12:14 AM
Inverness Inverness is offline
Incubator
Inverness's Avatar
Join Date: Aug 2004
Location: Houston, Texas
Posts: 3,613
Inverness is a jewel in the roughInverness is a jewel in the rough
Quote:
Originally Posted by Wiki
obj.replace(index,obj2)
obj.insert(index,obj2)
...
Indexes start at zero.
PHP Code:
public function addPlayerNotification(msg) {
  
client.messages.insert(0msg);
  if (
client.messages.size() > 5) {
    
client.messages.delete(5);
  }

__________________

Last edited by Inverness; 05-23-2007 at 12:36 AM..
Reply With Quote