You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@openoffice.apache.org by ma...@apache.org on 2012/05/19 13:29:08 UTC

svn commit: r1340420 - /incubator/ooo/ooo-site/trunk/content/download/index_aoo.html

Author: marcus
Date: Sat May 19 11:29:08 2012
New Revision: 1340420

URL: http://svn.apache.org/viewvc?rev=1340420&view=rev
Log:
Fixed error with not-supported language. They were not redirected to the URL listed in the 'languages.js' file.

Modified:
    incubator/ooo/ooo-site/trunk/content/download/index_aoo.html

Modified: incubator/ooo/ooo-site/trunk/content/download/index_aoo.html
URL: http://svn.apache.org/viewvc/incubator/ooo/ooo-site/trunk/content/download/index_aoo.html?rev=1340420&r1=1340419&r2=1340420&view=diff
==============================================================================
--- incubator/ooo/ooo-site/trunk/content/download/index_aoo.html (original)
+++ incubator/ooo/ooo-site/trunk/content/download/index_aoo.html Sat May 19 11:29:08 2012
@@ -42,13 +42,11 @@
 <!-- Green: Stable release -->
   <script type="text/javascript">  
   <!--
-  var NL_LANGUAGE = "";
+  // Set a specific language ISO code to force to assemble a certain localized build as download URL
+  var NL_LANGUAGE = "eu";
+  // Get the download URL
   var LINK = getLink( VERSION, NL_LANGUAGE, MIRROR, SCHEMA );
 
-  // alert ( "Download link: " + LINK );
-  // normal processing to simply quoting issues -- keep original
-  // var newLINK = "<a href=\"" + LINK + "\"" + " title = \"" + LINK + " \" >";
-  // alert ( "hasMirrorLink: " + hasMirrorLink() );
   if ( hasMirrorLink( NL_LANGUAGE ) ) {
     document.write( "<div class=\"first button green\" id=\"optionitem1\" onclick=\"openItem('optionitem1','"
     + LINK + "');" + "return false;\">" );
@@ -58,19 +56,21 @@
     + "<br/></p>" );
   } else {
     // dump SF download and redirect to NL webpage (see URLs in "languages.js") if no mirror link (hasMirrorLink() == false)
-    // alert( "link before replacment: " + LINK );
-    var newLINK = LINK.replace(/\/download$/,"");
-    // alert ( "link after replacment: " + newLINK );
+    // Get first the array data for NL_LANGUAGE and then the redirect link from the array data
+    var a = getArray( NL_LANGUAGE );
+    var OLANG = a[ 1 ];
+    var OLINK = a[ 2 ];
+
     document.write( "<div class=\"first button green\" id=\"optionitem1\" onclick=\"openItem('optionitem1','"
-    + newLINK + "');" + "return false;\">" );
-    document.write( "<h2><a href='" + newLINK + "' title='" + newLINK + "'>Download Apache OpenOffice</a></h2>"
-    + "<p><a href='" + newLINK + "' title='" + newLINK + "'>Get Apache OpenOffice from your Native Language "
-    + "community.</a></p>" );
+    + OLINK + "');" + "return false;\">" );
+    document.write( "<h2><a href='" + OLINK + "' title='" + OLINK + "'>Download Apache OpenOffice " + VERSION + "</a></h2>"
+    + "<p><a href='" + OLINK + "' title='" + OLINK + "'>Apache OpenOffice for " + OLANG + " is not available. "
+    + "Please choose from the alternative download webpage for another language.</a></p>" );
   }
   
   document.write( "</div>" );
   document.write( "<div class=\"sub-green\">"
-    + "<p><a href='other.html' title='Get all platforms, languages, language packs, source code, SDK to download'>"
+    + "<p><a href='other.html' title='Get all platforms, languages, language packs to download'>"
     + "<b>Get all platforms, languages, language packs</b></a> | "
     + "<a href='other.html#tested-sdk' title='Get all source code tarballs and SDK to download'>"
     + "<b>Source Code tarballs and SDK</b></a> | <br />"