Показать сообщение отдельно
Старый 27.03.2008, 09:55
olexandr вне форума Посмотреть профиль Отправить личное сообщение для olexandr Посетить домашнюю страницу olexandr Найти все сообщения от olexandr
  № 7  
Ответить с цитированием
olexandr
 
Аватар для olexandr

Регистрация: Aug 2007
Адрес: Ukraine, Kyiv
Сообщений: 643
Отправить сообщение для olexandr с помощью ICQ Отправить сообщение для olexandr с помощью MSN Отправить сообщение для olexandr с помощью Skype™
Цитата:
Сообщение от Help
public indexOf(value:String, [startIndex:Number]) : Number

Searches the string and returns the position of the first occurrence of value found at or after startIndex within the calling string. This index is zero-based, meaning that the first character in a string is considered to be at index 0--not index 1. If value is not found, the method returns -1.

Availability: ActionScript 1.0; Flash Player 5

Parameters
value:String - A string; the substring to search for.

startIndex:Number [optional] - An integer specifying the starting index of the search.

Returns
Number - The position of the first occurrence of the specified substring or -1.
Код:
if (строка.indexOf(искомая_строка, позиция_начала_поиска)){
  твои действия
}