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

When clicking a URL in chat, it should open in a new window or tab

    XMLWordPrintable

    Details

    • Testing Instructions:
      Hide

      Test without URL link filter

      1. Make sure the "Convert URLs into links and images" filter is off ("Site administration" > "Plugins" > "Filters" > "Manage filters" )
      2. Create a course with a chat activity.
      3. Enter the chat.
      4. Enter the following message:

        <a href="http://bit.ly/1Qvxt0N">Hey, that's pretty good!</a>

      5. Inspect the link using your browser's inspector. Verify it has a target="_blank" attribute.
      6. Click the link and make sure the chat window remains, and the link is opened in a new tab.
      7. Verify it is pretty good.

      Test with URL link filter

      1. Make sure the "Convert URLs into links and images" filter is on ("Site administration" > "Plugins" > "Filters" > "Manage filters" )
      2. Enter the chat
      3. Enter the following message

        https://www.youtube.com/watch?v=gbt61vcAkG0

      4. Inspect the link using your browser's inspector. Verify it has a target="_blank" attribute.
      5. Click the link and make sure the chat window remains, and the link is opened in a new tab.

      Test messages

      1. With the URL link filter still enabled, send messages to and from users with URLs in them
      2. Ensure the links produced have a target="_blank" attribute

      Checking for regressions

      1. Do stuff with URLs in other text areas in moodle. Make sure target=_"blank" is not added.
      Show
      Test without URL link filter Make sure the "Convert URLs into links and images" filter is off ("Site administration" > "Plugins" > "Filters" > "Manage filters" ) Create a course with a chat activity. Enter the chat. Enter the following message: <a href="http://bit.ly/1Qvxt0N">Hey, that's pretty good!</a> Inspect the link using your browser's inspector. Verify it has a target="_blank" attribute. Click the link and make sure the chat window remains, and the link is opened in a new tab. Verify it is pretty good. Test with URL link filter Make sure the "Convert URLs into links and images" filter is on ("Site administration" > "Plugins" > "Filters" > "Manage filters" ) Enter the chat Enter the following message https://www.youtube.com/watch?v=gbt61vcAkG0 Inspect the link using your browser's inspector. Verify it has a target="_blank" attribute. Click the link and make sure the chat window remains, and the link is opened in a new tab. Test messages With the URL link filter still enabled, send messages to and from users with URLs in them Ensure the links produced have a target="_blank" attribute Checking for regressions Do stuff with URLs in other text areas in moodle. Make sure target=_"blank" is not added.
    • Affected Branches:
      MOODLE_23_STABLE, MOODLE_24_STABLE, MOODLE_29_STABLE, MOODLE_30_STABLE
    • Fixed Branches:
      MOODLE_30_STABLE, MOODLE_31_STABLE
    • Pull Master Branch:
      MDL-37138-master-2
    • Sprint:
      3.1 Sprint 5, 3.1 Sprint 7, 3.2 Sprint 1
    • Issue size:
      Small

      Description

      Currently in chat, an URL can be shared within a conversation. But when we click it, it opens in the same ongoing chat window. It should open in a pop-up window or in a new tab instead.

      To reproduce this behavior:
      1. Create a chat activity
      2. Share a link
      3. Click on link

      Result: the link opens up in the same windows. While you do not lose the conversation history, it could be nervebreaking for some...

      Is there any way to activate pop-up windows for the chat module ?

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                9 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  11/Jul/16