It’s been a while since this question was asked, but on the off chance that you are still looking for a solution:
items_frame = wp.media.frames.items = wp.media({
title: 'Add to Gallery',
button: {
text: 'Select'
},
library: {
type: [ 'video', 'image' ]
},
});
Related Posts:
- Open media frame and select an attachment
- Switch to the library tab in the media uploader
- How to retrieve a value from an input field in a media view template
- Youtube api – stop video
- TypeError: res.status is not a function
- WP Rest API – How to get featured image
- Is it Possible to Extend WP Customize JS Methods?
- Display attachments by ID in a wp.media frame
- Customizing the 3.5 “Add Media” popup (Backbone.js)
- WordPress Rest API
- Is it possible to enqueue the Youtube API script or does it have to be inline?
- What type of template are WP media-modal’s templates?
- Customizer JS API: Defining control settings
- Headless WordPress: How to authenticate front end requests?
- Customizer JS API: Adding Setting Dynamically Not Working
- Is there a client side API for handling transients or options?
- Restrict file types in the uploader of a wp.media frame
- Rest API invalid nonce with Backbone Client
- Sending custom data with Media Frame Model
- Customizer JS API: Adding a “dropdown-pages” control
- Only displaying zip files with wp media
- window.send_to_editor throws unterminated string literal error when adding image with multi line description
- How to disable inline css styles generated by Gutenberg editor?
- Uppload image from another source wp.media
- Multiple media uploader buttons target only one input on the same page
- Setting/unsetting terms using the Backbone JavaScript client
- WordPress customizer get control
- Get a default value of the Customizer setting using wp.customize API (JS)
- Is there a media_upload_tabs-similar filter to add tabs to the simple/featured image picker?
- I am trying to add current logged in user to my zoho chat
- This page can’t load Google Maps correctly [closed]
- Customizer JS API: Defining active_callback for a section
- Building a Featured Gallery component for Gutenberg
- How to render WP Rest-API Endpoints in a React.js Theme with Woocommerce
- how to use nimble-API and Display data?
- create timestamp links to jump to specific times on rumble videos
- Check if user can in javascript
- wp-api Backbone JS Client fetch options
- WordPress Guternberg Content For React Native
- Access checks with custom REST endpoints and backbone
- Insert HTML markup to page content from the Media Frame modal
- Show sections based on a control in WordPress Customizer using JS API
- I would like to retrive JSON value and display it in wordpress page or widget
- How do I add a class to Customizer preview based on class of Customizer control? (Customizer Javascript API)
- Get a default customizeAction text for a section using Customizer JS API
- Create new product with woocommerce REST API with javascript (clientside)?
- Anyway to disable the auto excerpt creation?
- how to refresh page after user logout with ‘wp_logout_url’?
- Open image gallery on link click
- How do I call for two js files into a custom template?
- How to delay display of page elements until enqueued script has injected html
- load-scripts.php loads incorrect file names
- How to change number field to text field using JS
- Enqueue concatinated JS file in WordPress
- Custom Media Meta fields to alter the generated image HTML that is inserted into a post for my animated GIF image player?
- wp_enqueue_scripts doesn’t work for template pages
- WordPress text widget with onclick function
- Connecting a wordpress site to an AngularJS APP
- Can’t change javascript files
- how to do open a link in a open window from menu bar? [closed]
- Combining results from WP-API using AngularJS
- JavaScript and Google PageSpeed + wp_enqueue_script
- Javascript file doesn’t load
- Script not working in post content
- JavaScript problem in a WordPress PAGE
- How to identify which javascript is being executed
- Put dynamic Javascript in header after doing operations
- Hook into backbone to add js to wp-admin -> media library?
- Unserialize WP_Options options programatically?
- how to include js in widget?
- early enqueueing javascript file in page template, not in functions.php
- Wysiwyg editor not working on 4.2.2
- Editing the source of a display for posts (to category recent)
- Dequeue set-post-thumbnail.min.js
- How to adjust the selector used in JS to target only the one that was clicked on?
- WordPress 4.2 mce-views migration guide?
- Receive “menu-toogle” event from section menu in customizer
- Adding javascript blocks to a single file and adding it to the header
- None of the JavaScript works when using wp_editor
- How would I get this to work – send to post from thick box
- JS files landing on page but not working, using childtheme of twentyeleven
- WordPress 4.1 crashes loading of ArcGIS Javascript API
- jQuery + more won’t load in header
- How to modify a class in load-scripts.js ?
- Convert javascript running xml files to wordpress platform
- WOW.js Script Tag Initialization Header/Footer
- How would I remove an inline googleAPI font script in the the parent theme header.php?
- Remove WordPress default registration client side validation?
- How to integrate a different (JavaScript) editor in WordPress?
- JS enqueue path (localhost)
- Load and execute javascript from body
- Why can’t I load JS script in a plugin?
- Page template dynamic links based on browser size
- javascript errors on mobile browser, not on desktop
- Trigger a function during onload
- Loaded JavaScript file not showing [duplicate]
- WordPress Theme – jQuery JavaScript Library Issue
- I keep getting Javascript error messages
- How to add additional JavaScript code [duplicate]
- custom page url slug needs illegal ?id=1 for javascript