document.write("<div class=\"pastie\">\n");
document.write("  <link href=\"http://pastie.org/stylesheets/embed.css\" media=\"screen\" rel=\"stylesheet\" type=\"text/css\" />\n");
document.write("  <link href=\"http://pastie.org/stylesheets/clean.css\" media=\"screen\" rel=\"stylesheet\" type=\"text/css\" />\n");
document.write("  \n");
document.write("\n");
document.write("  \n");
document.write("  \n");
document.write("\n");
document.write("\n");
document.write("<h2>Common Code <\/h2>\n");
document.write("\n");
document.write("\n");
document.write("\n");
document.write("\n");
document.write("	\n");
document.write("	<div class=\"allcode\">\n");
document.write("		<table cellpadding=\"0\" cellspacing=\"0\" border=\"0\">\n");
document.write("		<tr>\n");
document.write("			<td>\n");
document.write("				\n");
document.write("				<pre class=\"textmate-source-numbers\">1\n");
document.write("2\n");
document.write("3\n");
document.write("4\n");
document.write("5\n");
document.write("6\n");
document.write("7\n");
document.write("8\n");
document.write("9\n");
document.write("10\n");
document.write("11\n");
document.write("12\n");
document.write("13\n");
document.write("14\n");
document.write("15\n");
document.write("16\n");
document.write("17\n");
document.write("18\n");
document.write("19\n");
document.write("20\n");
document.write("21\n");
document.write("22\n");
document.write("23\n");
document.write("24\n");
document.write("25\n");
document.write("26\n");
document.write("27\n");
document.write("28\n");
document.write("29\n");
document.write("30\n");
document.write("31\n");
document.write("32\n");
document.write("33\n");
document.write("34\n");
document.write("35\n");
document.write("<\/pre>\n");
document.write("			<\/td>\n");
document.write("		<td>\n");
document.write("		<pre class=\"textmate-source\"><pre class=\"sunburst\"><span class=\'source source_php source_php_embedded source_php_embedded_block source_php_embedded_block_html\'>&lt;?php\n");
document.write("\n");
document.write("<span class=\'comment comment_block comment_block_documentation comment_block_documentation_phpdoc comment_block_documentation_phpdoc_php\'>/**<\/span>\n");
document.write("<span class=\"Comment\"> * This class represents a Country<\/span>\n");
document.write("<span class=\"Comment\"> */<\/span>\n");
document.write("<span class=\'meta meta_class meta_class_php\'><span class=\'storage storage_type storage_type_class storage_type_class_php\'>class<\/span> <span class=\'entity entity_name entity_name_type entity_name_type_class entity_name_type_class_php\'>Country<\/span><\/span>\n");
document.write("{\n");
document.write("    <span class=\'storage storage_modifier storage_modifier_php\'>public<\/span> <span class=\'variable variable_other variable_other_php\'>$iso<\/span> <span class=\'keyword keyword_operator keyword_operator_assignment keyword_operator_assignment_php\'>=<\/span> <span class=\'constant constant_language constant_language_php\'>NULL<\/span>;\n");
document.write("    <span class=\'storage storage_modifier storage_modifier_php\'>public<\/span> <span class=\'variable variable_other variable_other_php\'>$defaultLanguage<\/span> <span class=\'keyword keyword_operator keyword_operator_assignment keyword_operator_assignment_php\'>=<\/span> <span class=\'constant constant_language constant_language_php\'>NULL<\/span>;\n");
document.write("\n");
document.write("<span class=\'meta meta_function meta_function_php\'>    <span class=\'storage storage_modifier storage_modifier_php\'>public <\/span><span class=\'storage storage_type storage_type_function storage_type_function_php\'>function<\/span> <span class=\'entity entity_name entity_name_function entity_name_function_php\'>getByIso<\/span>(<span class=\'meta meta_function meta_function_arguments meta_function_arguments_php\'><span class=\'meta meta_function meta_function_argument meta_function_argument_default meta_function_argument_default_php\'><span class=\'variable variable_other variable_other_php\'>$iso<\/span> <span class=\'keyword keyword_operator keyword_operator_assignment keyword_operator_assignment_php\'>=<\/span> <span class=\'constant constant_language constant_language_php\'>NULL<\/span><\/span>,<span class=\'meta meta_function meta_function_argument meta_function_argument_default meta_function_argument_default_php\'> <span class=\'variable variable_other variable_other_php\'>$forcedLanguage<\/span> <span class=\'keyword keyword_operator keyword_operator_assignment keyword_operator_assignment_php\'>=<\/span> <span class=\'constant constant_language constant_language_php\'>NULL<\/span><\/span><\/span>)<\/span>{\n");
document.write("        <span class=\'keyword keyword_control keyword_control_php\'>if<\/span>(<span class=\'support support_function support_function_type support_function_type_php\'>is_null<\/span>(<span class=\'variable variable_other variable_other_php\'>$iso<\/span>)){\n");
document.write("            <span class=\'keyword keyword_control keyword_control_exception keyword_control_exception_php\'>throw<\/span> <span class=\'keyword keyword_other keyword_other_new keyword_other_new_php\'>new<\/span> <span class=\'support support_class support_class_php\'>Exception<\/span>(<span class=\'string string_quoted string_quoted_single string_quoted_single_php\'>\'<span class=\'meta meta_string-contents meta_string-contents_quoted meta_string-contents_quoted_single meta_string-contents_quoted_single_php\'>You must specify the iso code of the country<\/span>\'<\/span>);\n");
document.write("        }\n");
document.write("\n");
document.write("        <span class=\'comment comment_line comment_line_double-slash comment_line_double-slash_php\'>//Code to fetch the info related to a country<\/span>\n");
document.write("\n");
document.write("        <span class=\'keyword keyword_control keyword_control_php\'>if<\/span>(<span class=\'keyword keyword_operator keyword_operator_logical keyword_operator_logical_php\'>!<\/span><span class=\'support support_function support_function_type support_function_type_php\'>is_null<\/span>(<span class=\'variable variable_other variable_other_php\'>$forcedLanguage<\/span>)){\n");
document.write("            <span class=\'variable variable_other variable_other_php\'>$this<\/span><span class=\'keyword keyword_operator keyword_operator_class keyword_operator_class_php\'>-&gt;<\/span><span class=\'variable variable_other variable_other_property variable_other_property_php\'>defaultLanguage<\/span> <span class=\'keyword keyword_operator keyword_operator_assignment keyword_operator_assignment_php\'>=<\/span> <span class=\'variable variable_other variable_other_php\'>$forcedLanguage<\/span>;\n");
document.write("        }\n");
document.write("    }\n");
document.write("}\n");
document.write("\n");
document.write("<span class=\'comment comment_line comment_line_double-slash comment_line_double-slash_php\'>//Set the default country code<\/span>\n");
document.write("<span class=\'variable variable_other variable_other_php\'>$_defaultCountry<\/span> <span class=\'keyword keyword_operator keyword_operator_assignment keyword_operator_assignment_php\'>=<\/span> <span class=\'string string_quoted string_quoted_single string_quoted_single_php\'>\'<span class=\'meta meta_string-contents meta_string-contents_quoted meta_string-contents_quoted_single meta_string-contents_quoted_single_php\'>es<\/span>\'<\/span>;\n");
document.write("\n");
document.write("<span class=\'comment comment_line comment_line_double-slash comment_line_double-slash_php\'>//Some variables for mockup<\/span>\n");
document.write("<span class=\'variable variable_other variable_other_php\'>$country<\/span> <span class=\'keyword keyword_operator keyword_operator_assignment keyword_operator_assignment_php\'>=<\/span> <span class=\'constant constant_language constant_language_php\'>NULL<\/span>; <span class=\'comment comment_line comment_line_double-slash comment_line_double-slash_php\'>//Simulates the result from a GeoIP request<\/span>\n");
document.write("<span class=\'variable variable_other variable_other_php\'>$supportedCountries<\/span> <span class=\'keyword keyword_operator keyword_operator_assignment keyword_operator_assignment_php\'>=<\/span> <span class=\'meta meta_array meta_array_php\'><span class=\'support support_function support_function_construct support_function_construct_php\'>array<\/span>(<span class=\'string string_quoted string_quoted_single string_quoted_single_php\'>\'<span class=\'meta meta_string-contents meta_string-contents_quoted meta_string-contents_quoted_single meta_string-contents_quoted_single_php\'>Spain<\/span>\'<\/span>, <span class=\'string string_quoted string_quoted_single string_quoted_single_php\'>\'<span class=\'meta meta_string-contents meta_string-contents_quoted meta_string-contents_quoted_single meta_string-contents_quoted_single_php\'>France<\/span>\'<\/span>, <span class=\'string string_quoted string_quoted_single string_quoted_single_php\'>\'<span class=\'meta meta_string-contents meta_string-contents_quoted meta_string-contents_quoted_single meta_string-contents_quoted_single_php\'>Italy<\/span>\'<\/span>, <span class=\'string string_quoted string_quoted_single string_quoted_single_php\'>\'<span class=\'meta meta_string-contents meta_string-contents_quoted meta_string-contents_quoted_single meta_string-contents_quoted_single_php\'>Germany<\/span>\'<\/span>, <span class=\'string string_quoted string_quoted_single string_quoted_single_php\'>\'<span class=\'meta meta_string-contents meta_string-contents_quoted meta_string-contents_quoted_single meta_string-contents_quoted_single_php\'>Canada<\/span>\'<\/span>)<\/span>;\n");
document.write("<span class=\'variable variable_other variable_other_php\'>$forcedLanguage<\/span> <span class=\'keyword keyword_operator keyword_operator_assignment keyword_operator_assignment_php\'>=<\/span> <span class=\'string string_quoted string_quoted_single string_quoted_single_php\'>\'<span class=\'meta meta_string-contents meta_string-contents_quoted meta_string-contents_quoted_single meta_string-contents_quoted_single_php\'>es<\/span>\'<\/span>; <span class=\'comment comment_line comment_line_double-slash comment_line_double-slash_php\'>//Simulates a parameter fetched from the URL<\/span>\n");
document.write("\n");
document.write("<span class=\'comment comment_line comment_line_double-slash comment_line_double-slash_php\'>//Some checks<\/span>\n");
document.write("<span class=\'variable variable_other variable_other_php\'>$countryDetected<\/span> <span class=\'keyword keyword_operator keyword_operator_assignment keyword_operator_assignment_php\'>=<\/span> <span class=\'keyword keyword_operator keyword_operator_logical keyword_operator_logical_php\'>!<\/span><span class=\'support support_function support_function_type support_function_type_php\'>is_null<\/span>(<span class=\'variable variable_other variable_other_php\'>$country<\/span>);\n");
document.write("<span class=\'variable variable_other variable_other_php\'>$countrySupported<\/span> <span class=\'keyword keyword_operator keyword_operator_assignment keyword_operator_assignment_php\'>=<\/span> <span class=\'support support_function support_function_array support_function_array_php\'>in_array<\/span>(<span class=\'variable variable_other variable_other_php\'>$country<\/span>, <span class=\'variable variable_other variable_other_php\'>$supportedCountries<\/span>);\n");
document.write("<span class=\'variable variable_other variable_other_php\'>$isforcedLanguage<\/span> <span class=\'keyword keyword_operator keyword_operator_assignment keyword_operator_assignment_php\'>=<\/span> <span class=\'keyword keyword_operator keyword_operator_logical keyword_operator_logical_php\'>!<\/span><span class=\'support support_function support_function_type support_function_type_php\'>is_null<\/span>(<span class=\'variable variable_other variable_other_php\'>$forcedLanguage<\/span>);<\/span>\n");
document.write("<\/pre><\/pre>\n");
document.write("		<\/td>\n");
document.write("		<\/tr>\n");
document.write("		<\/table>\n");
document.write("	\n");
document.write("	<\/div>\n");
document.write("\n");
document.write("\n");
document.write("<hr />\n");
document.write("<h2>The easy way with some if\'s <\/h2>\n");
document.write("\n");
document.write("\n");
document.write("\n");
document.write("\n");
document.write("	\n");
document.write("	<div class=\"allcode\">\n");
document.write("		<table cellpadding=\"0\" cellspacing=\"0\" border=\"0\">\n");
document.write("		<tr>\n");
document.write("			<td>\n");
document.write("				\n");
document.write("				<pre class=\"textmate-source-numbers\">1\n");
document.write("2\n");
document.write("3\n");
document.write("4\n");
document.write("5\n");
document.write("6\n");
document.write("7\n");
document.write("8\n");
document.write("9\n");
document.write("10\n");
document.write("11\n");
document.write("12\n");
document.write("13\n");
document.write("14\n");
document.write("15\n");
document.write("16\n");
document.write("17\n");
document.write("18\n");
document.write("19\n");
document.write("20\n");
document.write("21\n");
document.write("22\n");
document.write("23\n");
document.write("24\n");
document.write("25\n");
document.write("26\n");
document.write("27\n");
document.write("28\n");
document.write("29\n");
document.write("30\n");
document.write("31\n");
document.write("32\n");
document.write("33\n");
document.write("<\/pre>\n");
document.write("			<\/td>\n");
document.write("		<td>\n");
document.write("		<pre class=\"textmate-source\"><pre class=\"sunburst\"><span class=\'source source_php source_php_embedded source_php_embedded_block source_php_embedded_block_html\'>&lt;?php\n");
document.write("\n");
document.write("<span class=\'comment comment_line comment_line_double-slash comment_line_double-slash_php\'>//Create the country object<\/span>\n");
document.write("<span class=\'variable variable_other variable_other_php\'>$country<\/span> <span class=\'keyword keyword_operator keyword_operator_assignment keyword_operator_assignment_php\'>=<\/span> <span class=\'keyword keyword_other keyword_other_new keyword_other_new_php\'>new<\/span> <span class=\'support support_class support_class_php\'>Country<\/span>();\n");
document.write("\n");
document.write("<span class=\'keyword keyword_control keyword_control_php\'>if<\/span>(<span class=\'keyword keyword_operator keyword_operator_logical keyword_operator_logical_php\'>!<\/span><span class=\'variable variable_other variable_other_php\'>$countrySupported<\/span> <span class=\'keyword keyword_operator keyword_operator_logical keyword_operator_logical_php\'>&amp;&amp;<\/span> <span class=\'keyword keyword_operator keyword_operator_logical keyword_operator_logical_php\'>!<\/span><span class=\'variable variable_other variable_other_php\'>$isforcedLanguage<\/span>){\n");
document.write("    <span class=\'comment comment_line comment_line_double-slash comment_line_double-slash_php\'>//The country is not supported, so or hasn\'t been detected<\/span>\n");
document.write("    <span class=\'comment comment_line comment_line_double-slash comment_line_double-slash_php\'>//or has been detected but it\'s not supported<\/span>\n");
document.write("    <span class=\'comment comment_line comment_line_double-slash comment_line_double-slash_php\'>//The language is not forced<\/span>\n");
document.write("\n");
document.write("    <span class=\'comment comment_line comment_line_double-slash comment_line_double-slash_php\'>//Fetch the default country<\/span>\n");
document.write("    <span class=\'variable variable_other variable_other_php\'>$country<\/span><span class=\'keyword keyword_operator keyword_operator_class keyword_operator_class_php\'>-&gt;<\/span><span class=\'meta meta_function-call meta_function-call_object meta_function-call_object_php\'>getByIso<\/span>(<span class=\'variable variable_other variable_other_php\'>$_defaultCountry<\/span>);\n");
document.write("}<span class=\'keyword keyword_control keyword_control_php\'>else<\/span> <span class=\'keyword keyword_control keyword_control_php\'>if<\/span>(<span class=\'keyword keyword_operator keyword_operator_logical keyword_operator_logical_php\'>!<\/span><span class=\'variable variable_other variable_other_php\'>$countrySupported<\/span> <span class=\'keyword keyword_operator keyword_operator_logical keyword_operator_logical_php\'>&amp;&amp;<\/span> <span class=\'variable variable_other variable_other_php\'>$isforcedLanguage<\/span>){\n");
document.write("    <span class=\'comment comment_line comment_line_double-slash comment_line_double-slash_php\'>//The country is not supported, so or hasn\'t been detected<\/span>\n");
document.write("    <span class=\'comment comment_line comment_line_double-slash comment_line_double-slash_php\'>//or has been detected but it\'s not supported<\/span>\n");
document.write("    <span class=\'comment comment_line comment_line_double-slash comment_line_double-slash_php\'>//The language is forced<\/span>\n");
document.write("\n");
document.write("    <span class=\'comment comment_line comment_line_double-slash comment_line_double-slash_php\'>//Fetch the default country and override the defaultLanguage<\/span>\n");
document.write("    <span class=\'comment comment_line comment_line_double-slash comment_line_double-slash_php\'>//with the lang coming from the URL<\/span>\n");
document.write("    <span class=\'variable variable_other variable_other_php\'>$country<\/span><span class=\'keyword keyword_operator keyword_operator_class keyword_operator_class_php\'>-&gt;<\/span><span class=\'meta meta_function-call meta_function-call_object meta_function-call_object_php\'>getByIso<\/span>(<span class=\'variable variable_other variable_other_php\'>$_defaultCountry<\/span>, <span class=\'variable variable_other variable_other_php\'>$forcedLanguage<\/span>);\n");
document.write("}<span class=\'keyword keyword_control keyword_control_php\'>else<\/span> <span class=\'keyword keyword_control keyword_control_php\'>if<\/span>(<span class=\'variable variable_other variable_other_php\'>$countrySupported<\/span> <span class=\'keyword keyword_operator keyword_operator_logical keyword_operator_logical_php\'>&amp;&amp;<\/span> <span class=\'keyword keyword_operator keyword_operator_logical keyword_operator_logical_php\'>!<\/span><span class=\'variable variable_other variable_other_php\'>$isforcedLanguage<\/span>){\n");
document.write("    <span class=\'comment comment_line comment_line_double-slash comment_line_double-slash_php\'>//The country it\'s supported, so the country has been detected<\/span>\n");
document.write("    <span class=\'comment comment_line comment_line_double-slash comment_line_double-slash_php\'>//The language is not forced<\/span>\n");
document.write("\n");
document.write("    <span class=\'comment comment_line comment_line_double-slash comment_line_double-slash_php\'>//Fetch the default country<\/span>\n");
document.write("    <span class=\'variable variable_other variable_other_php\'>$country<\/span><span class=\'keyword keyword_operator keyword_operator_class keyword_operator_class_php\'>-&gt;<\/span><span class=\'meta meta_function-call meta_function-call_object meta_function-call_object_php\'>getByIso<\/span>(<span class=\'variable variable_other variable_other_php\'>$country<\/span>);\n");
document.write("}<span class=\'keyword keyword_control keyword_control_php\'>else<\/span> <span class=\'keyword keyword_control keyword_control_php\'>if<\/span>(<span class=\'variable variable_other variable_other_php\'>$countrySupported<\/span> <span class=\'keyword keyword_operator keyword_operator_logical keyword_operator_logical_php\'>&amp;&amp;<\/span> <span class=\'variable variable_other variable_other_php\'>$isforcedLanguage<\/span>){\n");
document.write("    <span class=\'comment comment_line comment_line_double-slash comment_line_double-slash_php\'>//The country it\'s supported, so the country has been detected<\/span>\n");
document.write("    <span class=\'comment comment_line comment_line_double-slash comment_line_double-slash_php\'>//The language is forced<\/span>\n");
document.write("\n");
document.write("    <span class=\'comment comment_line comment_line_double-slash comment_line_double-slash_php\'>//Fetch the default country<\/span>\n");
document.write("    <span class=\'variable variable_other variable_other_php\'>$country<\/span><span class=\'keyword keyword_operator keyword_operator_class keyword_operator_class_php\'>-&gt;<\/span><span class=\'meta meta_function-call meta_function-call_object meta_function-call_object_php\'>getByIso<\/span>(<span class=\'variable variable_other variable_other_php\'>$country<\/span>, <span class=\'variable variable_other variable_other_php\'>$forcedLanguage<\/span>);\n");
document.write("}<\/span>\n");
document.write("<\/pre><\/pre>\n");
document.write("		<\/td>\n");
document.write("		<\/tr>\n");
document.write("		<\/table>\n");
document.write("	\n");
document.write("	<\/div>\n");
document.write("\n");
document.write("\n");
document.write("<hr />\n");
document.write("<h2>A little bit more complex. <\/h2>\n");
document.write("\n");
document.write("\n");
document.write("\n");
document.write("\n");
document.write("	\n");
document.write("	<div class=\"allcode\">\n");
document.write("		<table cellpadding=\"0\" cellspacing=\"0\" border=\"0\">\n");
document.write("		<tr>\n");
document.write("			<td>\n");
document.write("				\n");
document.write("				<pre class=\"textmate-source-numbers\">1\n");
document.write("2\n");
document.write("3\n");
document.write("4\n");
document.write("5\n");
document.write("6\n");
document.write("7\n");
document.write("8\n");
document.write("9\n");
document.write("10\n");
document.write("11\n");
document.write("12\n");
document.write("13\n");
document.write("14\n");
document.write("15\n");
document.write("16\n");
document.write("17\n");
document.write("18\n");
document.write("19\n");
document.write("20\n");
document.write("21\n");
document.write("22\n");
document.write("23\n");
document.write("24\n");
document.write("25\n");
document.write("26\n");
document.write("27\n");
document.write("28\n");
document.write("29\n");
document.write("30\n");
document.write("31\n");
document.write("32\n");
document.write("33\n");
document.write("<\/pre>\n");
document.write("			<\/td>\n");
document.write("		<td>\n");
document.write("		<pre class=\"textmate-source\"><pre class=\"sunburst\"><span class=\'source source_php source_php_embedded source_php_embedded_block source_php_embedded_block_html\'>&lt;?php\n");
document.write("\n");
document.write("<span class=\'comment comment_block comment_block_documentation comment_block_documentation_phpdoc comment_block_documentation_phpdoc_php\'>/**<\/span>\n");
document.write("<span class=\"Comment\"> * We have the truth table, so we can generate a binary tree with Arrays <\/span>\n");
document.write("<span class=\"Comment\"> * and use $countrySupported and $isforcedLanguage to access the results<\/span>\n");
document.write("<span class=\"Comment\"> */<\/span>\n");
document.write("\n");
document.write("<span class=\'comment comment_line comment_line_double-slash comment_line_double-slash_php\'>//Create the country object<\/span>\n");
document.write("<span class=\'variable variable_other variable_other_php\'>$country<\/span> <span class=\'keyword keyword_operator keyword_operator_assignment keyword_operator_assignment_php\'>=<\/span> <span class=\'keyword keyword_other keyword_other_new keyword_other_new_php\'>new<\/span> <span class=\'support support_class support_class_php\'>Country<\/span>();\n");
document.write("\n");
document.write("<span class=\'variable variable_other variable_other_php\'>$decisionTree<\/span> <span class=\'keyword keyword_operator keyword_operator_assignment keyword_operator_assignment_php\'>=<\/span> <span class=\'meta meta_array meta_array_php\'><span class=\'support support_function support_function_construct support_function_construct_php\'>array<\/span>(\n");
document.write("                    <span class=\'constant constant_numeric constant_numeric_php\'>0<\/span> <span class=\'keyword keyword_operator keyword_operator_key keyword_operator_key_php\'>=&gt;<\/span> <span class=\'meta meta_array meta_array_php\'><span class=\'support support_function support_function_construct support_function_construct_php\'>array<\/span>(\n");
document.write("                          <span class=\'constant constant_numeric constant_numeric_php\'>0<\/span> <span class=\'keyword keyword_operator keyword_operator_key keyword_operator_key_php\'>=&gt;<\/span> <span class=\'variable variable_other variable_other_php\'>$country<\/span><span class=\'keyword keyword_operator keyword_operator_class keyword_operator_class_php\'>-&gt;<\/span><span class=\'meta meta_function-call meta_function-call_object meta_function-call_object_php\'>getByIso<\/span>(<span class=\'variable variable_other variable_other_php\'>$_defaultCountry<\/span>)<\/span>,\n");
document.write("                          <span class=\'constant constant_numeric constant_numeric_php\'>1<\/span> <span class=\'keyword keyword_operator keyword_operator_key keyword_operator_key_php\'>=&gt;<\/span> <span class=\'variable variable_other variable_other_php\'>$country<\/span><span class=\'keyword keyword_operator keyword_operator_class keyword_operator_class_php\'>-&gt;<\/span><span class=\'meta meta_function-call meta_function-call_object meta_function-call_object_php\'>getByIso<\/span>(<span class=\'variable variable_other variable_other_php\'>$_defaultCountry<\/span>, <span class=\'variable variable_other variable_other_php\'>$forcedLanguage<\/span>)<\/span>\n");
document.write("                    ),\n");
document.write("                    <span class=\'constant constant_numeric constant_numeric_php\'>1<\/span> <span class=\'keyword keyword_operator keyword_operator_key keyword_operator_key_php\'>=&gt;<\/span> <span class=\'meta meta_array meta_array_php\'><span class=\'support support_function support_function_construct support_function_construct_php\'>array<\/span>(\n");
document.write("                          <span class=\'constant constant_numeric constant_numeric_php\'>0<\/span> <span class=\'keyword keyword_operator keyword_operator_key keyword_operator_key_php\'>=&gt;<\/span> <span class=\'variable variable_other variable_other_php\'>$country<\/span><span class=\'keyword keyword_operator keyword_operator_class keyword_operator_class_php\'>-&gt;<\/span><span class=\'meta meta_function-call meta_function-call_object meta_function-call_object_php\'>getByIso<\/span>(<span class=\'variable variable_other variable_other_php\'>$country<\/span>)<\/span>,\n");
document.write("                          <span class=\'constant constant_numeric constant_numeric_php\'>1<\/span> <span class=\'keyword keyword_operator keyword_operator_key keyword_operator_key_php\'>=&gt;<\/span> <span class=\'variable variable_other variable_other_php\'>$country<\/span><span class=\'keyword keyword_operator keyword_operator_class keyword_operator_class_php\'>-&gt;<\/span><span class=\'meta meta_function-call meta_function-call_object meta_function-call_object_php\'>getByIso<\/span>(<span class=\'variable variable_other variable_other_php\'>$country<\/span>, <span class=\'variable variable_other variable_other_php\'>$forcedLanguage<\/span>)\n");
document.write("                    )\n");
document.write("                );\n");
document.write("\n");
document.write("<span class=\'comment comment_line comment_line_double-slash comment_line_double-slash_php\'>//Get the result based on $countrySupported and $isforcedLanguage<\/span>\n");
document.write("<span class=\'variable variable_other variable_other_php\'>$country<\/span> <span class=\'keyword keyword_operator keyword_operator_assignment keyword_operator_assignment_php\'>=<\/span> <span class=\'variable variable_other variable_other_php\'>$decisionTree<\/span>[<span class=\'variable variable_other variable_other_php\'>$countrySupported<\/span>][<span class=\'variable variable_other variable_other_php\'>$isforcedLanguage<\/span>];\n");
document.write("\n");
document.write("<span class=\'comment comment_block comment_block_documentation comment_block_documentation_phpdoc comment_block_documentation_phpdoc_php\'>/**<\/span>\n");
document.write("<span class=\"Comment\"> * Whichever method we use to generate the country info <\/span>\n");
document.write("<span class=\"Comment\"> * we will create the localeString<\/span>\n");
document.write("<span class=\"Comment\"> */<\/span>\n");
document.write("<span class=\'variable variable_other variable_other_php\'>$localeString<\/span> <span class=\'keyword keyword_operator keyword_operator_assignment keyword_operator_assignment_php\'>=<\/span> <span class=\'support support_function support_function_formatted_print support_function_formatted_print_php\'>sprintf<\/span>(\n");
document.write("                  <span class=\'string string_quoted string_quoted_single string_quoted_single_php\'>\'<span class=\'meta meta_string-contents meta_string-contents_quoted meta_string-contents_quoted_single meta_string-contents_quoted_single_php\'>%s_%s<\/span>\'<\/span>, \n");
document.write("                  <span class=\'support support_function support_function_string support_function_string_php\'>strtolower<\/span>(<span class=\'variable variable_other variable_other_php\'>$country<\/span><span class=\'keyword keyword_operator keyword_operator_class keyword_operator_class_php\'>-&gt;<\/span><span class=\'variable variable_other variable_other_property variable_other_property_php\'>defaultLanguage<\/span>), \n");
document.write("                  <span class=\'support support_function support_function_string support_function_string_php\'>strtoupper<\/span>(<span class=\'variable variable_other variable_other_php\'>$country<\/span><span class=\'keyword keyword_operator keyword_operator_class keyword_operator_class_php\'>-&gt;<\/span><span class=\'variable variable_other variable_other_property variable_other_property_php\'>iso<\/span>)\n");
document.write("                );<\/span>\n");
document.write("<\/pre><\/pre>\n");
document.write("		<\/td>\n");
document.write("		<\/tr>\n");
document.write("		<\/table>\n");
document.write("	\n");
document.write("	<\/div>\n");
document.write("\n");
document.write("\n");
document.write("  \n");
document.write("  \n");
document.write("  <div class=\"credit\">\n");
document.write("    <div class=\"buttons\">\n");
document.write("      <a href=\"http://pastie.org/pastes/857090.txt\">\n");
document.write("      <img src=\"http://pastie.org/images/view.png\" height=\"20\" width=\"67\" /><\/a>\n");
document.write("    <\/div>\n");
document.write("  \n");
document.write("    <a href=\"http://pastie.org/857090\">Pastie #857090<\/a> linked directly from <a href=\"http://pastie.org/\">Pastie<\/a>.\n");
document.write("  <\/div><\/div>");

