/**
     * Renders the HTML code for a selectorbox for selecting a new translation language for the current
     * page (create a new "Alternative Page Header".
     *
     * @return	mixed		HTML code for the selectorbox or FALSE if no new translation can be created.
     * @access	protected
     */
    function sidebar_renderItem_renderNewTranslationSelectorbox()
    {
        global $LANG, $BE_USER;
        if (!$GLOBALS['BE_USER']->isPSet($this->pObj->calcPerms, 'pages', 'edit')) {
            return false;
        }
        $newLanguagesArr = $this->pObj->getAvailableLanguages(0, true, false);
        if (count($newLanguagesArr) < 1) {
            return FALSE;
        }
        $translatedLanguagesArr = $this->pObj->getAvailableLanguages($this->pObj->id);
        $optionsArr = array('<option value=""></option>');
        foreach ($newLanguagesArr as $language) {
            if ($BE_USER->checkLanguageAccess($language['uid']) && !isset($translatedLanguagesArr[$language['uid']])) {
                $flag = tx_templavoila_icons::getFlagIconFileForLanguage($language['flagIcon']);
                $style = isset($language['flagIcon']) ? 'background-image: url(' . $flag . '); background-repeat: no-repeat; padding-top: 0px; padding-left: 22px;' : '';
                $optionsArr[] = '<option style="' . $style . '" name="createNewPageTranslation" value="' . $language['uid'] . '">' . htmlspecialchars($language['title']) . '</option>';
            }
        }
        if (count($optionsArr) > 1) {
            $linkParam = $this->pObj->rootElementTable == 'pages' ? '&doktype=' . $this->pObj->rootElementRecord['doktype'] : '';
            $link = 'index.php?' . $this->pObj->link_getParameters() . '&createNewPageTranslation=\'+this.options[this.selectedIndex].value+\'&pid=' . $this->pObj->id . $linkParam;
            $output = '
				<tr class="bgColor4">
					<td width="20">
						' . t3lib_BEfunc::cshItem('_MOD_web_txtemplavoilaM1', 'createnewtranslation', $this->doc->backPath) . '
					</td><td width="200" style="vertical-align:middle;">
						' . $LANG->getLL('createnewtranslation', 1) . ':
					</td>
					<td style="vertical-align:middle;"><select onChange="document.location=\'' . htmlspecialchars($link) . '\'">' . implode('', $optionsArr) . '</select></td>
				</tr>
			';
        }
        return $output;
    }