小编Joh*_*Doe的帖子

如果在输出中使用"+"或"+",有什么区别?

Div1.InnerHtml = (someString);
Run Code Online (Sandbox Code Playgroud)

航班吗

Div1.InnerHtml += (someString);
Run Code Online (Sandbox Code Playgroud)


我注意到他们都做了同样的事情,但是我有没有真正的区别+
另外.. InnerText&之间有什么区别InnerHtml

c# string text

3
推荐指数
1
解决办法
106
查看次数

List <string>仅显示最后一项

试图从一串零件名称中制作一个列表.它正在跳过显示除列表中最后一个名称之外的所有名称.为什么这样做?有没有更好的方法呢?

我的代码背后

    List<string> Ta1PartNumbers = ta1input.Split('\n').ToList<string>(); //Trying to split at the line break.. Would this be the proper way to do it?

    foreach (string Tpartnumber in TramPartNumbers)
    {
        Div1.InnerText = (Tpartnumber);
    }
Run Code Online (Sandbox Code Playgroud)


列表是这样的:
Part_numbers
1017foo
1121bar
等.

c#

2
推荐指数
1
解决办法
645
查看次数

e.nodeName是未定义的Jquery

我绞尽脑汁经历它,查看示例并且不明白为什么firebug会抛出"e.nodeName is undefined"错误.

它可能是一个愚蠢的小支架不合适或需要第二双眼睛看到的东西..

我只是为一些输入做了一个简单的小ajax帖子,但这是我的第一篇文章,我关于由于我到目前为止遇到了多少错误而把头发拉了下来...
http://jsfiddle.net/JohnnyDoe/aQYra/

我的剧本

<script type="text/javascript">
    $(document).ready(function () {
        $('.hexen').after('<div class="ui-state-default ui-corner-all ui-icon-disk ui-icon saveButton" onClick="save();" title="Save" style="float:left; height:20px;" onclick="save()"></div><br />') // ui icon
    .keypress(function () {
        $(this).next('.saveButton').show(); //appends ui icon
    });

        $('.saveButton').hide().click(function () {
            $(this).hide(); // removes ui icon on click
        });

        $('.ui-state-default').hover(

    function () {
        $(this).addClass('ui-state-hover');
    }, function () {
        $(this).removeClass('ui-state-hover');
    } //ui icon hover
    );
    });

    function save(value) {
        $('.hexen').each(function () {
            var id = null;
        });
        if ($(this).val() !== '') {
            id = …
Run Code Online (Sandbox Code Playgroud)

ajax jquery post

1
推荐指数
2
解决办法
1万
查看次数

标签 统计

c# ×2

ajax ×1

jquery ×1

post ×1

string ×1

text ×1