added searchbox shortcode

This commit is contained in:
2026-01-29 20:41:13 +01:00
parent 61606fd793
commit 7fd99aebbc
7 changed files with 1993 additions and 41 deletions

View File

@@ -78,6 +78,7 @@ class Partnerexpo_Core {
$this->set_locale();
$this->define_admin_hooks();
$this->define_public_hooks();
$this->define_cpts();
}
@@ -167,7 +168,6 @@ class Partnerexpo_Core {
* @access private
*/
private function define_public_hooks() {
$plugin_public = new Partnerexpo_Core_Public( $this->get_plugin_name(), $this->get_version() );
$this->loader->add_action( 'wp_enqueue_scripts', $plugin_public, 'enqueue_styles' );
@@ -175,6 +175,29 @@ class Partnerexpo_Core {
}
private function define_cpts() {
$args = array(
'labels' => array(
'name' => 'partners',
'singular_name' => __('Partner', 'partnerexpo-core'),
'menu_name' => __('Partnerek', 'partnerexpo-core'),
'add_new' => __('Új partner hozzáadása', 'partnerexpo-core'),
'add_new_item' => __('Új partner hozzáadása', 'partnerexpo-core'),
'new_item' => __('Új partner', 'partnerexpo-core'),
'edit_item' => __('Partner szerkesztése', 'partnerexpo-core'),
'view_item' => __('Partner megtekintése', 'partnerexpo-core'),
'all_items' => __('Összes partner', 'partnerexpo-core'),
),
'public' => true,
'has_archive' => true,
'show_in_rest' => true,
'supports' => array( 'title', 'thumbnail', 'excerpt' ),
);
register_post_type( 'partners', $args );
}
/**
* Run the loader to execute all of the hooks with WordPress.
*