Unable to set BreakElement to P

Last post 08-08-2005, 12:35 PM by jmcwilliam. 4 replies.
Sort Posts: Previous Next
  •  08-05-2005, 5:53 PM 9322

    Unable to set BreakElement to P

    I am running DotNetNuke 3.1 and I have the latest version as of 7/11/05 for DNN 3.1.  It works well, but I am getting some horrible issues when trying to use bulleted lists.  I have traced it to the issue of the break element.  If you go into a current block of text, whether it is free or in a div, regardless of whether or not you have your BreakElement set to br or div, and you hit enter, you get br's for each new line inside the current div.  If you then try and create a bulletted list out of any line in there, it makes the entire div the first element of the list.  I have found that if you use P for your BreakElement, everytime you you hit enter, you always get a new paragraph, and creating a bulletted list works as you would suspect. 
     
    The only problem is I have set my BreakElement to 'p' in my web.config, and it is being ignored.  It still uses 'div'.  Please help!
  •  08-05-2005, 6:12 PM 9325 in reply to 9322

    Re: Unable to set BreakElement to P

    Let me explain the break elment isssue.

    For example, you set your breakelement to DIV.


     
    Scenario 1:
     
    <div>hello world</div>pess enter here
     
    You should get the following result:
     
    <div>hello world</div>
    <div>&#160;</div>

    -----------------------------------------------------------------------------------------------

    Scenario 2:
     
    <div>hello pess enter here world</div>
     
    You should get the following result:
     
    <div>hello <br/> world</div>




    In the Scenario 1, Cute Editor detects you just finish eding a block and want to start a new block (paragraph). So it will automatically insert the block element <div> or <p>.

    In the Scenario 2, Cute Editor detects you are editing the content in the same block (paragraph).

    So it will use the break element to force a break in the current line of text.


    Hope it helps.

    Let me know if you have any further questions about this.

    I am checking your second question.


     
     

    asp.net Chat http://cutesoft.net/ASP.NET+Chat/default.aspx
    Web Messenger: http://cutesoft.net/Web-Messenger/default.aspx
    asp.net wysiwyg editor: http://cutesoft.net/ASP.NET+WYSIWYG+Editor/default.aspx
    asp wysiwyg html editor: http://cutesoft.net/ASP
    asp.net Image Gallery: http://cutesoft.net/ASP.NET+Image+Gallery/default.aspx
    Live Support: http://cutesoft.net/live-support/default.aspx

  •  08-07-2005, 8:21 AM 9333 in reply to 9325

    Re: Unable to set BreakElement to P

    Yeah, I have figured out thats the way it works when the break element is set to div.  The problem is that it causes issues if someone does any sort of editing to a block of text.  If someone tried to go to an existing block of text and hit enter, they get different behavior than when they originally typed it.  One specific problem is if the user wants to insert an unordered list.  They hit enter and space out text, then hit the unordered list button, but the entire contents of the div become the first list item.
     
    From what I have seen in your demo and other editors, when you use the P tag for the break element, it always creates a seperate paragraph regardless of whether you are typing new text or editing.  When you try and create a list, it then works properly.  This is fine, but for some reason, I set the Break element to p (BreakElement="P") in my web.config but it still uses div.  I have tried both uppercase 'p' and lowercase.
  •  08-08-2005, 12:29 PM 9356 in reply to 9333

    Re: Unable to set BreakElement to P

     jmcwilliam wrote:
    but for some reason, I set the Break element to p (BreakElement="P") in my web.config but it still uses div.  I have tried both uppercase 'p' and lowercase.
     
    This is a bug in the provider.
     
                    Select Case _BreakElement Case "div" cntlCE.BreakElement = BreakElement.Div Case "br" cntlCE.BreakElement = BreakElement.Br Case "paragraph" cntlCE.BreakElement = BreakElement.P End Select


    Should be

                Select Case _BreakElement Case "div" cntlCE.BreakElement = BreakElement.Div Case "br" cntlCE.BreakElement = BreakElement.Br Case "p" cntlCE.BreakElement = BreakElement.P End Select

    Then you need to recompile your provider project. If you don't want to recompile the project by yourself, please download the provider again.

    Sorry for the inconvenience.


     

    asp.net Chat http://cutesoft.net/ASP.NET+Chat/default.aspx
    Web Messenger: http://cutesoft.net/Web-Messenger/default.aspx
    asp.net wysiwyg editor: http://cutesoft.net/ASP.NET+WYSIWYG+Editor/default.aspx
    asp wysiwyg html editor: http://cutesoft.net/ASP
    asp.net Image Gallery: http://cutesoft.net/ASP.NET+Image+Gallery/default.aspx
    Live Support: http://cutesoft.net/live-support/default.aspx

  •  08-08-2005, 12:35 PM 9359 in reply to 9356

    Re: Unable to set BreakElement to P

    That did it.  Thanks a lot!!
View as RSS news feed in XML