403Webshell
Server IP : 194.30.32.123  /  Your IP : 216.73.216.89
Web Server : Apache
System : Linux eab357717bca 5.10.0-44-amd64 #1 SMP Debian 5.10.257-1 (2026-05-27) x86_64
User : ftpbegirale ( 1001)
PHP Version : 7.4.33
Disable Function : exec,passthru,shell_exec,system,proc_open,popen,curl_multi_exec,show_source
MySQL : OFF  |  cURL : ON  |  WGET : OFF  |  Perl : ON  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /expert/htwebs/www.begirale.com/public/wp-content/themes/perspective-theme/include/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /expert/htwebs/www.begirale.com/public/wp-content/themes/perspective-theme/include/page_builder.php
<?php
global $cs_theme_option;
add_action( 'add_meta_boxes', 'cs_page_bulider_add' );
function cs_page_bulider_add() {
	add_meta_box( 'id_page_builder', 'Page Options', 'cs_page_bulider', 'page', 'normal', 'high' );  
}  
function cs_page_bulider( $post ) {
?>
    <div class="page-wrap page-opts" style="overflow:hidden; position:relative; height: 705px;">
        <div class="page-builder">
            <div class="page-head">
                <h5>Layout Sections</h5>
                <div class="add-widget">
                    <span class="addwidget">+ Add Page Elements</span>
                    <div class="widgets-list">
                        <a href="javascript:ajaxSubmit('cs_pb_accordion')">Accordion</a>
                        <a href="javascript:ajaxSubmit('cs_pb_adv_search')">Advance Search</a>
                        <a href="javascript:ajaxSubmit('cs_pb_blog')">Blog</a>
                        <a href="javascript:ajaxSubmit('cs_pb_column')">Column</a>
                        <a href="javascript:ajaxSubmit('cs_pb_contact')">Contact</a>
                        <a href="javascript:ajaxSubmit('cs_pb_review')">Reviews</a>
                        <a href="javascript:ajaxSubmit('cs_pb_divider')">Divider</a>
                        <a href="javascript:ajaxSubmit('cs_pb_dropcap')">Dropcap</a>
                        <a href="javascript:ajaxSubmit('cs_pb_event')">Events</a>
                        <a href="javascript:ajaxSubmit('cs_pb_gallery')">Gallery</a>
                        <a href="javascript:ajaxSubmit('cs_pb_image')">Image Frame</a>
                        <a href="javascript:ajaxSubmit('cs_pb_map')">Map</a>
                        <a href="javascript:ajaxSubmit('cs_pb_client')">Our Clients</a>
                        <a href="javascript:ajaxSubmit('cs_pb_portfolio')">Portfolio</a>
                        <a href="javascript:ajaxSubmit('cs_pb_pricetable')">Price Table</a>
                        <a href="javascript:ajaxSubmit('cs_pb_quote')">Quote</a>
                        <a href="javascript:ajaxSubmit('cs_pb_services')">Services</a>
                        <a href="javascript:ajaxSubmit('cs_pb_slider')">Slider</a>
                        <a href="javascript:ajaxSubmit('cs_pb_tabs')">Tabs</a>
                        <a href="javascript:ajaxSubmit('cs_pb_parallax')">Parallax</a>
						<a href="javascript:ajaxSubmit('cs_pb_video')">Video</a>
                     </div>
                </div>
            </div>
        </div>
        <div class="clear"></div>
        <div id="add_page_builder_item">
            <?php
				global $adv_search_array_counter,$node, $count_node, $xmlObject,$cs_theme_option;
				
				$adv_search_array_counter = 0;
                $count_node = 0;
				$count_widget = 0;
				$page_title = '';
				$page_content = '';
				$page_sub_title = '';
				$header_banner_options = '';
				$header_banner = '';
				$slider_id = '';
				$header_styles = '';
				$switch_footer_widgets = '';
                $cs_page_bulider = get_post_meta($post->ID, "cs_page_builder", true);
				if ( $cs_page_bulider <> "" ) {
                   	$xmlObject = new stdClass();
					$xmlObject = new SimpleXMLElement($cs_page_bulider);
						$count_widget = count($xmlObject->children())-10;
                        foreach ( $xmlObject->children() as $node ){
							if ( $node->getName() == "gallery" ) { cs_pb_gallery(1); }
							else if ( $node->getName() == "adv_search" ) { $adv_search_array_counter++; cs_pb_adv_search(1); }
							else if ( $node->getName() == "slider" ) { cs_pb_slider(1); }
							else if ( $node->getName() == "blog" ) { cs_pb_blog(1); }
 							else if ( $node->getName() == "event" ) { cs_pb_event(1); }
  							else if ( $node->getName() == "review" ) { cs_pb_review(1); }
   							else if ( $node->getName() == "portfolio" ) { cs_pb_portfolio(1); }
 							else if ( $node->getName() == "contact" ) { cs_pb_contact(1); }
							else if ( $node->getName() == "client" ) { cs_pb_client(1); }
							else if ( $node->getName() == "column" ) { cs_pb_column(1); }
							else if ( $node->getName() == "divider" ) { cs_pb_divider(1); }
 							else if ( $node->getName() == "image" ) { cs_pb_image(1); }
							else if ( $node->getName() == "map" ) { cs_pb_map(1); }
							else if ( $node->getName() == "video" ) { cs_pb_video(1); }
							else if ( $node->getName() == "quote" ) { cs_pb_quote(1); }
							else if ( $node->getName() == "dropcap" ) { cs_pb_dropcap(1); }
							else if ( $node->getName() == "pricetable" ) { cs_pb_pricetable(1); }
							else if ( $node->getName() == "tabs" ) { cs_pb_tabs(1); }
							else if ( $node->getName() == "accordions" ) { cs_pb_accordion(1); }
							else if ( $node->getName() == "services" ) { cs_pb_services(1); }
							else if ( $node->getName() == "parallax" ) { cs_pb_parallax(1); }
                         }
                }
 				if ( $cs_page_bulider <> "" ) {
					if ( isset($xmlObject->page_title) ) $page_title = $xmlObject->page_title;
					if ( isset($xmlObject->page_content) ) $page_content = $xmlObject->page_content;
					if ( isset($xmlObject->page_sub_title) ) $page_sub_title = $xmlObject->page_sub_title;
					if ( isset($xmlObject->header_banner_options) ) $header_banner_options = $xmlObject->header_banner_options;
					if ( isset($xmlObject->header_banner) ) $header_banner = $xmlObject->header_banner;
					if ( isset($xmlObject->slider_id) ) $slider_id = htmlspecialchars($xmlObject->slider_id);
					if ( isset($xmlObject->header_styles) ) $header_styles = $xmlObject->header_styles;
					if ( isset($xmlObject->switch_footer_widgets) ) $switch_footer_widgets = $xmlObject->switch_footer_widgets;
  				}else{
					// $header_styles = $cs_theme_option['default_header'];	
				}
			?>
            <div id="no_widget" class="placehoder">Page Builder is Empty, Please Select Page Element. <img src="<?php echo get_template_directory_uri()?>/images/admin/bg-arrowup.png" alt="" /></div>
        </div>
		<div id="loading" class="builderload"></div>
         <div class="clear"></div>
           <script type="text/javascript" src="<?php echo get_template_directory_uri()?>/scripts/admin/prettyCheckable.js"></script>
            <div class="elementhidden">
                <ul class="form-elements">
                    <li class="to-label"><label>Show Page Title</label></li>
                    <li class="to-field">
                        <select name="page_title" class="dropdown">
                            <option value="Yes" <?php if($page_title=="Yes")echo "selected";?> >Yes</option>
                            <option value="No" <?php if($page_title=="No")echo "selected";?> >No</option>
                        </select>
                        <p>Show the title of the page.</p>
                    </li>
                </ul>
                <ul class="form-elements">
                    <li class="to-label"><label>Show Page Description</label></li>
                    <li class="to-field">
                        <select name="page_content" class="dropdown">
                            <option value="Yes" <?php if($page_content=="Yes")echo "selected";?> >Yes</option>
                            <option value="No" <?php if($page_content=="No")echo "selected";?> >No</option>
                        </select>
                        <p>Show the description of the page.</p>
                    </li>
                </ul>
                <ul class="form-elements">
                    <li class="to-label"><label>Page Sub Title</label></li>
                    <li class="to-field">
                    	<input type="text" name="page_sub_title" value="<?php echo $page_sub_title ?>" />
                        <p>Put the sub title of the page.</p>
                    </li>
                </ul>
                <ul class="form-elements header-design">
                    <li class="to-label"><label>Header Styles</label></li>
                    <li class="to-field">
                        <select name="header_styles">
                        	<option value="default-header">Default Header</option>
                            <?php for($i=1; $i<=12; $i++){?>
                                <option value="<?php echo 'header'.$i;?>" <?php if(  $header_styles=='header'.$i ){ echo 'selected="selected"';}?>><?php echo 'Header '.$i;?></option>
                            <?php }?>
                        </select>
                    </li>
                </ul>                
				<ul class="form-elements noborder">
                    <li class="to-label"><label>Header Banner Options</label></li>
                    <li class="to-field">
                        <select name="header_banner_options" class="dropdown" onchange="javascript:toggle_header_banner(this.value)">
	                        <option <?php if($header_banner_options=="Default Image")echo "selected";?> >Default Image</option>
                        	<option <?php if($header_banner_options=="No Image")echo "selected";?> >No Image</option>
                            <option <?php if($header_banner_options=="No Header")echo "selected";?> >No Header</option>
                            <option <?php if($header_banner_options=="Custom Image")echo "selected";?> >Custom Image</option>
                            <option <?php if($header_banner_options=="Slider")echo "selected";?> >Slider</option>
                        </select>
                        <p></p>
                    </li>
					<ul class="form-elements" id="default_image" style="display:<?php if($header_banner_options=="Default Image" or $header_banner_options == "")echo 'inline"';else echo 'none';?>" >
                    	<li class="to-label"></li>
                        <li class="to-field"><p>Default image (subheader-bg.png) can be replaced from images folder</p></li>
                    </ul>                    
                    <ul class="form-elements" id="custom_image" style="display:<?php if($header_banner_options=="Custom Image")echo 'inline"';else echo 'none';?>" >
                    	<li class="to-label"><label>Header Banner</label></li>
                        <li class="to-field">
                        	<input id="header_banner" name="header_banner" value="<?php echo $header_banner?>" type="text" class="small" />
                            <input id="header_banner" name="header_banner" type="button" class="uploadfile left" value="Browse"/>
                        </li>
                    </ul>
                    <ul class="form-elements" id="layer_slider" style="display:<?php if($header_banner_options == "Slider")echo "inline"; else echo "none"; ?>" >
                        <li class="to-label">
                            <label>Use Short Code</label>
                        </li>
                        <li class="to-field">
                            <input type="text" id="slider_id" name="slider_id" class="txtfield" value="<?php echo $slider_id;?>" />
                        </li>
                        <li class="to-label"></li>
                        <li class="to-field">
                            <p>Please enter the Layer/Other Slider Short Code like [layerslider id="1"]</p>
                        </li>                                            
                    </ul>
                     <ul class="form-elements">
                        <li class="to-label"><label>Footer Widgets</label></li>
                        <li class="to-field">
                            <input type="hidden" name="color_switcher" value="" />
                            <input type="checkbox" class="myClass" name="switch_footer_widgets" <?php if(empty($switch_footer_widgets) || $switch_footer_widgets == "on"){ echo "checked"; } ?> />
                            <p>Make footer widgets On/Off</p>
                        </li>
                    </ul>
                    
                 </ul>
            </div>
		<?php cs_meta_layout() ?>
        <input type="hidden" name="page_builder_form" value="1" />
        <div class="clear"></div>
    </div>
<div class="clear"></div>
	
    <script type="text/javascript" src="<?php echo get_template_directory_uri()?>/scripts/admin/jquery.scrollTo-min.js"></script>
    <script>
		jQuery(function() {
			jQuery( "#add_page_builder_item" ).sortable({
				cancel : 'div div.poped-up'
			});
			//jQuery( "#add_page_builder_item" ).disableSelection();
		});
    </script>
	<script type="text/javascript">
		var adv_search_array_counter = <?php echo $adv_search_array_counter ?>;
		var count_widget = <?php echo $count_widget ; ?>;
        function ajaxSubmit(action){
			if ( action == "adv_search_pb" ){
				adv_search_array_counter++;
			}
 			counter++;
			count_widget++;
            var newCustomerForm = "action=" + action + '&counter=' + counter + '&adv_search_array_counter=' + adv_search_array_counter;
            jQuery.ajax({
                type:"POST",
                url: "<?php echo admin_url('admin-ajax.php');?>",
                data: newCustomerForm,
                success:function(data){
                    jQuery("#add_page_builder_item").append(data);
					if (count_widget > 0) jQuery("#add_page_builder_item").addClass('hasclass');
					//alert(count_widget);
                }
            });
            //return false;
        }
    </script>

<?php  
}
	if ( isset($_POST['page_builder_form']) and $_POST['page_builder_form'] == 1 ) {
		add_action( 'save_post', 'save_page_builder' );
		function save_page_builder( $post_id ) {
			if( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) return;
				if ( isset($_POST['cs_orderby']) ) {
					//creating xml page builder start
					$sxe = new SimpleXMLElement("<pagebuilder></pagebuilder>");
						$sxe->addChild('page_title', $_POST['page_title']);
						$sxe->addChild('page_content', $_POST['page_content']);
						$sxe->addChild('page_sub_title', $_POST['page_sub_title']);
						$sxe->addChild('header_banner_options', $_POST['header_banner_options']);
						$sxe->addChild('header_banner', $_POST['header_banner']);
						$sxe->addChild('slider_id', $_POST['slider_id']);
						$sxe->addChild('header_styles', $_POST['header_styles']);
						$sxe->addChild('switch_footer_widgets', $_POST['switch_footer_widgets']);
						$sxe = cs_save_layout_xml($sxe);
							if ( isset($_POST['cs_orderby']) ) {
								$counter = 0;
								$counter_gal = 0;
								$counter_port = 0;
								$counter_event = 0;
								$counter_review = 0;
								$counter_slider = 0;
								$counter_blog = 0;
								$counter_news = 0;
								$counter_contact = 0;
								$counter_testimonial = 0;
  								$counter_portfolio = 0;
								$counter_client = 0;
 								$counter_column = 0;
								$counter_divider = 0;
								$counter_mb = 0;
								$counter_image = 0;
								$counter_map = 0;
								$counter_video = 0;
								$counter_quote = 0;
								$counter_dropcap = 0;
								$counter_pricetable = 0;
								$counter_services = 0;
								$counter_services_node = 0;
								$counter_tabs = 0;
								$counter_tabs_node = 0;
								$counter_accordion = 0;
								$counter_accordion_node = 0;
								$counter_testimonial = 0;
								$counter_testimonial_node = 0;
								$counter_team = 0;
								$counter_team_node = 0;
								$counter_parallax =0;
								$counter_adv_search = 0;
 								foreach ( $_POST['cs_orderby'] as $count ){
									if ( $_POST['cs_orderby'][$counter] == "adv_search" ) {
										$adv_search = $sxe->addChild('adv_search');
											$adv_search->addChild('adv_search_element_size', $_POST['adv_search_element_size'][$counter_adv_search] );
											$adv_search->addChild('adv_search_title', $_POST['adv_search_title'][$counter_adv_search] );
											$adv_search->addChild('adv_search_desc', $_POST['adv_search_desc'][$counter_adv_search] );
											$categories = $adv_search->addChild('categories');
												if ( $_POST['adv_search_cats'][$counter_adv_search+1] ) {
													foreach ( $_POST['adv_search_cats'][$counter_adv_search+1] as $key => $val ) {
														$categories->addChild('category', $val );
													}
												}
										$counter_adv_search++;
									}
									else if ( $_POST['cs_orderby'][$counter] == "gallery" ) {
										$gallery = $sxe->addChild('gallery');
											$gallery->addChild('header_title', $_POST['cs_gal_header_title'][$counter_gal] );
											$gallery->addChild('layout', $_POST['cs_gal_layout'][$counter_gal] );
											$gallery->addChild('album', $_POST['cs_gal_album'][$counter_gal] );
											$gallery->addChild('desc', $_POST['cs_gal_desc'][$counter_gal] );
											$gallery->addChild('pagination', $_POST['cs_gal_pagination'][$counter_gal] );
											$gallery->addChild('media_per_page', $_POST['cs_gal_media_per_page'][$counter_gal] );
											$gallery->addChild('gallery_element_size', $_POST['gallery_element_size'][$counter_gal] );
										$counter_gal++;
									}
									else if ( $_POST['cs_orderby'][$counter] == "slider" ) {
										$slider = $sxe->addChild('slider');
											$slider->addChild('slider_header_title', $_POST['cs_slider_header_title'][$counter_slider] );
											$slider->addChild('slider_type', $_POST['cs_slider_type'][$counter_slider] );
											$slider->addChild('slider', $_POST['cs_slider'][$counter_slider] );
											$slider->addChild('slider_view', $_POST['slider_view'][$counter_slider] );
											$slider->addChild('slider_id', htmlspecialchars($_POST['cs_slider_id'][$counter_slider]) );
											$slider->addChild('width', $_POST['cs_slider_width'][$counter_slider] );
											$slider->addChild('height', $_POST['cs_slider_height'][$counter_slider] );
											$slider->addChild('slider_element_size', $_POST['slider_element_size'][$counter_slider] );
										$counter_slider++;
									}
									else if ( $_POST['cs_orderby'][$counter] == "blog" ) {
										$blog = $sxe->addChild('blog');
											$blog->addChild('cs_blog_title', htmlspecialchars($_POST['cs_blog_title'][$counter_blog]) );
											$blog->addChild('cs_blog_view', $_POST['cs_blog_view'][$counter_blog] );
											$blog->addChild('cs_blog_cat', $_POST['cs_blog_cat'][$counter_blog] );
											$blog->addChild('cs_blog_excerpt', $_POST['cs_blog_excerpt'][$counter_blog] );
											$blog->addChild('cs_blog_num_post', $_POST['cs_blog_num_post'][$counter_blog] );
											$blog->addChild('cs_blog_pagination', $_POST['cs_blog_pagination'][$counter_blog] );
											$blog->addChild('blog_element_size', $_POST['blog_element_size'][$counter_blog] );
										$counter_blog++;
									}
 									else if ( $_POST['cs_orderby'][$counter] == "event" ) {
										$event = $sxe->addChild('event');
											$event->addChild('cs_event_title', htmlspecialchars($_POST['cs_event_title'][$counter_event]) );
											$event->addChild('cs_event_view', $_POST['cs_event_view'][$counter_event] );
											$event->addChild('cs_event_type', $_POST['cs_event_type'][$counter_event] );
											$event->addChild('cs_event_category', $_POST['cs_event_category'][$counter_event] );
											$event->addChild('cs_event_time', $_POST['cs_event_time'][$counter_event] );
											$event->addChild('cs_event_organizer', $_POST['cs_event_organizer'][$counter_event] );
 											$event->addChild('cs_event_filterables', $_POST['cs_event_filterables'][$counter_event] );
											$event->addChild('cs_event_pagination', $_POST['cs_event_pagination'][$counter_event] );
											$event->addChild('cs_event_per_page', $_POST['cs_event_per_page'][$counter_event] );
											$event->addChild('event_element_size', $_POST['event_element_size'][$counter_event] );
										$counter_event++;
									}
									else if ( $_POST['cs_orderby'][$counter] == "review" ) {
										$review = $sxe->addChild('review');
											$review->addChild('review_title', htmlspecialchars($_POST['review_title'][$counter_review]) );
											$review->addChild('review_cat', $_POST['review_cat'][$counter_review] );
											$review->addChild('review_view', $_POST['review_view'][$counter_review] );
											$review->addChild('review_filterable', $_POST['review_filterable'][$counter_review] );
											$review->addChild('review_pagination', $_POST['review_pagination'][$counter_review] );
											$review->addChild('review_per_page', $_POST['review_per_page'][$counter_review] );
											$review->addChild('review_element_size', $_POST['review_element_size'][$counter_review] );
										$counter_review++;
									} 
 									else if ( $_POST['cs_orderby'][$counter] == "portfolio" ) {
										$portfolio = $sxe->addChild('portfolio');
											$portfolio->addChild('portfolio_title', htmlspecialchars($_POST['portfolio_title'][$counter_portfolio]) );
											$portfolio->addChild('portfolio_cat', $_POST['portfolio_cat'][$counter_portfolio] );
											$portfolio->addChild('portfolio_view', $_POST['portfolio_view'][$counter_portfolio] );
											$portfolio->addChild('portfolio_filterable', $_POST['portfolio_filterable'][$counter_portfolio] );
											$portfolio->addChild('portfolio_post_title', $_POST['portfolio_post_title'][$counter_portfolio] );
											$portfolio->addChild('portfolio_pagination', $_POST['portfolio_pagination'][$counter_portfolio] );
											$portfolio->addChild('portfolio_per_page', $_POST['portfolio_per_page'][$counter_portfolio] );
											$portfolio->addChild('portfolio_element_size', $_POST['portfolio_element_size'][$counter_portfolio] );
										$counter_portfolio++;
									}
									else if ( $_POST['cs_orderby'][$counter] == "contact" ) {
										$contact = $sxe->addChild('contact');
 											$contact->addChild('cs_contact_email', $_POST['cs_contact_email'][$counter_contact] );
											$contact->addChild('cs_contact_succ_msg', $_POST['cs_contact_succ_msg'][$counter_contact] );
											$contact->addChild('contact_element_size', $_POST['contact_element_size'][$counter_contact] );
										$counter_contact++;
									}
									else if ( $_POST['cs_orderby'][$counter] == "client" ) {
										$client = $sxe->addChild('client');
											$client->addChild('client_header_title', $_POST['client_header_title'][$counter_client] );
											$client->addChild('client_gallery', $_POST['client_gallery'][$counter_client] );
											$client->addChild('client_view', $_POST['client_view'][$counter_client] );
											$client->addChild('client_element_size', $_POST['client_element_size'][$counter_client] );
										$counter_client++;
									}
									else if ( $_POST['cs_orderby'][$counter] == "column" ) {
										$column = $sxe->addChild('column');
											$column->addChild('column_element_size', htmlspecialchars($_POST['column_element_size'][$counter_column]) );
											$column->addChild('column_text', htmlspecialchars($_POST['column_text'][$counter_column]));
										$counter_column++;
									}
									else if ( $_POST['cs_orderby'][$counter] == "divider" ) {
										$divider = $sxe->addChild('divider');
											$divider->addChild('divider_element_size', htmlspecialchars($_POST['divider_element_size'][$counter_divider]) );
											$divider->addChild('divider_style', $_POST['divider_style'][$counter_divider] );
											$divider->addChild('divider_backtotop', $_POST['divider_backtotop'][$counter_divider] );
											$divider->addChild('divider_mrg_top', $_POST['divider_mrg_top'][$counter_divider] );
											$divider->addChild('divider_mrg_bottom', $_POST['divider_mrg_bottom'][$counter_divider] );
										$counter_divider++;
									}
									/*else if ( $_POST['cs_orderby'][$counter] == "message_box" ) {
										$divider = $sxe->addChild('message_box');
											$divider->addChild('mb_element_size', htmlspecialchars($_POST['mb_element_size'][$counter_mb]) );
											$divider->addChild('mb_title', htmlspecialchars($_POST['mb_title'][$counter_mb]) );
											$divider->addChild('mb_content', htmlspecialchars($_POST['mb_content'][$counter_mb]) );
											$divider->addChild('mb_bg_color', htmlspecialchars($_POST['mb_bg_color'][$counter_mb]) );
										$counter_mb++;
									}*/
									else if ( $_POST['cs_orderby'][$counter] == "image" ) {
										$divider = $sxe->addChild('image');
											$divider->addChild('image_element_size', htmlspecialchars($_POST['image_element_size'][$counter_image]) );
											$divider->addChild('image_width', htmlspecialchars($_POST['image_width'][$counter_image]) );
											$divider->addChild('image_height', htmlspecialchars($_POST['image_height'][$counter_image]) );
											$divider->addChild('image_lightbox', htmlspecialchars($_POST['image_lightbox'][$counter_image]) );
											$divider->addChild('image_source', htmlspecialchars($_POST['image_source'][$counter_image]) );
											$divider->addChild('image_style', htmlspecialchars($_POST['image_style'][$counter_image]) );
											$divider->addChild('image_caption', htmlspecialchars($_POST['image_caption'][$counter_image]) );
										$counter_image++;
									}
									else if ( $_POST['cs_orderby'][$counter] == "map" ) {
										$divider = $sxe->addChild('map');
											$divider->addChild('map_element_size', htmlspecialchars($_POST['map_element_size'][$counter_map]) );
											$divider->addChild('map_title', htmlspecialchars($_POST['map_title'][$counter_map]) );
											$divider->addChild('map_height', htmlspecialchars($_POST['map_height'][$counter_map]) );
											$divider->addChild('map_lat', htmlspecialchars($_POST['map_lat'][$counter_map]) );
											$divider->addChild('map_lon', htmlspecialchars($_POST['map_lon'][$counter_map]) );
											$divider->addChild('map_zoom', htmlspecialchars($_POST['map_zoom'][$counter_map]) );
											$divider->addChild('map_type', htmlspecialchars($_POST['map_type'][$counter_map]) );
											$divider->addChild('map_info', $_POST['map_info'][$counter_map] );
											$divider->addChild('map_info_width', $_POST['map_info_width'][$counter_map] );
											$divider->addChild('map_info_height', $_POST['map_info_height'][$counter_map] );
											$divider->addChild('map_marker_icon', $_POST['map_marker_icon'][$counter_map] );
											$divider->addChild('map_show_marker', $_POST['map_show_marker'][$counter_map] );
											$divider->addChild('map_controls', $_POST['map_controls'][$counter_map] );
											$divider->addChild('map_draggable', htmlspecialchars($_POST['map_draggable'][$counter_map]) );
											$divider->addChild('map_scrollwheel', htmlspecialchars($_POST['map_scrollwheel'][$counter_map]) );
											$divider->addChild('map_view', htmlspecialchars($_POST['map_view'][$counter_map]) );

										$counter_map++;
									}
									else if ( $_POST['cs_orderby'][$counter] == "video" ) {
										$divider = $sxe->addChild('video');
											$divider->addChild('video_element_size', htmlspecialchars($_POST['video_element_size'][$counter_video]) );
											$divider->addChild('video_url', htmlspecialchars($_POST['video_url'][$counter_video]) );
											$divider->addChild('video_width', htmlspecialchars($_POST['video_width'][$counter_video]) );
											$divider->addChild('video_height', htmlspecialchars($_POST['video_height'][$counter_video]) );
										$counter_video++;
									}
									else if ( $_POST['cs_orderby'][$counter] == "quote" ) {
										$divider = $sxe->addChild('quote');
											$divider->addChild('quote_element_size', htmlspecialchars($_POST['quote_element_size'][$counter_quote]) );
											$divider->addChild('quote_text_color', htmlspecialchars($_POST['quote_text_color'][$counter_quote]) );
											$divider->addChild('quote_align', htmlspecialchars($_POST['quote_align'][$counter_quote]) );
											$divider->addChild('quote_content', htmlspecialchars($_POST['quote_content'][$counter_quote]) );
										$counter_quote++;
									}
									else if ( $_POST['cs_orderby'][$counter] == "dropcap" ) {
										$divider = $sxe->addChild('dropcap');
											$divider->addChild('dropcap_element_size', htmlspecialchars($_POST['dropcap_element_size'][$counter_dropcap]) );
											$divider->addChild('dropcap_content', htmlspecialchars($_POST['dropcap_content'][$counter_dropcap]) );
										$counter_dropcap++;
									}
									else if ( $_POST['cs_orderby'][$counter] == "pricetable" ) {
										$divider = $sxe->addChild('pricetable');
											$divider->addChild('pricetable_element_size', htmlspecialchars($_POST['pricetable_element_size'][$counter_pricetable]) );
											$divider->addChild('pricetable_title', htmlspecialchars($_POST['pricetable_title'][$counter_pricetable]) );
											$divider->addChild('pricetable_price', htmlspecialchars($_POST['pricetable_price'][$counter_pricetable]) );
											$divider->addChild('pricetable_currency', htmlspecialchars($_POST['pricetable_currency'][$counter_pricetable]) );
											$divider->addChild('pricetable_content', htmlspecialchars($_POST['pricetable_content'][$counter_pricetable]) );
											$divider->addChild('pricetable_linktitle', htmlspecialchars($_POST['pricetable_linktitle'][$counter_pricetable]) );
											$divider->addChild('pricetable_linkurl', htmlspecialchars($_POST['pricetable_linkurl'][$counter_pricetable]) );
											$divider->addChild('pricetable_featured', htmlspecialchars($_POST['pricetable_featured'][$counter_pricetable]) );
											$divider->addChild('pricetable_bgcolor', htmlspecialchars($_POST['pricetable_bgcolor'][$counter_pricetable]) );
  										$counter_pricetable++;
									}
									else if ( $_POST['cs_orderby'][$counter] == "services" ) {
										$services = $sxe->addChild('services');
											$services->addChild('services_element_size', htmlspecialchars($_POST['services_element_size'][$counter_services]) );
											for ( $i = 1; $i <= $_POST['services_num'][$counter_services]; $i++ ){
												$service = $services->addChild('service');
												$service->addChild('service_title', htmlspecialchars( $_POST['service_title'][$counter_services_node] ) );
												$service->addChild('service_icon', htmlspecialchars( $_POST['service_icon'][$counter_services_node] ) );
												$service->addChild('service_text', htmlspecialchars( $_POST['service_text'][$counter_services_node] ) );
												$service->addChild('service_style', htmlspecialchars( $_POST['service_style'][$counter_services_node] ) );
												$counter_services_node++;
											}
										$counter_services++;
									}
									else if ( $_POST['cs_orderby'][$counter] == "tabs" ) {
										$tabs = $sxe->addChild('tabs');
											$tabs->addChild('tabs_element_size', htmlspecialchars($_POST['tabs_element_size'][$counter_tabs]) );
											for ( $i = 1; $i <= $_POST['tabs_num'][$counter_tabs]; $i++ ){
												$tab = $tabs->addChild('tab');
												$tab->addChild('tab_title', htmlspecialchars( $_POST['tab_title'][$counter_tabs_node] ) );
												$tab->addChild('tab_text', htmlspecialchars( $_POST['tab_text'][$counter_tabs_node] ) );
												$tab->addChild('tab_title_icon', htmlspecialchars( $_POST['tab_title_icon'][$counter_tabs_node] ) );
												$tab->addChild('tab_active', htmlspecialchars( $_POST['tab_active'][$counter_tabs_node] ) );
												$counter_tabs_node++;
											}
										$counter_tabs++;
									}
									else if ( $_POST['cs_orderby'][$counter] == "accordions" ) {
										$accordions = $sxe->addChild('accordions');
											$accordions->addChild('accordion_element_size', htmlspecialchars($_POST['accordion_element_size'][$counter_accordion]) );
											for ( $i = 1; $i <= $_POST['accordion_num'][$counter_accordion]; $i++ ){
												$accordion = $accordions->addChild('accordion');
												$accordion->addChild('accordion_title', htmlspecialchars( $_POST['accordion_title'][$counter_accordion_node] ) );
												$accordion->addChild('accordion_text', htmlspecialchars( $_POST['accordion_text'][$counter_accordion_node] ) );
												$accordion->addChild('accordion_title_icon', htmlspecialchars( $_POST['accordion_title_icon'][$counter_accordion_node] ) );
												$accordion->addChild('accordion_active', htmlspecialchars( $_POST['accordion_active'][$counter_accordion_node] ) );
												$counter_accordion_node++;
											}
										$counter_accordion++;
									}
									else if ( $_POST['cs_orderby'][$counter] == "parallax" ) {
										$parallax = $sxe->addChild('parallax');
											$parallax->addChild('parallax_element_size', $_POST['parallax_element_size'][$counter_parallax] );
											$parallax->addChild('parallax_view', $_POST['parallax_view'][$counter_parallax] );
											$parallax->addChild('parallax_height', $_POST['parallax_height'][$counter_parallax] );
											$parallax->addChild('parallax_margin_top', $_POST['parallax_margin_top'][$counter_parallax] );
											$parallax->addChild('parallax_margin_bottom', $_POST['parallax_margin_bottom'][$counter_parallax] );
											$parallax->addChild('parallax_element', htmlspecialchars($_POST['parallax_element'][$counter_parallax]) );
												$parallax->addChild('parallax_twitter_profile', htmlspecialchars($_POST['parallax_twitter_profile'][$counter_parallax]) );
												$parallax->addChild('parallax_twitter_num_tweets', htmlspecialchars($_POST['parallax_twitter_num_tweets'][$counter_parallax]) );
												$parallax->addChild('parallax_twitter_back_top', htmlspecialchars($_POST['parallax_twitter_back_top'][$counter_parallax]) );
												$parallax->addChild('parallax_twitter_bgimg', htmlspecialchars($_POST['parallax_twitter_bgimg'][$counter_parallax]) );
												$parallax->addChild('parallax_twitter_bgcolor', htmlspecialchars($_POST['parallax_twitter_bgcolor'][$counter_parallax]) );
											$parallax->addChild('parallax_blog_category', htmlspecialchars($_POST['parallax_blog_category'][$counter_parallax]) );
											$parallax->addChild('parallax_blog_num_post', htmlspecialchars($_POST['parallax_blog_num_post'][$counter_parallax]) );
											$parallax->addChild('parallax_blog_bgcolor', htmlspecialchars($_POST['parallax_blog_bgcolor'][$counter_parallax]) );
											$parallax->addChild('parallax_blog_bgimg', htmlspecialchars($_POST['parallax_blog_bgimg'][$counter_parallax]) );
												$parallax->addChild('parallax_portfolio_category', htmlspecialchars($_POST['parallax_portfolio_category'][$counter_parallax]) );
												$parallax->addChild('parallax_portfolio_num_post', htmlspecialchars($_POST['parallax_portfolio_num_post'][$counter_parallax]) );
												$parallax->addChild('parallax_portfolio_bgcolor', htmlspecialchars($_POST['parallax_portfolio_bgcolor'][$counter_parallax]) );
												$parallax->addChild('parallax_portfolio_bgimg', htmlspecialchars($_POST['parallax_portfolio_bgimg'][$counter_parallax]) );
											$parallax->addChild('parallax_map_title', htmlspecialchars($_POST['parallax_map_title'][$counter_parallax]) );
											$parallax->addChild('parallax_map_lat', htmlspecialchars($_POST['parallax_map_lat'][$counter_parallax]) );
											$parallax->addChild('parallax_map_lon', htmlspecialchars($_POST['parallax_map_lon'][$counter_parallax]) );
											$parallax->addChild('parallax_map_zoom', htmlspecialchars($_POST['parallax_map_zoom'][$counter_parallax]) );
											$parallax->addChild('parallax_map_type', htmlspecialchars($_POST['parallax_map_type'][$counter_parallax]) );
											$parallax->addChild('parallax_map_info', $_POST['parallax_map_info'][$counter_parallax] );
											$parallax->addChild('parallax_map_info_width', $_POST['parallax_map_info_width'][$counter_parallax] );
											$parallax->addChild('parallax_map_info_height', $_POST['parallax_map_info_height'][$counter_parallax] );
											$parallax->addChild('parallax_map_marker_icon', $_POST['parallax_map_marker_icon'][$counter_parallax] );
											$parallax->addChild('parallax_map_show_marker', $_POST['parallax_map_show_marker'][$counter_parallax] );
											$parallax->addChild('parallax_map_controls', $_POST['parallax_map_controls'][$counter_parallax] );
											$parallax->addChild('parallax_map_draggable', htmlspecialchars($_POST['parallax_map_draggable'][$counter_parallax]) );
											$parallax->addChild('parallax_map_scrollwheel', htmlspecialchars($_POST['parallax_map_scrollwheel'][$counter_parallax]) );
											$parallax->addChild('parallax_map_view', htmlspecialchars($_POST['parallax_map_view'][$counter_parallax]) );
				
											     $parallax->addChild('parallax_map_bgcolor', htmlspecialchars($_POST['parallax_map_bgcolor'][$counter_parallax]) );
												$parallax->addChild('parallax_custom_text', htmlspecialchars($_POST['parallax_custom_text'][$counter_parallax]) );
												$parallax->addChild('parallax_custom_img', htmlspecialchars($_POST['parallax_custom_img'][$counter_parallax]) );
												$parallax->addChild('parallax_custom_back_top', htmlspecialchars($_POST['parallax_custom_back_top'][$counter_parallax]) );
												$parallax->addChild('parallax_custom_bgcolor', htmlspecialchars($_POST['parallax_custom_bgcolor'][$counter_parallax]) );
											
										$counter_parallax++;
									}
									/*else if ( $_POST['cs_orderby'][$counter] == "testimonials" ) {
										$testimonials = $sxe->addChild('testimonials');
											$testimonials->addChild('testimonial_element_size', htmlspecialchars($_POST['testimonial_element_size'][$counter_testimonial]) );
											for ( $i = 1; $i <= $_POST['testimonial_num'][$counter_testimonial]; $i++ ){
												$testimonial = $testimonials->addChild('testimonial');
												$testimonial->addChild('testimonial_title', htmlspecialchars( $_POST['testimonial_title'][$counter_testimonial_node] ) );
												$testimonial->addChild('testimonial_text', htmlspecialchars( $_POST['testimonial_text'][$counter_testimonial_node] ) );
												$testimonial->addChild('testimonial_company', htmlspecialchars( $_POST['testimonial_company'][$counter_testimonial_node] ) );
												$testimonial->addChild('testimonial_img', htmlspecialchars( $_POST['testimonial_img'][$counter_testimonial_node] ) );
												$counter_testimonial_node++;
											}
										$counter_testimonial++;
									}
									else if ( $_POST['cs_orderby'][$counter] == "teams" ) {
										$teams = $sxe->addChild('teams');
											$teams->addChild('team_element_size', htmlspecialchars($_POST['team_element_size'][$counter_team]) );
											for ( $i = 1; $i <= $_POST['team_num'][$counter_team]; $i++ ){
												$team = $teams->addChild('team');
												$team->addChild('team_image_url', htmlspecialchars( $_POST['team_image_url'][$counter_team_node] ) );
												$team->addChild('team_name', htmlspecialchars( $_POST['team_name'][$counter_team_node] ) );
												$team->addChild('team_designation', htmlspecialchars( $_POST['team_designation'][$counter_team_node] ) );
												$team->addChild('team_fb', htmlspecialchars( $_POST['team_fb'][$counter_team_node] ) );
												$team->addChild('team_twitter', htmlspecialchars( $_POST['team_twitter'][$counter_team_node] ) );
												$team->addChild('team_in', htmlspecialchars( $_POST['team_in'][$counter_team_node] ) );
												$counter_team_node++;
											}
										$counter_team++;
									}
*/									 
									$counter++;
								}
							}
							update_post_meta( $post_id, 'cs_page_builder', $sxe->asXML() );
					//creating xml page builder end
				}
		}
	}
?>

Youez - 2016 - github.com/yon3zu
LinuXploit