LLMS_Meta_Box_Video::save( int $post_id, object $post )

Static save method cleans variables and saves using update_post_meta


Description Description


Parameters Parameters

$post_id

(int) (Required) id of post object

$post

(object) (Required) WP post object


Top ↑

Return Return

(void)


Top ↑

Source Source

File: includes/admin/post-types/meta-boxes/class.llms.meta.box.video.php

	public static function save( $post_id, $post ) {
		global $wpdb;

		if ( isset( $_POST['_video_embed'] ) ) {
			$video = ( llms_clean( $_POST['_video_embed'] ) );
			update_post_meta( $post_id, '_video_embed', ( '' === $video ) ? '' : $video );
		}
		if ( isset( $_POST['_audio_embed'] ) ) {
			$audio = ( llms_clean( $_POST['_audio_embed'] ) );
			update_post_meta( $post_id, '_audio_embed', ( '' === $audio ) ? '' : $audio );
		}
	}

Top ↑

Changelog Changelog

Changelog
Version Description
?? Introduced.


Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.