在IE中显示逗号(,)的Ajax数组[关闭]

                <div class="grid--cell fl1 lh-lg">
                    <div class="grid--cell fl1 lh-lg">
                        It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and   cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened,   <a href="/help/reopen-questions">visit the help center</a>.

                    </div>
                </div>
            </div>
            <div class="grid--cell mb0 mt8">Closed <span title="2013-01-07 15:32:18Z" class="relativetime">7 years ago</span>.</div>
        </div>
    </aside>

I do not understand as to why I have this issue arising. in Chrome and Firefox my ajax works well and there are so errors, however, when I run the Ajax request in IE the resulting output is the data but with a series of commas (,) at the top of my page.

example:

,
,
,
,
<tr> row1 </tr>
<tr> row2 </tr>
<tr> row3 </tr>
<tr> row4 </tr>

I want the output to be:

    <tr> row1 </tr>
    <tr> row2 </tr>
    <tr> row3 </tr>
    <tr> row4 </tr>

Code: index.php

function indexMostRecent(linkcode) {
            var lines = '';
                $.ajax( {
                type: 'POST',
                url:'http://site.test.co.uk/shortlinks/nextLines.php', 
                data: { 'indexLeft': 1 },
                cache: false,
            }).done( function(jsondata) {

            lines = jsondata; 

            var obj = jQuery.parseJSON( lines );

            $('#leftIndex').append( obj + '<tr id="less"><td> End </td></tr> ' );
            $('#indexLeft').remove();
        });
    };


    $('#indexLeft').click(indexMostRecent);

nextlines.php

<?php
include ('connection.php');
//these are the queries for the index page
    if(isSet($_POST['indexLeft'])){

            $mostRec = "SELECT * FROM shortlink_analytics ORDER BY hitTime DESC LIMIT 11, 999999";

            $array=array();

            $loadRec = mysql_query($mostRec);

            while($row = mysql_fetch_array($loadRec))
            {
                $array[] = '<tr><td class="overflow"><a href = "info.php?link='. $row['shortlink'] .'">hud.ac/' . $row['shortlink'] . '</a> - ' . $row['hitTime'] . '</td></tr>';
            } 

            echo json_encode($array);

        }

?>

what is causing this? How would I go about solving it? Might it have something to do with the PHP that is getting called in during the AJAX request?

</div>
var obj = jQuery.parseJSON( lines );

this will produce an array.

... .append( obj + '<tr ...

this will convert the array to string that looks very much like this: '...</tr>,<tr ...' before appending your new row.

If you want to concatenate the elements of the string client-side (why not do it server-side?), you can use the array method join:

... .append( obj.join('') + '<tr ...