Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-36112

Importing entries into a database activity generates php warnings

XMLWordPrintable

    • MOODLE_23_STABLE
    • MOODLE_24_STABLE
    • wip-MDL-36112-master
    • Hide

      Pre-requisites

      • Debugging should be set to "Developer" level.

      Testing: Import of csv file.

      1. Create a database activity.
      2. Create two fields: A URL and a text area.
      3. Create a csv file with contents similar to what is mentioned in the description.
      4. Import the file [Settings ► Database activity administration ► Import entries].
        Check that no php warnings are generated when importing the file.

      Testing: URL form aesthetics.

      1. Click the 'Add entry' tab.
        Observe that the 'Choose a link...' button is next to the URL field.
      2. Click the 'Fields' tab and edit the url field type.
      3. Check 'Autolink the URL'.
      4. Click the 'Add entry' tab.
        Observe that the 'Choose a link...' button is next to the URL field.
      Show
      Pre-requisites Debugging should be set to "Developer" level. Testing: Import of csv file. Create a database activity. Create two fields: A URL and a text area. Create a csv file with contents similar to what is mentioned in the description. Import the file [Settings ► Database activity administration ► Import entries] . Check that no php warnings are generated when importing the file. Testing: URL form aesthetics. Click the 'Add entry' tab. Observe that the 'Choose a link...' button is next to the URL field. Click the 'Fields' tab and edit the url field type. Check 'Autolink the URL'. Click the 'Add entry' tab. Observe that the 'Choose a link...' button is next to the URL field.

      Here is the contents of my csv file. It imports successfully but I get the following php warnings. My database activity contains a URL and a text area field.

      myblog, about me
      http://bob.com,I am bob. Fear me.
      http://joe.com, I am joe. I like Joe. Joe good.
      http://blamo.com,blamo i am.
       
       

      Notice: Undefined offset: 1 in /home/andrew/Desktop/code/moodle/int/master/mod/data/import.php on line 162 Added 1. Entry (ID 1)
      Notice: Undefined offset: 1 in /home/andrew/Desktop/code/moodle/int/master/mod/data/import.php on line 162 Added 2. Entry (ID 2)
      Notice: Undefined offset: 1 in /home/andrew/Desktop/code/moodle/int/master/mod/data/import.php on line 162 Added 3. Entry (ID 3)

            abgreeve Adrian Greeve
            andyjdavis Andrew Davis
            Frédéric Massart Frédéric Massart
            Dan Poltawski Dan Poltawski
            Rajesh Taneja Rajesh Taneja
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved:

                Error rendering 'clockify-timesheets-time-tracking-reports:timer-sidebar'. Please contact your Jira administrators.