PluginProbe ʕ •ᴥ•ʔ
Independent Analytics – WordPress Analytics Plugin / 1.17.1
Independent Analytics – WordPress Analytics Plugin v1.17.1
2.15.0 2.14.10 trunk 1.1 1.10 1.10.1 1.11 1.12 1.13 1.14 1.15 1.16 1.17 1.17.1 1.17.2 1.17.3 1.17.4 1.18 1.18.1 1.19.0 1.19.1 1.2 1.20.0 1.21.0 1.22.0 1.22.1 1.23.0 1.23.1 1.24.0 1.24.1 1.25.0 1.25.1 1.26.0 1.27.0 1.28.0 1.28.1 1.28.2 1.28.3 1.29.0 1.3 1.30.0 1.30.1 1.4 1.5 1.6 1.7 1.8 1.9 2.0.0 2.0.1 2.1.4 2.1.5 2.1.6 2.10.0 2.10.1 2.10.2 2.10.3 2.10.4 2.11.0 2.11.1 2.11.10 2.11.2 2.11.3 2.11.4 2.11.5 2.11.6 2.11.7 2.11.8 2.11.9 2.12.0 2.12.1 2.12.2 2.13.1 2.13.2 2.13.5 2.13.6 2.14.0 2.14.1 2.14.2 2.14.4 2.14.6 2.14.7 2.14.8 2.14.9 2.2.0 2.2.1 2.3.1 2.3.2 2.4.2 2.4.3 2.5.0 2.5.1 2.6.0 2.6.1 2.6.2 2.6.3 2.6.4 2.7.0 2.7.1 2.7.2 2.7.3 2.8.2 2.8.3 2.8.4 2.8.5 2.8.6 2.8.7 2.8.8 2.8.9 2.9.2 2.9.3 2.9.4 2.9.5 2.9.6 2.9.7
independent-analytics / templates / campaign_builder.php
independent-analytics / templates Last commit date
layout 3 years ago learn 3 years ago pdf 3 years ago settings 3 years ago table 3 years ago campaign_builder.php 3 years ago migration_running.php 3 years ago quick_stats.php 3 years ago real_time.php 3 years ago
campaign_builder.php
218 lines
1 <?php
2 $new_campaign_url = $new_campaign_url ?? null;
3 $path = $path ?? null;
4 $path_error = $path_error ?? null;
5 $utm_source = $utm_source ?? null;
6 $utm_source_error = $utm_source_error ?? null;
7 $utm_medium = $utm_medium ?? null;
8 $utm_medium_error = $utm_medium_error ?? null;
9 $utm_campaign = $utm_campaign ?? null;
10 $utm_campaign_error = $utm_campaign_error ?? null;
11 $utm_term = $utm_term ?? null;
12 $utm_content = $utm_content ?? null;
13 ?>
14
15 <div class="campaign-builder" data-controller="campaign-builder">
16 <div class="settings-container">
17 <div class="settings-container-header">
18 <h2><?php esc_html_e('Campaign URL Builder', 'iawp'); ?></h2>
19 <a class="link-purple"
20 href="https://independentwp.com/knowledgebase/campaigns/how-to-campaign-builder"
21 target="_blank"><?php esc_html_e('Learn how to create campaigns', 'iawp'); ?> <span
22 class="dashicons dashicons-external"></span></a>
23 </div>
24 <form action="" data-action="campaign-builder#submit" data-campaign-builder-target="form">
25 <div class="table-container">
26 <table class="form-table campaign-table" role="presentation">
27 <tbody>
28 <tr>
29 <th scope="row">
30 <label for="iawp_site_url"><?php esc_html_e('Site URL', 'iawp'); ?></label>
31 </th>
32 <td>
33 <input type="text"
34 name="site_url"
35 id="iawp_site_url"
36 value="<?php echo trailingslashit(site_url()) ?>"
37 disabled="disabled"
38 />
39 <p class="description"><?php esc_html_e('Campaign links always lead to your site', 'iawp'); ?></p>
40 </td>
41 </tr>
42 <tr>
43 <th scope="row">
44 <label for="iawp_path"><?php esc_html_e('Landing Page Path', 'iawp'); ?></label>
45 </th>
46 <td>
47 <input type="text"
48 name="path"
49 id="iawp_path"
50 placeholder="/blog/some-post"
51 value="<?php esc_attr_e($path) ?>"
52 />
53 <p class="description"><?php esc_html_e('Leave empty to use your homepage', 'iawp'); ?></p>
54 </td>
55 </tr>
56 <tr>
57 <th scope="row">
58 <label for="iawp_utm_source">Source <span
59 class="required">*</span></label>
60 </th>
61 <td>
62 <input type="text"
63 name="utm_source"
64 id="iawp_utm_source"
65 placeholder="Twitter"
66 value="<?php esc_attr_e($utm_source); ?>"
67 class="<?php echo isset($utm_source_error) ? 'error' : '' ?>"
68 />
69 <p class="description"><?php esc_html_e('Name of the website the link will be placed on', 'iawp'); ?></p>
70 <?php if (isset($utm_source_error)): ?>
71 <p class="error"><?php esc_html_e($utm_source_error) ?></p>
72 <?php endif; ?>
73 </td>
74 </tr>
75 <tr>
76 <th scope="row">
77 <label for="iawp_utm_medium">Medium <span
78 class="required">*</span></label>
79 </th>
80 <td>
81 <input type="text"
82 name="utm_medium"
83 id="iawp_utm_medium"
84 placeholder="<?php esc_attr_e('Social Media', 'iawp'); ?>"
85 value="<?php esc_attr_e($utm_medium) ?>"
86 class="<?php echo isset($utm_medium_error) ? 'error' : '' ?>"
87 />
88 <p class="description"><?php esc_html_e('Type of website e.g. Search, Social, Ad', 'iawp'); ?></p>
89 <?php if (isset($utm_medium_error)): ?>
90 <p class="error"><?php esc_html_e($utm_medium_error) ?></p>
91 <?php endif; ?>
92 </td>
93 </tr>
94 <tr>
95 <th scope="row">
96 <label for="iawp_utm_campaign">Campaign <span class="required">*</span></label>
97 </th>
98 <td>
99 <input type="text"
100 name="utm_campaign"
101 id="iawp_utm_campaign"
102 placeholder="<?php esc_attr_e('5 Ways to Get More Traffic', 'iawp'); ?>"
103 value="<?php esc_attr_e($utm_campaign) ?>"
104 class="<?php echo isset($utm_campaign_error) ? 'error' : '' ?>"
105 />
106 <p class="description"><?php esc_html_e('Title of the page or ad', 'iawp'); ?></p>
107 <?php if (isset($utm_campaign_error)): ?>
108 <p class="error"><?php esc_html_e($utm_campaign_error) ?></p>
109 <?php endif; ?>
110 </td>
111 </tr>
112 <tr>
113 <th scope="row">
114 <label for="iawp_utm_term">Term</label>
115 </th>
116 <td>
117 <input type="text"
118 name="utm_term"
119 id="iawp_utm_term"
120 placeholder="<?php esc_attr_e('Get website traffic', 'iawp'); ?>"
121 value="<?php esc_attr_e($utm_term) ?>"
122 />
123 <p class="description"><?php esc_html_e('Keyword used in paid advertising', 'iawp'); ?></p>
124 </td>
125 </tr>
126 <tr>
127 <th scope="row">
128 <label for="iawp_utm_content">Content</label>
129 </th>
130 <td>
131 <input type="text"
132 name="utm_content"
133 id="iawp_utm_content"
134 placeholder="<?php esc_attr_e('Bio link', 'iawp'); ?>"
135 value="<?php esc_attr_e($utm_content) ?>"
136 />
137 <p class="description"><?php esc_html_e('Position of the link on the page e.g. author bio', 'iawp'); ?></p>
138 </td>
139 </tr>
140 </tbody>
141 </table>
142 </div>
143 <div class="submit-container">
144 <p class="submit">
145 <button class="button iawp-button purple"
146 data-campaign-builder-target="submitButton"
147 >
148 <span><?php esc_html_e('Create Campaign URL', 'iawp'); ?></span><span
149 class="dashicons dashicons-update"></span>
150 </button>
151 </p>
152 </div>
153 </form>
154 <?php if (isset($new_campaign_url)): ?>
155 <div class="campaign new"
156 data-campaign-builder-target="newCampaign">
157 <p class="campaign-title"><?php esc_html_e('New campaign created', 'iawp'); ?>
158 &#127881;</p>
159 <div class="campaign-copy">
160 <div class="campaign-text">
161 <input readonly class="campaign-url"
162 data-controller="select-input"
163 data-action="click->select-input#selectInput"
164 value="<?php esc_attr_e($new_campaign_url); ?>"/>
165 </div>
166 <div class="campaign-actions">
167 <button class="iawp-button purple"
168 data-controller="clipboard"
169 data-action="clipboard#copy"
170 data-clipboard-text-value="<?php esc_attr_e($new_campaign_url); ?>"
171 >
172 <?php esc_html_e('Copy URL', 'iawp'); ?>
173 </button>
174 </div>
175 </div>
176 </div>
177 <?php endif; ?>
178 </div>
179 <div class="settings-container">
180 <div class="campaigns-heading">
181 <h2><?php esc_html_e('Latest Campaign URLs', 'iawp'); ?></h2>
182 </div>
183 <?php if (count($campaigns) === 0): ?>
184 <p class="campaigns-empty"><?php esc_html_e('No campaign URLs found', 'iawp'); ?></p>
185 <?php endif ?>
186 <?php foreach ($campaigns as $campaign): ?>
187 <div class="campaign">
188 <div class="campaign-copy">
189 <div class="campaign-text">
190 <input readonly class="campaign-url"
191 data-controller="select-input"
192 data-action="click->select-input#selectInput"
193 value="<?php esc_attr_e($campaign['url']); ?>">
194 <p class="campaign-created-at">
195 <?php printf(esc_html_x('Created %s', 'Created five minutes ago', 'iawp'), esc_html__($campaign['created_at'])); ?>
196 </p>
197 </div>
198 <div class="campaign-actions">
199 <button class="iawp-button purple"
200 data-controller="clipboard"
201 data-action="clipboard#copy"
202 data-clipboard-text-value="<?php esc_attr_e($campaign['url']); ?>"
203 >
204 <?php esc_html_e('Copy URL', 'iawp'); ?>
205 </button>
206 <button class="iawp-button ghost-purple"
207 data-action="campaign-builder#reuse"
208 data-result="<?php esc_attr_e($campaign['result']) ?>"
209 >
210 <?php esc_html_e('Reuse', 'iawp'); ?>
211 </button>
212 </div>
213 </div>
214 </div>
215 <?php endforeach ?>
216 </div>
217 </div>
218