need help with visiting urls

xxmatt3232xx

New member
my only experience scripting in mafia is with very basic farming scripts. im trying to figure out visiting urls, to kind of test this i made a simple ash script to visit the council to see if there are no more quests for me to do
Code:
void main()
{
	if(substring(visit_url("council.php"),string_start,string_end)=="Unfortunately")
	{
	cli_execute("print nothing to do");
	}
}
note: string_start and string_end are not variables i will be using in the script

now what im unsure of is how to count the starting and ending string values, i went to the relay browser and saved council.php and opened it in notepad ++ and from there i got nothing.

is there a way i can just search the entire string for the word "Unfortunately" or do i have to have a starting and ending point?

ive been looking at a few other scripts on here and they are helpful, and i looked at the advanced scripting tutorial and the ASH reference thing so this is the last place to turn.

thanks for any help
 

jasonharper

Developer
contains_text() is what you're looking for - first parameter is the full string, second is the substring to be searched for.
 
Top