Mable Posted June 25, 2019 Share Posted June 25, 2019 Hi all, I'm new. I've been trying to connect modules for a couple of days, but nothing works. The question is how to connect the modules? Can explain how to include them? Link to comment Share on other sites More sharing options...
wbmnfktr Posted June 25, 2019 Share Posted June 25, 2019 Can you tell more about what you want to accomplish? Installating a module is fairly easy. Connecting them can be difficult sometimes. Link to comment Share on other sites More sharing options...
Mable Posted June 26, 2019 Author Share Posted June 26, 2019 I installed 2 modules but I can figure out how to make them activated. Player PlyrPhotoswipe Gallery <!doctype html> <html> <head> <title><?php echo $page->title; ?></title> </head> <body> <h1><?php echo $page->title; ?></h1> <h2>Type: <?php echo $page->planet_type; ?>, Age: <?php echo $page->planet_age; ?> years</h2> <p><?php echo $page->planet_summary; ?></p> <?php $pwpswp = $modules->get('MarkupProcesswirePhotoswipe'); echo $pwpswp->renderGallery(); $plyr = $modules->get("MarkupPlyrMediaPlayer"); echo $plyr->renderVideoPlayer($poster, $mp4, $webm, $captions); ?> </body> </html> I tried to test on a test page. I added the code as it was written in the tutorial. In the admin panel, I created the fields and connect them to the template. Then through these fields I tried to upload videos and pictures but they did not appear in my template. What am I doing wrong? Link to comment Share on other sites More sharing options...
Mable Posted June 29, 2019 Author Share Posted June 29, 2019 Gosh, tell me how to properly upload a video and display it. Why such simple things are difficult to do. Link to comment Share on other sites More sharing options...
bernhard Posted June 29, 2019 Share Posted June 29, 2019 For creating screencasts you can use https://screencast-o-matic.com/home or https://www.cockos.com/licecap/ Link to comment Share on other sites More sharing options...
dragan Posted June 29, 2019 Share Posted June 29, 2019 Did you notice that one of those modules is not officially stated as compatible with PW3? You should always post module-specific questions in their dedicated support forums, instead of creating a new thread (the blue button on the official module page at the left) At quick glance, I noticed you are not supplying the page field for your Photoswipe gallery. On 6/26/2019 at 8:53 AM, Mable said: echo $pwpswp->renderGallery(); It should be: echo $pwpswp->renderGallery($page->nicePictures); // or whatever you've called your images-field... I have never used any of those two modules. But a potential "gotcha" with outputting files in a template is if you're allowing just one single file or multiple. If you expect an array of items, use $page->fieldName->first()->url (in case of the video file). Depending on your field-settings, you can use one method or another, i.e. if it's set to 1 file only, you can use $page->fieldName->url etc. Do you get errors? If you're in debug mode, you should see errors appearing. Also look at the browser console for JS errors. Finally, if you use Tracy Debugger, you should get hints and more extensive debugging infos. 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now