Ledger Nano X - The secure hardware wallet
SHARE
TWEET

Untitled

IDDQD-IDKFA May 20th, 2020 1,162 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.     protected static function cutFromDom($current, $length) {
  2.         $i = 0;
  3.         while($i < $current->childNodes->length) {
  4.             $node = $current->childNodes->item($i);
  5.             if($length > 0) {
  6.                 switch ($node->type) {
  7.                     case XML_TEXT_NODE:
  8.                     case XML_CDATA_SECTION_NODE:
  9.                         $node->textContent = mb_substr($node->textContent, 0, $length);
  10.                         $length -= mb_strlen($node->textContent);
  11.                         break;
  12.                     case XML_ELEMENT_NODE:
  13.                         $length = self::cutFromDom($node, $length);
  14.                         break;
  15.                 }
  16.                 $i++;
  17.             }
  18.             else {
  19.                 $current->removeChild($node);
  20.             }
  21.         }
  22.         return $length;
  23.     }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Top