<%@ Page language="C#" Inherits="Microsoft.SharePoint.Publishing.PublishingLayoutPage,Microsoft.SharePoint.Publishing,Version=15.0.0.0,Culture=neutral,PublicKeyToken=71e9bce111e9429c" %>
<%-- SharePoint Register tags --%>
<%@ Register Tagprefix="SharePointWebControls" Namespace="Microsoft.SharePoint.WebControls" Assembly="Microsoft.SharePoint, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>
<%@ Register Tagprefix="WebPartPages" Namespace="Microsoft.SharePoint.WebPartPages" Assembly="Microsoft.SharePoint, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>
<%@ Register Tagprefix="PublishingWebControls" Namespace="Microsoft.SharePoint.Publishing.WebControls" Assembly="Microsoft.SharePoint.Publishing, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>
<%@ Register Tagprefix="Taxonomy" Namespace="Microsoft.SharePoint.Taxonomy" Assembly="Microsoft.SharePoint.Taxonomy, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>
<%-- SharePoint Register tags --%>

<asp:Content ContentPlaceholderID="PlaceHolderAdditionalPageHead" runat="server">     
    <style type="text/css">
        #sideNavBox { display: none; }
        #contentBox { margin-left: 0 !important; margin-right: 0 !important; }
    </style>

	<SharePointWebControls:CssRegistration ID="CssRegistration1" name="<% $SPUrl:~sitecollection/Style Library/~language/Themable/Core Styles/pagelayouts15.css %>" runat="server"/>

	<PublishingWebControls:EditModePanel ID="EditModePanel1" runat="server">
		<!-- Styles for edit mode only-->
        <style type="text/css">
            .wizdom-bootstrap-wrapper .wt-newsPage .wt-shadow { padding-left: 25px !important; padding-right: 25px !important; }
            .wizdom-bootstrap-wrapper .wt-newsPage .wt-newsContentArea { padding-right: 0; }
            .wizdom-bootstrap-wrapper, #s4-bodyContainer { background-color: #ffffff !important; }
        </style>
		<script type="text/javascript">
			document.documentElement.className += ' wt-editmode ';
		</script> 
		<SharePointWebControls:CssRegistration ID="CssRegistration3" name="<% $SPUrl:~sitecollection/Style Library/~language/Themable/Core Styles/editmode15.css %>" After="<% $SPUrl:~sitecollection/Style Library/~language/Themable/Core Styles/pagelayouts15.css %>" runat="server"/>
	</PublishingWebControls:EditModePanel>
		<!-- moved from wizdoms masterpage-->
		<!-- Wizdom Custom CSS -->
		<!-- moved to powershell -->

		<!-- Wizdom Custom Scripts -->
		<!-- moved to globalResource.js -->
    <!-- end moved from wizdoms masterpage-->
    <script type="text/template" id="pageColumns">
        <%-- 
			Dont change position!
			Its index based in script that iterates through the values in scriptloader.js
			Always add to the bottom if needed
		--%>
        <div name="Title"><SharePointWebControls:FieldValue FieldName="Title" runat="server" /></div>
        <div name="PublishingContact"><SharePointWebControls:FieldValue FieldName="PublishingContact" runat="server" /></div>
        <div name="W365_HidePageInfo"><SharePointWebControls:FieldValue FieldName="W365_HidePageInfo" runat="server" /></div>
        <div name="W365_Author"><SharePointWebControls:FieldValue FieldName="W365_Author" runat="server" /></div>
        <div name="W365_DepartmentContact"><SharePointWebControls:FieldValue FieldName="W365_DepartmentContact" runat="server" /></div>
        <div name="W365_UseDepartmentContact"><SharePointWebControls:FieldValue FieldName="W365_UseDepartmentContact" runat="server" /></div>
        <div name="W365_HidePageContact"><SharePointWebControls:FieldValue FieldName="W365_HidePageContact" runat="server" /></div>
        <div name="W365_HideRelatedDocuments"><SharePointWebControls:FieldValue FieldName="W365_HideRelatedDocuments" runat="server" /></div>
        <div name="W365_HideRelatedNews"><SharePointWebControls:FieldValue FieldName="W365_HideRelatedNews" runat="server" /></div>
        <div name="W365_HideRelatedPages"><SharePointWebControls:FieldValue FieldName="W365_HideRelatedPages" runat="server" /></div>
        <div name="W365_HideRelatedPeople"><SharePointWebControls:FieldValue FieldName="W365_HideRelatedPeople" runat="server" /></div>
		<div name="W365_HideLeftMenu"><SharePointWebControls:FieldValue FieldName="W365_HideLeftMenu" runat="server" /></div>
		<div name="W365_HideBreadCrumb"><SharePointWebControls:FieldValue FieldName="W365_HideBreadCrumb" runat="server" /></div>
		<div name="pageType">contentPage</div>
        <div name="W365_EnableSocial"><SharePointWebControls:FieldValue FieldName="W365_EnableSocial" runat="server" /></div>
        <div name="w365_PageModified"><SharePointWebControls:DateTimeField FieldName="Modified" runat="server" ControlMode="Display" /></div>
        <div name="w365_PageEditor"><SharePointWebControls:FieldValue FieldName="Editor" runat="server" /></div>
        <div name="W365_NewsDate"><SharePointWebControls:DateTimeField FieldName="W365_NewsDate" runat="server" ControlMode="Display" /></div>
        <div name="W365_RelatedTopic"><SharePointWebControls:FieldValue FieldName="W365_RelatedTopic" runat="server" /></div>
        <div name="W365_Language"><SharePointWebControls:FieldValue FieldName="W365_Language" runat="server" /></div>
        <div name="W365_Departments"><SharePointWebControls:FieldValue FieldName="W365_Departments" runat="server" /></div>
        <div name="W365_Locations"><SharePointWebControls:FieldValue FieldName="W365_Locations" runat="server" /></div>
        <div name="W365_Modul">Corporatenews</div>
        <div name="W365_InstanceId"><SharePointWebControls:FieldValue FieldName="W365_InstanceId" runat="server" /></div>
		<div name="W365_EnableMachineTranslation"><SharePointWebControls:FieldValue FieldName="W365_EnableMachineTranslation" runat="server" /></div>
    </script>
</asp:Content>
<asp:Content ContentPlaceHolderId="PlaceHolderPageTitle" runat="server">
    <SharePointWebControls:FieldValue ID="FieldValue1" FieldName="Title" runat="server"/>
</asp:Content>
<asp:Content ContentPlaceHolderId="PlaceHolderPageTitleInTitleArea" runat="server">
	<SharePointWebControls:FieldValue ID="FieldValue2" FieldName="Title" runat="server" />
</asp:Content>
<asp:Content ContentPlaceHolderId="PlaceHolderTitleBreadcrumb" runat="server">
	<SharePointWebControls:ListSiteMapPath ID="ListSiteMapPath1" runat="server" SiteMapProviders="CurrentNavigationSwitchableProvider" RenderCurrentNodeAsLink="false" PathSeparator="" CssClass="s4-breadcrumb" NodeStyle-CssClass="s4-breadcrumbNode" CurrentNodeStyle-CssClass="s4-breadcrumbCurrentNode" RootNodeStyle-CssClass="s4-breadcrumbRootNode" NodeImageOffsetX=0 NodeImageOffsetY=289 NodeImageWidth=16 NodeImageHeight=16 NodeImageUrl="/_layouts/15/images/fgimg.png?rev=23" HideInteriorRootNodes="true" SkipLinkText="" />
</asp:Content>
<asp:Content ContentPlaceHolderId="PlaceHolderPageDescription" runat="server">
    <SharePointWebControls:ProjectProperty ID="ProjectProperty1" Property="Description" runat="server" />
</asp:Content>
<asp:Content ContentPlaceHolderId="PlaceHolderMain" runat="server">
<div class="wt-2column wt-2column-news wt-newsPage wt-white" id="wizdomPageLayout" ng-controller="wizdom365CorporateNewsInfo">

<div class="container-fluid">
    <div class="row">
        <div class="col-sm-9 wt-shadow bootstrap-wrapper">
            <div class="container-fluid wd-noticeboard">
                <div class="row wt-news-videoRow wizdom-news">
                    <div class="col-xs-12" style="padding: 0;">
                        <div class="wt-news-thumb" id="wt-news-thumb">
                            <PublishingWebControls:RichImageField ID="NewsImageField" runat="server" FieldName="PublishingRollupImage" />
                        </div>
                    </div>
                </div>
                <div class="row">
                    <div class="col-xs-12 col-sm-3">
                        <div class="wt-pagecontrol" wizdom365-newsinfo>
                        </div>
                        <div wizdom365-item-social-container itemid="socialId" itemtype="corporateNews" item="item" tooltipposition="bottom" ng-if="socialFeatureEnabled && socialEnabledOnItem">
                        </div>
                    </div>
                    <div class="col-xs-12 col-sm-9">
                        <div class="wt-newsContentArea">
							<div class="wt-page-translation" wizdom365-pagetranslation ui="true"></div>
                            <h1 class="wt-news-title"><SharePointWebControls:TextField ID="TextField1" runat="server" FieldName="Title" />
                            </h1>
                            <br /><hr class="separator" /><br />
                            <PublishingWebControls:EditModePanel runat="server" ID="EditModePanelNewsDate">
                                <SharePointWebControls:DateTimeField ID="NewsDateField" runat="server" FieldName="W365_NewsDate" />
                            </PublishingWebControls:EditModePanel>
                            <div class="wt-news-content">
                                <PublishingWebControls:RichHtmlField ID="RichHtmlField1" FieldName="PublishingPageContent" HasInitialFocus="True" MinimumEditHeight="400px" runat="server" />
                            </div>
                            <PublishingWebControls:EditModePanel runat="server" ID="EditModePanelResume">
                                <PublishingWebControls:RichHtmlField FieldName="W365_NewsSummary" runat="server" />
                            </PublishingWebControls:EditModePanel>
                            <div wizdom365-comments-panel itemid="socialId" itemtype="corporateNews" item="item" ng-if="socialFeatureEnabled && socialEnabledOnItem">
                            </div>
                            <div wizdom365-relatednews="newsPage" id="relatednews_plc" class="wt-pagecontrol"></div>
                            <div class="wt-webpartzone wt-webpartzone-var2">
                                <WebPartPages:WebPartZone runat="server" AllowPersonalization="true" ID="wt2columnscenter" FrameType="TitleBarOnly" Title="Center" Orientation="Vertical"></WebPartPages:WebPartZone>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>

        <div class="col-sm-3 wt-right-column wt-shadow-panel">
            <!-- Wizdom Pagesettings -->
            <PublishingWebControls:EditModePanel runat="server" PageDisplayMode="Edit">
                <div id="instanceIdWrapper" style="display:none">
                    <SharePointWebControls:TextField ID="InstanceId" runat="server" FieldName="W365_InstanceId"></SharePointWebControls:TextField>
                </div>
                <div class="bootstrap-wrapper" ng-controller="wizdomPageSettings">
                    <div id="wizsettingsctrl" class="wt-controlpanel panel-group" role="tablist" aria-multiselectable="true">
                        <div class="panel panel-default">
                            <div class="panel-heading" role="tab" id="headingOne">
                                <h4 class="panel-title">
                                    <a class="collapsed" ng-click="panels[0].isOpen = !panels[0].isOpen" data-toggle="collapse" href="#collapseOne" aria-expanded="true" aria-controls="collapseOne">
                                        <div class="wt-controlpanel-item-title">
                                            <span class="ms-Icon ms-Icon--Settings editPanelTopAlignment" aria-hidden="true"></span>
                                            <span>{{"General" | translate}}</span>
                                            <i class="pull-right ms-Icon editPanelTopAlignment" ng-class="{'ms-Icon--ChevronDown': panels[0].isOpen, 'ms-Icon--ChevronRight': !panels[0].isOpen}"></i>
                                        </div>
                                    </a>
                                </h4>
                            </div>
                            <div id="collapseOne" class="panel-collapse collapse" role="tabpanel" aria-labelledby="headingOne">
                                <div class="panel-body">
                                    <ul class="ul-reset">
                                        <li ng-hide="disabledPageInfo"><SharepointWebControls:BooleanField ID="W365_HidePageInfo_Field" runat="server" FieldName="W365_HidePageInfo" /></li>
                                        <li ng-if="disabledPageInfo" class="ms-status-yellow" style="padding-left: 10px;">{{"Hide page information is disabled" | translate}}</li>
                                        <li><SharePointWebControls:BooleanField ID="topnewsid" runat="server" FieldName="W365_TopNews" /></li>
										<li id="wt-hidebreadcrumb"><SharePointWebControls:BooleanField ID="W365_HideBreadCrumb_BooleanField" runat="server" FieldName="W365_HideBreadCrumb" /></li>
                                        <li ng-show="socialFeatureEnabled"><SharePointWebControls:BooleanField ID="enablesocial" runat="server" FieldName="W365_EnableSocial" /></li>
										<li ng-show="machineTranslationEnabled && localMachineTranslationEnabled" id="wt-enablemachinetranslation"><SharePointWebControls:BooleanField ID="W365_EnableMachineTranslation_BooleanField" runat="server" FieldName="W365_EnableMachineTranslation" /></li>
                                        <li ng-hide="disabledPageInfo" id="wt-author"><SharepointWebControls:UserField ID="W365_Author_Field" runat="server" FieldName="W365_Author" /></li> 
                                    </ul>
                                </div>
                            </div>
                        </div>
                        <div class="panel panel-default">
                            <div class="panel-heading" role="tab" id="headingTwo">
                                <h4 class="panel-title">
                                    <a class="collapsed" ng-click="panels[1].isOpen = !panels[1].isOpen" data-toggle="collapse" href="#collapseTwo" aria-expanded="false" aria-controls="collapseTwo">
                                        <div class="wt-controlpanel-item-title">
                                            <span class="ms-Icon ms-Icon--Contact editPanelTopAlignment" aria-hidden="true"></span>
                                            <span>{{"Contact settings" | translate}}</span>
                                            <i class="pull-right ms-Icon editPanelTopAlignment" ng-class="{'ms-Icon--ChevronDown': panels[1].isOpen, 
															  'ms-Icon--ChevronRight': !panels[1].isOpen}">
                                            </i>
                                        </div>
                                    </a>
                                </h4>
                            </div>
                            <div id="collapseTwo" class="panel-collapse collapse" role="tabpanel" aria-labelledby="headingTwo">
                                <div class="panel-body">
                                    <ul class="ul-reset">
                                        <li id="wt-publishingcontact" class="wt-publishingcontact">
                                            <SharepointWebControls:UserField ID="PublishingContact_Field" runat="server" FieldName="PublishingContact" />
                                        </li>
                                        <li id="wt-departmentcontact" class="wt-departmentcontact">
                                            <Taxonomy:TaxonomyFieldControl ID="W365_DepartmentContact_Field" runat="server" FieldName="W365_DepartmentContact" />
                                        </li>
                                        <li>
                                            <SharepointWebControls:BooleanField ID="W365_UseDepartmentContact_Field" runat="server" FieldName="W365_UseDepartmentContact" />
                                        </li>
                                        <li ng-hide="disabledPageContact">
                                            <SharepointWebControls:BooleanField ID="W365_HidePageContact_Field" runat="server" FieldName="W365_HidePageContact" />
                                        </li>
                                        <li ng-if="disabledPageContact" class="ms-status-yellow" style="padding-left: 10px;">
                                            {{"Hide contact information is disabled" | translate}}
                                        </li>
                                    </ul>
                                </div>
                            </div>
                        </div>
                        <div class="panel panel-default">
                            <div class="panel-heading" role="tab" id="headingThree">
                                <h4 class="panel-title">
                                    <a class="collapsed" ng-click="panels[2].isOpen = !panels[2].isOpen" data-toggle="collapse" href="#collapseThree" aria-expanded="false" aria-controls="collapseThree">
                                        <div class="wt-controlpanel-item-title">
                                            <span class="ms-Icon ms-Icon--BuildQueue editPanelTopAlignment" aria-hidden="true"></span>
                                            <span>{{"Related Content" | translate}}</span>
                                            <i class="pull-right ms-Icon editPanelTopAlignment" ng-class="{'ms-Icon--ChevronDown': panels[2].isOpen, 
															  'ms-Icon--ChevronRight': !panels[2].isOpen}">
                                            </i>
                                        </div>
                                    </a>
                                </h4>
                            </div>
                            <div id="collapseThree" class="panel-collapse collapse" role="tabpanel" aria-labelledby="headingThree">
                                <div class="panel-body">
                                    <ul class="ul-reset">
                                        <li class="wt-relatedtopic">
                                            <Taxonomy:TaxonomyFieldControl ID="W365_RelatedTopic_Field" runat="server" FieldName="W365_RelatedTopic" />
                                        </li>
                                        <li>
                                            <SharepointWebControls:BooleanField ID="W365_HideRelatedDocuments_Field" runat="server" FieldName="W365_HideRelatedDocuments" />
                                        </li>
                                        <li>
                                            <SharepointWebControls:BooleanField ID="W365_HideRelatedNews_Field" runat="server" FieldName="W365_HideRelatedNews" />
                                        </li>
                                        <li>
                                            <SharepointWebControls:BooleanField ID="W365_HideRelatedPages_Field" runat="server" FieldName="W365_HideRelatedPages" />
                                        </li>
                                        <li>
                                            <SharepointWebControls:BooleanField ID="W365_HideRelatedPeople_Field" runat="server" FieldName="W365_HideRelatedPeople" />
                                        </li>
                                    </ul>
                                </div>
                            </div>
                        </div>
                        <div class="panel panel-default">
                            <div class="panel-heading" role="tab" id="headingFour">
                                <h4 class="panel-title">
                                    <a class="collapsed" ng-click="panels[3].isOpen = !panels[3].isOpen" data-toggle="collapse" href="#collapseFour" aria-expanded="false" aria-controls="collapseFour">
                                        <div class="wt-controlpanel-item-title">
                                            <span class="ms-Icon ms-Icon--AnalyticsQuery editPanelTopAlignment" aria-hidden="true"></span>
                                            <span>{{"Targeting" | translate}}</span>
                                            <i class="pull-right ms-Icon editPanelTopAlignment" ng-class="{'ms-Icon--ChevronDown': panels[3].isOpen, 
														'ms-Icon--ChevronRight': !panels[3].isOpen}">
                                            </i>
                                        </div>
                                    </a>
                                </h4>
                            </div>
                            <div id="collapseFour" class="panel-collapse collapse" role="tabpanel" aria-labelledby="headingFour">
                                <div class="panel-body">
                                    <ul class="ul-reset">
                                        <li class="wt-relatedtopic"><Taxonomy:TaxonomyFieldControl ID="W365_Language_Field" runat="server" FieldName="W365_Language" /></li>
                                        <li class="wt-relatedtopic"><Taxonomy:TaxonomyFieldControl ID="W365_Departments_Field" runat="server" FieldName="W365_Departments" /></li>
                                        <li class="wt-relatedtopic"><Taxonomy:TaxonomyFieldControl ID="W365_Locations_Field" runat="server" FieldName="W365_Locations" /></li>
                                    </ul>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </PublishingWebControls:EditModePanel>
            <!-- End Wizdom Pagesettings -->

            <div id="pagecontact_plc" class="wt-pagecontrol" wizdom365-pagecontact></div>
			<div class="wt-pagecontrol" wizdom365-pagetags></div>
            <div id="relations_plc" class="wt-pagecontrol" wizdom365-relations></div>
            <div class="wt-webpartzone wt-webpartzone-var1 shadowWebpart"><WebPartPages:WebPartZone runat="server" AllowPersonalization="true" ID="wt2columnsright" FrameType="TitleBarOnly" Title="Right" Orientation="Vertical"></WebPartPages:WebPartZone>
            </div>
        </div>
    </div>
</div>

<PublishingWebControls:EditModePanel ID="SpellCheckEditModePanel" runat="server">
     <script type="text/javascript">
            window.addEventListener ? 
            window.addEventListener("load",runAfterLoad,false) : 
            window.attachEvent && window.attachEvent("onload",runAfterLoad);
            function runAfterLoad() {
                function wizdomExcludeFromSpellcheck(divId)
                {
                    try {
                        var a = document.getElementById(divId);
                        var b = a.getElementsByTagName('input');
                        for (var i = 0; i < b.length; i++)
                        {
                            b[i].setAttribute("excludeFromSpellCheck", "true");
                        }

                        var c = a.getElementsByTagName('textarea');
                        for (var i = 0; i < c.length; i++)
                        {
                            c[i].setAttribute("excludeFromSpellCheck", "true");
                        }
                    }
                    catch(error) {

                    }
                }

                wizdomExcludeFromSpellcheck("wizsettingsctrl");
                wizdomExcludeFromSpellcheck("helppanelCntdiv");

                if (!wizdomPageColumns.pageInstanceId) {                    
                    var instanceIdInput = $("#instanceIdWrapper").find("input");
                    var spPageContextInfo = window["_spPageContextInfo"];
                    if (instanceIdInput && spPageContextInfo) {
                        instanceIdInput[0].value = spPageContextInfo.pageItemId + spPageContextInfo.pageListId;
                    }
                }
            }
        </script>
</PublishingWebControls:EditModePanel>
</asp:Content>