skt_itconsultant_customize_register

Add postMessage support for site title and description for the Theme Customizer.

Description

skt_itconsultant_customize_register( (WP_Customize_Manager) $wp_customize ); 

Parameters (1)

0. $wp_customize (WP_Customize_Manager)
Theme Customizer object.

Usage

  1. if ( !function_exists( 'skt_itconsultant_customize_register' ) ) { 
  2. require_once '/inc/customizer.php'; 
  3.  
  4. // Theme Customizer object. 
  5. $wp_customize = null; 
  6.  
  7. // NOTICE! Understand what this does before running. 
  8. $result = skt_itconsultant_customize_register($wp_customize); 
  9.  

Defined (1)

The function is defined in the following location(s).

/inc/customizer.php  
  1. function skt_itconsultant_customize_register( $wp_customize ) { 
  2. $wp_customize->get_setting( 'blogname' )->transport = 'postMessage'; 
  3. $wp_customize->get_setting( 'blogdescription' )->transport = 'postMessage'; 
  4. $wp_customize->remove_control('display_header_text'); 
  5. $wp_customize->remove_control('header_textcolor'); 
  6.  
  7. class Itconsultant_info extends WP_Customize_Control{ 
  8. public $type = 'info'; 
  9. public $label = ''; 
  10. public function render_content() { 
  11. ?> 
  12. <h3 style="text-decoration:underline; color:#DA4141; text-transform:uppercase;"><?php echo esc_html($this->label); ?></h3> 
  13. <?php } 
  14.  
  15. class WP_Customize_Textarea_Control extends WP_Customize_Control { 
  16. public $type = 'textarea'; 
  17.  
  18. public function render_content() { 
  19. ?> 
  20. <label> 
  21. <span class="customize-control-title"><?php echo esc_html( $this->label ); ?></span> 
  22. <textarea rows="5" style="width:100%;" <?php $this->link(); ?>><?php echo esc_textarea( $this->value() ); ?></textarea> 
  23. </label> 
  24. <?php 
  25.  
  26. $wp_customize->add_section( 
  27. 'logo_sec',  
  28. array( 
  29. 'title' => __('Logo (PRO Version)', 'itconsultant'),  
  30. 'priority' => 1,  
  31. 'description' => sprintf( __( 'Logo Settings available in %s.', 'itconsultant' ), sprintf( '<a href="%1$s" target="_blank">%2$s</a>', esc_url( '"'.SKT_PRO_THEME_URL.'"' ), __( 'PRO Version', 'itconsultant' ))),  
  32. ); 
  33.  
  34. $wp_customize->add_setting('itconsultant_option[logo-info]', array( 
  35. 'sanitize_callback' => 'sanitize_text_field',  
  36. 'type' => 'info_control',  
  37. 'capability' => 'edit_theme_options',  
  38. )); 
  39.  
  40. $wp_customize->add_control( 
  41. new Itconsultant_info( 
  42. $wp_customize,  
  43. 'itconsultant_option[logo-info]',  
  44. array( 
  45. 'setting' => 'itconsultant_option[logo-info]',  
  46. 'section' => 'logo_sec',  
  47. 'priority' => null 
  48. ); 
  49.  
  50. $wp_customize->add_setting('color_scheme', array( 
  51. 'default' => '#b40000',  
  52. 'sanitize_callback' => 'sanitize_hex_color' 
  53. ));  
  54.  
  55.  
  56.  
  57. $wp_customize->add_control( 
  58. new WP_Customize_Color_Control($wp_customize, 'color_scheme', array( 
  59. 'label' => __('Color Scheme', 'itconsultant'),  
  60. 'description' => sprintf( __( 'More color options in %s.', 'itconsultant' ), sprintf( '<a href="%1$s" target="_blank">%2$s</a>', esc_url( '"'.SKT_PRO_THEME_URL.'"' ), __( 'PRO Version', 'itconsultant' ))),  
  61. 'section' => 'colors',  
  62. 'settings' => 'color_scheme' 
  63. )) 
  64. ); 
  65.  
  66.  
  67.  
  68. $wp_customize->add_section( 
  69. 'slider_sec',  
  70. array( 
  71. 'title' => __('Slider Settings', 'itconsultant'),  
  72. 'priority' => null,  
  73. 'description' => sprintf( __( 'Featured Image Size Should be ( 1400x648 ) More slider settings available in %s.', 'itconsultant' ), sprintf( '<a href="%1$s" target="_blank">%2$s</a>', esc_url( '"'.SKT_PRO_THEME_URL.'"' ), __( 'PRO Version', 'itconsultant' ))),  
  74. ); 
  75.  
  76.  
  77.  
  78. $wp_customize->add_setting('slide1', array( 
  79. 'default' => get_template_directory_uri().'/images/slides/slide_01.jpg',  
  80. 'sanitize_callback' => 'esc_url_raw' 
  81. )); 
  82.  
  83. $wp_customize->add_control( 
  84. new WP_Customize_Image_Control( 
  85. $wp_customize,  
  86. 'slide1',  
  87. array( 
  88. 'label' => __('Add slide image 1', 'itconsultant'),  
  89. 'setting' => 'slide1',  
  90. 'section' => 'slider_sec' 
  91. ); 
  92.  
  93. $wp_customize->add_setting('slidetitle1', array( 
  94. 'default' => __('Use information technology to meet your business objectives.', 'itconsultant'),  
  95. 'sanitize_callback' => 'wp_htmledit_pre' 
  96. )); 
  97.  
  98. $wp_customize->add_control( 
  99. new WP_Customize_Textarea_Control( 
  100. $wp_customize,  
  101. 'slidetitle1',  
  102. array( 
  103. 'label' => __('Add slide caption 1 here', 'itconsultant'),  
  104. 'setting' => 'slidetitle1',  
  105. 'section' => 'slider_sec' 
  106. ); 
  107.  
  108. $wp_customize->add_setting('slideurl1', array( 
  109. 'default' => '#1',  
  110. 'sanitize_callback' => 'esc_url_raw' 
  111. )); 
  112.  
  113. $wp_customize->add_control('slideurl1', array( 
  114. 'label' => __('Add slide link 1 here.', 'itconsultant'),  
  115. 'setting' => 'slideurl1',  
  116. 'section' => 'slider_sec' 
  117. )); 
  118.  
  119. $wp_customize->add_setting('slide2', array( 
  120. 'default' => get_template_directory_uri().'/images/slides/slide_02.jpg',  
  121. 'sanitize_callback' => 'esc_url_raw' 
  122. )); 
  123.  
  124. $wp_customize->add_control( 
  125. new WP_Customize_Image_Control( 
  126. $wp_customize,  
  127. 'slide2',  
  128. array( 
  129. 'label' => __('Add slide image 2', 'itconsultant'),  
  130. 'setting' => 'slide2',  
  131. 'section' => 'slider_sec' 
  132. ); 
  133.  
  134. $wp_customize->add_setting('slidetitle2', array( 
  135. 'default' => __('Use information technology to meet your business objectives', 'itconsultant'),  
  136. 'sanitize_callback' => 'wp_htmledit_pre' 
  137. )); 
  138.  
  139. $wp_customize->add_control( 
  140. new WP_Customize_Textarea_Control( 
  141. $wp_customize,  
  142. 'slidetitle2',  
  143. array( 
  144. 'label' => __('Add slide caption 2 here', 'itconsultant'),  
  145. 'setting' => 'slidetitle2',  
  146. 'section' => 'slider_sec' 
  147. ); 
  148.  
  149. $wp_customize->add_setting('slideurl2', array( 
  150. 'default' => '#2',  
  151. 'sanitize_callback' => 'esc_url_raw',  
  152. )); 
  153.  
  154. $wp_customize->add_control('slideurl2', array( 
  155. 'label' => __('Add slide link 2 here', 'itconsultant'),  
  156. 'setting' => 'slideurl2',  
  157. 'section' => 'slider_sec' 
  158. )); 
  159.  
  160. $wp_customize->add_setting('slide3', array( 
  161. 'default' => get_template_directory_uri().'/images/slides/slide_03.jpg',  
  162. 'sanitize_callback' => 'esc_url_raw' 
  163. )); 
  164.  
  165. $wp_customize->add_control( 
  166. new WP_Customize_Image_Control( 
  167. $wp_customize,  
  168. 'slide3',  
  169. array( 
  170. 'label' => __('Add slide image 3', 'itconsultant'),  
  171. 'setting' => 'slide3',  
  172. 'section' => 'slider_sec' 
  173. ); 
  174.  
  175. $wp_customize->add_setting('slidetitle3', array( 
  176. 'default' => __('Use information technology to meet your business objectives', 'itconsultant'),  
  177. 'sanitize_callback' => 'wp_htmledit_pre' 
  178. )); 
  179.  
  180. $wp_customize->add_control( 
  181. new WP_Customize_Textarea_Control( 
  182. $wp_customize,  
  183. 'slidetitle3',  
  184. array( 
  185. 'label' => __('Add slide caption 3 here', 'itconsultant'),  
  186. 'setting' => 'slidetitle3',  
  187. 'section' => 'slider_sec' 
  188. ); 
  189.  
  190. $wp_customize->add_setting('slideurl3', array( 
  191. 'default' => '#3',  
  192. 'sanitize_callback' => 'esc_url_raw' 
  193. )); 
  194.  
  195. $wp_customize->add_control('slideurl3', array( 
  196. 'label' => __('Add slide link 3 here', 'itconsultant'),  
  197. 'setting' => 'slideurl3',  
  198. 'section' => 'slider_sec' 
  199. )); 
  200.  
  201. $wp_customize->add_setting('slide4', array( 
  202. 'default' => get_template_directory_uri().'/images/slides/slide_04.jpg',  
  203. 'sanitize_callback' => 'esc_url_raw' 
  204. )); 
  205.  
  206. $wp_customize->add_control( 
  207. new WP_Customize_Image_Control( 
  208. $wp_customize,  
  209. 'slide4',  
  210. array( 
  211. 'label' => __('Add slide image 4', 'itconsultant'),  
  212. 'setting' => 'slide4',  
  213. 'section' => 'slider_sec' 
  214. ); 
  215.  
  216. $wp_customize->add_setting('slidetitle4', array( 
  217. 'default' => __('Use information technology to meet your business objectives', 'itconsultant'),  
  218. 'sanitize_callback' => 'wp_htmledit_pre' 
  219. )); 
  220.  
  221. $wp_customize->add_control( 
  222. new WP_Customize_Textarea_Control( 
  223. $wp_customize,  
  224. 'slidetitle4',  
  225. array( 
  226. 'label' => __('Add slide caption 4 here', 'itconsultant'),  
  227. 'setting' => 'slidetitle4',  
  228. 'section' => 'slider_sec' 
  229. ); 
  230.  
  231. $wp_customize->add_setting('slideurl4', array( 
  232. 'default' => '#4',  
  233. 'sanitize_callback' => 'esc_url_raw' 
  234. )); 
  235.  
  236. $wp_customize->add_control('slideurl4', array( 
  237. 'label' => __('Add slide link 4 here', 'itconsultant'),  
  238. 'setting' => 'slideurl4',  
  239. 'section' => 'slider_sec' 
  240. )); 
  241.  
  242. $wp_customize->add_setting('slide5', array( 
  243. 'default' => '',  
  244. 'sanitize_callback' => 'esc_url_raw' 
  245. )); 
  246.  
  247. $wp_customize->add_control( 
  248. new WP_Customize_Image_Control( 
  249. $wp_customize,  
  250. 'slide5',  
  251. array( 
  252. 'label' => __('Add slide image 5', 'itconsultant'),  
  253. 'setting' => 'slide5',  
  254. 'section' => 'slider_sec' 
  255. ); 
  256.  
  257. $wp_customize->add_setting('slidetitle5', array( 
  258. 'default' => '',  
  259. 'sanitize_callback' => 'wp_htmledit_pre' 
  260. )); 
  261.  
  262. $wp_customize->add_control( 
  263. new WP_Customize_Textarea_Control( 
  264. $wp_customize,  
  265. 'slidetitle5',  
  266. array( 
  267. 'label' => __('Add slide caption 5 here', 'itconsultant'),  
  268. 'setting' => 'slidetitle5',  
  269. 'section' => 'slider_sec' 
  270. ); 
  271.  
  272. $wp_customize->add_setting('slideurl5', array( 
  273. 'default' => '',  
  274. 'sanitize_callback' => 'esc_url_raw' 
  275. )); 
  276.  
  277. $wp_customize->add_control('slideurl5', array( 
  278. 'label' => __('Add slide link 5', 'itconsultant'),  
  279. 'setting' => 'slideurl5',  
  280. 'section' => 'slider_sec' 
  281. )); 
  282.  
  283. $wp_customize->add_section('homepage_sec', array( 
  284. 'title' => __('Homepage Boxes', 'itconsultant'),  
  285. 'description' => __('Select page for homepage boxes', 'itconsultant'),  
  286. 'priority' => null  
  287. )); 
  288.  
  289. // Page settings  
  290. $wp_customize->add_section('page_boxes', array( 
  291. 'title' => __('Homepage Boxes', 'itconsultant'),  
  292. 'description' => __('Select Pages from the dropdown', 'itconsultant'),  
  293. 'priority' => null 
  294. )); 
  295.  
  296. $wp_customize->add_setting( 
  297. 'page-setting1',  
  298. array( 
  299. 'sanitize_callback' => 'itconsultant_sanitize_integer',  
  300. ); 
  301.  
  302. $wp_customize->add_control( 
  303. 'page-setting1',  
  304. array( 
  305. 'type' => 'dropdown-pages',  
  306. 'label' => __('Choose a page for box one:', 'itconsultant'),  
  307. 'section' => 'page_boxes',  
  308. ); 
  309.  
  310. $wp_customize->add_setting( 
  311. 'page-setting2',  
  312. array( 
  313. 'sanitize_callback' => 'itconsultant_sanitize_integer',  
  314. ); 
  315.  
  316. $wp_customize->add_control( 
  317. 'page-setting2',  
  318. array( 
  319. 'type' => 'dropdown-pages',  
  320. 'label' => __('Choose a page for box Two:', 'itconsultant'),  
  321. 'section' => 'page_boxes',  
  322. ); 
  323.  
  324. $wp_customize->add_setting( 
  325. 'page-setting3',  
  326. array( 
  327. 'sanitize_callback' => 'itconsultant_sanitize_integer',  
  328. ); 
  329.  
  330. $wp_customize->add_control( 
  331. 'page-setting3',  
  332. array( 
  333. 'type' => 'dropdown-pages',  
  334. 'label' => __('Choose a page for box Three:', 'itconsultant'),  
  335. 'section' => 'page_boxes',  
  336. ); 
  337.  
  338. $wp_customize->add_setting( 
  339. 'page-setting4',  
  340. array( 
  341. 'sanitize_callback' => 'itconsultant_sanitize_integer',  
  342. ); 
  343.  
  344. $wp_customize->add_control( 
  345. 'page-setting4',  
  346. array( 
  347. 'type' => 'dropdown-pages',  
  348. 'label' => __('Choose a page for box Four:', 'itconsultant'),  
  349. 'section' => 'page_boxes',  
  350. ); 
  351.  
  352. $wp_customize->add_section('footer_sec', array( 
  353. 'title' => __('Footer', 'itconsultant'),  
  354. 'description' => __('Customize footer content from here.', 'itconsultant'),  
  355. 'priority' => null 
  356. )); 
  357.  
  358. $wp_customize->add_setting('footcolonetitle', array( 
  359. 'default' => __('john doe', 'itconsultant'),  
  360. 'sanitize_callback' => 'sanitize_text_field' 
  361. )); 
  362.  
  363. $wp_customize->add_control('footcolonetitle', array( 
  364. 'label' => __('Add footer column one title', 'itconsultant'),  
  365. 'setting' => 'footcolonetitle',  
  366. 'section' => 'footer_sec' 
  367. )); 
  368.  
  369. $wp_customize->add_setting('footcolonecontent', array( 
  370. 'default' => __('Lorem ipsum dolor sit amet, consectetur adipiscing elit. Quisque augue eros, posuere a condimentum sit amet, rhoncus eu libero. Maecenas in tincidunt turpis, ut rhoncus neque. Nullam sit amet porta odio. Maecenas mattis nulla ac aliquet facilisis.', 'itconsultant'),  
  371. 'sanitize_callback' => 'wp_htmledit_pre' 
  372. )); 
  373.  
  374. $wp_customize->add_control( 
  375. new WP_Customize_Textarea_Control( 
  376. $wp_customize,  
  377. 'footcolonecontent',  
  378. array( 
  379. 'label' => __('Add footer column one content', 'itconsultant'),  
  380. 'setting' => 'footcolonecontent',  
  381. 'section' => 'footer_sec' 
  382. ); 
  383.  
  384. $wp_customize->add_setting('social_title', array( 
  385. 'default' => __('Connect with us', 'itconsultant'),  
  386. 'sanitize_callback' => 'sanitize_text_field' 
  387. )); 
  388.  
  389. $wp_customize->add_control('social_title', array( 
  390. 'label' => __('Social Icons', 'itconsultant'),  
  391. 'description' => __('Add social title here', 'itconsultant'),  
  392. 'setting' => 'social_title',  
  393. 'section' => 'footer_sec' 
  394. )); 
  395.  
  396. $wp_customize->add_setting('fb_link', array( 
  397. 'default' => '#facebook',  
  398. 'sanitize_callback' => 'esc_url_raw' 
  399. )); 
  400.  
  401. $wp_customize->add_control('fb_link', array( 
  402. 'description' => __('Add facebook link here', 'itconsultant'),  
  403. 'setting' => 'fb_link',  
  404. 'section' => 'footer_sec' 
  405. )); 
  406.  
  407. $wp_customize->add_setting('twitt_link', array( 
  408. 'default' => '#twitter',  
  409. 'sanitize_callback' => 'esc_url_raw' 
  410. )); 
  411.  
  412. $wp_customize->add_control('twitt_link', array( 
  413. 'description' => __('Add twitter link here', 'itconsultant'),  
  414. 'setting' => 'twitt_link',  
  415. 'section' => 'footer_sec' 
  416. )); 
  417.  
  418. $wp_customize->add_setting('linked_link', array( 
  419. 'default' => '#linkedin',  
  420. 'sanitize_callback' => 'esc_url_raw' 
  421. )); 
  422.  
  423. $wp_customize->add_control('linked_link', array( 
  424. 'description' => __('Add Linkedin link here', 'itconsultant'),  
  425. 'setting' => 'itconsultant',  
  426. 'section' => 'footer_sec' 
  427. )); 
  428.  
  429. $wp_customize->add_setting('gplus_link', array( 
  430. 'default' => '#gplus',  
  431. 'sanitize_callback' => 'esc_url_raw' 
  432. )); 
  433.  
  434. $wp_customize->add_control('gplus_link', array( 
  435. 'description' => __('Add google plus link here', 'itconsultant'),  
  436. 'setting' => 'gplus_link',  
  437. 'section' => 'footer_sec' 
  438. )); 
  439.  
  440. $wp_customize->add_setting('contact_info', array( 
  441. 'default' => __('Contact info', 'itconsultant'),  
  442. 'sanitize_callback' => 'sanitize_text_field' 
  443. )); 
  444.  
  445. $wp_customize->add_control('contact_info', array( 
  446. 'label' => __('Contact details', 'itconsultant'),  
  447. 'description' => __('Add contact title here', 'itconsultant'),  
  448. 'setting' => 'contact_info',  
  449. 'section' => 'footer_sec' 
  450. )); 
  451.  
  452. $wp_customize->add_setting('contact_add', array( 
  453. 'default' => __('Office Blvd No. 000-000, Farmville Town, LA 12345', 'itconsultant'),  
  454. 'sanitize_callback' => 'wp_htmledit_pre' 
  455. )); 
  456.  
  457. $wp_customize->add_control( 
  458. new WP_Customize_Textarea_Control( 
  459. $wp_customize,  
  460. 'contact_add',  
  461. array( 
  462. 'label' => __('Add contact address here', 'itconsultant'),  
  463. 'setting' => 'contact_add',  
  464. 'section' => 'footer_sec' 
  465. ); 
  466.  
  467. $wp_customize->add_setting('contact_call', array( 
  468. 'default' => '+62 500 800 123',  
  469. 'sanitize_callback' => 'sanitize_text_field' 
  470. )); 
  471.  
  472. $wp_customize->add_control('contact_call', array( 
  473. 'description' => __('Add contact number here', 'itconsultant'),  
  474. 'setting' => 'contact_call',  
  475. 'section' => 'footer_sec' 
  476. )); 
  477.  
  478. $wp_customize->add_setting('contact_fax', array( 
  479. 'default' => '+62 500 800 112',  
  480. 'sanitize_callback' => 'sanitize_text_field' 
  481. )); 
  482.  
  483. $wp_customize->add_control('contact_fax', array( 
  484. 'description' => __('Add fax number here', 'itconsultant'),  
  485. 'setting' => 'contact_fax',  
  486. 'section' => 'footer_sec' 
  487. )); 
  488.  
  489. $wp_customize->add_setting('contact_mail', array( 
  490. 'default' => 'testmail@yourdomain.com',  
  491. 'sanitize_callback' => 'sanitize_email' 
  492. )); 
  493.  
  494. $wp_customize->add_control('contact_mail', array( 
  495. 'description' => __('Add email address here', 'itconsultant'),  
  496. 'setting' => 'contact_mail',  
  497. 'section' => 'footer_sec'  
  498. )); 
  499.  
  500. $wp_customize->add_setting('contact_web', array( 
  501. 'default' => 'www.yourdomain.com',  
  502. 'sanitize_callback' => 'esc_url_raw' 
  503. )); 
  504.  
  505. $wp_customize->add_control('contact_web', array( 
  506. 'description' => __('Add web url here', 'itconsultant'),  
  507. 'setting' => 'contact_web',  
  508. 'section' => 'footer_sec' 
  509. )); 
  510.  
  511. $wp_customize->add_section('copy_sec', array( 
  512. 'title' => __('Copyright', 'itconsultant'),  
  513. 'description' => __('Add copyright text here.', 'itconsultant'),  
  514. 'priority' => null 
  515. )); 
  516.  
  517. $wp_customize->add_setting('copy_text', array( 
  518. 'default' => __('IT Consultant 2015', 'itconsultant'),  
  519. 'sanitize_callback' => 'wp_kses_post' 
  520. )); 
  521.  
  522. $wp_customize->add_control( 
  523. new WP_Customize_Textarea_Control( 
  524. $wp_customize,  
  525. 'copy_text',  
  526. array( 
  527. 'setting' => 'copy_text',  
  528. 'section' => 'copy_sec' 
  529. ); 
  530.  
  531. $wp_customize->add_section('homepagecontent_sec', array( 
  532. 'title' => __('Homepage Sections (PRO Version)', 'itconsultant'),  
  533. 'description' => sprintf( __( 'Homepage sections available in %s.', 'itconsultant' ), sprintf( '<a href="%1$s" target="_blank">%2$s</a>', esc_url( '"'.SKT_PRO_THEME_URL.'"' ), __( 'PRO Version', 'itconsultant' ))),  
  534.  
  535. )); 
  536.  
  537. $wp_customize->add_setting('itconsultant[home-info]', array( 
  538. 'sanitize_callback' => 'sanitize_text_field',  
  539. 'type' => 'info_control',  
  540. 'capability' => 'edit_theme_options' 
  541. )); 
  542.  
  543. $wp_customize->add_control( 
  544. new Itconsultant_info( 
  545. $wp_customize,  
  546. 'itconsultant[home-info]',  
  547. array( 
  548. 'setting' => 'itconsultant[home-info]',  
  549. 'section' => 'homepagecontent_sec',  
  550. 'priority' => null 
  551. ); 
  552.  
  553. $wp_customize->add_section('typography', array( 
  554. 'title' => __('Typography (PRO Version)', 'itconsultant'),  
  555. 'description' => sprintf( __( 'Typography option available in %s.', 'itconsultant' ), sprintf( '<a href="%1$s" target="_blank">%2$s</a>', esc_url( '"'.SKT_PRO_THEME_URL.'"' ), __( 'PRO Version', 'itconsultant' ))),  
  556. 'priority' => null 
  557. )); 
  558.  
  559. $wp_customize->add_setting('typography[info]', array( 
  560. 'sanitize_callback' => 'sanitize_text_field',  
  561. 'type' => 'info_control',  
  562. 'capability' => 'edit_theme_options' 
  563. )); 
  564.  
  565. $wp_customize->add_control( 
  566. new Itconsultant_info( 
  567. $wp_customize,  
  568. 'typography[info]',  
  569. array( 
  570. 'setting' => 'typography[info]',  
  571. 'section' => 'typography',  
  572. 'priority' => null 
  573. ); 
  574.  
  575. $wp_customize->add_section('layout_sec', array( 
  576. 'title' => __('Layout Settings (PRO Version)', 'itconsultant'),  
  577. 'description' => sprintf( __( 'Layout settings available in %s.', 'itconsultant' ), sprintf( '<a href="%1$s" target="_blank">%2$s</a>', esc_url( '"'.SKT_PRO_THEME_URL.'"' ), __( 'PRO Version', 'itconsultant' ))),  
  578. 'priority' => null 
  579. )); 
  580.  
  581. $wp_customize->add_setting('layout[info]', array( 
  582. 'sanitize_callback' => 'sanitize_text_field',  
  583. 'type' => 'info_control',  
  584. 'capability' => 'edit_theme_options' 
  585. )); 
  586.  
  587. $wp_customize->add_control( 
  588. new Itconsultant_info( 
  589. $wp_customize,  
  590. 'layout[info]',  
  591. array( 
  592. 'setting' => 'layout[info]',  
  593. 'section' => 'layout_sec',  
  594. 'priority' => null 
  595. ); 
  596.  
  597. $wp_customize->add_section( 
  598. 'theme_doc_sec',  
  599. array( 
  600. 'title' => __('Documentation & Support', 'itconsultant'),  
  601. 'priority' => null,  
  602. 'description' => sprintf( __( 'For documentation and support check this link %s.', 'itconsultant' ), sprintf( '<a href="%1$s" target="_blank">%2$s</a>', esc_url( '"'.SKT_THEME_DOC.'"' ), __( 'IT Consultant Documentation', 'itconsultant' ))),  
  603.  
  604. ) );  
  605.  
  606. $wp_customize->add_setting('itconsultant_options[info]', array( 
  607. 'sanitize_callback' => 'sanitize_text_field',  
  608. 'type' => 'info_control',  
  609. 'capability' => 'edit_theme_options',  
  610. ); 
  611. $wp_customize->add_control( new Itconsultant_info( $wp_customize, 'doc_section', array( 
  612. 'section' => 'theme_doc_sec',  
  613. 'settings' => 'itconsultant_options[info]',  
  614. 'priority' => 10 
  615. ) ) 
  616. ); 
  617.