su_slide_link_save

The shortcodes-ultimate su slide link save function.

Published Date - February 15, 2021

Description

Saves 'Slide Link' field.

su_slide_link_save( $post, $attachment );

Parameters

  1. $post

  2. $attachment


Usage

The following example is for adding a hook callback.

if ( !function_exists( 'su_slide_link_save' ) ) {
    require_once ABSPATH . PLUGINDIR . 'shortcodes-ultimateshortcodes-ultimate/includes/functions-galleries.php';
}

// The input(s). 
$post = null;
$attachment = null;

// NOTICE! Understand what this does before running.
$result = su_slide_link_save( $post, $attachment );
            

Defined

The function is defined in the following location(s).

shortcodes-ultimate/includes/functions-galleries.php

function su_slide_link_save( $post, $attachment ) {

	if ( isset( $attachment['su_slide_link'] ) ) {
		update_post_meta( $post['ID'], 'su_slide_link', $attachment['su_slide_link'] );
	}

	return $post;

}