'From etoys4.0 of 9 October 2008 [latest update: #2278] on 8 September 2009 at 4:00:27 pm'! "Change Set: localizedCats-sw Date: 8 September 2009 Author: Scott Wallace Obtain language-specific category-lists from the web site where possible."! !EToyProjectDetailsMorph class methodsFor: 'classification information' stamp: 'sw 9/8/2009 16:00'! updateTripletsFromWebSite "Attempt to update the age-range, subject, and region triplets stored in the image by referring to the latest versions on the web site." | url result suffix | suffix := '?lang=', Locale current localeID printString. url := 'http://squeakland.org/subjectCatList', suffix. [result := (self linesIn: (((HTTPSocket httpGet: url args: #() user: '' passwd: '')) contents copyReplaceAll: String lf with: String cr)) collect: [:l | self csvLineQuotedDecodedFor: l]] on: Error do: [:ex | ^ self]. (result isNil or: [result size < 2]) ifTrue: [^ self]. SubjectTriplets := result. url := 'http://squeakland.org/ageCatList', suffix. [result := (self linesIn: (((HTTPSocket httpGet: url args: #() user: '' passwd: '')) contents copyReplaceAll: String lf with: String cr)) collect: [:l | self csvLineQuotedDecodedFor: l]] on: Error do: [:ex | ^ self]. (result isNil or: [result size < 2]) ifTrue: [^ self]. AgeTriplets := result. url := 'http://squeakland.org/regionCatList', suffix. [result := (self linesIn: (((HTTPSocket httpGet: url args: #() user: '' passwd: '')) contents copyReplaceAll: String lf with: String cr)) collect: [:l | self csvLineQuotedDecodedFor: l]] on: Error do: [:ex | ^ self]. (result isNil or: [result size < 2]) ifTrue: [^ self]. RegionTriplets := result " EToyProjectDetailsMorph updateTripletsFromWebSite "! !