Random Photo / Video Gallery Display
|
Posted
#68809
(In Topic #14606)
|
|
|---|---|
|
Well-settled |
Display random pictures/videos from the galleryI am migrating from PHP Fusion to ocPortal. So far, I'm impressed with the features it has come with. As much as I loved PHP Fusion and found it very easy to use, it was just filled with bugs and as much as I tried to re-code many of them, there are just some that are way too hard to re-code, and it has kind of rendered my site almost useless beyond the first few pages. So I needed a switch. I attempted a go at WordPress/BuddyPress and it didn't go so well. I was in the process of learning Joomla and in my search for a plugin to make it compaitbile with previous versions, I discovered ocPortal. And though ocPortal is going to take some time to learn, as it is a mostly completed CMS with many things already built in, I was immediately won as it contains everything I need, including a point system which gives the users several things to do in order to even want to remain on the site.. a point store, games, etc., and even a chance to sell "ad space" for points which is a great idea and encourages users to participate on the site. There are / were two things that I had on my site when I was using PHP Fusion, and that was a gallery panel that displayed videos AND/OR photos and I could display randomly however many I wanted using the Rand() function. Is this possible to do with ocPortal? Thanks in advance. |
|
Posted
|
|
|
ocStaff (admin) |
The main_content block can randomise against gallery images. If I answered something that you think should be in the documentation, please take the initiative and add it to the community documentation. We really need people to help out here and build a well-organised large support resource. |
|
Posted
|
|
|
Well-settled |
|
|
Posted
|
|
|
ocStaff (admin) |
If I answered something that you think should be in the documentation, please take the initiative and add it to the community documentation. We really need people to help out here and build a well-organised large support resource. |
|
Posted
|
|
|
Well-settled |
Hehe jk. I'll be around. Definitely want to learn this whole system.. only took me a week to catch on to php itself and php fusion. And I like the fact that, although a major complaint is that it is a small community.. it is what makes it unique.. and the creation of such websites using this particular CMS which probably isn't too buggy in its main scripts, might make it even more unique. Thanks again Chris. |
|
Posted
|
|
|
ocStaff (admin) |
If I answered something that you think should be in the documentation, please take the initiative and add it to the community documentation. We really need people to help out here and build a well-organised large support resource. |
|
Posted
|
|
|
Well-settled |
I was hoping to put a panel on top of the front page with 5 or so random videos from any of the video galleries, like a teaser. If it's the teaser that does that.. the videos and images are not displaying at all. |
|
Posted
|
|
|
ocStaff (admin) |
When you say 'download', are you talking about the downloads addon, or referring somehow to the videos being downloaded? If it's the former, if you use the 'Add block' tool/button to add the block it let's you pick the content type you want, including video. If it's the latter, I'm not sure I understand the issue. (btw I think main_multi_content can probably do it to pick 5 random ones which is better than using main_content 5 times, but I can't remember off-hand.) I'm not sure what you mean by 'teaser'. You said 'like a teaser' (i.e. you introduced the term), but then asked if it's the teaser that does that, so I'm not sure if you're referring to two different kinds of teaser there or not. If I answered something that you think should be in the documentation, please take the initiative and add it to the community documentation. We really need people to help out here and build a well-organised large support resource. |
|
Posted
|
|
|
Well-settled |
What I was looking for is displaying a block of 5 random videos from the video galleries which will be displayed each time the page is refreshed. Just so that my visitors/members are more likely inclined to click on a random video in the panel than go searching through the galleries when they first visit. And main_multi_content is the same as main_content, but maybe for multiple files: it takes me to: Add a New Download.
Last edit: by Xarex
|
|
Posted
|
|
|
ocStaff (admin) |
If I answered something that you think should be in the documentation, please take the initiative and add it to the community documentation. We really need people to help out here and build a well-organised large support resource. |
|
Posted
|
|
|
Well-settled |
Code
[block=gallery]main_content[/block]
This brings up either a photo gallery or the multi-content displays the actual galleries. My code name for where all the videos are located is called 'ytv' or Videos. Code
[block=videos][/block]
Do you know what the proper code would be to display only 5 random videos from the galleries? |
|
Posted
|
|
|
ocStaff (admin) |
If I answered something that you think should be in the documentation, please take the initiative and add it to the community documentation. We really need people to help out here and build a well-organised large support resource. |
|
Posted
|
|
|
Well-settled |
So I don't write this at all: block main_multi_content /block Another route through clicking Add Block. I am trying to familiarize myself with ocPortal and where things are.. I know where mostly everything is, but I'm not sure how to add custom block. Where is this button? Ultimately, the outcome will look something like this:
Last edit: by Xarex
|
|
Posted
|
|
|
Community saint |
|
|
Posted
|
|
|
Well-settled |
Thank you gentleman for your help. Not sure why I missed that button. As for displaying multi-content, it displays the videos way too large. I would just like a horizontal row of them, like shown above. Not a huge problem though, I can work with one video.
Last edit: by Xarex
|
1 guests and 0 members have just viewed this: None
Control functions:








Last edit: by 