uapte
This commit is contained in:
@@ -310,11 +310,29 @@ class Opalestate_Agency_Front {
|
||||
public function register_shortcodes() {
|
||||
$this->shortcodes = [
|
||||
'search_agencies' => [ 'code' => 'search_agencies', 'label' => esc_html__( 'Search Agencies', 'opalestate-pro' ) ],
|
||||
'agency_carousel' => [ 'code' => 'agency_carousel', 'label' => esc_html__( 'Agency Carousel', 'opalestate-pro' ) ],
|
||||
];
|
||||
|
||||
foreach ( $this->shortcodes as $shortcode ) {
|
||||
add_shortcode( 'opalestate_' . $shortcode['code'], [ $this, $shortcode['code'] ] );
|
||||
}
|
||||
}
|
||||
|
||||
public function agency_carousel ( $atts ) {
|
||||
|
||||
$atts = is_array( $atts ) ? $atts : [];
|
||||
|
||||
$default = array(
|
||||
'current_uri' => null,
|
||||
'column' => 3,
|
||||
'limit' => 12,
|
||||
'paged' => 1,
|
||||
'onlyfeatured' => 0,
|
||||
);
|
||||
|
||||
$atts = array_merge( $default, $atts );
|
||||
|
||||
return opalestate_load_template_path( 'shortcodes/agency-carousel' , $atts );
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
* @version $Id$
|
||||
* @package $package$
|
||||
* @author Opal Team <info@wpopal.com >
|
||||
* @copyright Copyright (C) 2014 wpopal.com. All Rights Reserved.
|
||||
* @copyright Copyright (C) 2019 wpopal.com. All Rights Reserved.
|
||||
* @license GNU/GPL v2 or later http://www.gnu.org/licenses/gpl-2.0.html
|
||||
*
|
||||
* @website http://www.wpopal.com
|
||||
|
||||
Reference in New Issue
Block a user