michaelR-26
Fils de soutien créés au cours des 30 derniers jours : 0
Sujets de forum favoris
This user has no favorite topics.
Sujets de forum créés
Status | Sujet | Supporter | Voix | Publications | Nouveauté |
---|---|---|---|---|---|
I am using the all import plugin to import fields from a csv, but during the pro
Commencé par : michaelR-26 in: Toolset Professional Support |
|
1 | 2 | Il y a 3 mois | |
Social Share Block not working correctly
Commencé par : michaelR-26 in: Toolset Professional Support |
|
4 | 15 | Il y a 4 années et 3 mois | |
Conditional Fields in CRED form based on Taxonomy selected in custom post type
Commencé par : michaelR-26 in: Toolset Professional Support |
|
3 | 13 | Il y a 4 années et 9 mois | |
Youtube url – related videos
Commencé par : michaelR-26
in: Toolset Professional Support
Problem: I have a custom URL field that my visitors populate using a front-end Form. The URL is a YouTube video URL, and I would like to display the video in an embedded player with the URL parameter rel=0 attached so no related videos are displayed. However, I do not expect my Users to add the rel=0 parameter when they enter the YouTube URL on the front-end. How can I append the URL parameter programmatically in the template when the video is displayed? Solution: You need a custom shortcode to do this. The following can be used as a guide: add_shortcode( 'no-rel-youtube', 'no_rel_youtube_func' ); function no_rel_youtube_func($atts) { global $post, $wp_embed; $atts = shortcode_atts( array( 'field-slug' => 'your-field-slug', 'post-id' => $post->ID ), $atts ); $field_value = get_post_meta( $atts['post-id'], 'wpcf-' . $atts['field-slug'], true ); return $wp_embed->run_shortcode("[embed width='500' height='300']" . $field_value . "&rel=0[/embed]"); } Replace your-field-slug with the slug of the field containing the URL, and adjust the height and width of the embed shortcode as needed. Render the player with the custom shortcode, like this: [no-rel-youtube][/no-rel-youtube] Relevant Documentation: |
|
2 | 7 | Il y a 4 années et 9 mois | |
Images in tempate do not retain the dynamic link assigned
Commencé par : michaelR-26 in: Toolset Professional Support |
|
3 | 4 | Il y a 4 années et 10 mois | |
Cred Forms Conditional fields wrapped in a conditional field?
Commencé par : michaelR-26
in: Toolset Professional Support
Problem: Display different content depends on custom field value. Solution: You can try wpv-conditional shortcode, for example: Relevant Documentation: https://toolset.com/documentation/user-guides/views/conditional-html-output-in-views/ |
|
2 | 6 | Il y a 4 années et 11 mois |