14 Replies Latest reply on Mar 14, 2006 6:16 PM by ilangocal

    Image galery module dev

    maitreya

      Hi there !

      This is my first post on this forum so I M VERY PLEASED TO MEET THIS COMMUNITY ;)


      I have a question about a module i had to work on, it's a gallery module which will contains about 5000 - 15000 photos for the first time.
      What is the best way to put the images on the server ?
      I'm currently working with ear which is not the best way and i do not
      want to upload all the images by using the FileEJB ! is there a way
      to put a direct reference to a directory like in standard Web Server ?

      It's my first involvment in the J2EE so any help will be appreciate :) !

      THX

        • 1. Re: Image galery module dev
          cnovara

          I work with a lot of images too and I have some ideas about file upload in nukes.

          First to preserve the CMS philosophy, images must be loaded into db, and managed/versionned by the HTML module ;

          BUT uploading each image file by hand is not possible ;

          So what about managing image file hierarchy on a standard filesystem, and then update nukes HTML file structure by uploading the whole directory, passing the directory root as a parameter to the new module.

          The module could test a file modification (checksum ?), creating a new version, "unprod" deleted files, creating new ones etc ... to keep nukes repository consistant with the file structure.

          Basically this module could be an extension of the existing HTML module but taking a directory as the upload parameter, thus keeping the advantages of the two worlds : DB et file system.

          Any comments ?

          • 2. Re: Image galery module dev

            someone worked on importing a zip file in the database that contains a heirarchy of files

            isnt it what you want ?

            • 3. Re: Image galery module dev
              maitreya

              In fact, i have created an external DB in the nukes data directory called IcarusDB , it will be used to store the references to the images.

              Something like /imgs/architecture/metz/stjacques.jpg in the field Location of the Table that can have several more fields like description, etc

              and i would like to display the image by using the url http://myhost/imgs/architecture/metz/stjacques.jpg

              not http://myhost/imgs/architecture/metz/stjacques
              that could have been configured in the html module

              I have started to read the source to find how to directly display image but i have no idea for now !

              • 4. Re: Image galery module dev
                theute

                You can put the

                http://myhost/imgs/architecture/metz/stjacques.jpg

                in the HTML module, there is nothing wrong with that.

                • 5. Re: Image galery module dev
                  maitreya

                  Maybe my question is not clear but i think it's a tedious way to
                  use the html module to upload the image. i will work on the Zip solution
                  or the direct ressources access. THX for your help :)

                  • 6. Re: Image galery module dev
                    cnovara

                    I use another way to achieve this.
                    To serve big amount of downloads (static content), it's better to use Apache instead of Tomcat.
                    This way I manage a complete directory out of Nukes, with classic Apache Locations/Directories, that I synchronize with Nukes DB wich contains links (this could be automatic).
                    Anyway, Apache is always in front of Tomcat, because it's more versatile.

                    See enfanceetcroissance.com

                    • 7. Re: Image galery module dev
                      maitreya

                      Thx for your help !

                      finally i've used the Zip way ( cooper ;) ) to upload the content beause i'm not using apache !

                      Bravo les petits francais LOL !

                      • 8. Re: Image galery module dev
                        lepe

                         

                        "cnovara" wrote:
                        I use another way to achieve this.
                        To serve big amount of downloads (static content), it's better to use Apache instead of Tomcat.
                        This way I manage a complete directory out of Nukes, with classic Apache Locations/Directories, that I synchronize with Nukes DB wich contains links (this could be automatic).
                        Anyway, Apache is always in front of Tomcat, because it's more versatile.

                        See enfanceetcroissance.com


                        Could you please explain some more regarding how you done this!? What is the setup on Apache side and on JBoss/Tomcat/Nukes side?

                        So, the result of this is that when you in Nukes selects a link to some static stuff this is served by Apache and not Tomcat?

                        Thanks,
                        /L

                        • 9. Re: Image galery module dev
                          javajenks

                          Is anyone porting the php gallery module, that runs under phpNuke ?

                          • 10. Re: Image galery module dev
                            theute

                            Some people were talking about it but AFAIK there is nothing done so far.

                            • 11. Re: Image galery module dev

                              What you are doing for the image gallery module sounds similar to what I was looking into for the download module - uploading a file and unzipping to a directory and maintaining a link to the files. The uploading of files/zip to a directory could be a jar or something in common which could be added to the downloads module as well as the image gallery module.

                              Danny

                              • 12. Re: Image galery module dev

                                In fact i wanted to upload a Zip file and use some of the my links to point to the files in the zip. eg, if the zip has "a/b/1.html" i wanted to use this in my pages.

                                JULIEN said:

                                someone worked on importing a zip file in the database that contains a heirarchy of files

                                isnt it what you want ?


                                and also the last comment from Danny. I tried to use the Html module, which allowed me to access the Zip file but not the contents directly as i mentioned above.

                                JULIEN, MAITREYA : Could you give some details on how you did this ?

                                • 13. Re: Image galery module dev
                                  cnovara

                                  Hi lepe.

                                  Managing static content can be achieved in two ways :

                                  The Apacha way, if you use it in front of tomcat. That's pure http.conf hack, so this forum is not the right place to discuss it, contact me.

                                  The tomcat way. You can create an additional static context in Tomcat, not linked with nukes (see my previous reply http://jboss.org/index.html?module=bb&op=viewtopic&t=57461)

                                  The former is far more powerfull, the later far more simple.

                                  see http://enfanceetcroissance.com
                                  see http://gitesprovence.fr.to

                                  • 14. Re: Image galery module dev

                                    hi Everbody
                                    I have been trying out the Image gallery portlet on JBoss 2.2. It does not work well at all. I am not sure if I am doing things right.

                                    I see that you gentlemen have all been working on the Image Portlet. Could you tell me what to do?

                                    many thanks