Uploaded image for project: 'Plugins'
  1. Plugins
  2. CONTRIB-8373

questionnaire restore span

    XMLWordPrintable

    Details

    • Plugin Version:
      3.9.1
    • Affected Branches:
      MOODLE_38_STABLE

      Description

      1.backup a questionnaire with choice that contain a multilang or style span 

      2. restore it 

      3. preview the restored questionnaire - the span is print to the screen 

       

       I saw that the restore code contain this:

      // Replace the = separator with :: separator in quest_choice content.
      // This fixes radio button options using old "value"="display" formats.
      if (($data->value == null || $data->value == 'NULL') && !preg_match("/^([0-9]{1,3}=.*|!other=.*)$/", $data->content)) {
       $content = questionnaire_choice_values($data->content);
       if (strpos($content->text, '=')) {
       $data->content = str_replace('=', '::', $content->text);
       }
      }
      

       

      but I didn't get why replace all the "=" to "::" which casing the problem 

       

       

        Attachments

          Activity

            People

            Assignee:
            mchurch Mike Churchward
            Reporter:
            chenlevy Chen Levy
            Participants:
            Component watchers:
            Mike Churchward
            Votes:
            2 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated: