Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

Added some missing title attributes for various JavaScript pickers #4222

Closed
wants to merge 2 commits into from

3 participants

@xchs

This is my implementation of ticket #2634.

Added also some missing language variables that were not shown in the simple modal window title and fixed a few other minor issues.

BTW: If the new language variables for the title attributes doesn't fit well, feel free to replace them by something else.

@qzminski

I think you should use specialchars() while inside HTML attributes.

Regarding this commit and 8106739:

What about my modifications in these files:

Did they not fit?

I added there some missing language variables that were not shown in the simple modal window title (like mentioned by @lionel-m in #4347, too). As you can see, due to the lack of a corresponding language variable there is shown a "Untitled" title in the simple modal header.

Back end modules

Allowed page types

@leofeyer
Owner

It is not necessary and not always correct to assign an alt attribute to every image. Also, if there is an alt attribute, there is no need to additionally set a title attribute (probably even with the same content).

@leofeyer
Owner

I have implemented the appropriate changes in 8106739.

@leofeyer leofeyer closed this
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Apr 20, 2012
Commits on Apr 22, 2012
This page is out of date. Refresh to see the latest.
View
2  .htaccess.default
@@ -18,7 +18,7 @@
# License along with this program. If not, please visit the Free
# Software Foundation website at <http://www.gnu.org/licenses/>.
#
-# PHP version 5
+# PHP version 5.3
# @copyright Leo Feyer 2005-2012
# @author Leo Feyer <http://www.contao.org>
# @license LGPL
View
2  README.md
@@ -21,7 +21,7 @@ System requirements
-------------------
* Webserver (Apache, IIS, etc.)
-* PHP version 5.2 or greater
+* PHP version 5.3 or greater
* MySQL version 4.1 or greater
* PHP extension GDLib
* PHP extension mcrypt (optional)
View
4 system/modules/backend/DataContainer.php
@@ -357,7 +357,7 @@ protected function row($strPalette=null)
break;
}
- $datepicker = ' <img src="plugins/mootools/datepicker/icon.gif" width="20" height="20" alt="" id="toggle_' . $objWidget->id . '" style="vertical-align:-6px">
+ $datepicker = ' <img src="plugins/mootools/datepicker/icon.gif" width="20" height="20" alt="" title="' . specialchars($GLOBALS['TL_LANG']['DP']['datepickerTitle']) . '" id="toggle_' . $objWidget->id . '" style="vertical-align:-6px">
<script>
window.addEvent("domready", function() {
new Picker.Date($$("#ctrl_' . $objWidget->id . '"), {
@@ -377,7 +377,7 @@ protected function row($strPalette=null)
// Color picker
if ($arrData['eval']['colorpicker'])
{
- $colorpicker = ' ' . $this->generateImage('pickcolor.gif', $GLOBALS['TL_LANG']['MSC']['colorpicker'], 'style="vertical-align:top;cursor:pointer" id="moo_' . $this->strField . '"') . '
+ $colorpicker = ' ' . $this->generateImage('pickcolor.gif', $GLOBALS['TL_LANG']['MSC']['colorpicker'], 'title="' . specialchars($GLOBALS['TL_LANG']['MSC']['colorpickerTitle']) . '" style="vertical-align:top;cursor:pointer" id="moo_' . $this->strField . '"') . '
<script>
window.addEvent("domready", function() {
new MooRainbow("moo_' . $this->strField . '", {
View
2  system/modules/backend/dca/tl_content.php
@@ -1332,7 +1332,7 @@ public function tableImportWizard()
*/
public function pagePicker(\DataContainer $dc)
{
- return ' <a href="contao/page.php?table='.$dc->table.'&amp;field='.$dc->field.'&amp;value='.str_replace(array('{{link_url::', '}}'), '', $dc->value).'" onclick="Backend.getScrollOffset();Backend.openModalSelector({\'width\':765,\'title\':\''.$GLOBALS['TL_LANG']['MOD']['page'][0].'\',\'url\':this.href,\'id\':\''.$dc->field.'\',\'tag\':\'ctrl_'.$dc->field . (($this->Input->get('act') == 'editAll') ? '_' . $dc->id : '').'\',\'self\':this});return false">' . $this->generateImage('pickpage.gif', $GLOBALS['TL_LANG']['MSC']['pagepicker'], 'style="vertical-align:top;cursor:pointer"') . '</a>';
+ return ' <a href="contao/page.php?table='.$dc->table.'&amp;field='.$dc->field.'&amp;value='.str_replace(array('{{link_url::', '}}'), '', $dc->value).'" onclick="Backend.getScrollOffset();Backend.openModalSelector({\'width\':765,\'title\':\''.$GLOBALS['TL_LANG']['MOD']['page'][0].'\',\'url\':this.href,\'id\':\''.$dc->field.'\',\'tag\':\'ctrl_'.$dc->field . (($this->Input->get('act') == 'editAll') ? '_' . $dc->id : '').'\',\'self\':this});return false">' . $this->generateImage('pickpage.gif', $GLOBALS['TL_LANG']['MSC']['pagepicker'], 'title="' . specialchars($GLOBALS['TL_LANG']['MSC']['pagepickerTitle']) . '" style="vertical-align:top;cursor:pointer"') . '</a>';
}
View
2  system/modules/backend/dca/tl_style.php
@@ -695,7 +695,7 @@ public function checkCategory($varValue)
*/
public function filePicker(\DataContainer $dc)
{
- return ' <a href="contao/file.php?table='.$dc->table.'&amp;field='.$dc->field.'&amp;value='.$dc->value.'" onclick="Backend.getScrollOffset();Backend.openModalSelector({\'width\':765,\'title\':\''.$GLOBALS['TL_LANG']['MOD']['files'][0].'\',\'url\':this.href,\'id\':\''.$dc->field.'\',\'tag\':\'ctrl_'.$dc->field . (($this->Input->get('act') == 'editAll') ? '_' . $dc->id : '').'\',\'self\':this});return false">' . $this->generateImage('pickfile.gif', $GLOBALS['TL_LANG']['MSC']['filepicker'], 'style="vertical-align:top;cursor:pointer"') . '</a>';
+ return ' <a href="contao/file.php?table='.$dc->table.'&amp;field='.$dc->field.'&amp;value='.$dc->value.'" onclick="Backend.getScrollOffset();Backend.openModalSelector({\'width\':765,\'title\':\''.$GLOBALS['TL_LANG']['MOD']['files'][0].'\',\'url\':this.href,\'id\':\''.$dc->field.'\',\'tag\':\'ctrl_'.$dc->field . (($this->Input->get('act') == 'editAll') ? '_' . $dc->id : '').'\',\'self\':this});return false">' . $this->generateImage('pickfile.gif', $GLOBALS['TL_LANG']['MSC']['filepicker'], 'title="' . specialchars($GLOBALS['TL_LANG']['MSC']['filepickerTitle']) . '" style="vertical-align:top;cursor:pointer"') . '</a>';
}
View
5 system/modules/backend/languages/de/default.php
@@ -231,6 +231,8 @@
/**
* Datepicker
*/
+$GLOBALS['TL_LANG']['DP']['datepicker'] = 'Datumswähler (benötigt JavaScript)';
+$GLOBALS['TL_LANG']['DP']['datepickerTitle'] = 'Den Datumswähler aufrufen';
$GLOBALS['TL_LANG']['DP']['select_a_time'] = 'Uhrzeit auswählen';
$GLOBALS['TL_LANG']['DP']['use_mouse_wheel'] = 'Ändern Sie die Werte mit Hilfe des Mausrads';
$GLOBALS['TL_LANG']['DP']['time_confirm_button'] = 'OK';
@@ -396,8 +398,11 @@
$GLOBALS['TL_LANG']['MSC']['view'] = 'In einem neuen Fenster öffnen';
$GLOBALS['TL_LANG']['MSC']['fullsize'] = 'Großansicht des Bildes in einem neuen Fenster öffnen';
$GLOBALS['TL_LANG']['MSC']['colorpicker'] = 'Farbwähler (benötigt JavaScript)';
+$GLOBALS['TL_LANG']['MSC']['colorpickerTitle'] = 'Den Farbwähler aufrufen';
$GLOBALS['TL_LANG']['MSC']['pagepicker'] = 'Seitenwähler (benötigt JavaScript)';
+$GLOBALS['TL_LANG']['MSC']['pagepickerTitle'] = 'Den Seitenwähler aufrufen';
$GLOBALS['TL_LANG']['MSC']['filepicker'] = 'Dateiwähler (benötigt JavaScript)';
+$GLOBALS['TL_LANG']['MSC']['filepickerTitle'] = 'Den Dateiwähler aufrufen';
$GLOBALS['TL_LANG']['MSC']['ppHeadline'] = 'Contao-Seiten';
$GLOBALS['TL_LANG']['MSC']['fpHeadline'] = 'Contao-Dateien';
$GLOBALS['TL_LANG']['MSC']['yes'] = 'ja';
View
2  system/modules/backend/languages/de/tl_user_group.php
@@ -32,6 +32,8 @@
* Fields
*/
$GLOBALS['TL_LANG']['tl_user_group']['name'] = array('Titel', 'Bitte geben Sie den Titel der Gruppe ein.');
+$GLOBALS['TL_LANG']['tl_user_group']['modules'] = array('Backend-Module', 'Hier können Sie den Zugriff auf ein oder mehrere Backend-Module erlauben.');
+$GLOBALS['TL_LANG']['tl_user_group']['alpty'] = array('Erlaubte Seitentypen', 'Hier können Sie die erlaubten Seitentypen festlegen.');
$GLOBALS['TL_LANG']['tl_user_group']['alexf'] = array('Erlaubte Felder', 'Hier können Sie festlegen, welche Felder bearbeitet werden dürfen.');
$GLOBALS['TL_LANG']['tl_user_group']['disable'] = array('Deaktivieren', 'Die Gruppe vorübergehend deaktivieren.');
$GLOBALS['TL_LANG']['tl_user_group']['start'] = array('Aktivieren am', 'Die Gruppe automatisch an diesem Tag aktivieren.');
View
5 system/modules/backend/languages/en/default.php
@@ -230,6 +230,8 @@
/**
* Datepicker
*/
+$GLOBALS['TL_LANG']['DP']['datepicker'] = 'Date picker (requires JavaScript)';
+$GLOBALS['TL_LANG']['DP']['datepickerTitle'] = 'Open the date picker';
$GLOBALS['TL_LANG']['DP']['select_a_time'] = 'Select a time';
$GLOBALS['TL_LANG']['DP']['use_mouse_wheel'] = 'Use the mouse wheel to quickly change value';
$GLOBALS['TL_LANG']['DP']['time_confirm_button'] = 'OK';
@@ -395,8 +397,11 @@
$GLOBALS['TL_LANG']['MSC']['view'] = 'View in a new window';
$GLOBALS['TL_LANG']['MSC']['fullsize'] = 'Open full size image in a new window';
$GLOBALS['TL_LANG']['MSC']['colorpicker'] = 'Color picker (requires JavaScript)';
+$GLOBALS['TL_LANG']['MSC']['colorpickerTitle'] = 'Open the color picker';
$GLOBALS['TL_LANG']['MSC']['pagepicker'] = 'Page picker (requires JavaScript)';
+$GLOBALS['TL_LANG']['MSC']['pagepickerTitle'] = 'Open the page picker';
$GLOBALS['TL_LANG']['MSC']['filepicker'] = 'File picker (requires JavaScript)';
+$GLOBALS['TL_LANG']['MSC']['filepickerTitle'] = 'Open the file picker';
$GLOBALS['TL_LANG']['MSC']['ppHeadline'] = 'Contao pages';
$GLOBALS['TL_LANG']['MSC']['fpHeadline'] = 'Contao files';
$GLOBALS['TL_LANG']['MSC']['yes'] = 'yes';
View
2  system/modules/backend/languages/en/tl_user_group.php
@@ -32,6 +32,8 @@
* Fields
*/
$GLOBALS['TL_LANG']['tl_user_group']['name'] = array('Title', 'Please enter the group title.');
+$GLOBALS['TL_LANG']['tl_user_group']['modules'] = array('Back end modules', 'Here you can grant access to one or more back end modules.');
+$GLOBALS['TL_LANG']['tl_user_group']['alpty'] = array('Allowed page types', 'Here you can select the page types you want to allow.');
$GLOBALS['TL_LANG']['tl_user_group']['alexf'] = array('Allowed fields', 'Here you can choose which fields will be editable.');
$GLOBALS['TL_LANG']['tl_user_group']['disable'] = array('Deactivate', 'Temporarily disable the group.');
$GLOBALS['TL_LANG']['tl_user_group']['start'] = array('Activate on', 'Automatically activate the group on this day.');
View
2  system/modules/calendar/dca/tl_calendar_events.php
@@ -934,7 +934,7 @@ public function scheduleUpdate()
*/
public function pagePicker(\DataContainer $dc)
{
- return ' <a href="contao/page.php?table='.$dc->table.'&amp;field='.$dc->field.'&amp;value='.str_replace(array('{{link_url::', '}}'), '', $dc->value).'" onclick="Backend.getScrollOffset();Backend.openModalSelector({\'width\':765,\'title\':\''.$GLOBALS['TL_LANG']['MOD']['page'][0].'\',\'url\':this.href,\'id\':\''.$dc->field.'\',\'tag\':\'ctrl_'.$dc->field . (($this->Input->get('act') == 'editAll') ? '_' . $dc->id : '').'\',\'self\':this});return false">' . $this->generateImage('pickpage.gif', $GLOBALS['TL_LANG']['MSC']['pagepicker'], 'style="vertical-align:top;cursor:pointer"') . '</a>';
+ return ' <a href="contao/page.php?table='.$dc->table.'&amp;field='.$dc->field.'&amp;value='.str_replace(array('{{link_url::', '}}'), '', $dc->value).'" onclick="Backend.getScrollOffset();Backend.openModalSelector({\'width\':765,\'title\':\''.$GLOBALS['TL_LANG']['MOD']['page'][0].'\',\'url\':this.href,\'id\':\''.$dc->field.'\',\'tag\':\'ctrl_'.$dc->field . (($this->Input->get('act') == 'editAll') ? '_' . $dc->id : '').'\',\'self\':this});return false">' . $this->generateImage('pickpage.gif', $GLOBALS['TL_LANG']['MSC']['pagepicker'], 'title="' . specialchars($GLOBALS['TL_LANG']['MSC']['pagepickerTitle']) . '" style="vertical-align:top;cursor:pointer"') . '</a>';
}
View
1  system/modules/calendar/languages/de/tl_calendar_events.php
@@ -45,6 +45,7 @@
$GLOBALS['TL_LANG']['tl_calendar_events']['repeatEach'] = array('Intervall', 'Hier können Sie das Wiederholungsintervall festlegen.');
$GLOBALS['TL_LANG']['tl_calendar_events']['recurrences'] = array('Wiederholungen', 'Geben Sie 0 ein, um das Event unbefristet zu wiederholen.');
$GLOBALS['TL_LANG']['tl_calendar_events']['addImage'] = array('Ein Bild hinzufügen', 'Dem Event ein Bild hinzufügen.');
+$GLOBALS['TL_LANG']['tl_calendar_events']['size'] = array('Bildbreite und Bildhöhe', 'Hier können Sie die Abmessungen des Bildes und den Skalierungsmodus festlegen.');
$GLOBALS['TL_LANG']['tl_calendar_events']['addEnclosure'] = array('Anlagen hinzufügen', 'Dem Event eine oder mehrere Dateien als Download hinzufügen.');
$GLOBALS['TL_LANG']['tl_calendar_events']['enclosure'] = array('Anlagen', 'Bitte wählen Sie die Dateien aus, die Sie hinzufügen möchten.');
$GLOBALS['TL_LANG']['tl_calendar_events']['source'] = array('Weiterleitungsziel', 'Hier können Sie die Standard-Weiterleitung überschreiben.');
View
1  system/modules/calendar/languages/en/tl_calendar_events.php
@@ -42,6 +42,7 @@
$GLOBALS['TL_LANG']['tl_calendar_events']['teaser'] = array('Event teaser', 'The event teaser can be shown in an event list instead of the full article. A "read more …" link will be added automatically.');
$GLOBALS['TL_LANG']['tl_calendar_events']['details'] = array('Event text', 'Here you can enter the event text.');
$GLOBALS['TL_LANG']['tl_calendar_events']['addImage'] = array('Add an image', 'Add an image to the event.');
+$GLOBALS['TL_LANG']['tl_calendar_events']['size'] = array('Image width and height', 'Here you can set the image dimensions and the resize mode.');
$GLOBALS['TL_LANG']['tl_calendar_events']['recurring'] = array('Repeat event', 'Create a recurring event.');
$GLOBALS['TL_LANG']['tl_calendar_events']['repeatEach'] = array('Interval', 'Here you can set the recurrence interval.');
$GLOBALS['TL_LANG']['tl_calendar_events']['recurrences'] = array('Recurrences', 'Set to 0 for unlimited recurrences.');
View
2  system/modules/news/dca/tl_news_feed.php
@@ -20,7 +20,7 @@
* License along with this program. If not, please visit the Free
* Software Foundation website at <http://www.gnu.org/licenses/>.
*
- * PHP version 5
+ * PHP version 5.3
* @copyright Leo Feyer 2005-2012
* @author Leo Feyer <http://www.contao.org>
* @package News
View
1  system/modules/news/languages/de/tl_news.php
@@ -40,6 +40,7 @@
$GLOBALS['TL_LANG']['tl_news']['teaser'] = array('Teasertext', 'Der Teasertext kann in einer Nachrichtenliste anstatt des Nachrichtentextes angezeigt werden. Ein "Weiterlesen …"-Link wird automatisch hinzugefügt.');
$GLOBALS['TL_LANG']['tl_news']['text'] = array('Nachrichtentext', 'Hier können Sie den Nachrichtentext eingeben.');
$GLOBALS['TL_LANG']['tl_news']['addImage'] = array('Ein Bild hinzufügen', 'Dem Beitrag ein Bild hinzufügen.');
+$GLOBALS['TL_LANG']['tl_news']['size'] = array('Bildbreite und Bildhöhe', 'Hier können Sie die Abmessungen des Bildes und den Skalierungsmodus festlegen.');
$GLOBALS['TL_LANG']['tl_news']['addEnclosure'] = array('Anlagen hinzufügen', 'Dem Beitrag eine oder mehrere Dateien als Download hinzufügen.');
$GLOBALS['TL_LANG']['tl_news']['enclosure'] = array('Anlagen', 'Bitte wählen Sie die Dateien aus, die Sie hinzufügen möchten.');
$GLOBALS['TL_LANG']['tl_news']['source'] = array('Weiterleitungsziel', 'Hier können Sie die Standard-Weiterleitung überschreiben.');
View
2  system/modules/news/languages/de/tl_news_feed.php
@@ -20,7 +20,7 @@
* License along with this program. If not, please visit the Free
* Software Foundation website at <http://www.gnu.org/licenses/>.
*
- * PHP version 5
+ * PHP version 5.3
* @copyright Leo Feyer 2005-2012
* @author Leo Feyer <http://www.contao.org>
* @package News
View
1  system/modules/news/languages/en/tl_news.php
@@ -40,6 +40,7 @@
$GLOBALS['TL_LANG']['tl_news']['teaser'] = array('News teaser', 'The news teaser can be shown in a news list instead of the full article. A "read more …" link will be added automatically.');
$GLOBALS['TL_LANG']['tl_news']['text'] = array('News text', 'Here you can enter the news text.');
$GLOBALS['TL_LANG']['tl_news']['addImage'] = array('Add an image', 'Add an image to the news item.');
+$GLOBALS['TL_LANG']['tl_news']['size'] = array('Image width and height', 'Here you can set the image dimensions and the resize mode.');
$GLOBALS['TL_LANG']['tl_news']['addEnclosure'] = array('Add enclosures', 'Add one or more downloadable files to the news item.');
$GLOBALS['TL_LANG']['tl_news']['enclosure'] = array('Enclosures', 'Please choose the files you want to attach.');
$GLOBALS['TL_LANG']['tl_news']['source'] = array('Redirect target', 'Here you can override the default redirect target.');
View
2  system/modules/news/languages/en/tl_news_feed.php
@@ -20,7 +20,7 @@
* License along with this program. If not, please visit the Free
* Software Foundation website at <http://www.gnu.org/licenses/>.
*
- * PHP version 5
+ * PHP version 5.3
* @copyright Leo Feyer 2005-2012
* @author Leo Feyer <http://www.contao.org>
* @package News
View
2  system/modules/rep_base/languages/de/tl_repository.php
@@ -89,7 +89,7 @@
$GLOBALS['TL_LANG']['tl_repository']['relusability'] = 'Version Bedienung';
$GLOBALS['TL_LANG']['tl_repository']['save'] = 'Speichern';
$GLOBALS['TL_LANG']['tl_repository']['shop'] = 'Shop';
-$GLOBALS['TL_LANG']['tl_repository']['showpicture'] = 'Bild in voller Grösse anzeigen';
+$GLOBALS['TL_LANG']['tl_repository']['showpicture'] = 'Bild in voller Größe anzeigen';
$GLOBALS['TL_LANG']['tl_repository']['state'] = 'Status';
$GLOBALS['TL_LANG']['tl_repository']['tag'] = 'Suchbegriff';
$GLOBALS['TL_LANG']['tl_repository']['thumbnail'] = 'Miniaturbild';
View
2  system/modules/rep_client/templates/repository_mgrlist.html5
@@ -55,7 +55,7 @@ $state_options = &$GLOBALS['TL_LANG']['tl_repository_state_options'];
?>
<tr class="datarow">
<td class="col_selectcheckbox"><?php if (property_exists($ext, 'updateLink')): ?><input type="checkbox" name="selectedids[]" value="<?php echo $ext->id; ?>" onclick="enableSelectFunctions()"><?php else: ?>&nbsp;<?php endif; ?></td>
- <td class="col_extension"><?php echo property_exists($ext, 'catalogLink') ? '<a href="'.$ext->catalogLink.'">'.$ext->extension.'</a>' : $ext->extension; ?></td>
+ <td class="col_extension"><?php echo property_exists($ext, 'catalogLink') ? '<a href="'.$ext->catalogLink.'" title="'.$text['showdetails'].'">'.$ext->extension.'</a>' : $ext->extension; ?></td>
<td class="col_version"><?php echo Repository::formatVersion($ext->version); ?></td>
<td class="col_build"><?php echo $ext->build; ?></td>
<td class="col_status"><?php foreach ($ext->status as $sta) echo '<div class="color_'.$sta->color.'">'.sprintf($statext[$sta->text], $sta->par1, $sta->par2).'</div>'; ?></td>
Something went wrong with that request. Please try again.