mardi 29 décembre 2015

DomCrawler Checkbox Checking or Adding new DOM Content

I'm using Symfony2 (and Goutte). I have a page that's old and I need to check a checkbox on the page, but can't find a way to do it. I have scraped the page into a $crawler object and am using different methods from the domcrawler API. Here's the HTML:

<tr>
    <td>
        <input type="checkbox">
        Text Next to Checkbox
    </td>
</tr> 

I've tried so many $crawler-> things, but cannot figure out how to check that checkbox, neither with domcrawler nor goutte. Also, I cannot use $form[]->tick() because this page is terrible in its architecture, and I'm unable to make a $form object.

Any ideas? Thanks!




Aucun commentaire:

Enregistrer un commentaire