Go Headless

/

Velo
Articles
API Overview
Getting Started
Tutorials
Velo Package Readmes
Release Notes

Velo-Only APIs
About Velo-Only APIs and the SDK
$w
$widget
wix-animations-frontend
wix-configs-backend
wix-http-functions
wix-realtime-backend
wix-application
wix-editor
wix-widget

APIs
About Velo APIs and the SDK
wix-activity-counters.v2
wix-analytics.v2
wix-auth
wix-billing.v2
wix-billing-backend
wix-blog-backend
wix-bookings-frontend
wix-bookings.v1
wix-bookings.v2
wix-bookings-backend
wix-business-tools.v2
wix-cache-backend
wix-captcha.v2
wix-captcha-backend
wix-chat-backend
wix-comments.v2
wix-crm-frontend
wix-crm.v2
wix-crm-backend
wix-dashboard
wix-dashboard-management.v2
wix-data
wix-data.v2
wix-ecom.v2
wix-ecom-frontend
wix-ecom-backend
wix-email-marketing.v2
wix-events-frontend
wix-events.v2
wix-events-backend
wix-fetch
wix-forms.v2
wix-forum.v2
wix-forum-backend
wix-groups.v2
wix-groups-backend
wix-inbox.v2
wix-location-frontend
wix-loyalty.v2
wix-marketing-backend
wix-marketing.v2
wix-marketing-tags.v2
wix-media-backend
wix-media.v2
wix-members-frontend
wix-members.v2
wix-members-backend
wix-mobile
wix-multilingual.v2
wix-navigate-mobile
wix-pay-frontend
wix-pay-backend
wix-payment-provider-backend
wix-pricing-plans-frontend
wix-pricing-plans.v2
wix-pricing-plans-backend
wix-pro-gallery-backend
Introduction
Creating a Gallery
Tutorial: Display a Pro Gallery on Your Site
ProGallery
wix-realtime-frontend
wix-reviews.v2
wix-restaurants.v2
wix-search
wix-secrets-backend
wix-secrets-backend.v2
wix-seo-frontend
wix-site-frontend
wix-site-backend
wix-storage-frontend
wix-storage-mobile
wix-stores.v2
wix-stores-frontend
wix-stores-backend
wix-table-reservations.v2
wix-tags.v1
wix-urls.v2
wix-web-module
wix-window-frontend
wix-site-plugins.v1

Events & Service Plugins
About Events & Service Plugins and the SDK
Activity Counters
Automations
Billing
Bookings
Business Tools
Comments
CRM
Data
eCommerce
Email Marketing
Forms
Forum
Groups
Inbox
Loyalty
Marketing
Marketing Tags
Media
Members
Pricing Plans
Payments
Pro-Gallery
Routers
Site Monitoring
Stores
Table Reservations
Wix Events

Creating a Gallery

There are 2 ways to create a pro gallery:

Scenario 1: Creating a Pro Gallery using the Editor (Recommended)

When you add a pro gallery element to your site using the Add Panel in the Editor, a corresponding pro gallery is automatically created on your site's backend. These 2 galleries are synced, and have the same gallery ID. Changes to the pro gallery element in the UI affect the corresponding pro gallery on your site's backend, and changes to the pro gallery on your site's backend affect the corresponding pro gallery element on your site.

Diagram1

Scenario 2: Creating a Pro Gallery using the Pro Gallery Backend API (Not recommended)

Important: This scenario is not recommended because it has limitations and requires extra steps.

When you create a pro gallery on your site's backend, it is a standalone gallery as there isn't a corresponding frontend pro gallery element. However, you may want to display a pro gallery from your site's backend on your site.

For example, let's say you have a site with a pro gallery element and you want to display different galleries for each site member who logs in to your site. You can use the Pro Gallery Backend API to store the pro galleries in the backend instead of overloading the frontend. You can then display the relevant pro gallery from your site's backend on your live site for each site member who logs in.

Doing this requires a few steps. Currently the pro gallery backend API and the frontend $w() Gallery API have different formats, so you need to convert the backend gallery items to the frontend gallery items format. You can then import the converted items to your page code, and set the converted items to the items of a particular gallery element on your site. This temporarily overrides the frontend gallery element's items with the converted backend gallery items. However, the pro gallery element's ID remains the same. For example, if you call the getGallery() function with the gallery element's ID, the original gallery element's items are returned, and not the converted backend gallery items. To learn more, see Displaying a Pro Gallery on Your Site Using the Pro Gallery Backend API.

Limitations

Note the following limitations when converting backend gallery items to the frontend $w() Gallery items format. To avoid these limitations, use scenario 1 instead.

  • text items in your backend gallery won't appear on your site. This is because text items can't be converted to the frontend $w.Gallery() items format.
  • Items in your backend gallery that contain a link with text won't appear on your site. This is because the text property in the item's link object can't be converted to the frontend $w.Gallery() items format.

Diagram2

Did this help?