DCuserName
Forum Replies Created
-
Patrick, I must have missed your reply earlier, I’ll try the em_event_save_pre action, that sounds promising! I managed to nerf the whose database last night with one of my experiments, ha, thank various deities for backups….
For what it’s worth, this seems to work.
I created a PHP file containing the shortcode stored as a variable, $eventslist_shortcode, with another variable, $cat_ids, for the actual categories — that could be passed in the URL, from a form submission, from a page’s custom field, etc.
$eventslist_shortcode = '[events_list_grouped mode="monthly" limit="20" category="'.$cat_ids.'"] <-----HTML AND PLACEHOLDER TAGS GO HERE ---> [/events_list_grouped]';
Then created a function in a new page template like this:
include_once(get_stylesheet_directory() . '/some/path/eventlist_shortcode.php'); echo do_shortcode($eventslist_shortcode);
Can be fancied up a bit, but as proof of concept it does what I need, so yay!
And it seems to work so far
Thanks Patrick, I saw that but was hoping to find a hook to be able to change the query pre-display, so that I can make use a single calendar theme template that uses the shortcode, but displays different results based on the custom field from the specific page where the template is used.
I’ll play with the shortcode though, worst case maybe I generate the shortcode to a custom field on each page, then use that on subsequent page loads — a little hacky but it could maybe work….
Thanks!
DavidForum: Plugins
In reply to: [Events Manager - OpenStreetMaps] Location autofillInteresting! Don’t mean to send you down a rabbit hole, hopefully this is useful to you in the larger context of the plugin.
If I try searches at openstreetmap.org, The only way to see a single result is to include both the city and state:
278 S Main Street Independence Oregon
If I use only the city, it returns multiple entries. Technically I think the “S” abbreviation is the correct form for the address in the US though, I could be wrong.
Is it possible to include the same sort of choices that the openstreetmap.org search does? So a list of possible addresses, and no autofill until one is chosen? I don’t know if that’s a feature offered by the API, or would be a huge custom project, just throwing out ideas.
Forum: Plugins
In reply to: [Events Manager - OpenStreetMaps] Location autofillAh, that makes sense, thanks for looking at it. : )
278 S Main Street
Independence
Oregon
Polk County
97351Forum: Plugins
In reply to: [Events Manager - OpenStreetMaps] Location autofillOh, what I meant was that State and Region, while different from each other, will always be the same values, Oregon and Polk County respectively for us.
As an example of the bad behavior, if I put in Monmouth or Independence for the city, it won’t guess the Oregon cities, which is what I want. That in itself wouldn’t be the end of the world, but when I change each field with the correct info, the map doesn’t update again to reflect the changes. I thought I could outsmart it by filling in the fields in reverse (Polk County for Region, Oregon for state, then address, etc.), but when I type the city name in, it changes all of the other fields.
Not your fault at all, but unfortunately it makes it pretty unusable for us right now. I’ll see if I can contact OpenCage for possible solutions, ideally it needs to offer options rather than picking the first match, or look forward to the other fields to narrow the choice, or just have a way to turn off autofill.
Fantastic! Downloading now, will let you know how it works. Thanks for putting this together.
That’s great news! I’ll keep an eye out, what’s the plugin name? Or if you post here when it’s approved, I’ll be among the first beta testers…
Same here. Are any or all of you also running WooCommerce? I have WP 4.7.5, CPTonomy 1.3.6, WC 3.0.7
Just testing this plugin for the first time. It’s exactly what I need, just seems to have issues right now. Would love to hear if anyone has narrowed down the problem or found a workaround.
Forum: Plugins
In reply to: [Polylang] PolyLang and get_posts()Ah! Thanks so much, sorry I missed that. So maybe what I need to do then is write a function that abstracts that a bit, either retrieving posts from the default language first, and splicing in any translations in the current language. That could have a high overhead for performance I guess, but useful in some situations.
I’d still love to hear if anyone has implemented a kind of “clone all to new language” system, copying all content, custom fields, attachments, etc., from the primary language to another. I suppose ideally things should just be carefully translated a piece at a time, and permalink slugs would be better kept in the new language than copied from the old.
Thanks again for a great plugin by the way, so much more stable and usable than others I’ve tried!
DavidForum: Plugins
In reply to: [Yoast Duplicate Post] Action hooks? I want to modify cloned post permalink.Doh! Sorry, I should have looked harder. Thanks for the fast reply!