1. Home
  2. Car Demon Code Docs
  3. Display Filters
  4. cd_lightbox_filter

cd_lightbox_filter

This filter can be used to modify the default lightbox used on the VDPs (Vehicle Display Pages).

apply_filters( ‘cd_lightbox_filter’, $html );

add_filter( 'cd_lightbox_filter', 'my_lightbox', 10, $html );
function my_lightbox( $html ) {

    $html = '<div class="my_class">' . $html . '</div>';

    return $html;
}

The above example will wrap the Car Demon lightbox with a <div> tag that has a CSS class of “my_class”.

Was this article helpful to you? Yes No

How can we help?