ContentLink::prepareLinkBuilding()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 3
Bugs 0 Features 0
Metric Value
c 3
b 0
f 0
dl 0
loc 5
rs 9.4285
cc 1
eloc 3
nc 1
nop 4
1
<?php
2
/**
3
 * Content Link preparation
4
 *
5
 * @author  Tim Lochmüller
6
 */
7
8
namespace HDNET\Tagger;
9
10
use TYPO3\CMS\Backend\Utility\BackendUtility;
11
12
/**
13
 * Prepare the content Link
14
 */
15
class ContentLink implements LinkBuilderCallbackInterface
16
{
17
18
    /**
19
     * Prepare the link building array
20
     *
21
     * @param string $table
22
     * @param int    $uid
23
     * @param array  $configuration
24
     * @param array  $markers
25
     */
26
    public function prepareLinkBuilding($table, $uid, &$configuration, &$markers)
27
    {
28
        $row = BackendUtility::getRecord($table, $uid);
29
        $markers['###PAGE_UID###'] = $row['pid'] . '#' . $uid;
30
    }
31
}
32