Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Pages: 1
#1 2017-08-03 07:53:39
- raminrahimi
- Member
- From: India
- Registered: 2013-03-19
- Posts: 278
i need to have easy photo gallery
curently i’ve a gallery like this:
—> made an article category “gallery”
—> uploading images one by one
—> creating a new article (e.g canada tour) , chose an article image for that, then adding all related photos to the body
it means each article will be my album name and photos will be added to the body area.
but this system is booring to my client, because it will take much time.
when i was working joomla CMS, they had some good plugins like upload multi images, doing auto resize and just chose album name, and publish.
so, anyone plz help me the easy way or any gallery plugin ?
Offline
Re: i need to have easy photo gallery
There are some older multi-upload plugins that still work, but I’m not sure that they work through the images tab (I think most use FTP). The uploading of images is what takes longest for me, too, especially if uploading multiple smd_thumbnail profiles too…
Otherwise, you can use image categories and a custom field or an smd_macro to automate the rest.
Example with a custom field:
- Assign your images to an image category.
- Create a custom_field such as image_gallery_category.
- In your article, put the desired image gallery in your custom field.
- Adapt your page template to output that image gallery if the custom field has been filled out.
Example with an smd_macro:
- Assign your images to an image category
- Install smd_macro
- Create a macro tag, e.g.
ram_img_gallery
that outputs the code for a gallery taking the category as an attribute. - Instruct your client to add the tag
[space]<txp:ram_img_gallery category="my-gallery-category" />
to the article body wherever they want a gallery to appear.
You can adapt the latter with other types of galleries, sliders, image sets, or to use image_ids instead of categories. It’s quite flexible, especially if you need galleries, sliders etc. at specific points in your article body.
Another option if you have a section of the site just with galleries:
- Create an
image-galleries
parent category, and then create sub-categories for each of the galleries. - Assign the images to the respective image sub-categories.
- Create a page_template for your gallery section that does
txp:category_list parent="image-galleries" children="1" exclude="image-galleries" …
and outputs the gallery code for each image category.
With this method, your client just needs to create a sub-category and assign the images to it to create a new gallery…
PS: There’s also smd_imagery
TXP Builders – finely-crafted code, design and txp
Offline
Re: i need to have easy photo gallery
raminrahimi wrote #306527:
curently i’ve a gallery like this:
—> made an article category “gallery”
—> uploading images one by one
—> creating a new article (e.g canada tour) , chose an article image for that, then adding all related photos to the body
it means each article will be my album name and photos will be added to the body area.but this system is boring to my client, because it will take much time.
Boring, indeed. But you can assign multiple images to articles, then use <txp:images />
(thanks GugUser) to output the gallery. If needed, the first image can be separated from the rest (with limit
and offset
).
To upload multiple article images, you could tweak this plugin.
Last edited by etc (2017-08-03 16:19:08)
Offline
#4 2017-08-03 13:03:34
- GugUser
- Member
- From: Quito (Ecuador)
- Registered: 2007-12-16
- Posts: 1,473
Re: i need to have easy photo gallery
etc wrote #306530:
(…) you can assign multiple images to articles, then use
<txp:image />
to output the gallery.
The tag ist <txp:images />
.
Offline
#5 2017-08-03 13:34:58
- uli
- Moderator
- From: Cologne
- Registered: 2006-08-15
- Posts: 4,306
Re: i need to have easy photo gallery
Two useful plugins I was reminded of while reading jakob’s proposals:
smd_write_cats (create categories from the Write page)
abl_dropload (multi-image dragndrop uploader for the Write page, assigns categories to images)
EDIT: Is there already a plugin to place snippets (smd_macro) right amidst the body text of an article? If not: I’m quite certain that with little effort rah_textilebar could be hacked to accomplish that, I’ve once done that for inserting spans or the like containing a CSS class.
Last edited by uli (2017-08-03 13:41:25)
In bad weather I never leave home without wet_plugout, smd_where_used and adi_form_links
Offline
Re: i need to have easy photo gallery
uli wrote #306532:
Is there already a plugin to place snippets (smd_macro) right amidst the body text of an article? If not: I’m quite certain that with little effort rah_textilebar could be hacked to accomplish that, I’ve once done that for inserting spans or the like containing a CSS class.
Tagbuilder, to some extent, though it’s not (yet) visible on Write tab and does not include plugins tags. The second point is not evident to fix since tags do not register their attributes atm. The first point should be fixed, imo.
Offline
Pages: 1