Question

I have a website project that include a masterpage : when ı tried to add ajax control toolkit EDITOR, I am getting a error like This page is missing a HtmlHead control which is required for the CSS stylesheet link that is being added. Please add <head runat="server" />.

when ı add masterpage ContentPlaceHolder1 a <form runat="server"></form>, there arent any error but I don't want to add each masterpage form element how can ı solved this problem?

<%@ Page Title="" Language="C#" MasterPageFile="~/AdminPanel/Admin.Master" AutoEventWireup="true" CodeBehind="Tadd.aspx.cs" Inherits="Tadd.AdminPanel.Tadd1" %>

<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit.HTMLEditor" TagPrefix="cc1" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
        <ajaxToolkit:ToolkitScriptManager ID="ToolkitScriptManager1" runat="server"></ajaxToolkit:ToolkitScriptManager>

</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <form runat="server">
    <cc1:Editor ID="Editor1" runat="server" />
        </form>
</asp:Content>
Was it helpful?

Solution

You should have an head tag in your Master-Page which is run at server:

<head id="page-head" runat="server">
...
</head>

And positioned it in top of your page/html.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top