Skip to content
This repository has been archived by the owner on Nov 1, 2022. It is now read-only.

Commit

Permalink
Fixing diff char being left over
Browse files Browse the repository at this point in the history
  • Loading branch information
pierre-alain-b committed Apr 24, 2022
1 parent f1e5dc2 commit c786132
Showing 1 changed file with 1 addition and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -239,9 +239,8 @@ public static function GetTextFromDom($oDom, $bWrapByFakeHtmlAndBodyDiv = true)
$oWrapHtml->setAttribute($sKey, $sValue);
}

#$oWrapDom = $oDom->createElement('div', '___xxx___');
$rand_str = base64_encode(random_bytes(32));
+ $oWrapDom = $oDom->createElement('div', $rand_str);
$oWrapDom = $oDom->createElement('div', $rand_str);
$oWrapDom->setAttribute('data-x-div-type', 'body');
foreach ($aBodylAttrs as $sKey => $sValue)
{
Expand All @@ -252,7 +251,6 @@ public static function GetTextFromDom($oDom, $bWrapByFakeHtmlAndBodyDiv = true)

$sWrp = $oDom->saveHTML($oWrapHtml);

#$sResult = \str_replace('___xxx___', $sResult, $sWrp);
$sResult = \str_replace($rand_str, $sResult, $sWrp);
}

Expand Down

0 comments on commit c786132

Please sign in to comment.