Step 2 of 7
Liferay DXP’s Documents and Media features provide tools for uploading, organizing, and displaying various types of documents and media, including images, audio, and video. For example, you can use Documents and Media for collaborating on files like text documents or spreadsheets, managing collections of images, or simply storing the images that your web content references.
You’ve been using Documents and Media without knowing it. The images you added when creating web content were automatically added to the Documents and Media library. But there’s a more efficient way to add images to Documents and Media. You can add many images at once, directly in the Documents and Media library. This saves you a step when creating content that uses those images. Working directly in the Documents and Media library also lets you organize your files in folders just as you would on a traditional desktop environment.
Now you’ll take advantage of these features in the Lunar Resort.
You still need to create more content in the Lunar Resort, and this content needs images. You’ll upload all these images now in the Documents and Media library:
Open the Menu () and select The Lunar Resort → Content → Documents and Media. The Documents and Media screen appears and displays the Documents and Media library’s Home folder (its root folder). Note that the images you added while creating content earlier are all here.
Click the Add icon () at the bottom-right of the page and select Multiple Documents.
Use the Add Multiple Documents screen to add the images
guide-steve.png. You can either drag and drop the files from your file system to the box, or click Select Files to select the files via a file manager window. If you wish, you can also categorize and describe the files. Click Publish to complete the upload.
Great! The Lunar Resort’s Documents and Media library now contains more images–enough to warrant organizing them in folders.
Your Documents and Media library is now a bit more crowded. It’s time to organize it with folders. Besides basic file organization, you can also use folders for managing access to files via permissions.
Follow these steps to add some folders to the Lunar Resort’s Documents and Media library:
Return to the Documents and Media library’s Home folder.
Click the Add icon () at the bottom-right of the page and select Folder.
Name the folder Web Content Images, and give it the description Images used in Lunar Resort Web Content.
Click Save. This returns you to the Documents and Media library’s Home folder, where your new folder is now available.
Repeat the steps above to folders named Frontpage Images and Lunar Guides to the Home folder.
Sweet! The Lunar Resort’s Documents and Media library now contains two folders. You’ll use them to organize images next.
Before moving your files into the new folders, it’s important to know that you can move files that are currently in use, without issue. For example, if a piece of web content uses an image, and you move that image to a different Documents and Media folder, you don’t need to update that web content with the image’s new location. Liferay DXP maintains such file connections for you.
Follow these steps to move files to your new folders:
Return to the Documents and Media library’s Home folder and check the boxes on the images
Drag and drop the selected images to the Web Content Images folder.
The next screen lets you review and confirm the move. It also lets you change which files are included, and their destination. Leave the default selections and click Move.
Repeat these steps to move the guide images to the Lunar Guides folder and the Home folder’s remaining files to the Frontpage Images folder.
Well done! Now your Documents and Media library contains the images you need for creating more content. You also learned how to upload and manage files in Documents and Media. Next, you’ll learn about creating more complex content and styles using structures and templates.