Suppose you want to open the modal to the create gallery section:
var options = {
frame: 'post',
state: 'gallery',
title: wp.media.view.l10n.createGalleryTitle,
multiple: true
};
var frame = wp.media.editor.open(null,options)
If you want something else, I suggest you search through the core js source to change the Library ID as appropriate for the section you need.
Related Posts:
- Custom “Uploads” Dir: “Edit Image” in Media Library broken
- Restrict file types in the uploader of a wp.media frame
- Only displaying zip files with wp media
- Insert HTML markup to page content from the Media Frame modal
- Trigger refresh for new media manager in 3.5
- Javascript WP Object Documentation?
- What type of template are WP media-modal’s templates?
- Modify Custom Field in Media Library using JavaScript
- Filter medias from the Media Uploader (wp.media) modal with a post meta
- What is “open()” in MediaUpload?
- How to retrieve a value from an input field in a media view template
- Uppload image from another source wp.media
- Search media with javascript
- Media library not working with wp_editor() on the front end
- WordPress Media Library: Custom tab content displayed in “Media Library” tab
- Manually mark imported photo as selected in media library
- Modal working only on home page
- Is there a media_upload_tabs-similar filter to add tabs to the simple/featured image picker?
- Update media library attachments
- How to locate the js code and php code for certain function?
- How to validate image with specific height and width selection in media selector
- Custom Media Meta fields to alter the generated image HTML that is inserted into a post for my animated GIF image player?
- Is there any halfway decent documentation on the wp.media JS class?
- How can I submit a form using JavaScript?
- How do I get the current date in JavaScript?
- How to do a redirect to another route with react-router?
- Jest spy on functionality
- Use a JSON array with objects with javascript
- Toggle show/hide on click with jQuery
- How to create a GUID / UUID
- How does “/\s/g” replace spaces with other characters?
- What is the correct way to check for string equality in JavaScript?
- JavaScript TypeError: Cannot read property ‘style’ of null
- How to obtain username from Promise
? - How do you check if a variable is an array in JavaScript?
- Understanding React-Redux and mapStateToProps()
- ReferenceError : window is not defined at object.
Node.js - Node.js Port 3000 already in use but it actually isn’t?
- Uncaught TypeError: $.post is not a function
- Unable to verify leaf signature
- When and why to ‘return false’ in JavaScript?
- In angularjs we are having ng-disabled directive, why ng-enabled directive is not provided by the framework as we are having ng-show and ng-hide
- Send POST data using XMLHttpRequest
- querySelector vs. getElementById
- Google weather widget on my website
- How to format numbers as currency strings
- Understanding how data-dismiss attribute works in Bootstrap
- Add table row in jQuery
- Node.js document is not defined
- Create table with jQuery – append
- When is JavaScript synchronous?
- How to reset a form using jQuery with .reset() method
- Uncaught ReferenceError: Firebase is not defined
- Permutations in JavaScript?
- How do I remove documents using Node.js Mongoose?
- node-request – Getting error “SSL23_GET_SERVER_HELLO:unknown protocol”
- Count the number of occurrences of a character in a string in Javascript
- Javascript removeEventListener not working
- Load image with jQuery and append it to the DOM
- javascript unexpected identifier
- How to send email by using javascript or jquery
- Access to Image from origin ‘null’ has been blocked by CORS policy
- Onclick on bootstrap button
- TypeError: res.json is not a function
- How to do case insensitive string comparison?
- Understanding the ngRepeat ‘track by’ expression
- How can I test if a letter in a string is uppercase or lowercase using JavaScript?
- JavaScript post request like a form submit
- Jest encountered an unexpected token
- How to get the first element of an array?
- How to check if the URL contains a given string?
- How to enable CORS in AngularJs
- bootstrap buttons onclick events
- Cannot read property ‘forEach’ of undefined
- JavaScript: function returning an object
- What are the benefits of using wp_enqueue_script?
- Is it Possible to Extend WP Customize JS Methods?
- ThickBox replacement
- Load multiple Javascript scripts
- WP script versioning breaks cross-site caching?
- Is there a client side API for handling transients or options?
- How should I add JavaScript to a child theme?
- Create user from outside WordPress through api?
- Load plugin JS in footer
- Using wp_localize_script inside template page to transfer var from php to js
- Setting a menu link to open a pop-up
- Tinymce.js editor in Chrome?
- How to include a JSON file on my page?
- Gutenberg consume wp-json data and reflect in frontend the content
- How to add “on change” to a text input in contact form7?
- JavaScript Libraries in WordPress
- How to use WP switchEditors.switchto(this) JS function in your own script?
- overwrite wordpress gallery with custom gallery shortcode
- Landing function through URL
- Escaping quotes while enqueuing scripts
- Changed media upload path for plugin, but generates error & shows wrong url
- Combining results from WP-API using AngularJS
- Anyway to disable the auto excerpt creation?
- How do I cycle a JS function in WordPress? [closed]
- Use add_action to run a script, but only on the post editor page