We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 9532
    • 9 Posts
    Hi,

    I have searched the forums but couldn’t find which image gallery software best works with MODx. We’re setting-up a MODx hosting service with a number of preinstalled tools for site owners without skills id development. So I need your recommendation for Photo gallery / Image galley.

    I’ve seen someone teste Simpleviewer (we have it in our software library) and Gallery 2. Did you try to integrate Zenphoto with MODx?

    I appreciate your comments.
      HostColor.com - Quality MODx Web Hosting
      • Studying MODX in the desert - http://sottwell.com
        Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
        Join the Slack Community - http://modx.org
        • 13726
        • 16 Posts
        I too am having difficulties finding the perfect image gallery, maybe because I am not a web designer/developer or any of that, but I am learning smiley

        I have been searching for weeks, and have been testing almost every image gallery I can get my hands on, and nothing seems to fit my needs. I volunteer for Arizona Beagle Rescue, and have been spening sometime redeveloping their website (old --> www.azbeaglerescue.com) (new test site --> www.azbeaglerescue.azmarketingpros.com). I am really pulling my hair out here on how to make it a easy web based program so that any of our volunteers can logon and update the adoption photo gallery.

        MaxiGallery I have installed, and working, but don’t know java script well enough to add description fields to the images.

        I like the G2 mod because its so easy for the enduser to upload, and update the adoption photo’s, and i can add as many custom fields as I like. However, I can’t get the g2 mod to work with my site. It installed just fine after hours of guessing on the path names, but I just couldn’t get the images to show on my site.

        So now I have everything uninstalled, and just don’t know where to go from here.

        I would really appreciate anyone who has any advice for me.

        Thanks,
        Julie
          • 16680
          • 73 Posts
          Try and have a look at this article from the wiki: http://wiki.modxcms.com/index.php/MaxiGallery:_Front_end_user_created_galleries

          larsb
            Signature on it's way
            • 7923
            • 4,213 Posts
            Quote from: JBCreative at Jul 31, 2008, 10:13 PM

            MaxiGallery I have installed, and working, but don’t know java script well enough to add description fields to the images.
            You don’t need to know javascript to add custom fields to MaxiGallery images. Or that’s not exactly true, it depends on the display style that you choose to use.

            But to add a custom field in MaxiGallery is pretty simple:

            1. First add &customFields=`testfield,anotherfield` to your snippet call to add two new fields.
            2. Second, open up /assets/snippets/maxigallery/templates/managepicturetpl.html template and create new chunk with that content called "mg_managepicturetpl"
            3. In that template, you see the definitions for the picture management field, eg. description field:
            [+maxigallery.strings.description+]:


            <textarea name="[+maxigallery.fieldnames.description+]" rows="4" cols="40" onKeyDown="document.editform.[+maxigallery.fieldnames.modified+].value=’yes’">[+maxigallery.picture.descr:htmlent+]</textarea>

            Duplicate that for the two new fields that you did and place them to the template, for example after the description field. In the example below, I have hardcoded the field descriptions to the template. If you are building multi-language site, you could use the [+maxigallery.strings...+] array and add the translation for the string to the MaxiGallery language file:

            My testfield:


            <textarea name="[+maxigallery.fieldnames.testfield+]" rows="4" cols="40" onKeyDown="document.editform.[+maxigallery.fieldnames.modified+].value=’yes’">[+maxigallery.picture.testfield:htmlent+]</textarea>


            My another field:


            <textarea name="[+maxigallery.fieldnames.anotherfield+]" rows="4" cols="40" onKeyDown="document.editform.[+maxigallery.fieldnames.modified+].value=’yes’">[+maxigallery.picture.anotherfield:htmlent+]</textarea>


            4. Now, make your MaxiGallery use this new custom template by adding following to your snippet call &managePictureTpl=`mg_managepicturetpl`
            5. If you now go to the picture management, you see the two new custom fields that you created and can modify their content, but the content is not shown in the gallery view side yet. For that you need to create a custom templates to show your new fields. The new fields now has placeholders in &galleryPictureTpl and &pictureTpl what are [+maxigallery.picture.testfield+] and [+maxigallery.picture.anotherfield+], so they are just like all the other fields.
            6. To get the new fields showing in normal picture view mode, open up /assets/snippets/maxigallery/templates/picturetpl.html file and create a new chunk with that content called "mg_picturetpl". If you are using embedded view mode, you can skip this and go straight to step 10.
            7. In that template you see various places where [+maxigallery.picture.title+] or [+maxigallery.picture.description+] placeholders are used. To get your new fields showing also, add the [+maxigallery.picture.testfield+] and [+maxigallery.picture.anotherfield+] placeholders to relevant places. The title and description what are shown in the picture view page are in the bottom of the template. The top ones are for various different ways to show the big image. If you don’t have the big image enabled, you only need to modify the bottom of the template.
            8. Now, make your MaxiGallery use this new custom template by adding following to your snippet call &pictureTpl=`mg_picturetpl`
            9. If you now go to your gallery and view a single picture, you will see the content from your custom fields.
            10. To get the new fields showing in embedded picture view mode and/or in gallery thumbnail view, open up /assets/snippets/maxigallery/templates/gallerypicturetpl.html file and create a new chunk with that content called "mg_gallerypicturetpl".
            11. In that template you see various places where [+maxigallery.picture.title+] or [+maxigallery.picture.description+] placeholders are used. To get your new fields showing also, add the [+maxigallery.picture.testfield+] and [+maxigallery.picture.anotherfield+] placeholders to relevant places. There are sections for various different display styles (eg. [+maxigallery.embedtype:is=`smoothgallery`:then=`.... and [+maxigallery.embedtype:is=`slimbox`:then=`.... etc), so choose the correct place. If you do not know what would be the correct place, just add your new placeholders to every place where title and description is used. The title placeholder that is in the bottom of the template is the one that is shown in the thumnail view. So if you don’t want your new custom fields to show in the thumbnail view, do not put them in the bottom of the template.

            That should be it. The only case when you need to know a little bit javascript is if you are using the Picture and thumbnails on same page tutorial from the MaxiGallery wiki. In that case you can refer to this thread.


              "He can have a lollipop any time he wants to. That's what it means to be a programmer."
              • 13726
              • 16 Posts
              OMG THANK YOU Doze. I am in the middle of implementing your instructions, and I got the fields added, however, the name’s are missing from the manage pictures side. I just see : then the text area.
              I am going to keep working on this to try and see if I can fix it, but if your around smiley



              I can see the light at the end of the tunnel!!!!
                • 13726
                • 16 Posts
                Update:

                I still have no text by my new descriptions text areas, and got an error when I tried to type something in the text area.

                Now I got the error to go away, but when I type something in the text area and his save changes, it saves, but then disappears.

                I looked at my database tables, (after finally finding it) and I noticed I have the three new fields there and two other fields that look like errors because i was using ’ instead of ` in my snippet call. So I THINK it created these fields, and I have to manually delete them from my database?

                THEN i thought maybe i have to rysynch my gallery, but then when I hit that button I get this

                Fatal error: Allowed memory size of 10485760 bytes exhausted (tried to allocate 12288 bytes) in /home/azmarket/public_html/azbeaglerescue/assets/snippets/maxigallery/watermark/Thumbnail.class.php on line 183

                Am I asking stupid questions here?
                  • 7923
                  • 4,213 Posts
                  Can you post your template chunks? and also the used snippet call.. (and you are using the v0.6 test version of MaxiGallery, yes?)

                  You can remove the fields that were erroneously done by using alter table functions of the database viewer that you are using. If you cannot find it, just delete the whole table and MaxiGallery will re-create it on first run.


                    "He can have a lollipop any time he wants to. That's what it means to be a programmer."
                    • 13726
                    • 16 Posts
                    I was just in the process of doing that:)

                    Here is my managepictureTpl

                    <div class="managepicturecontainer">
                    <input type="hidden" name="[+maxigallery.fieldnames.pictureid+]" value="[+maxigallery.picture.id+]"/>
                    <input type="hidden" name="[+maxigallery.fieldnames.modified+]" id="[+maxigallery.fieldnames.modified+]" value="no"/>
                    <div class="managepicture"> <a href="[(base_url)][+maxigallery.path_to_gal+][+maxigallery.picture.filename+]" target=_new> <img src="[(base_url)][+maxigallery.path_to_gal+]tn_[+maxigallery.picture.filename+]" alt="[+maxigallery.strings.click_to_zoom+]"/> </a> </div>
                    <div class="shortfields"> ID: [+maxigallery.picture.id+]

                    [+maxigallery.strings.delete+]:
                    <input type="checkbox" name="[+maxigallery.fieldnames.delete+]" value="yes" title="[+maxigallery.strings.check_to_delete_this_picture+]"/>


                    [+maxigallery.strings.hide+]:
                    <input type="checkbox" name="[+maxigallery.fieldnames.hide+]" value="yes" title="[+maxigallery.strings.check_to_hide_this_picture+]" onClick="document.editform.[+maxigallery.fieldnames.modified+].value=’yes’" [+maxigallery.picture.hide:is=`1`:then=`checked="checked"`+]/>


                    [+maxigallery.strings.position+]:
                    <input type="text" size="3" name="[+maxigallery.fieldnames.position+]" id="[+maxigallery.fieldnames.position+]" onKeyDown="document.editform.[+maxigallery.fieldnames.modified+].value=’yes’" value="[+maxigallery.picture.pos+]"/>
                    </div>

                    <br class="clearboth"/>
                    [+maxigallery.strings.title+]:

                    <textarea name="[+maxigallery.fieldnames.title+]" rows="2" cols="40" onKeyDown="document.editform.[+maxigallery.fieldnames.modified+].value=’yes’">[+maxigallery.picture.title:htmlent+]</textarea>


                    [+maxigallery.strings.description+]:

                    <textarea name="[+maxigallery.fieldnames.description+]" rows="4" cols="40" onKeyDown="document.editform.[+maxigallery.fieldnames.modified+].value=’yes’">[+maxigallery.picture.descr:htmlent+]</textarea>


                    [+maxigallery.strings.AdoptionStatus+]:

                    <textarea name="[+maxigallery.fieldnames.adoptionstatus+]" rows="4" cols="40" onKeyDown="document.editform.[+maxigallery.fieldnames.modified+].value=’yes’">[+maxigallery.picture.adoptionstatus:htmlent+]</textarea>


                    [+maxigallery.strings.gender+]:

                    <textarea name="[+maxigallery.fieldnames.gender+]" rows="4" cols="40" onKeyDown="document.editform.[+maxigallery.fieldnames.modified+].value=’yes’">[+maxigallery.picture.gender:htmlent+]</textarea>


                    [+maxigallery.strings.age+]:

                    <textarea name="[+maxigallery.fieldnames.age+]" rows="4" cols="40" onKeyDown="document.editform.[+maxigallery.fieldnames.modified+].value=’yes’">[+maxigallery.picture.age:htmlent+]</textarea>


                    <hr />
                    </div>

                    my picturetpl

                    [+maxigallery.config.display:is=`pictureview`:then=`
                    [+maxigallery.managebutton:isnot=``:then=`
                    <center>
                    [+maxigallery.managebutton+]
                    </center>


                    `+]
                    `+]
                    <div class="picturecontainer">
                    <p class="navigation"> [+maxigallery.counter:is=`1`:or:is=`0`:then=`

                    [+maxigallery.strings.previous+] |

                    `:else=` <a href="[+maxigallery.previous_pic_url+]">[+maxigallery.strings.previous+]</a> |

                    `+] <a href="[+maxigallery.index_url+]">[+maxigallery.strings.index+]</a> |

                    [+maxigallery.counter:is=`[+maxigallery.total_pics_count+]`:then=`

                    [+maxigallery.strings.next+]

                    `:else=` <a href="[+maxigallery.next_pic_url+]">[+maxigallery.strings.next+]</a> `+] </p>
                    <p class="picturecount">[+maxigallery.strings.picture+] [+maxigallery.counter+] / [+maxigallery.total_pics_count+]</p>
                    [+maxigallery.total_pics_count:isnot=`0`:then=`
                    <div class="picture"> [+maxigallery.big_pic_exists:isnot=`0`:then=`

                    [+maxigallery.big_img_linkstyle:is=`slidebox`:then=` <a href="[(base_url)][+maxigallery.path_to_gal+]big_[+maxigallery.picture.filename+]" rel="lightbox" title="[+maxigallery.picture.title:htmlent+] - [+maxigallery.picture.descr:htmlent+] - [+maxigallery.picture.AdoptionStatus:htmlent+] - [+maxigallery.picture.Gender:htmlent+]" - [+maxigallery.picture.age:htmlent+]"> `+]

                    [+maxigallery.big_img_linkstyle:is=`lightboxv2`:then=` <a href="[(base_url)][+maxigallery.path_to_gal+]big_[+maxigallery.picture.filename+]" rel="lightbox" title="[+maxigallery.picture.title:htmlent+] - [+maxigallery.picture.descr:htmlent+] - [+maxigallery.picture.AdoptionStatus:htmlent+] - [+maxigallery.picture.Gender:htmlent+]" - [+maxigallery.picture.age:htmlent+]"> `+]

                    [+maxigallery.big_img_linkstyle:is=`slimbox`:then=` <a href="[(base_url)][+maxigallery.path_to_gal+]big_[+maxigallery.picture.filename+]" rel="lightbox" title="[+maxigallery.picture.title:htmlent+] - [+maxigallery.picture.descr:htmlent+] - [+maxigallery.picture.AdoptionStatus:htmlent+] - [+maxigallery.picture.Gender:htmlent+]" - [+maxigallery.picture.age:htmlent+]"> `+]

                    [+maxigallery.big_img_linkstyle:is=`popup`:then=` <a href="javascript:void(0);" onClick="javascript:openWindow(’[(base_url)][+maxigallery.path_to_gal+]big_[+maxigallery.picture.filename+]’,’[+maxigallery.picture.title:htmlent+]’,[+maxigallery.picture_height_big+],[+maxigallery.picture_width_big+],’gallery’);" title="[+maxigallery.strings.click_to_open_original+]"> `+]

                    [+maxigallery.big_img_linkstyle:is=`external`:then=` <a href="[(base_url)][+maxigallery.path_to_gal+]big_[+maxigallery.picture.filename+]" rel="external" title="[+maxigallery.strings.click_to_open_original+]"> `+]

                    `+]

                    [+maxigallery.keep_bigimg:is=`0`:then=` <a href="[+maxigallery.index_url+]" title="[+maxigallery.strings.click_to_go_back+]"> `+] <img src="[(base_url)][+maxigallery.path_to_gal+][+maxigallery.picture.filename+]" class="imageview" alt="[+maxigallery.strings.date+] : [+maxigallery.picture.date+]" /> [+maxigallery.big_pic_exists:isnot=`0`:then=` </a> `+] </div>
                    `+]

                    [+maxigallery.picture.title:isnot=``:then=`
                    <p class="title">[+maxigallery.picture.title:htmlent+]</p>
                    `+]
                    [+maxigallery.picture.descr:isnot=``:then=`
                    <p class="description">[+maxigallery.picture.descr:htmlent+]</p>
                    `+]
                    [+maxigallery.picture.descr:isnot=``:then=`
                    <p class="AdoptionStatus">[+maxigallery.picture.AdoptionStatus:htmlent+]</p>
                    `+]
                    [+maxigallery.picture.descr:isnot=``:then=`
                    <p class="Gender">[+maxigallery.picture.Gender:htmlent+]</p>
                    `+]
                    [+maxigallery.picture.descr:isnot=``:then=`
                    <p class="Age">[+maxigallery.picture.Age:htmlent+]</p>
                    `+]

                    </div>


                    And my snippet call is

                    [!MaxiGallery? &display=`normal` &pics_per_row=`3` &max_thumb_size=`210` &max_pic_size=`0` &customFields=`AdoptionStatus,Gender,Age` &managePictureTpl=`mg_managepicturetpl` &pictureTpl=`mg_picturetpl`!]

                    I am using the svn version of maxigallery trunk r165 ... i think.
                    • Code is better displayed in forum posts using the code tags (click the # icon to get them inserted automatically) instead of quote tags.
                        Studying MODX in the desert - http://sottwell.com
                        Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
                        Join the Slack Community - http://modx.org