Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6531935
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T09:56:18+00:00 2026-05-25T09:56:18+00:00

recently i was working on a tool, where user makes changes on the interface

  • 0

recently i was working on a tool, where user makes changes on the interface and while hitting save, the template gets stored on server.. as an HTML file.. everything was well… i was able to save the file from all the major browsers (i checked on FireFox and Chrome), but when i tried to save the file from internet explorer….

it does not emit file properly.. the HTML is not properly formatted.. because of which the applications crashes…

Below is the proper format when checked from Firefox and Chrome…

    <tr>
                <td colspan="2" align="center">
                    <div class="searchDiv">
                        <span>Leader Board Box: </span><span class="pd2">
                            <textarea rows="5" cols="52" id="txtLeaderBoardAd" style="width:631px;"></textarea></span><br>
                        <br>
                        <span>Site Logo: </span><span style="padding-left: 34px">
                            <input type="text" size="47" id="txtLogoImage" value=""></span><span>Width: </span><span>
                            <input type="text" size="15" id="txtLogoImageWidth" value=""></span><span>Height: </span><span>
                            <input type="text" size="15" id="txtLogoImageHeight" value=""></span><br>
                        <br>
                        <span>Link Url: </span><span style="padding-left: 70px">
                            <input type="text" id="txtLogoLinkUrl" size="100" value=""></span><br>
                        <br>
                    </div>
                </td>
            </tr>


But when tried to save the same format from Internet Explorer... it emit the format like below


<TR sizset="9" sizcache="3">
        <TD colSpan="2" align="middle" nodeindex="1" nodeIndex="1">
            <DIV class="searchDiv">
                <SPAN>Leader Board Box: </SPAN>
                <SPAN class="pd2">
                    <TEXTAREA style="WIDTH: 631px" id="txtLeaderBoardAd" rows="5" cols="52"></TEXTAREA>
                </SPAN>
                <BR>
                    <BR>
                        <SPAN>Site Logo: </SPAN>
                        <SPAN style="PADDING-LEFT: 34px">
                            <INPUT id="txtLogoImage" size="47" type="text">
                        </SPAN>
                        <SPAN>Width: </SPAN>
                        <SPAN>
                            <INPUT id="txtLogoImageWidth" size="15" type="text">
                        </SPAN>
                        <SPAN>Height: </SPAN>
                        <SPAN>
                            <INPUT id="txtLogoImageHeight" size="15" type="text">
                        </SPAN>
                        <BR>
                            <BR>
                                <SPAN>Link Url: </SPAN>
                                <SPAN style="PADDING-LEFT: 70px">
                                    <INPUT id="txtLogoLinkUrl" size="100" type="text">
                                </SPAN>
                                <BR>
                                    <BR>
            </DIV>
        </TD>
    </TR>

i dont understand… it just removes Quotes from all attributes.. and also adds extra attributes as sizset and sizcache… do i need to format for something extra for IE

Please help… i am stuck over here.
*********************THIS IS HOW I AM SAVING FILE**********
i am using Ajax Jquery for saving the file in html Format…

[WebMethod]
    public static string WriteToHTMLFile(string data) 
    {
        using (StreamWriter writer = new StreamWriter(HttpContext.Current.Server.MapPath("/NewsletterTemplate/HTMLPage.htm")))
        {
            writer.WriteLine(data);
            writer.Flush();
        }
        return "Saved Successfully";
    }

and then just calling the above function in Javascript.. like below

$.ajax({ type: "POST", url: "AjaxMethods.aspx/WriteToHTMLFile", contentType: "application/json", data: "{'data':'" + $("#dvGetHTML").html() + "'}", success: function (data) {
                        $("#dvGetHTML").html($("#dvGetHTML").html());
                    }, error: function (data) { alert("Error in Save.. Please contact your administrator !!!" + data.responseText); }
                    });
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T09:56:19+00:00Added an answer on May 25, 2026 at 9:56 am

    ahhhhhh…..

    I see where your going wrong 🙂

    Your yanking the html straight out of the browsers DOM right? and I’m guessing that #dvGetHTML is a div?

    It sounds to me like IE is in some way representing the HTML internally in a different way to the other browsers, and when you yank it it out of your div that’s what your getting.

    By way of an experiment, try using a plain old text area tag, you can edit in that and the formatting tends to obey good old fashioned pre tag rules.

    The bonus is that anything typed in a textarea is returned verbatim as is, as though is was an input field, if you don’t get the strange formatting when you do this it’s likely that the problem is as anticipated.

    If you prove that is your issue, then I’d use a client side editor such as “Tiny MCE” to achive what your trying to do with a div.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I've been a long time user of R and have recently started working with
I had a working WCF published to IIS on my server. Recently I created
recently while working on the dropdownlist, i came accross a strange issue, i am
I was recently working on an application that sent and received messages over Ethernet
I was recently working with a DateTime object, and wrote something like this: DateTime
I was recently working on a windows program that would sometimes become unresponsive when
I recently was working with a subversion project that checked out code not only
I recently started working on a large complex application, and I've just been assigned
I recently started working in Java and was introduced to the wild and crazy
I recently started working at a company with an enormous enterprisey application. At my

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.