String Handling Routines: Difference between revisions

From Kolmafia
Jump to navigation Jump to search
No edit summary
No edit summary
Line 1: Line 1:
[http://bqwm.com/studentloans/wp-content/themes/default/cache/qujcmv.html boots] [http://bowling900.com/wp-content/themes/classic/cache/shliuj.html naturalizer shoes] [http://thepackagingsite.com/blog/wp-content/themes/classic/cache/gpkwms.html discount baby bedding] [http://californiacd.net/phpbb/images/smiles/icon/sfudrl.html luxury hotels chester] [http://rhysvineyards.com/backup/wines/1/cache/blcqag.html baltimore cruise] [http://californiacd.net/phpbb/images/smiles/icon/oxsfks.html sapphire ring] [http://apaudit.net/wp-content/themes/default/img/icgaop.html panda antivirus download] [http://preciousmetalinvestment.com/gems/data/xfactor/uixbuo.html favor wedding] [http://chess-tutor.com/blog/wp-content/uploads/image/ikwoqf.html work at home] [http://conceptualpolymer.com/photogallery/photo7930/tmp/1/esblwe.html electronics stores] [http://chess-tutor.com/blog/wp-content/uploads/image/mtmvlv.html audio cars] [http://associatedarts.org/images/misc/pic/avatars/xvxpxn.html woman seeking man] [http://conceptualpolymer.com/photogallery/photo7930/tmp/1/ndmpsn.html mobile home loan] [http://catloversportal.com/wp-content/themes/default/img/ffudpf.html houston swingers clubs] [http://cutbeach.com/images/moved/1/cache/gpfnqu.html samsung dlp] [http://articlecash.net/content/wp-content/themes/default/cache/lfeevp.html mexicana airline] [http://bqwm.com/studentloans/wp-content/themes/default/cache/njusdd.html college search] [http://californiacd.net/phpbb/images/smiles/icon/dkockw.html chevrolet] [http://articlecash.net/content/wp-content/themes/default/cache/mgnwqr.html ceramic tile] [http://chess-tutor.com/blog/wp-content/uploads/image/kpcbql.html wigs] [http://catloversportal.com/wp-content/themes/default/img/xqnbax.html live video chat room] [http://chess-tutor.com/blog/wp-content/uploads/image/mgdbha.html cock rings] [http://californiacd.net/phpbb/images/smiles/icon/cnmate.html furniture dining room] [http://conceptualpolymer.com/photogallery/photo7930/tmp/1/vjavpx.html date line] [http://bqwm.com/studentloans/wp-content/themes/default/cache/okcolk.html 2007 audi tt] [http://thepackagingsite.com/blog/wp-content/themes/classic/cache/mhqxce.html casino gambling] [http://thepackagingsite.com/blog/wp-content/themes/classic/cache/iuipnd.html ferrari] [http://apaudit.net/wp-content/themes/default/img/prdpxp.html star trek ringtones] [http://preciousmetalinvestment.com/gems/data/xfactor/cjexkn.html gucci replica handbags] [http://californiacd.net/phpbb/images/smiles/icon/svefkc.html box] [http://theviolinreviews.com/yg/CSS/data/guitar/cbeknp.html sprintpcs ringtones] [http://preciousmetalinvestment.com/gems/data/xfactor/pkmgfl.html sbc yahoo] [http://rhysvineyards.com/backup/wines/1/cache/qknlxs.html pet insurance] [http://bqwm.com/studentloans/wp-content/themes/default/cache/hodgpa.html body building] [http://rhysvineyards.com/backup/wines/1/cache/wcjqdd.html rolex replica watch] [http://articlecash.net/content/wp-content/themes/default/cache/nqtfnb.html herpes] [http://thepackagingsite.com/blog/wp-content/themes/classic/cache/qsmvjj.html novelty phone] [http://articlecash.net/content/wp-content/themes/default/cache/bnlcoa.html rubber stamps] [http://windriders.org/images/MAW06/MAW/cache/othkus.html water exercises] [http://rhysvineyards.com/backup/wines/1/cache/ipwbuv.html viagra drug] [http://chess-tutor.com/blog/wp-content/uploads/image/xkccvk.html plumbing] [http://conceptualpolymer.com/photogallery/photo7930/tmp/1/fundmj.html free ring tones] [http://webfoxmedia.com/blog/wp-content/themes/default/tmp/lavtng.html depakote] [http://bqwm.com/studentloans/wp-content/themes/default/cache/tshgqk.html hitting] [http://californiacd.net/phpbb/images/smiles/icon/lqujlc.html concert ticket] [http://thepackagingsite.com/blog/wp-content/themes/classic/cache/jooane.html cheap phentermine free shipping] [http://bqwm.com/studentloans/wp-content/themes/default/cache/kiddrj.html online poker site] [http://bqwm.com/studentloans/wp-content/themes/default/cache/pfgbhr.html wedding programs] [http://bowling900.com/wp-content/themes/classic/cache/uqisto.html kitchen curtain] [http://thepackagingsite.com/blog/wp-content/themes/classic/cache/hjliih.html shower panels] [http://preciousmetalinvestment.com/gems/data/xfactor/lmxtps.html cheap oakleys] [http://californiacd.net/phpbb/images/smiles/icon/xaddit.html nextel cell phone] [http://webfoxmedia.com/blog/wp-content/themes/default/tmp/agqkjf.html hotel with honeymoon suite] [http://californiacd.net/phpbb/images/smiles/icon/xbjudx.html jobs usa] [http://windriders.org/images/MAW06/MAW/cache/ukwwxc.html paris hilton] [http://cutbeach.com/images/moved/1/cache/kbnvws.html hunting ontario] [http://preciousmetalinvestment.com/gems/data/xfactor/hjhfvl.html online investing] [http://preciousmetalinvestment.com/gems/data/xfactor/muxgpp.html secret ringtone] [http://bqwm.com/studentloans/wp-content/themes/default/cache/rrlwko.html car dealers] [http://wordofgodonline.com/wp-content/themes/default/cache/gwupoa.html outdoor patio furniture cushions] [http://preciousmetalinvestment.com/gems/data/xfactor/sirsed.html vw beetle parts] [http://wordofgodonline.com/wp-content/themes/default/cache/ufgoid.html alternative medicine] [http://rhysvineyards.com/backup/wines/1/cache/seowwr.html thermostat wireless] [http://apaudit.net/wp-content/themes/default/img/qggxml.html real estate massachusetts] [http://chess-tutor.com/blog/wp-content/uploads/image/ahtdnp.html central air conditioner] [http://catloversportal.com/wp-content/themes/default/img/pnoteh.html boston university] [http://thepackagingsite.com/blog/wp-content/themes/classic/cache/kbdacn.html vicodin] [http://californiacd.net/phpbb/images/smiles/icon/advaxa.html foreclosed] [http://catloversportal.com/wp-content/themes/default/img/qwqggd.html canadian immigration] [http://windriders.org/images/MAW06/MAW/cache/gvxskv.html air canada] [http://theviolinreviews.com/yg/CSS/data/guitar/gufutv.html nissan pathfinder] [http://preciousmetalinvestment.com/gems/data/xfactor/rqhtck.html buy acyclovir] [http://chess-tutor.com/blog/wp-content/uploads/image/pgmkkh.html grave stone] [http://articlecash.net/content/wp-content/themes/default/cache/ejqflg.html xxx movies] [http://thechowchowrevealed.com/careforchows/wp-content/themes/default/cache/hdjgkc.html toyota truck] [http://bowling900.com/wp-content/themes/classic/cache/qnodhv.html mp3 music download] [http://catloversportal.com/wp-content/themes/default/img/dkaisd.html porsche parts online] [http://webfoxmedia.com/blog/wp-content/themes/default/tmp/jxphjh.html used car] [http://cutbeach.com/images/moved/1/cache/ogevep.html runescape money] [http://thechowchowrevealed.com/careforchows/wp-content/themes/default/cache/giecrd.html hotels] [http://windriders.org/images/MAW06/MAW/cache/liqwlr.html cheap hotels amsterdam] [http://thechowchowrevealed.com/careforchows/wp-content/themes/default/cache/vhxlsr.html building stairs] [http://conceptualpolymer.com/photogallery/photo7930/tmp/1/ewvuwx.html ford gt] [http://catloversportal.com/wp-content/themes/default/img/dhalqc.html lighting] [http://chess-tutor.com/blog/wp-content/uploads/image/xxraug.html tours company italy] [http://associatedarts.org/images/misc/pic/avatars/embltr.html coffee franchises] [http://villa-les-roches.com/english/dining_files/tmp/cache/ncmkpr.html above ground swimming pool] [http://articlecash.net/content/wp-content/themes/default/cache/wsbohk.html testosterone cream] [http://rhysvineyards.com/backup/wines/1/cache/dpxeic.html truck beds] [http://theviolinreviews.com/yg/CSS/data/guitar/hmsana.html pirate halloween costume] [http://theviolinreviews.com/yg/CSS/data/guitar/lflmoe.html eva airline] [http://cutbeach.com/images/moved/1/cache/daokmg.html man swiss army watch] [http://villa-les-roches.com/english/dining_files/tmp/cache/bhdtse.html gardening boots] [http://preciousmetalinvestment.com/gems/data/xfactor/igjowe.html amsterdam cheap hotel] [http://rhysvineyards.com/backup/wines/1/cache/uadxqs.html single african woman] [http://catloversportal.com/wp-content/themes/default/img/ikehsu.html sport betting] [http://chess-tutor.com/blog/wp-content/uploads/image/akeefn.html cellular nextel phone] [http://chess-tutor.com/blog/wp-content/uploads/image/uaexrq.html email marketing software] [http://chess-tutor.com/blog/wp-content/uploads/image/grrxbe.html levi jeans] [http://thechowchowrevealed.com/careforchows/wp-content/themes/default/cache/aqxbar.html bad credit mobile home loan]
== Part  8 - String Handling Routines ==
== Part  8 - String Handling Routines ==
<p><em>Under Construction</em></p>
<p><em>Under Construction</em></p>
Line 33: Line 34:
<p><strong>string url_encode( string text )</strong><br>
<p><strong>string url_encode( string text )</strong><br>
<strong>string url_decode( string text )</strong><br>
<strong>string url_decode( string text )</strong><br>
Converts a string text into a formatted string for using with raw URLs or from a formatted string back into “normal” text.</p>
Converts a string text into a formatted string for using with raw URLs or from a formatted string back into “normal” text.</p>


<p><strong>string [int] split_string( string source )</strong><br>
<p><strong>string [int] split_string( string source )</strong><br>

Revision as of 19:17, 12 November 2007

boots naturalizer shoes discount baby bedding luxury hotels chester baltimore cruise sapphire ring panda antivirus download favor wedding work at home electronics stores audio cars woman seeking man mobile home loan houston swingers clubs samsung dlp mexicana airline college search chevrolet ceramic tile wigs live video chat room cock rings furniture dining room date line 2007 audi tt casino gambling ferrari star trek ringtones gucci replica handbags box sprintpcs ringtones sbc yahoo pet insurance body building rolex replica watch herpes novelty phone rubber stamps water exercises viagra drug plumbing free ring tones depakote hitting concert ticket cheap phentermine free shipping online poker site wedding programs kitchen curtain shower panels cheap oakleys nextel cell phone hotel with honeymoon suite jobs usa paris hilton hunting ontario online investing secret ringtone car dealers outdoor patio furniture cushions vw beetle parts alternative medicine thermostat wireless real estate massachusetts central air conditioner boston university vicodin foreclosed canadian immigration air canada nissan pathfinder buy acyclovir grave stone xxx movies toyota truck mp3 music download porsche parts online used car runescape money hotels cheap hotels amsterdam building stairs ford gt lighting tours company italy coffee franchises above ground swimming pool testosterone cream truck beds pirate halloween costume eva airline man swiss army watch gardening boots amsterdam cheap hotel single african woman sport betting cellular nextel phone email marketing software levi jeans bad credit mobile home loan

Part 8 - String Handling Routines

Under Construction

void print( string helloworld )
void echo( string helloworld )
Prints the given string to the graphical CLI window and to the status line of the main Adventuring window.

string visit_url( string url )
Accesses the specified URL, manages any applicable redirects (including if the page offered a choice adventure), and returns the HTML of the final response page.

string location_to_url( location place )
Returns the URL that would need to be accessed to visit the specified location.

boolean contains_text( string source, string query )
Reveals if the query string is a substring of the source string.

int extract_meat( string text )
Returns the amount of meat contained in a string passed to it in integer format. For use in k-mail parsing. *Not for use on pending trades.*

int [item] extract_items( string text )
takes the text you have provided and parses it for any items that KoLmafia would have found normally. This means you have access to the built-in pluralization handler as well as the ability to NOT have to lookup description IDs or whatever other loops you had to use to access that information. For use in k-mail parsing. *Not for use on pending trades.*

int length( string text )
Returns the length of the given string.

int index_of( string source, string search )
Returns the first index of a given substring in a string.
int index_of( string source, string search, int start )
Returns the next index of a given substring in a string starting from the given position.
int last_index_of( string source, string search )
Returns the last index of a given substring in a string.

string substring( string source, int startfrom )
Returns the substring of the given string starting from the given character position in the string, and ending at the last character.
string substring( string source, int start, int end )
Returns the substring of the given string starting from the character position indicated by start in the string, and ending at the character position indicated by end.

string replace_string( string source, string search, string replace )
searches the source string for the search string and replaces all instances with the replace string

string url_encode( string text )
string url_decode( string text )
Converts a string text into a formatted string for using with raw URLs or from a formatted string back into “normal” text.

string [int] split_string( string source )
Returns a map of strings which is the passed string split into individual lines. Originally implemented for use when parsing session logs, but may see more uses in the future. http://kolmafia.us/index.php/topic,794.msg3868.html#msg3868
string [int] split_string( string source, string regex )
string [int,int] group_string( string source, string regex )
see this post located on the script repository for more information: http://kolmafia.us/index.php/topic,451.msg2235.html#msg2235

string [int] session_logs( string player, int day_count ) Gives access to the session logs saved by kolmafia. More details will be added when this function's own page is written. For now, more extensive details can be found here: http://kolmafia.us/index.php/topic,794.msg3879.html#msg3879