C:\xampp\htdocs\landing\wp-content\themes\pennews\inc\customizer\06-block-pag.php


1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
<?php
$wp_customize
->add_section'penci_block_pag', array(
    
'title' => esc_html__'Block VC Pagination Numbers Options''pennews' ),
    
'description' => esc_html__'When you click on pagination numbers on Blocks from Visual Composer - you will redirect to the pages without other blocks - this help your readers can focus on your content. And here is options for that pages.''pennews' ),
    
'priority' => 5,
) );

$wp_customize->add_setting'penci_block_pag_sidebar_layout', array(
    
'default'           => 'sidebar-right',
    
'sanitize_callback' => array( $sanitizer'select' ),
) );
$wp_customize->add_control( new Penci_Customize_Control_Radio_Image(
    
$wp_customize,
    
'penci_block_pag_sidebar_layout',
    array(
        
'label'    => __'Archive Page Sidebar Layout''pennews' ),
        
'section'  => 'penci_block_pag',
        
'type'     => 'radio-image',
        
'choices'  => array(
            
'no-sidebar-wide' => array( 'url' => '%s/images/layout/wide-content.png''label' => esc_html__'Wide content''pennews' ) ),
            
'no-sidebar'      => array( 'url' => '%s/images/layout/no-sidebar.png''label' => esc_html__'No Sidebar''pennews' ) ),
            
'sidebar-left'    => array( 'url' => '%s/images/layout/sidebar-left.png''label' => esc_html__'Sidebar Left''pennews' ) ),
            
'sidebar-right'   => array( 'url' => '%s/images/layout/sidebar-right.png''label' => esc_html__'Sidebar Right''pennews' ) ),
            
'two-sidebar'     => array( 'url' => '%s/images/layout/3cm.png''label' => esc_html__'Two Sidebar''pennews' ) ),
        ),
        
'settings' => 'penci_block_pag_sidebar_layout',
    )
) );

// Archive page layout style
$wp_customize->add_setting'penci_block_pag_layout_style', array(
    
'default'           => 'blog-default',
    
'sanitize_callback' => array( $sanitizer'select' ),
) );
$wp_customize->add_control( new Penci_Customize_Control_Radio_Image(
    
$wp_customize,
    
'penci_block_pag_layout_style',
    array(
        
'label'    => esc_html__'Archive Page Layout Style''pennews' ),
        
'section'  => 'penci_block_pag',
        
'type'     => 'radio-image',
        
'choices'  => penci_get_option_blog_layout(),
        
'settings' => 'penci_block_pag_layout_style',
    )
) );


$wp_customize->add_setting'penci_block_pag_post_per_page', array(
    
'sanitize_callback' => array( $sanitizer'text' ),
) );
$wp_customize->add_control( new Penci_Customize_Number_Control$wp_customize,  'penci_block_pag_post_per_page', array(
    
'label'    => esc_html__'Show Post Per Page''pennews' ),
    
'section'  => 'penci_block_pag',
    
'settings' => 'penci_block_pag_post_per_page',
    
'type'     => 'number',
) ) );

// Custom sidebar left
$wp_customize->add_setting'penci_block_pag_custom_sidebar_left', array(
    
'default'           => 'sidebar-2',
    
'sanitize_callback' => array( $sanitizer'select' ),
) );
$wp_customize->add_control(
    
'penci_block_pag_custom_sidebar_left',
    array(
        
'label'    => esc_html__'Custom Sidebar Left''pennews' ),
        
'section'  => 'penci_block_pag',
        
'type'     => 'select',
        
'choices'  => Penci_Custom_Sidebar::get_list_sidebar( ),
        
'settings' => 'penci_block_pag_custom_sidebar_left',
    )
);

// Custom sidebar right
$wp_customize->add_setting'penci_block_pag_custom_sidebar_right', array(
    
'default'           => 'sidebar-1',
    
'sanitize_callback' => array( $sanitizer'select' ),
) );
$wp_customize->add_control(
    
'penci_block_pag_custom_sidebar_right',
    array(
        
'label'    => esc_html__'Custom Sidebar right''pennews' ),
        
'section'  => 'penci_block_pag',
        
'type'     => 'select',
        
'choices'  => Penci_Custom_Sidebar::get_list_sidebar'right' ),
        
'settings' => 'penci_block_pag_custom_sidebar_right',
    )
);

// Blog display
$wp_customize->add_setting'penci_block_pag_display', array(
    
'default'           => 'excerpt',
    
'sanitize_callback' => array( $sanitizer'select' ),
) );
$wp_customize->add_control(
    
'penci_block_pag_display',
    array(
        
'label'    => esc_html__'Content Display On Blog Archive Page''pennews' ),
        
'section'  => 'penci_block_pag',
        
'type'     => 'select',
        
'choices'  => array(
            
'excerpt' => esc_html__'Post excerpt''pennews' ),
            
'content' => esc_html__'Post content''pennews' ),
            
'more'    => esc_html__'Post content before more tag''pennews' ),
        ),
        
'settings' => 'penci_block_pag_display',
    )
);

// Post content limit (words)
$wp_customize->add_setting'penci_block_pag_content_limit', array(
    
'default'           => '25',
    
'sanitize_callback' => array( $sanitizer'text' ),
) );
$wp_customize->add_control( new Penci_Customize_Number_Control$wp_customize,  'penci_block_pag_content_limit', array(
    
'label'    => esc_html__'Post Content Limit (words)''pennews' ),
    
'section'  => 'penci_block_pag',
    
'settings' => 'penci_block_pag_content_limit',
    
'type'     => 'number',
) ) );

// font size

$wp_customize->add_setting'penci_block_pag_size_item_post_title', array(
    
'sanitize_callback' => array( $sanitizer'html' ),
    
'default'           => '',
) );

$wp_customize->add_control( new Penci_Customize_Font_Size_Control$wp_customize'penci_block_pag_size_item_post_title', array(
    
'label'    => esc_html__'Custom Font Size For Post Title''pennews' ),
    
'section'  => 'penci_block_pag',
    
'settings' => 'penci_block_pag_size_item_post_title',
    
'type'     => 'font_size',
) ) );

$wp_customize->add_setting'penci_block_pag_fweight_item_ptitle', array(
    
'default'           => '600',
    
'sanitize_callback' => array( $sanitizer'select' ),
) );
$wp_customize->add_control'penci_block_pag_fweight_item_ptitle', array(
    
'label'    => esc_html__'Custom Font Weight For Post Title''pennews' ),
    
'section'  => 'penci_block_pag',
    
'settings' => 'penci_block_pag_fweight_item_ptitle',
    
'type'     => 'select',
    
'choices'  => array(
        
'normal'  => 'Normal',
        
'bold'    => 'Bold',
        
'bolder'  => 'Bolder',
        
'lighter' => 'Lighter',
        
'100'     => '100',
        
'200'     => '200',
        
'300'     => '300',
        
'400'     => '400',
        
'500'     => '500',
        
'600'     => '600',
        
'700'     => '700',
        
'800'     => '800',
        
'900'     => '900'
    
)
) );

$wp_customize->add_setting'penci_block_pag_size_item_post_meta', array(
    
'sanitize_callback' => array( $sanitizer'html' ),
    
'default'           => '',
) );

$wp_customize->add_control( new Penci_Customize_Font_Size_Control$wp_customize'penci_block_pag_size_item_post_meta', array(
    
'label'    => esc_html__'Custom Font Size For Post Meta''pennews' ),
    
'section'  => 'penci_block_pag',
    
'settings' => 'penci_block_pag_size_item_post_meta',
    
'type'     => 'font_size',
) ) );


$wp_customize->add_setting'penci_block_pag_size_item_post_desc', array(
    
'sanitize_callback' => array( $sanitizer'html' ),
    
'default'           => '',
) );

$wp_customize->add_control( new Penci_Customize_Font_Size_Control$wp_customize'penci_block_pag_size_item_post_desc', array(
    
'label'    => esc_html__'Custom Font Size For Post Description''pennews' ),
    
'section'  => 'penci_block_pag',
    
'settings' => 'penci_block_pag_size_item_post_desc',
    
'type'     => 'font_size',
) ) );

/**
 * Button readmore
 */

$wp_customize->add_setting'penci_bpag_show_rmore_post', array(
    
'sanitize_callback' => array( $sanitizer'checkbox' ),
) );

$wp_customize->add_control( new WP_Customize_Control(
    
$wp_customize,
    
'penci_bpag_show_rmore_post',
    array(
        
'label'    => esc_html__'Show Read More Button''pennews' ),
        
'section'  => 'penci_block_pag',
        
'type'     => 'checkbox',
        
'settings' => 'penci_bpag_show_rmore_post',
    )
) );

$wp_customize->add_setting'penci_block_pag_rmore_fsize', array(
    
'sanitize_callback' => array( $sanitizer'html' ),
) );
$wp_customize->add_control( new Penci_Customize_Font_size_Control$wp_customize'penci_block_pag_rmore_fsize', array(
    
'label'    => esc_html__'Custom Font Size For Button Read More''pennews' ),
    
'section'  => 'penci_block_pag',
    
'settings' => 'penci_block_pag_rmore_fsize',
    
'type'     => 'font_size',
) ) );

$wp_customize->add_setting'penci_block_pag_rmore_font', array(
    
'default'           => penci_default_setting'penci_block_pag_rmore_font' ),
    
'sanitize_callback' => array( $sanitizer'text' ),
) );
$wp_customize->add_control'penci_block_pag_rmore_font', array(
    
'label'       => esc_html__'Custom Font Family For Button Read More''pennews' ),
    
'section'     => 'penci_block_pag',
    
'settings'    => 'penci_block_pag_rmore_font',
    
'description' => 'Default font is "Mukta Vaani"',
    
'type'        => 'select',
    
'choices'     => penci_all_fonts()
) );

$wp_customize->add_setting'penci_block_pag_rmore_fweight', array(
    
'default'           => '500',
    
'sanitize_callback' => array( $sanitizer'select' ),
) );
$wp_customize->add_control'penci_block_pag_rmore_fweight', array(
    
'label'    => esc_html__'Custom Font Weight For Button Read More''pennews' ),
    
'section'  => 'penci_block_pag',
    
'settings' => 'penci_block_pag_rmore_fweight',
    
'type'     => 'select',
    
'choices'  => array(
        
'normal'  => 'Normal',
        
'bold'    => 'Bold',
        
'bolder'  => 'Bolder',
        
'lighter' => 'Lighter',
        
'100'     => '100',
        
'200'     => '200',
        
'300'     => '300',
        
'400'     => '400',
        
'500'     => '500',
        
'600'     => '600',
        
'700'     => '700',
        
'800'     => '800',
        
'900'     => '900'
    
)
) );


// Pagination style
$wp_customize->add_setting'penci_block_pag_pag_heading', array(
    
'sanitize_callback' => 'esc_url_raw'
) );
$wp_customize->add_control( new Penci_Customize_Heading_Control$wp_customize'penci_block_pag_pag_heading', array(
    
'label'    => esc_html__'Pagination setting''pennews' ),
    
'section'  => 'penci_block_pag',
    
'settings' => 'penci_block_pag_pag_heading',
    
'type'     => 'heading',
) ) );

$wp_customize->add_setting'penci_block_pag_pagination', array(
    
'default'           => 'default',
    
'sanitize_callback' => array( $sanitizer'select' ),
) );
$wp_customize->add_control'penci_block_pag_pagination', array(
        
'label'    => esc_html__'Pagination Style''pennews' ),
        
'section'  => 'penci_block_pag',
        
'type'     => 'select',
        
'choices'  => array(
            
'default'         => esc_html__'Default''pennews' ),
            
'load_more'       => esc_html__'Load more button''pennews' ),
            
'infinite_scroll' => esc_html__'Infinite scroll''pennews' ),

        ),
        
'settings' => 'penci_block_pag_pagination',
    )
);

$wp_customize->add_setting'penci_block_pag_pos', array(
    
'default'           => 'left',
    
'sanitize_callback' => array( $sanitizer'select' ),
) );
$wp_customize->add_control'penci_block_pag_pos', array(
        
'label'    => esc_html__'Page Navigation Alignment''pennews' ),
        
'section'  => 'penci_block_pag',
        
'type'     => 'select',
        
'choices'  => array(
            
'left'   => esc_html__'left''pennews' ),
            
'center' => esc_html__'Center''pennews' ),
            
'right'  => esc_html__'Right''pennews' ),
        ),
        
'settings' => 'penci_block_pag_pos',
    )
);



// Button click handle text
$wp_customize->add_setting'penci_block_pag_number_load_more', array(
    
'sanitize_callback' => array( $sanitizer'html' ),
    
'default'           => 6,
) );

$wp_customize->add_control( new Penci_Customize_Number_Control$wp_customize'fi', array(
    
'label'    => esc_html__'Custom Number Posts for Each Time Load More Posts''pennews' ),
    
'section'  => 'penci_block_pag',
    
'settings' => 'penci_block_pag_number_load_more',
    
'type'     => 'number',
) ) );

$wp_customize->add_setting'penci_block_pag_extra_heading', array(
    
'sanitize_callback' => 'esc_url_raw'
) );
$wp_customize->add_control( new Penci_Customize_Heading_Control$wp_customize'penci_block_pag_extra_heading', array(
    
'label'    => esc_html__'Extra setting''pennews' ),
    
'section'  => 'penci_block_pag',
    
'settings' => 'penci_block_pag_extra_heading',
    
'type'     => 'heading',
) ) );

$archive_list_check = array(
    
'penci_block_pag_hide_breadcrumb'         => esc_html__'Hide Breadcrumbs''pennews' ),
    
'penci_block_pag_hide_post_cat'         => esc_html__'Hide Post Category''pennews' ),
    
'penci_block_pag_hide_post_review'      => esc_html__'Hide Post Review Pie Chart''pennews' ),
    
'penci_block_pag_hide_post_description' => esc_html__'Hide Post Description''pennews' ),
    
'penci_block_pag_hide_post_author'      => esc_html__'Hide Post Author''pennews' ),
    
'penci_block_pag_hide_date'             => esc_html__'Hide Post Date''pennews' ),
    
'penci_block_pag_hide_view'             => esc_html__'Hide Post Count View''pennews' ),
    
'penci_block_pag_hide_post_comment'     => esc_html__'Hide Post Comment''pennews' ),
);

foreach ( 
$archive_list_check as $id_option => $label_option ) {
    
$wp_customize->add_setting$id_option, array(
        
'sanitize_callback' => array( $sanitizer'checkbox' ),
    ) );

    
$wp_customize->add_control( new WP_Customize_Control(
        
$wp_customize,
        
$id_option,
        array(
            
'label'    => $label_option,
            
'section'  => 'penci_block_pag',
            
'type'     => 'checkbox',
            
'settings' => $id_option,
        )
    ) );
}

// Color
$wp_customize->add_setting'penci_block_pag_colors_heading', array(
    
'sanitize_callback' => 'esc_url_raw'
) );
$wp_customize->add_control( new Penci_Customize_Heading_Control$wp_customize'penci_block_pag_colors_heading', array(
    
'label'    => esc_html__'Colors''pennews' ),
    
'section'  => 'penci_block_pag',
    
'settings' => 'penci_block_pag_colors_heading',
    
'type'     => 'heading',
) ) );

$options_color_block_pag = array(
    
'penci_block_pag_breadcrumbs_color'         => esc_html__'Breadcrumbs Color''pennews' ),
    
'penci_block_pag_list_post_title_color'     => esc_html__'Post title color''pennews' ),
    
'penci_block_pag_list_post_meta_color'      => esc_html__'Post Meta Color''pennews' ),
    
'penci_block_pag_list_post_des_color'       => esc_html__'Post Description Color''pennews' ),

    
'penci_block_pag_rmore_color'    => esc_html__'Read More Button Text Color''pennews' ),
    
'penci_block_pag_rmore_bgcolor'  => esc_html__'Read More Button Background Color''pennews' ),
    
'penci_block_pag_rmore_hcolor'   => esc_html__'Read More Button Hover Text Color''pennews' ),
    
'penci_block_pag_rmore_hbgcolor' => esc_html__'Read More Button Hover Background Color''pennews' ),

    
'penci_block_pag_list_post_cat_color'    => esc_html__'Post Categories Text Color''pennews' ),
    
'penci_block_pag_list_post_cat_bgcolor'  => esc_html__'Post Categories Background Color''pennews' ),
    
'penci_block_pag_list_post_cat_hcolor'   => esc_html__'Post Categories Hover Text Color''pennews' ),
    
'penci_block_pag_list_post_cat_hbgcolor' => esc_html__'Post Categories Hover Background Color''pennews' ),
);

foreach ( 
$options_color_block_pag as $key => $label ) {

    
$wp_customize->add_setting$key, array(
        
'default'           => penci_default_setting$key ),
        
'sanitize_callback' => array( $sanitizer'hex_color' ),
    ) );
    
$wp_customize->add_control( new WP_Customize_Color_Control$wp_customize$key, array(
        
'label'       => $label,
        
'section'     => 'penci_block_pag',
        
'settings'    => $key,
        
'description' => ''
    
) ) );
}
x

Windows NT KPTV 6.2 build 9200 (Windows Server 2012 Datacenter Edition) i586