0

My galleria won't work like it does in the showcase. It displays the images all at once with the style of a bulleted list

  • picture 1
  • picture 2

I pretty much copied the code from the showcase website (link). But it doesn't work at all like it should. I used Mozilla Firefox and Internet Explorer for testing. Both same result.

I'm running on a glassfish 5.0. Using Java 8, PrimeFaces 6.0 and JSF 2.1. Both images have a resolution of 711 x 400.

Here is my code.

xhtml

<p:galleria var="currentImage" value="#{homeBean.images}" panelWidth="500" panelHeight="313"
showCaption="true">

  <p:graphicImage value="/image/#{currentImage}"></p:graphicImage>

</p:galleria>

Java-Bean

@ManagedBean
@ApplicationScoped
public class HomeBean {

  private final List<String> images;
  {
    images = new ArrayList<>();
    images.add("image1.png");
    images.add("image2.png");
  }

  public List<String> getImages() {
    return images;
  }

}

But this is how its displayed enter image description here

marc_s
  • 732,580
  • 175
  • 1,330
  • 1,459
Basti
  • 1,117
  • 12
  • 32
  • Did you do a 'view-source' of the page? What did you see? Did you do check the browser console for errors? Did you check the server logs for errors? Did you run the application in development mode? – Kukeltje Jan 15 '18 at 08:40
  • No errors anywhere :^ ) Log empty, debug empty, nothing anywhere.... Browser console shows the html like its supposed to be :/ – Basti Jan 15 '18 at 20:15
  • If you are 100% sure there is no '404' loading the PF css, then you have custom CSS that messes things up. Only thing left to do for you is to create a [mcve] – Kukeltje Jan 16 '18 at 08:03
  • I dont know what magic makes this happen. I developed this on my normal computer. I copied the app on my laptop, installed the same gf version and it runs like warm butter... Reinstalling the gf on my computer doesnt help it there tho... Something must be faulty with my setup. Thanks anyways – Basti Jan 17 '18 at 14:17

0 Answers0