PluginProbe
Import Social Events / 1.8.7
Import Social Events v1.8.7
1.9.1 1.9.0 trunk 1.0.0 1.0.1 1.1.0 1.1.1 1.1.2 1.1.3 1.1.4 1.1.5 1.2.0 1.3.0 1.4.0 1.5.0 1.5.1 1.5.2 1.5.3 1.5.4 1.5.5 1.6.0 1.6.1 1.6.10 1.6.11 1.6.12 All 61 releases
import-facebook-events / templates / admin / facebook-import-events.php

facebook-import-events.php in Import Social Events 1.8.7, at templates/admin/facebook-import-events.php

136 lines 6.2 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * Template file for admin import events form.
4 *
5 * @package Import_Facebook_Events
6 */
7
8 // If this file is called directly, abort.
9 if ( ! defined( 'ABSPATH' ) ) {
10 exit;
11 }
12
13 global $ife_events;
14 $user_fb_pages = get_option( 'ife_fb_user_pages', array() );
15 $disabled = '';
16 if ( ! ife_is_pro() ) {
17 $disabled = 'disabled';
18 }
19 ?>
20 <div class="ife-card" style="margin-top:20px;" >
21 <div class="ife-content ife_source_import" aria-expanded="true" style=" ">
22 <div class="ife-inner-main-section">
23 <div class="ife-inner-section-1" >
24 <span class="ife-title-text" >
25 <?php esc_attr_e( 'Import by', 'import-facebook-events' ); ?>
26 <span class="ife-tooltip">
27 <div>
28 <svg viewBox="0 0 20 20" fill="#000" xmlns="http://www.w3.org/2000/svg" class="ife-circle-question-mark">
29 <path fill-rule="evenodd" clip-rule="evenodd" d="M1.6665 10.0001C1.6665 5.40008 5.39984 1.66675 9.99984 1.66675C14.5998 1.66675 18.3332 5.40008 18.3332 10.0001C18.3332 14.6001 14.5998 18.3334 9.99984 18.3334C5.39984 18.3334 1.6665 14.6001 1.6665 10.0001ZM10.8332 13.3334V15.0001H9.1665V13.3334H10.8332ZM9.99984 16.6667C6.32484 16.6667 3.33317 13.6751 3.33317 10.0001C3.33317 6.32508 6.32484 3.33341 9.99984 3.33341C13.6748 3.33341 16.6665 6.32508 16.6665 10.0001C16.6665 13.6751 13.6748 16.6667 9.99984 16.6667ZM6.6665 8.33341C6.6665 6.49175 8.15817 5.00008 9.99984 5.00008C11.8415 5.00008 13.3332 6.49175 13.3332 8.33341C13.3332 9.40251 12.6748 9.97785 12.0338 10.538C11.4257 11.0695 10.8332 11.5873 10.8332 12.5001H9.1665C9.1665 10.9824 9.9516 10.3806 10.6419 9.85148C11.1834 9.43642 11.6665 9.06609 11.6665 8.33341C11.6665 7.41675 10.9165 6.66675 9.99984 6.66675C9.08317 6.66675 8.33317 7.41675 8.33317 8.33341H6.6665Z" fill="currentColor"></path>
30 </svg>
31 <span class="ife-popper">
32 <?php
33 $text = sprintf(
34 /* translators: 1: First option (by Facebook Event ID), 2: Second option (Facebook Page) */
35 esc_html__( 'Select Event source. %1$s, %2$s.', 'import-facebook-events' ),
36 '<br><strong>' . esc_html__( '1. by Facebook Event ID', 'import-facebook-events' ) . '</strong>',
37 '<br><strong>' . esc_html__( '2. Facebook Page', 'import-facebook-events' ) . '</strong>'
38 );
39
40 echo wp_kses(
41 $text,
42 array(
43 'strong' => array(),
44 'br' => array(),
45 )
46 );
47 ?>
48 <div class="ife-popper__arrow"></div>
49 </span>
50 </div>
51 </span>
52 </span>
53 </div>
54 <div class="ife-inner-section-2">
55 <label for="cleanup_post_type">
56 <select name="facebook_import_by" id="facebook_import_by">
57 <option value="facebook_event_id"><?php esc_attr_e( 'Facebook Event ID', 'import-facebook-events' ); ?></option>
58 <option value="facebook_organization"><?php esc_attr_e( 'Facebook Page', 'import-facebook-events' ); ?></option>
59 <?php if ( ! empty( $user_fb_pages ) ) { ?>
60 <option value="my_pages"><?php esc_attr_e( 'My Pages', 'import-facebook-events' ); ?></option>
61 <?php } ?>
62 </select>
63 </label>
64 </div>
65 </div>
66
67 <div class="ife-inner-main-section facebook_eventid_wrapper" >
68 <div class="ife-inner-section-1" >
69 <span class="ife-title-text" ><?php esc_attr_e( 'Facebook Event IDs', 'import-facebook-events' ); ?></span>
70 </div>
71 <div class="ife-inner-section-2">
72 <textarea name="facebook_event_ids" class="facebook_event_ids" placeholder="<?php esc_attr_e( 'One event ID per line, ( Eg. Event ID for https://www.facebook.com/events/123456789/ is "123456789" ).', 'import-facebook-events' ); ?>" rows="5" cols="52"></textarea>
73 </div>
74 </div>
75
76 <div class="ife-inner-main-section facebook_page_wrapper" style="display: none;" >
77 <div class="ife-inner-section-1" >
78 <span class="ife-title-text" ><?php esc_attr_e( 'Page username / ID to fetch events from', 'import-facebook-events' ); ?></span>
79 </div>
80 <div class="ife-inner-section-2">
81 <input class="ife_text facebook_page_username" name="facebook_page_username" type="text" <?php echo esc_attr( $disabled ); ?>/>
82 <span class="ife_small">
83 <?php esc_attr_e( ' Eg. username for https://www.facebook.com/xylusinfo/ is "xylusinfo".', 'import-facebook-events' ); ?>
84 </span>
85 <?php do_action( 'ife_render_pro_notice' ); ?>
86 </div>
87 </div>
88
89 <div class="ife-inner-main-section facebook_account_wrapper" style="display: none;" >
90 <div class="ife-inner-section-1" >
91 <span class="ife-title-text" ><?php esc_attr_e( 'My Pages', 'import-facebook-events' ); ?></span>
92 </div>
93 <div class="ife-inner-section-2">
94 <?php if ( ! empty( $user_fb_pages ) ) { ?>
95 <select name="my_page" class="my_page" required="required" <?php echo esc_attr( $disabled ); ?>>
96 <option value=""><?php esc_attr_e( 'Select Page', 'import-facebook-events' ); ?></option>
97 <?php
98 foreach ( $user_fb_pages as $pkey => $pvalue ) {
99 echo '<option value="' . esc_attr( $pkey ) . '">' . esc_attr( $pvalue['name'] ) . '</option>';
100 }
101 ?>
102 </select>
103 <?php } ?>
104 <span class="ife_small">
105 <?php esc_attr__( 'Select Page for import events from it.', 'import-facebook-events' ); ?>
106 </span>
107 <?php do_action( 'ife_render_pro_notice' ); ?>
108 </div>
109 </div>
110
111 <div class="ife-inner-main-section import_type_wrapper" >
112 <div class="ife-inner-section-1" >
113 <span class="ife-title-text" ><?php esc_attr_e( 'Import type', 'import-facebook-events' ); ?></span>
114 </div>
115 <div class="ife-inner-section-2">
116 <?php $ife_events->common->render_import_type(); ?>
117 </div>
118 </div>
119 <?php
120 $ife_events->common->render_import_into_and_taxonomy();
121 $ife_events->common->render_eventstatus_input();
122 ?>
123
124 <div class="ife-inner-main-section" >
125 <div class="ife-inner-section-1" >
126 <span class="ife-title-text" ><?php esc_attr_e( 'Author', 'import-facebook-events' ); ?></span>
127 </div>
128 <div class="ife-inner-section-2">
129 <?php wp_dropdown_users( array( 'show_option_none' => esc_attr__( 'Select Author','import-facebook-events'), 'name' => 'event_author', 'option_none_value' => get_current_user_id() ) ); ?>
130 <span class="ife_small">
131 <?php esc_attr_e( 'Select event author for imported events. Default event author is current loggedin user.', 'import-facebook-events' ); ?>
132 </span>
133 </div>
134 </div>
135 </div>
136 </div>