From 7f008c0502ac81d57118e91e01a82c0b4c114e57 Mon Sep 17 00:00:00 2001
From: robertall <robertall>
Date: Sat, 31 May 2008 15:05:57 +0000
Subject: [PATCH] [MDL-8407] Don't offer the semicolon in the CSV delimiter
 selection menu. Merged from MOODLE_19_STABLE.

---
 mod/data/export_form.php | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/mod/data/export_form.php b/mod/data/export_form.php
index 512173f70b..66545851e2 100644
--- a/mod/data/export_form.php
+++ b/mod/data/export_form.php
@@ -18,6 +18,11 @@ class mod_data_export_form extends moodleform {
         $mform =& $this->_form;
         $mform->addElement('header', 'notice', get_string('chooseexportformat', 'data'));
         $choices = csv_import_reader::get_delimiter_list();
+        $key = array_search(';', $choices);
+        if (! $key === FALSE) {
+            // array $choices contains the semicolon -> drop it (because its encrypted form also contains a semicolon):
+            unset($choices[$key]);
+        }
         $typesarray = array();
         $typesarray[] = &MoodleQuickForm::createElement('radio', 'exporttype', null, get_string('csvwithselecteddelimiter', 'data') . '&nbsp;', 'csv');
         $typesarray[] = &MoodleQuickForm::createElement('select', 'delimiter_name', null, $choices);
-- 
2.39.5