Line break problem - to many braks being inserted

Last post 09-08-2008, 9:35 PM by mat41. 5 replies.
Sort Posts: Previous Next
  •  09-08-2008, 12:00 AM 43679

    Line break problem - to many braks being inserted

    Hello - I have a strange issue I have been avoiding for a while now.  if I enter:
     
    the first line
    the second line immediatly after the first

    the third line has one line break above it


    the fourth line has two line breaks above it
     
    Before I submit the txt above I click the HTML button.  It shows me the following:
     
    the first line<br />
    the second line immediatly after the first<br />
    <br />
    the third line has one line break above it<br />
    <br />
    <br />
    the fourth line has two line breaks above it
     
    Which is perfect.  Exactly as I want it to look.  Now I submit the information into my DB however when the page refreshes the content look like this:
     
    the first line

    the second line immediatly after the first



    the third line has one line break above it





    the fourth line has two line breaks above it
     
    As you can see for some reason all the BR tags are doubling up.  The HTML button in relation to the above output is:
     
    the first line<br />
    <br />
    the second line immediatly after the first<br />
    <br />
    <br />
    <br />
    the third line has one line break above it<br />
    <br />
    <br />
    <br />
    <br />
    <br />
    the fourth line has two line breaks above it 
     
    My editor (version 6.0) break element is set to:
     editor.BreakElement= "br"
    I have tried changing this to p and div however it makes no diference.  Any ideas how to fix this?
     
    TYIA

    Wind is your friend
  •  09-08-2008, 12:43 AM 43680 in reply to 43679

    Re: Line break problem - to many braks being inserted

    wow no I have real trouble!!!! I just rolled back my editor to version 5 because this problem did not occur as described above and I am getting a client side error saying 'The Licence for this Editor is not valid'  Damn what have i done, how can I undo this??????
     
    NOTE - I wiould like to run 6.0 so my questions in the above post would still like to be addressed.
     
    FYI as a comparison between different versions behaviours and I guess to enforce the page that renders the editor shouldnt be contributing to my issue.  I enter the same text:
     
    the first line
    the second line immediatly after the first

    the third line has one line break above it


    the fourth line has two line breaks above it
     
    and then click the HTML button it shows:
     
    the first line<br>the second line immediatly after the first<br><br>the third line has one line break above it<br><br><br>the fourth line has two line breaks above it

    Now I submit the text and it works perfectly as it should:

    the first line
    the second line immediatly after the first

    the third line has one line break above it


    the fourth line has two line breaks above it

    I should have never tried to run version 6.  The page I am talking about has four version of the editor therefore i am getting four client side 'The Licence for this Editor is not valid' errors...........Please help. 
     
     

    Wind is your friend
  •  09-08-2008, 12:38 PM 43717 in reply to 43680

    Re: Line break problem - to many braks being inserted

  •  09-08-2008, 6:24 PM 43742 in reply to 43717

    Re: Line break problem - to many braks being inserted

    Hi Adam
     
    Yes mate it works as expected there.  Any ideas what i can try??
     
    In addition to my break problem why cant I roll back to version 5 without getting the 'The Licence for this Editor is not valid' error?  I need to get rid of this.  End users are getting frustrated.  As I said there is four instances of the editor on the page so they are getting this error four times before the page loads.  please help???
     
     
    Please note: In relation to the break problem the same page which runs fine in version 5 is doing this in version 6, logic tells me it cant be my code.  It run fine for some time until I changed to 6.  Anyhow here is the code which renders the editor:
     
    <%     content = ""
        if updateAllowed = true then  
              if trim(displayMemo(getHRA(8))) <> "" then
              if updateAllowed = true then content = trim(displayMemo(getHRA(8)))  end if
           end if
           Set editor = New CuteEditor
           editor.ID = "evaluateRisk"
           editor.ThemeType = "OfficeXP"
           editor.text = content
           editor.FilesPath = "../CuteEditor_Files/CuteEditor_Files"
           editor.ImageGalleryPath = "/Uploads"
           editor.MaxImageSize = 50
           editor.BreakElement= "br"
           editor.ShowHtmlMode = true
           editor.ShowPreviewMode = false
           'editor.AutoConfigure = "Minimal"
           editor.UseNetSpell = true
           editor.showPreviewmode = false
           editor.TemplateItemList= "netspell,Bold,Italic,Underline,justifyLeft,justifyCenter,justifyRight,justifyFull,justifyNone,InsertOrderedList,InsertunOrderedList,indent,outdent,removeFormat,ucase,lcase,cut,copy,paste,pastText,pasteword,print,find,delete,undo,redo,insertDate,insertTime,help,linebreak,FontName,FontSize,forecolor,backColor,"
           editor.Width = 620
           editor.Height = 240
           editor.Draw() %> 
           <div align="center"><bR><input type="submit" class="inputbuttonnNavy" title="Clicking this button will update all areas on this page except for the 'Accept/Update Risk' area at the foot of the page." value="Submit / Update Details"></div>
    <%     else
                if foundHRA = true then %><% if trim(getHRA(8)) <> "" then %> <%= trim(displayMemo(getHRA(8))) %> <% else %> <div align="center"><i>No 'EVALUATE RISK' information found in the system.</i></div><br> <% end if %> <% else %> <div align="center"><i>No 'EVALUATE RISK' information found in the system.</i></div><br> <% end if %>
    <%     end if %>

    Wind is your friend
  •  09-08-2008, 8:16 PM 43744 in reply to 43742

    Re: Line break problem - to many braks being inserted

    >>Yes mate it works as expected there.  Any ideas what i can try??
     
    Please download the control again (version 6.1). The download link is same as version 6.0.
     
     
    >>In addition to my break problem why cant I roll back to version 5 without getting the 'The Licence for this Editor is not valid' error?  I need to get rid of this.  End users are getting frustrated.  As I said there is four instances of the editor on the page so they are getting this error four times before the page loads.  please help???
     
    If you want to roll back to version 5.x, please use the license file for the version 5.x.
     
    Hope it helps.
     
    Keep me posted
     
     

    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

  •  09-08-2008, 9:35 PM 43745 in reply to 43744

    Re: Line break problem - to many braks being inserted

    Thank you I am downloading it now.  How would I identify a version?
     
    Is this allowed? Inside my application on my dev machine I currently have two folders:
     
    CuteEditor_Files_version_5
    CuteEditor_Files
     
    I am just renaming what ever version I wish to use for testing.  The one named 'CuteEditor_Files' above holds version 6.  What i would like to do now after downloading version 6.1 is have three folders:
     
    CuteEditor_Files_version_5
    CuteEditor_Files_version_6
    CuteEditor_Files_version_6.1
     
    of course I would rename the version I am testing at the time to 'CuteEditor_Files'
     
    When you say:
     
    'If you want to roll back to version 5.x, please use the license file for the version 5.x.'
     
    how do I do this?  if I have the three dir's above do I need to be swapping files.  Im a little confused about that. 
     
    TYIA 

    Wind is your friend
View as RSS news feed in XML