【问题标题】:Select the current date and other date in the phpunit selenium?在phpunit selenium中选择当前日期和其他日期?
【发布时间】:2014-08-20 10:05:05
【问题描述】:

我在文本框中使用 jquery 制作日期格式。 并想知道如何在输入框中选择日期。

如何在 phpunit selenium 中设置当前日期格式的值?

【问题讨论】:

    标签: selenium-webdriver phpunit


    【解决方案1】:

    尝试使用php的日期功能

     $startDate = date('Y-m-d');
     $endDate = date('Y-m-d', strtotime("+30 days"));
    
     $this->type('name=from_date',$startDate);
     $this->type('name=to_date',$endDate);
    

    【讨论】:

      猜你喜欢
      • 2021-02-28
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2014-03-23
      • 1970-01-01
      • 1970-01-01
      • 2013-12-25
      相关资源
      最近更新 更多