Forum Replies Created
-
AuthorPosts
-
JasonKeymasterThanks friendlyfire3! We’re always glad to hear when someone thinks Piklist is as awesome as we do! 🙂
I’ve personally thought about making endpoints easier. I think first, though, we want to make sure that all the existing functionality within Piklist works via the api. But it’s definitely a great idea!
JasonKeymasterHey friendlyfire3!
There’s actually a couple different overhauls in the works. First, if you’re using the trunk, the relate data is no longer held in a separate wp_relationships table, but now in the respective meta tables. With that, the relationships were also opened up beyond just post-to-post; it’s now possible to relate users, posts, and comments in any combination (e.g. user-to-user, comment-to-comment, post-to-user, etc.).
Next, not available yet but was just finished internally, we finished a relate_query system (much like meta_query) that will support any combination of conditions. I’m pretty excited about it. 🙂
As for your scenario, I assume you’re using the WP-API v2 plugin? Keep in mind that WP 4.4 only has the core for the api, and none of the endpoints, yet. From there, all you need to do is provide the post_has/post_belongs arguments to the filter in the endpoint. Whatever you put in there is passed directly to the wp_query, like you would normally use.
Hope that helps!
JasonKeymasterHi!
Unfortunately I’m not aware of a script like this, just yet. But that would make for a great add-on in the future! If you do end up throwing together a script, please share it! I’m afraid I haven’t used ACF in quite some time and don’t have time to dig into it just to make a conversion script. Still, I’d love to see this in the future.
February 21, 2015 at 8:50 am in reply to: Using piklist_taxonomies and piklist_post_types breaks WooCommerce endpoints #3335
JasonKeymasterThat’s strange! I’ve used Piklist on a few sites now that use WooCommerce. Obviously follow Steve up on emailing support, but out of curiosity have you tried refreshing the permalinks? Or have you tried using rewrite analyzer (my favorite: https://wordpress.org/plugins/monkeyman-rewrite-analyzer/ and it does still work) to see what happens when you type in the endpoint there?
Hope this helps!
JasonKeymaster@Steve: That’s true, and does make sense. Still, it could be useful to store the date in one format and display it in another, as to make date queries possible. Could be a nice extension to the datepicker field.
JasonKeymasterNormally you’d be able to use the custom field parameters in WP_Query, but Piklist doesn’t store the dates in the necessary YYYY-MM-DD format. I’m not sure why. May be worth changing to make this possible!
JasonKeymasterGreetings!
Someone just made a similar issue here: https://github.com/JasonTheAdams/PiklistHelper/issues/2
So don’t use parse_piklist_array anymore. Once you’ve done that, checkout wp_get_attachment_image_src to retrieve the url for the image id that you’re being returned.
Hope this helps! 🙂
February 3, 2015 at 4:00 pm in reply to: Validation of multiple custom fields at the same time? #3269
JasonKeymasterGreetings! Like Kevin said, in the next version you can view all the fields and validate accordingly. Presently, it’s possible to do this if multiple fields belong to a single group. For an example of this check out the ‘date-range’ validation in PiklistHelper: https://github.com/JasonTheAdams/PiklistHelper/blob/master/PiklistHelper.php#L231
JasonKeymasterI’ve had issues with this as well. The validation and sanitization systems are powerful, but I’ve had issues with them always passing.
JasonKeymasterIf your email is sent immediately when the password is sent, that just means it’s passing the string momentarily to email content and sends the email before password gets encrypted and stored. Nothing to worry about. 🙂
JasonKeymasterHello!
Are you trying to filter the main loop? Or are you trying to retrieve the posts using something like get_posts()?
JasonKeymaster@waterschaats Be careful of using the Google Maps API in the admin-side of your site. I developed a plugin a while ago that handles searching for posts within range by latitude/longitude, and I decided against using a map admin-side. The reason being that it’s actually against the Google Maps API terms of use unless you have a business account with them (which is very expensive). The API is for use up to 25,000 uses/day from a public facing page. In other words, if someone has to log in to see the map, it’s against their terms of use. And I was speaking with a Google rep a couple months ago and they mentioned they’re intending on cracking down on this, as they’re aware that it’s commonly ignored.
Just a friendly warning. 🙂
JasonKeymasterHi @azizultex
Use the PiklistHelper::parse_array function found here: https://github.com/JasonTheAdams/PiklistHelper
That should work for both fields, as it works recursively to support nested groups. If there’s any problems please make an Issue on Github. 🙂
JasonKeymasterWoo! Looking forward to the next beta! 🙂
December 10, 2014 at 9:34 am in reply to: Error when attempting to display a single ungrouped add_more field #3019
JasonKeymasterAs far as the the true/false in the final parameter of the get_post_meta function goes, it’s really a simple concept: true if you want only a single row from the database; false if you want every row it finds that matches the meta name.
The only trick is knowing what’s stored as a single row and what’s not. So here it is:
- Single/Add_More Groups => Single row (true)
- Single non-group field => Single row (true)
- Add_More non-group field => Multiple rows (false)
Really not too bad! 🙂 The only unexpected one is that a group field with add_more is still a single row. The reason for this is that all the data is stored as a single, serialized array.
-
AuthorPosts