1
|
|
|
<?php |
2
|
|
|
namespace SEOstats\Config; |
3
|
|
|
|
4
|
|
|
/** |
5
|
|
|
* Configuration constants for the SEOstats library. |
6
|
|
|
* |
7
|
|
|
* @package SEOstats |
8
|
|
|
* @author Stephan Schmitz <[email protected]> |
9
|
|
|
* @copyright Copyright (c) 2010 - present Stephan Schmitz |
10
|
|
|
* @license http://eyecatchup.mit-license.org/ MIT License |
11
|
|
|
* @updated 2013/08/17 |
12
|
|
|
*/ |
13
|
|
|
|
14
|
|
|
/** |
15
|
|
|
* Default client settings |
16
|
|
|
* @package SEOstats |
17
|
|
|
*/ |
18
|
|
|
interface DefaultSettings |
19
|
|
|
{ |
20
|
|
|
// The default value returned by all SEOstats methods if no result available. |
21
|
|
|
// Can be either of type String, Int, Bool or NULL. |
22
|
|
|
const DEFAULT_RETURN_NO_DATA = 'n.a.'; |
23
|
|
|
|
24
|
|
|
// The default top level domain ending to use to query Google. |
25
|
|
|
const GOOGLE_TLD = 'com'; |
26
|
|
|
|
27
|
|
|
// The HTTP header value for the 'Accept-Language' attribute. |
28
|
|
|
// |
29
|
|
|
// Note: Google search results, doesn't matter which tld you request, vary depending on |
30
|
|
|
// the value sent for the HTTP header attribute 'Accept-Language'! Eg: I am from Germany. |
31
|
|
|
// Even if I use the "ncr" (no country redirect) request parameter, all search results |
32
|
|
|
// that I get in response to a query on google.com will be localized to German, because |
33
|
|
|
// my browser sends an Accept-Language header value of 'de-de,de;q=0.8,en-us;q=0.5,en;q=0.3'. |
34
|
|
|
// On the other side, if I change my browser settings to send a value of 'en-us;q=0.8,en;q=0.3', |
35
|
|
|
// all my searches on google.de (the german Google page) will be localized English. |
36
|
|
|
// Thus, if you want to get the same results that you see when you search Google from |
37
|
|
|
// your browser, you must not only set the @const GOOGLE_TLD to your country specifiy TLD, |
38
|
|
|
// but also set the value below to be the same used by your browser! |
39
|
|
|
const HTTP_HEADER_ACCEPT_LANGUAGE = 'en-us;q=0.8,en;q=0.3'; |
40
|
|
|
|
41
|
|
|
// For curl instances: Whether to allow Google to store cookies, or not. |
42
|
|
|
const ALLOW_GOOGLE_COOKIES = 0; |
43
|
|
|
|
44
|
|
|
// Choose the local SEMRush database to use. |
45
|
|
|
// Valid values are: |
46
|
|
|
// au - Google.com.au (Australia) |
47
|
|
|
// br - Google.com.br (Brazil) |
48
|
|
|
// ca - Google.ca (Canada) |
49
|
|
|
// de - Google.de (Germany) |
50
|
|
|
// es - Google.es (Spain) |
51
|
|
|
// fr - Google.fr (France) |
52
|
|
|
// it - Google.it (Italy) |
53
|
|
|
// ru - Google.ru (Russia) |
54
|
|
|
// uk - Google.co.uk (United Kingdom) |
55
|
|
|
// us - Google.com (United States) |
56
|
|
|
const SEMRUSH_DB = 'us'; |
57
|
|
|
|
58
|
|
|
// Choose the local SISTRIX database to use. |
59
|
|
|
// Valid values are: |
60
|
|
|
// de – Germany |
61
|
|
|
// at – Austria |
62
|
|
|
// ch – Switzerland |
63
|
|
|
// us – USA |
64
|
|
|
// uk – England |
65
|
|
|
// es – Spain |
66
|
|
|
// fr – France |
67
|
|
|
// it – Italy |
68
|
|
|
const SISTRIX_DB = 'de'; |
69
|
|
|
|
70
|
|
|
// Enter proxy to use with curl |
71
|
|
|
// leave empty to disable proxy |
72
|
|
|
// can be overwritten by dynamic configuration |
73
|
|
|
const CURLOPT_PROXY = ''; |
74
|
|
|
|
75
|
|
|
// Enter proxy username and password (seperated by :) if necessary |
76
|
|
|
// leave empty to disable |
77
|
|
|
// can be overwritten by dynamic configuration |
78
|
|
|
const CURLOPT_PROXYUSERPWD = ''; |
79
|
|
|
|
80
|
|
|
// Enter own useragent |
81
|
|
|
// leave empty to use default |
82
|
|
|
// can be overwritten by dynamic configuration |
83
|
|
|
const UA = ''; |
84
|
|
|
} |
85
|
|
|
|