Make WordPress Core

Changeset 54228


Ignore:
Timestamp:
09/19/2022 11:32:10 PM (19 months ago)
Author:
joedolson
Message:

Media: Set https as placeholder for embedding media from URL.

Change the "Insert from URL" field in the media library to use a placeholder suggesting the https:// protocol instead of a value attribute with http://.

Props Presskopp, adamsilverstein, joyously, thijso, joedolson, costdev.
Fixes #53404.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/js/media/views/embed/url.js

    r50547 r54228  
    4949        }
    5050
    51         this.input.value = this.model.get('url') || 'http://';
     51        if ( this.model.get( 'url' ) ) {
     52            this.input.value = this.model.get('url');
     53        } else {
     54            this.input.setAttribute( 'placeholder', 'https://' );
     55        }
     56
    5257        /**
    5358         * Call `render` directly on parent class with passed arguments
Note: See TracChangeset for help on using the changeset viewer.