This topic contains 9 reply and 3 voices, and was last updated by sayyam 6 years, 6 months ago
Viewing 9 Posts - 1 through 9 (of 9 total)
Author Posts
May 16, 2013 at 7:40 pm 3718
sayyam whith front end user pro how can we integerate custom fields like dp_video_file, dp_video_url and dp_video_code i am using detube wordpress theme and want to make a form which enable user to submit the videos front end but they haven't used any custom post, they used default post please help
May 16, 2013 at 8:30 pm 3719
Tareq Hasan Tareq Hasan

What type of value stores in that meta field? Video url?

This plugin usually saves the image/file’s attachment ID in those custom fields. You can get the url’s of those videos/files like this:
[php]
$video_id = get_post_meta( $post->ID, ‘db_video_file’, true );
$video_url = wp_get_attachment_url( $video_id );
[/php]

May 16, 2013 at 8:40 pm 3720
sayyam sayyam

i have gravity forum, it give this option

http://awesomescreenshot.com/0c31a7mu3f

http://awesomescreenshot.com/0c91a7nb4d

that means in Post options at your plugin we are not having such option where we can describe the custom fields of the post

May 16, 2013 at 8:47 pm 3721
Tareq Hasan Tareq Hasan

It’s not like gravity form here, you’ve to explicitly mention the meta key.

May 16, 2013 at 8:50 pm 3722
sayyam sayyam

means this plugin can’t do.

May 16, 2013 at 8:59 pm 3723
Mahi Mahi

Please check this. Same theme same issue already been fixed.

Thanks.

May 16, 2013 at 9:01 pm 3724
Tareq Hasan Tareq Hasan

I think you are getting the wrong idea. The plugin can DO. The screenshots you provided, doesn’t go with what you want. You want video URL on those custom fields, WP User Frontend puts those video ID’s. Thats the problem, and there is two solutions. First, change your theme code, I’ve given you the code and may be you didn’t understand.

The Second solution is adding a hook. So the idea is, you’ll add a custom field with meta key dp_video_url_id and this custom field will have the video ID. Upon submitting the form, the correct video url will be saved to dp_video_url custom field. Here’s the code that does it, paste in your themes functions.php
[php]
function wpuf_dp_integration( $post_id ) {

if ( isset( $_POST[‘dp_video_url_id’] ) ) {
$video_url = wp_get_attachment_url( $_POST[‘dp_video_url_id’] );
update_post_meta( $post_id, ‘dp_video_url’, $video_url );
}
}

add_action( ‘wpuf_add_post_after_insert’, ‘wpuf_dp_integration’ );
add_action( ‘wpuf_edit_post_after_update’, ‘wpuf_dp_integration’ );
[/php]

May 16, 2013 at 9:37 pm 3725
sayyam sayyam

i select the text box and captioned it as video url
after then at meta field bix i wrote dp_video_url_id
but it doesn’t work

same in case of embed code also

May 16, 2013 at 9:59 pm 3730
Tareq Hasan Tareq Hasan

I am not sure if you understand what I said. This is a simple solution that will fix your url problem.

May 18, 2013 at 5:39 pm 3835
sayyam sayyam

and it worked
hope that you also give in next version an option to do
step wise data submmsions and themes also for the forum.

Viewing 9 Posts - 1 through 9 (of 9 total)