CloneSet173


Previous CloneSetNext CloneSetBack to Main Report
Clone
Mass
Clones in
CloneSet
Parameter
Count
Clone
Similarity
Syntax Category
[Sequence Length]
11250.956statement_sequence[2]
Clone AbstractionParameter Bindings
Clone Instance
(Click to see clone)
Line CountSource Line
Source File
112120
plugins/content/emailcloak.php
211138
plugins/content/emailcloak.php
Clone Instance
1
Line Count
12
Source Line
120
Source File
plugins/content/emailcloak.php

        /*
         * Search for derivatives of link code <a href="mailto:[email protected]?
         * subject=Text">[email protected]</a>
         */
        $pattern=  plgContentEmailCloak_searchPattern($searchEmailLink, $searchEmail);
        while (preg_match($pattern, $text, $regs, PREG_OFFSET_CAPTURE)) {
                $mail=  $regs[1][0]
                        .             $regs[2][0];
                $mailText=  $regs[3][0];
                // Needed for handling of Body parameter
                $mail=  str_replace('&amp;', '&', $mail);
                // Check to see if mail text is different from mail addy
                $replacement=  JHtml::_('email.cloak', $mail, $mode, $mailText);

                // Replace the found address with the js cloaked email
                $text=  substr_replace($text, $replacement, $regs[0][1], strlen($regs[0][0]));
              }


Clone Instance
2
Line Count
11
Source Line
138
Source File
plugins/content/emailcloak.php

        /*
         * Search for derivatives of link code <a href="mailto:[email protected]?
         * subject=Text">anytext</a>
         */
        $pattern=  plgContentEmailCloak_searchPattern($searchEmailLink, $searchText);
        while (preg_match($pattern, $text, $regs, PREG_OFFSET_CAPTURE)) {
                $mail=  $regs[1][0]
                        .             $regs[2][0];
                $mailText=  $regs[3][0];
                // Needed for handling of Body parameter
                $mail=  str_replace('&amp;', '&', $mail);
                $replacement=  JHtml::_('email.cloak', $mail, $mode, $mailText, 0);

                // Replace the found address with the js cloaked email
                $text=  substr_replace($text, $replacement, $regs[0][1], strlen($regs[0][0]));
              }


Clone AbstractionParameter Count: 5Parameter Bindings

/*
         * Search for derivatives of link code <a href="mailto:[email protected]?
         * subject=Text">anytext</a>
         */
/*
         * Search for derivatives of link code <a href="mailto:[email protected]?
         * subject=Text">[email protected]</a>
         */
$pattern=plgContentEmailCloak_searchPattern($searchEmailLink, [[#variable4e957d60]]);
while (preg_match($pattern,$text,$regs,PREG_OFFSET_CAPTURE)) {
  $mail=$regs[1][0]
        . $regs[2][0];
  $mailText=$regs[3][0];
  // Needed for handling of Body parameter
  $mail=str_replace('&amp;','&',$mail);
  // Check to see if mail text is different from mail addy
  $replacement=JHtml::_( [[#variable4e957cc0]], [[#variable4e957c80]], [[#variable5233bf20]], [[#variable226dc7c0]]);
  // Replace the found address with the js cloaked email
  $text=substr_replace($text,$replacement,$regs[0][1],strlen($regs[0][0]));
}
 

CloneAbstraction
Parameter Bindings
Parameter
Index
Clone
Instance
Parameter
Name
Value
11[[#4e957d60]]
$searchText 
12[[#4e957d60]]
$searchEmail 
21[[#4e957cc0]]
'email.cloak',$mail 
22[[#4e957cc0]]
'email.cloak' 
31[[#4e957c80]]
$mode 
32[[#4e957c80]]
$mail 
41[[#5233bf20]]
$mailText 
42[[#5233bf20]]
$mode 
51[[#226dc7c0]]
0 
52[[#226dc7c0]]
$mailText