Advertisement
Guest User

Untitled

a guest
Apr 28th, 2017
108
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.37 KB | None | 0 0
  1. <?php
  2.  
  3. /**
  4. * Symfony's DomCrawler component has a method called each that is meant to be used with a closure. How do I replace the closure with a * method in the class?
  5. */
  6.  
  7. $installs = $installRows->each(
  8.     function(Crawler $node, $i){
  9.             //Do $node stuff
  10.     }
  11. );
  12. return $installs;
  13.  
  14. $installs = $installRows->each($this->assembleInstallations($node, $i));
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement