Uploads Block

Added in 1.1.0. The Uploads block (lh-share-target/uploads) is an upload form for any page. It exists because iPhones cannot use an installed web app as a share target, so this is the iOS route into the same pipeline as the Android share sheet.

What people see

Settings

How it works

The form is rendered on the server. Its script posts the files, title and note as multipart/form-data to the share endpoint (lh-share-target/v1/receive) with the REST nonce, so the request is authenticated as the logged-in user. The endpoint stages the upload exactly as a share from the share sheet. The form needs JavaScript; without it a notice is shown.

Private staging

Since 1.1.1 every share is staged as a private lh_share post, and its files as inherit attachments inserted with wp_insert_attachment(), so their path is known when add_attachment fires. LH Private Uploads keys privacy on post status, so where it is active the files go straight into the site’s private directory, outside the web root. There is no direct dependency: without LH Private Uploads the files stay in normal uploads.