{"id":769,"date":"2007-08-12T03:00:00","date_gmt":"2007-08-11T18:00:00","guid":{"rendered":"https:\/\/ecoop.net\/memo\/2007-08-12-3.html"},"modified":"2007-08-12T03:00:00","modified_gmt":"2007-08-11T18:00:00","slug":"2007-08-12-3","status":"publish","type":"post","link":"https:\/\/www.ecoop.net\/memo\/archives\/2007-08-12-3.html","title":{"rendered":"symfony &#8211; sfDomCssSelector \u306e\u30bb\u30ec\u30af\u30bf\u306e\u66f8\u5f0f"},"content":{"rendered":"<p>\n<\/p>\n<blockquote><p>object sfTestBrowser::checkResponseElement(string $selector [, mixed $value [, array $options]])\n<\/p><\/blockquote>\n<p>\u306b\u3082\u4f7f\u308f\u308c\u308b\u3001\n<\/p>\n<blockquote><p>array sfDomCssSelector::getTexts(string $selector) \n<\/p><\/blockquote>\n<p>\u306e\u5f15\u6570\u306e\u6587\u6cd5\u306b\u3064\u3044\u3066\u3001symfony \u306e\u30c9\u30ad\u30e5\u30e1\u30f3\u30c8\u3067\u3042\u307e\u308a\u89e6\u308c\u3089\u308c\u3066\u3044\u306a\u3044\u3088\u3046\u306a\u306e\u3067\u3001\u7c21\u5358\u306b\u307e\u3068\u3081\u3066\u307f\u307e\u3057\u305f\u3002<br \/>\n&nbsp;<br \/>\n\u25a0\u57fa\u672c\u8981\u7d20(DOM Element)\n<\/p>\n<blockquote><p><\u30bf\u30b0\u540d>\n<\/p><\/blockquote>\n<p>\u4f8b: body \u30bf\u30b0\u306e\u4e2d\u8eab(&lt;body>\u301c&lt;\/body>)\u3092\u53d6\u5f97\u3059\u308b\n<\/p>\n<blockquote><p>$cssSelector->getTexts(&#8220;body&#8221;)\n<\/p><\/blockquote>\n<p>&nbsp;<br \/>\n\u25a0\u5c5e\u6027\u6307\u5b9a\u8981\u7d20\n<\/p>\n<blockquote><p><\u30bf\u30b0\u540d>[<\u5c5e\u6027\u540d1>=&#8221;<\u50241>&#8220;][<\u5c5e\u6027\u540d2>=&#8221;<\u50242>&#8220;][&#8230;]\n<\/p><\/blockquote>\n<p>\u4f8b: id \u304c foo \u306e div \u30bf\u30b0\u306e\u4e2d\u8eab(&lt;div id=&#8221;foo&#8221;>\u301c&lt;\/div>)\u3092\u53d6\u5f97\u3059\u308b\n<\/p>\n<blockquote><p>$cssSelector->getTexts(&#8216;div[id=&#8221;foo&#8221;]&#8217;)\n<\/p><\/blockquote>\n<p>&nbsp;<br \/>\n\u25a0\u8981\u7d20\u306e\u968e\u5c64\u69cb\u9020\n<\/p>\n<blockquote><p><\u8981\u7d201> <\u8981\u7d202> <\u8981\u7d203> &#8230;\n<\/p><\/blockquote>\n<p>\u4f8b1: (\u3088\u308a\u6b63\u78ba\u306b)\u30da\u30fc\u30b8\u30bf\u30a4\u30c8\u30eb\u3092\u53d6\u5f97\u3059\u308b\n<\/p>\n<blockquote><p>$cssSelector->getTexts(&#8216;html head title&#8217;)\n<\/p><\/blockquote>\n<p>\u4f8b2: \u30d5\u30a9\u30fc\u30e0\u306e\u6295\u7a3f\u30dc\u30bf\u30f3\u304c\u300c\u9001\u4fe1\u300d\u3068\u3044\u3046\u8868\u793a\u306b\u306a\u3063\u3066\u3044\u308b\u304b\u78ba\u304b\u3081\u308b\n<\/p>\n<blockquote><p>$texts = $cssSelector->getTexts(&#8216;form input[type=&#8221;submit&#8221;][value=&#8221;\u9001\u4fe1&#8221;]&#8217;);<br \/>\nif(count($texts) > 0){<br \/>\n&nbsp;&nbsp;echo &#8220;\u30d5\u30a9\u30fc\u30e0\u4e2d\u306b &lt;input type=&#8221;submit&#8221; value=&#8221;\u9001\u4fe1&#8221;> \u304c\u5b58\u5728\u3057\u307e\u3059\\n&#8221;;<br \/>\n}\n<\/p><\/blockquote>\n<p>\u3061\u306a\u307f\u306b\u3001sfTestBrowser::checkResponseElement() \u306e\u7b2c\u4e8c\u5f15\u6570\u3092\u7701\u7565\u3001\u3042\u308b\u3044\u306f bool \u5024\u306b\u3057\u305f\u5834\u5408\u306f\u3053\u306e\u4f8b\u306e\u3088\u3046\u306b\u5b58\u5728\u306e\u6709\u7121\u3092\u30c6\u30b9\u30c8\u3057\u307e\u3059\u3002<br \/>\n&nbsp;<br \/>\n\u8ffd\u8a18:<br \/>\n(2007-08-30) symfony WiKi \u306b\u3082\u30bb\u30ec\u30af\u30bf\u306e\u66f8\u5f0f\u304c\u66f8\u304b\u308c\u3066\u3044\u307e\u3057\u305f\u3002<br \/>\n<a href=\"http:\/\/trac.symfony-project.com\/trac\/wiki\/LimeFunctionalTestingHints\">lime functional testing hints<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>object sfTestBrowser::checkResponseElement(string $selector [, mixed $value [, array $options]]) \u306b\u3082\u4f7f\u308f\u308c\u308b\u3001 array &hellip; <a href=\"https:\/\/www.ecoop.net\/memo\/archives\/2007-08-12-3.html\" class=\"more-link\">\u7d9a\u304d\u3092\u8aad\u3080 <span class=\"screen-reader-text\">symfony &#8211; sfDomCssSelector \u306e\u30bb\u30ec\u30af\u30bf\u306e\u66f8\u5f0f<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[32],"class_list":["post-769","post","type-post","status-publish","format-standard","hentry","tag-php"],"jetpack_featured_media_url":"","_links":{"self":[{"href":"https:\/\/www.ecoop.net\/memo\/wp-json\/wp\/v2\/posts\/769","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.ecoop.net\/memo\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.ecoop.net\/memo\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.ecoop.net\/memo\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.ecoop.net\/memo\/wp-json\/wp\/v2\/comments?post=769"}],"version-history":[{"count":0,"href":"https:\/\/www.ecoop.net\/memo\/wp-json\/wp\/v2\/posts\/769\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.ecoop.net\/memo\/wp-json\/wp\/v2\/media?parent=769"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.ecoop.net\/memo\/wp-json\/wp\/v2\/categories?post=769"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.ecoop.net\/memo\/wp-json\/wp\/v2\/tags?post=769"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}