hamzaalibhatti Posted December 9, 2015 Share Posted December 9, 2015 @kongondo install all the three module in the MarkupSlider.Module file it not get the slider id if i place the slider id in the query slider is showing but the problem exist $sliderId is not getting the id from db yes my error is on the same line if i pass the id in the getreplacement function in query in the place of :id to 1the slider id in db its showing the slider Link to comment Share on other sites More sharing options...
mauricius Posted December 9, 2015 Author Share Posted December 9, 2015 @kongondo install all the three module in the MarkupSlider.Module file it not get the slider id if i place the slider id in the query slider is showing but the problem exist $sliderId is not getting the id from db yes my error is on the same line if i pass the id in the getreplacement function in query in the place of :id to 1the slider id in db its showing the slider Make sure that the field that contains the ID of the slider is called exactly 'Slider1'. If you use only the instruction $page->get('Slider1'), without the module, it should print the ID of the slider. Link to comment Share on other sites More sharing options...
hamzaalibhatti Posted December 9, 2015 Share Posted December 9, 2015 $page->get('Slider1') it returns nothing Link to comment Share on other sites More sharing options...
BitPoet Posted December 9, 2015 Share Posted December 9, 2015 Perhaps a silly question, but is $page actually the page on which you filled in the Slider1 field? 2 Link to comment Share on other sites More sharing options...
mauricius Posted December 9, 2015 Author Share Posted December 9, 2015 $page->get('Slider1') it returns nothing I'm starting to think that the documentation is not clear enough on this point, I should definitely add more information. Let's try to explain better how the module works: Create your slider using the module, suppose that this slider is called Slider1. Define a field of type Slider and give it a name. I'm calling it slider. Add this field to an existing template, for example on the home template. Now go to your pages tree and edit the home page. On the slider field select the slider that you want to display on the page. On your template file use the code $page->get('slider') to get the ID of the Slider1 slider, and pass it to the MarkupSlider module. 1 Link to comment Share on other sites More sharing options...
hamzaalibhatti Posted December 9, 2015 Share Posted December 9, 2015 i filled the slider field in the template name home and get the slider on the same template file and place the code before body I'm starting to think that the documentation is not clear enough on this point, I should definitely add more information. Let's try to explain better how the module works: Create your slider using the module, suppose that this slider is called Slider1. Define a field of type Slider and give it a name. I'm calling it slider. Add this field to an existing template, for example on the home template. Now go to your pages tree and edit the home page. On the slider field select the slider that you want to display on the page. On your template file use the code $page->get('slider') to get the ID of the Slider1 slider, and pass it to the MarkupSlider module. i do the same steps that you advised but it throws the error Link to comment Share on other sites More sharing options...
mauricius Posted December 9, 2015 Author Share Posted December 9, 2015 i filled the slider field in the template name home and get the slider on the same template file and place the code before body i do the same steps that you advised but it throws the error I really don't know how to help you. Just make sure that $page->get('slider') returns a valid slider ID otherwise it will throw that error because you're trying to render NULL. 1 Link to comment Share on other sites More sharing options...
hamzaalibhatti Posted December 9, 2015 Share Posted December 9, 2015 I really don't know how to help you. Just make sure that $page->get('slider') returns a valid slider ID otherwise it will throw that error because you're trying to render NULL. $page->get('slider') returns nothing my issue resolver if this return SliderId Link to comment Share on other sites More sharing options...
manlio Posted January 17, 2016 Share Posted January 17, 2016 This module is really great, thank Mauricius! Do you have any plan to support multilanguage website? I think now is not possible, right? Ciao! Link to comment Share on other sites More sharing options...
horst Posted January 17, 2016 Share Posted January 17, 2016 echo $slider->render($page->get('Slider1'), $includeScript = true, $options = array()); Hm, is 'Slider1' a valid fieldname? I thought fieldnames are only lowercase? Link to comment Share on other sites More sharing options...
kongondo Posted January 17, 2016 Share Posted January 17, 2016 Hm, is 'Slider1' a valid fieldname? I thought fieldnames are only lowercase? And for some unbeknown reason such 'invalid' fieldnames still work! Have tested several times. The latest one was last week. 1 Link to comment Share on other sites More sharing options...
horst Posted January 17, 2016 Share Posted January 17, 2016 (edited) I'm really not sure if this works every time. Lately I have tricked my self with using dashes - - - in fieldnames and not underscores _ _ _ . Fieldcreation was via API, where the fieldname was stored in a class constant: const MYFIELDNAME = 'my-new-fieldname'. The new fieldname of the created field worked out as: 'my_new_fieldname'. Later in the code, where I want access one field with a selector like $page->get("name=" . CLASS::MYFIELDNAME), it doesn't work. I'm not sure if this was with fields of type text / integer or only Page, but I perfectly remember that it hasn't worked. ---- There was also this: https://processwire.com/talk/topic/8709-croppableimage/page-2#entry86866 (read this and the two following posts) Edited January 18, 2016 by horst add link to related issue with croppableimages modules 1 Link to comment Share on other sites More sharing options...
mauricius Posted January 18, 2016 Author Share Posted January 18, 2016 This module is really great, thank Mauricius! Do you have any plan to support multilanguage website? I think now is not possible, right? Ciao! Thank you! Unfortunately this module doesn't use any ProcessWire fields (except for the images). It works only with HTML, therefore at this point building multilanguage sliders is nearly impossible. The only way you could build multilanguage sliders would be creating each time a new slider. However if you have access to your database you can easily use a little trick to speed up the process: add a new row in the slider table for each one of your languages. For example if you have German and English you can add two new rows (let's call them slider_de and slider_en) and you can copy and paste the code column to have the same settings as the original slider. Now you can translate your text in the administration section. As the last step you have to change the type of the Slider field from Slider to TextLanguage. In this way you can reference a different slider for each language, but remember that you have to type in the ID of the slider and not the name. 2 Link to comment Share on other sites More sharing options...
manlio Posted January 18, 2016 Share Posted January 18, 2016 Thank you, I will try your suggestion! Link to comment Share on other sites More sharing options...
deepentim Posted February 4, 2016 Share Posted February 4, 2016 I was able to load the slider images but not the actual slider. In Console it throws error JssorCaptionSlider not defined. Link to comment Share on other sites More sharing options...
mauricius Posted February 4, 2016 Author Share Posted February 4, 2016 I was able to load the slider images but not the actual slider. In Console it throws error JssorCaptionSlider not defined. You have to make sure that the Jssor library is available in the folder /site/modules/ProcessSlider/jssor. Otherwise you can download it from the official website at http://jssor.com/download.html. The module uses only the files in the "js" and "img" folders, specifically the files "jssor.slider.debug.js" in development mode and "jssor.slider.min.js" in production. Link to comment Share on other sites More sharing options...
deepentim Posted February 5, 2016 Share Posted February 5, 2016 I would like to display a full width slider instead of size of pixels defined in ProcessSlider set up page. How can I get full width responsive slider? Link to comment Share on other sites More sharing options...
mauricius Posted February 9, 2016 Author Share Posted February 9, 2016 I would like to display a full width slider instead of size of pixels defined in ProcessSlider set up page. How can I get full width responsive slider? Just check the Responsive/Full Width checkbox! However you still have to define the size of the slider in pixels. Ideally you should set the values based on the largest uploaded image. Link to comment Share on other sites More sharing options...
Juergen Posted February 10, 2016 Share Posted February 10, 2016 I use the latest PW (3.0.7) and unfortunately the slider doesnt fetch any images. I have tried it with 2 pages which have images, but no luck. Best regards Link to comment Share on other sites More sharing options...
mauricius Posted February 10, 2016 Author Share Posted February 10, 2016 I use the latest PW (3.0.7) and unfortunately the slider doesnt fetch any images. I have tried it with 2 pages which have images, but no luck. fyIII2mxw9.gif Best regards Unfortunately I haven't had the opportunity to play with PW 3 yet, so I don't know what's wrong here. Probably something is different in the way that PW fetches images. I'm quite busy by now, but I'll look into it as soon as possible, hopefully next week. 2 Link to comment Share on other sites More sharing options...
Juergen Posted February 11, 2016 Share Posted February 11, 2016 Edit to my last post: Slider works, but if the Images are inside in a repeater field it doesnt fetch the images. I dont know if this is a usual behavior or not. If the Image field ist standing alone it will work in PW 3.0.7. Best regards Link to comment Share on other sites More sharing options...
kemeris Posted March 17, 2016 Share Posted March 17, 2016 Hi all, I have strange problem with this module. My banner contains two slides and module renders both slides at once. Please take a took at screenshot. I would appreciate any help Link to comment Share on other sites More sharing options...
mauricius Posted March 20, 2016 Author Share Posted March 20, 2016 Hi all, I have strange problem with this module. My banner contains two slides and module renders both slides at once. Please take a took at screenshot. I would appreciate any help You need to check if the Javascript code kicks in. Make sure to follow the instructions of the MarkupSlider module or make sure that you have all the JSSOR dependencies on your page. Link to comment Share on other sites More sharing options...
MisterM Posted April 23, 2016 Share Posted April 23, 2016 Hi all, I have strange problem with this module. My banner contains two slides and module renders both slides at once. Please take a took at screenshot. I would appreciate any help I had the same problem and had to remove a part of SliderGenerator.php to make it partially work: \$CaptionSliderOptions: { \$Class: \$JssorCaptionSlider$, \$CaptionTransitions : _CaptionTransitions, \$PlayInMode : 3, \$PlayOutMode : 3 }, Removing this, makes transitions between slides work. But animation of elements doesn't work. All elements of a slide are displayed at once. Something changed inside jssor. Link to comment Share on other sites More sharing options...
mauricius Posted April 24, 2016 Author Share Posted April 24, 2016 I had the same problem and had to remove a part of SliderGenerator.php to make it partially work: \$CaptionSliderOptions: { \$Class: \$JssorCaptionSlider$, \$CaptionTransitions : _CaptionTransitions, \$PlayInMode : 3, \$PlayOutMode : 3 }, Removing this, makes transitions between slides work. But animation of elements doesn't work. All elements of a slide are displayed at once. Something changed inside jssor. Yeah something might have changed in the last few months. As soon as I have a little bit of time I'm going to look into these recent issues with a new fresh PW 3 installation. 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