{"id":205,"date":"2009-02-28T09:39:57","date_gmt":"2009-02-28T16:39:57","guid":{"rendered":"https:\/\/actionsnippet.com\/?p=870"},"modified":"2009-02-28T09:39:57","modified_gmt":"2009-02-28T16:39:57","slug":"stringlocalecompare","status":"publish","type":"post","link":"https:\/\/actionsnippet.com\/?p=205","title":{"rendered":"String.localeCompare()"},"content":{"rendered":"<pre class=\"brush: as3; title: ; notranslate\" title=\"\">\r\nvar letterA:String = &quot;a&quot;;\r\nvar letterZ:String = &quot;z&quot;;\r\n\r\ntrace(letterA.localeCompare(letterZ));\r\ntrace(letterZ.localeCompare(letterA));\r\n\/*\r\noutputs\r\n-25\r\n25\r\n*\/\r\n<\/pre>\n<p>String.localeCompare() calculates  the sorting order between two Strings&#8230;. <\/p>\n","protected":false},"excerpt":{"rendered":"<p>var letterA:String = &quot;a&quot;; var letterZ:String = &quot;z&quot;; trace(letterA.localeCompare(letterZ)); trace(letterZ.localeCompare(letterA)); \/* outputs -25 25 *\/ String.localeCompare() calculates the sorting order between two Strings&#8230;.<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[21],"tags":[3,4],"class_list":["post-205","post","type-post","status-publish","format-standard","hentry","category-strings","tag-actionscript","tag-flash"],"_links":{"self":[{"href":"https:\/\/actionsnippet.com\/index.php?rest_route=\/wp\/v2\/posts\/205","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/actionsnippet.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/actionsnippet.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/actionsnippet.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/actionsnippet.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=205"}],"version-history":[{"count":0,"href":"https:\/\/actionsnippet.com\/index.php?rest_route=\/wp\/v2\/posts\/205\/revisions"}],"wp:attachment":[{"href":"https:\/\/actionsnippet.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=205"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/actionsnippet.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=205"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/actionsnippet.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=205"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}