Viewing 7 posts - 1 through 7 (of 7 total)
Viewing 7 posts - 1 through 7 (of 7 total)
- The forum ‘Requests and Feedback’ is closed to new topics and replies.
Forum closed. Use forum at Wordpress.org: Gmedia Support
Forum
Is there a way to create a shortcode with filter for a taken date?
Like this one:
[gm album=1 query=year=2017&monthnum=06&day=05]
Only for the taken date and not the upload date?
g
Thomas
It will be too complicated to create such query, because you need to transform date to timestamp and find images created between these timestamps.
For example, here is the shortcode for for the date between 2017-06-05 00:00:00 and 2017-06-06 00:00:00:
[gm album=1 query="meta_key=_created_timestamp&meta_value%5B%5D=1496620800&meta_value%5B%5D=1496707200&meta_compare=BETWEEN"]
thank – I can calculate the timestamp value?
g
Thomas
thx – it defiantly not so comfortable. But my 2nd option will also not work. I tried to add a tag like “20180402” to add the crate date as tag to the picture. But it’s not possible to add a numeric only tag.
you can make tag like “2018.04.02”
Hi Rattus
Thank for all the help. The Shortcode with the timestamp is not working on my installation. The 2nd idea with the tag is not a bad idea. but also there is the problem, that I can’t use it directly in my blogs. It’s needed to use the index of the TAG in the query and not the TAG self.
I think there will be at the moment no other solution to create a new gallery for each blog entry manual.
I have a site with blogs (day review of a travel). So my hope was, that have now a solution with gmedia to generate a dynamic Gallery over the Shortcode to present the Pictures taken on that day.
g.
Thomas