|
1
|
|
|
<?php |
|
2
|
|
|
|
|
3
|
|
|
/*************************************************************** |
|
4
|
|
|
* Copyright notice |
|
5
|
|
|
* |
|
6
|
|
|
* (c) 2017 AOE GmbH <[email protected]> |
|
7
|
|
|
* |
|
8
|
|
|
* All rights reserved |
|
9
|
|
|
* |
|
10
|
|
|
* This script is part of the TYPO3 project. The TYPO3 project is |
|
11
|
|
|
* free software; you can redistribute it and/or modify |
|
12
|
|
|
* it under the terms of the GNU General Public License as published by |
|
13
|
|
|
* the Free Software Foundation; either version 3 of the License, or |
|
14
|
|
|
* (at your option) any later version. |
|
15
|
|
|
* |
|
16
|
|
|
* The GNU General Public License can be found at |
|
17
|
|
|
* http://www.gnu.org/copyleft/gpl.html. |
|
18
|
|
|
* |
|
19
|
|
|
* This script is distributed in the hope that it will be useful, |
|
20
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
21
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
22
|
|
|
* GNU General Public License for more details. |
|
23
|
|
|
* |
|
24
|
|
|
* This copyright notice MUST APPEAR in all copies of the script! |
|
25
|
|
|
***************************************************************/ |
|
26
|
|
|
|
|
27
|
|
|
/** |
|
28
|
|
|
* Class Tx_Asdis_Backend_Utility_ScraperUtility |
|
29
|
|
|
*/ |
|
30
|
|
|
class Tx_Asdis_Backend_Utility_ScraperUtility { |
|
31
|
|
|
|
|
32
|
|
|
/** |
|
33
|
|
|
* Register Scraper |
|
34
|
|
|
* |
|
35
|
|
|
* @param $extensionPath string |
|
36
|
|
|
* |
|
37
|
|
|
* @return void |
|
38
|
|
|
*/ |
|
39
|
|
|
public static function registerScrapers($extensionPath) { |
|
40
|
|
|
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['asdis']['scrapers'][] = array( |
|
41
|
|
|
'key' => 'cssUrl', |
|
42
|
|
|
'class' => 'Tx_Asdis_Content_Scraper_Css_Url', |
|
43
|
|
|
'file' => $extensionPath . 'Classes/Content/Scraper/Css/Url.php' |
|
44
|
|
|
); |
|
45
|
|
|
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['asdis']['scrapers'][] = array( |
|
46
|
|
|
'key' => 'htmlCssFile', |
|
47
|
|
|
'class' => 'Tx_Asdis_Content_Scraper_Html_CssFile', |
|
48
|
|
|
'file' => $extensionPath . 'Classes/Content/Scraper/Html/CssFile.php' |
|
49
|
|
|
); |
|
50
|
|
|
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['asdis']['scrapers'][] = array( |
|
51
|
|
|
'key' => 'htmlAppleTouchIcon', |
|
52
|
|
|
'class' => 'Tx_Asdis_Content_Scraper_Html_AppleTouchIcon', |
|
53
|
|
|
'file' => $extensionPath . 'Classes/Content/Scraper/Html/AppleTouchIcon.php' |
|
54
|
|
|
); |
|
55
|
|
|
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['asdis']['scrapers'][] = array( |
|
56
|
|
|
'key' => 'htmlCssAttribute', |
|
57
|
|
|
'class' => 'Tx_Asdis_Content_Scraper_Html_CssAttribute', |
|
58
|
|
|
'file' => $extensionPath . 'Classes/Content/Scraper/Html/CssAttribute.php' |
|
59
|
|
|
); |
|
60
|
|
|
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['asdis']['scrapers'][] = array( |
|
61
|
|
|
'key' => 'htmlCssInline', |
|
62
|
|
|
'class' => 'Tx_Asdis_Content_Scraper_Html_CssInline', |
|
63
|
|
|
'file' => $extensionPath . 'Classes/Content/Scraper/Html/CssInline.php' |
|
64
|
|
|
); |
|
65
|
|
|
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['asdis']['scrapers'][] = array( |
|
66
|
|
|
'key' => 'htmlEmbed', |
|
67
|
|
|
'class' => 'Tx_Asdis_Content_Scraper_Html_Embed', |
|
68
|
|
|
'file' => $extensionPath . 'Classes/Content/Scraper/Html/Embed.php' |
|
69
|
|
|
); |
|
70
|
|
|
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['asdis']['scrapers'][] = array( |
|
71
|
|
|
'key' => 'htmlFavicon', |
|
72
|
|
|
'class' => 'Tx_Asdis_Content_Scraper_Html_Favicon', |
|
73
|
|
|
'file' => $extensionPath . 'Classes/Content/Scraper/Html/Favicon.php' |
|
74
|
|
|
); |
|
75
|
|
|
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['asdis']['scrapers'][] = array( |
|
76
|
|
|
'key' => 'htmlImage', |
|
77
|
|
|
'class' => 'Tx_Asdis_Content_Scraper_Html_Image', |
|
78
|
|
|
'file' => $extensionPath . 'Classes/Content/Scraper/Html/Image.php' |
|
79
|
|
|
); |
|
80
|
|
|
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['asdis']['scrapers'][] = array( |
|
81
|
|
|
'key' => 'htmlInputImage', |
|
82
|
|
|
'class' => 'Tx_Asdis_Content_Scraper_Html_InputImage', |
|
83
|
|
|
'file' => $extensionPath . 'Classes/Content/Scraper/Html/InputImage.php' |
|
84
|
|
|
); |
|
85
|
|
|
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['asdis']['scrapers'][] = array( |
|
86
|
|
|
'key' => 'htmlOpenGraphImage', |
|
87
|
|
|
'class' => 'Tx_Asdis_Content_Scraper_Html_OpenGraphImage', |
|
88
|
|
|
'file' => $extensionPath . 'Classes/Content/Scraper/Html/OpenGraphImage.php' |
|
89
|
|
|
); |
|
90
|
|
|
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['asdis']['scrapers'][] = array( |
|
91
|
|
|
'key' => 'htmlScript', |
|
92
|
|
|
'class' => 'Tx_Asdis_Content_Scraper_Html_Script', |
|
93
|
|
|
'file' => $extensionPath . 'Classes/Content/Scraper/Html/Script.php' |
|
94
|
|
|
); |
|
95
|
|
|
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['asdis']['scrapers'][] = array( |
|
96
|
|
|
'key' => 'htmlCss3Image', |
|
97
|
|
|
'class' => 'Tx_Asdis_Content_Scraper_Html_Css3Image', |
|
98
|
|
|
'file' => $extensionPath . 'Classes/Content/Scraper/Html/Css3Image.php' |
|
99
|
|
|
); |
|
100
|
|
|
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['asdis']['scrapers'][] = array( |
|
101
|
|
|
'key' => 'htmlMetaMsApplication', |
|
102
|
|
|
'class' => 'Tx_Asdis_Content_Scraper_Html_MetaMsApplication', |
|
103
|
|
|
'file' => $extensionPath . 'Classes/Content/Scraper/Html/MetaMsApplication.php' |
|
104
|
|
|
); |
|
105
|
|
|
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['asdis']['scrapers'][] = array( |
|
106
|
|
|
'key' => 'htmlDataSrc', |
|
107
|
|
|
'class' => 'Tx_Asdis_Content_Scraper_Html_DataSrc', |
|
108
|
|
|
'file' => $extensionPath . 'Classes/Content/Scraper/Html/DataSrc.php' |
|
109
|
|
|
); |
|
110
|
|
|
} |
|
111
|
|
|
} |