dqm7854 2012-03-30 08:03
浏览 80

从下拉列表中选择值时,值会显示在文本框中

I'll try my level best by using AJAX, but I'm not able to get this to work.

I have 5 select boxes and 5 text boxes, and when I select the first drop down its value is shown in a text box and so on with the other text boxes.

I have been trying this:

ajax: {
        url: 'help/ajax_help.php',
        type: 'GET',
        data: {help: function(){return $(this).attr('id');}},               
      },

Taking the current value of the dropdown, but it is not working.

Please help me.

Thanks and Regards.

  • 写回答

1条回答 默认 最新

  • doubi5127 2012-03-31 03:44
    关注
    ajax: {
            url: 'help/ajax_help.php',
            type: 'GET',
            data: $(this).val(),
          },
    

    Does that work?

    评论

报告相同问题?

悬赏问题

  • ¥15 微信小程序协议怎么写
  • ¥15 c语言怎么用printf(“\b \b”)与getch()实现黑框里写入与删除?
  • ¥20 怎么用dlib库的算法识别小麦病虫害
  • ¥15 华为ensp模拟器中S5700交换机在配置过程中老是反复重启
  • ¥15 java写代码遇到问题,求帮助
  • ¥15 uniapp uview http 如何实现统一的请求异常信息提示?
  • ¥15 有了解d3和topogram.js库的吗?有偿请教
  • ¥100 任意维数的K均值聚类
  • ¥15 stamps做sbas-insar,时序沉降图怎么画
  • ¥15 买了个传感器,根据商家发的代码和步骤使用但是代码报错了不会改,有没有人可以看看