Contents

Parsedown::blockFencedCodeContinue( $Line,  $Block )

Description

Source

File: bp-help/vendors/parsedown/Parsedown.php

502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
protected function blockFencedCodeContinue($Line, $Block)
{
    if (isset($Block['complete']))
    {
        return;
    }
 
    if (isset($Block['interrupted']))
    {
        $Block['element']['element']['text'] .= str_repeat("\n", $Block['interrupted']);
 
        unset($Block['interrupted']);
    }
 
    if (($len = strspn($Line['text'], $Block['char'])) >= $Block['openerLength']
        and chop(substr($Line['text'], $len), ' ') === ''
    ) {
        $Block['element']['element']['text'] = substr($Block['element']['element']['text'], 1);
 
        $Block['complete'] = true;
 
        return $Block;
    }
 
    $Block['element']['element']['text'] .= "\n" . $Line['body'];
 
    return $Block;
}

Questions?

We're always happy to help with code or other questions you might have! Search our developer docs, contact support, or connect with our sales team.