nindex.php
7.74 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
<?php
/**
* Pagina inicial do i3Geo
* Voce pode utilizar o parametro customDir para indicar a pasta onde
* as interfaces de mapa estao. Nesse caso, os links utilizarao esse parametro
* Exemplo: localhost/i3geo/init/index.php?customDir=minhaPasta
*
* minhaPasta deve estar dentor da pasta i3geo.
*
* Se dentro da pasta $customDir existir um arquivo chamado index.php sera feito o include
* na pagina.
*/
/**
* Cria as pastas temporarias que o i3Geo precisa, caso nao existam
*/
include (dirname ( __FILE__ ) . "/../ms_configura.php");
if (! empty ( $_GET ["customDir"] )) {
$customDir = strip_tags ( $_GET ["customDir"] );
} else if (empty ( $customDir )) {
$customDir = "interface";
}
if (! file_exists ( $dir_tmp )) {
@mkdir ( $dir_tmp, 0777 );
}
if (file_exists ( $dir_tmp )) {
@mkdir ( $dir_tmp . "/comum", 0777 );
@mkdir ( $dir_tmp . "/saiku-datasources", 0777 );
chmod ( $dir_tmp . "/saiku-datasources", 0777 );
@mkdir ( $dir_tmp . "/cache", 0777 );
chmod ( $dir_tmp . "/cache", 0777 );
@mkdir ( $dir_tmp . "/cache/googlemaps", 0777 );
chmod ( $dir_tmp . "/cache/googlemaps", 0777 );
}
if (file_exists ( $locaplic . "/" . $customDir . "/index.php" )) {
include ($locaplic . "/" . $customDir . "/index.php");
}
error_reporting ( 0 );
define ( "ONDEI3GEO", ".." );
?>
<!DOCTYPE html>
<html lang="pt-br">
<head>
<?php include "head.php"; ?>
<style>
#brasil {
background-image: url("../imagens/sprite.png");
background-position: 0 -600px;
background-repeat: no-repeat;
cursor: pointer;
height: 13px;
width: 22px;
}
#uk {
background-image: url("../imagens/sprite.png");
background-position: 0 -625px;
background-repeat: no-repeat;
cursor: pointer;
height: 13px;
width: 22px;
}
#espanhol {
background-image: url("../imagens/sprite.png");
background-position: 0 -1400px;
background-repeat: no-repeat;
cursor: pointer;
height: 13px;
width: 22px;
}
#bandeiras img {
margin-left: 7px;
}
#bandeiras {
width: 100px;
text-align: left;
}
</style>
<script src='../classesjs/compactados/dicionario_compacto.js'></script>
<script src='../classesjs/compactados/classe_util_compacto.js'></script>
<script src='../classesjs/compactados/classe_idioma_compacto.js'></script>
<script src='../classesjs/compactados/mustache.js'></script>
<script src='dicionario.js'></script>
</head>
<body style="background-color: #eeeeee; padding-top: 80px;">
<nav class="navbar navbar-fixed-top navbar-inverse">
<div class="container">
<div class="navbar-header">
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar" aria-expanded="false" aria-controls="navbar">
<span class="sr-only"></span> <span class="icon-bar"></span> <span class="icon-bar"></span> <span class="icon-bar"></span>
</button>
<a class="navbar-brand" href="#"><?php echo $mensagemInicia;?></a>
</div>
<div id="navbar" class="collapse navbar-collapse">
<ul class="nav navbar-nav">
<li><a href="#"><div class="fa" id="bandeiras"></div></a></li>
</ul>
<!-- template para permitir a traducao -->
<div id="menuTpl" >
<ul class="nav navbar-nav">
<li><a href="#map-o">{{{mapas}}}</a></li>
</ul>
<ul class="nav navbar-nav">
<li><a href="#download">Download</a></li>
</ul>
<ul class="nav navbar-nav">
<li><a href="#check">{{{admin}}}</a></li>
</ul>
<ul class="nav navbar-nav">
<li><a href="#book">{{{docs}}}</a></li>
</ul>
<ul class="nav navbar-nav">
<li><a href="#group">{{{comunidade}}}</a></li>
</ul>
<ul class="nav navbar-nav pull-right">
<li><a href="#"><i class="fa fa-home fa-2x"></i></i></a></li>
</ul>
</div>
</div>
</div>
</nav>
<div class="container">
<div class="row" >
<div class="col-sm-12" id="mensagemLogin">
</div>
<div class="col-sm-12">
<div class="jumbotron" id="jumbotron">
</div>
</div>
<!-- Template para criacao dos quadros ver index.js -->
<div id="botoesTpl">
<div id="{{{fa}}}" class="col-sm-12" style="width:260px;min-width:260px;max-width:260px;">
<div class="panel panel-default">
<div class="panel-body" style="height: 250px;">
<div class="thumbnail" style="height:90px;">
<img class="img-rounded" style="height: 100%; width: 100%" src="imagens/{{{img}}}" />
</div>
<h4>{{{titulo}}}</h4>
<div style="overflow:auto;height:200px;">
<p>{{{subtitulo}}}</p>
</div>
</div>
<div class="panel-footer text-right" style="border:0px;background-color:white;">
<p>
<a class="btn btn-primary btn-raised" href="{{{href}}}" role="button" target="_blank" >
{{{abrir}}} <i class="fa fa-{{{fa}}}" aria-hidden="true" ></i>
</a>
</p>
</div>
</div>
</div>
</div>
<div class="col-sm-12 hidden" id="tt" style="width:260px;">
<div class="panel panel-default" >
<div class="panel-body">
<a class="twitter-timeline" href="https://twitter.com/i3geo" data-widget-id="288061915689787392" height="300">Tweets @i3Geo</a>
</div>
</div>
</div>
<div class="col-sm-12 hidden" style="width:260px;">
<div class="panel panel-default" >
<div class="panel-body">
<a class="twitter-timeline" href="https://twitter.com/hashtag/i3geo" data-widget-id="643417277208133633" height="300">i3geo Tweets</a>
</div>
</div>
</div>
</div>
<hr>
<footer class="text-center" >
<div class="row hidden" >
<div class="col-sm-6"
<a rel="license" href="http://creativecommons.org/licenses/GPL/2.0/legalcode.pt" target="_blank"><img alt="Licença Creative Commons" style="border-width: 0" src="https://i.creativecommons.org/l/GPL/2.0/88x62.png" /></a><br />O i3Geo está licenciado com uma Licença <a
rel="license" href="http://creativecommons.org/licenses/GPL/2.0/legalcode.pt" target="_blank">Creative Commons - Licença Pública Geral GNU ("GNU General Public License")</a>
</div>
<div class="col-sm-6">
<script type='text/javascript' src='https://www.openhub.net/p/i3geo/widgets/project_users?format=js&style=blue'></script>
</div>
</div>
</footer>
</div>
<?php
echo "<script>";
include "index.js";
echo "</script>";
include "body.php";
?>
<script>
$(document).ready(function(){
var template = '<div class="col-sm-12" style="width:260px;min-width:260px;max-width:260px;"><div class="panel panel-default"><div class="panel-body" style="height: 250px;"><div class="thumbnail" style="height:90px;"><img class="img-rounded" style="height: 100%; width: 100%" src="imagens/{{{img}}}" /></div><h4>{{{titulo}}}</h4><div style="overflow:auto;height:200px;"><p>{{{subtitulo}}}</p></div></div><div class="panel-footer text-right" style="border:0px;background-color:white;"><p><a class="btn btn-primary btn-raised" href="{{{href}}}" role="button" target="_blank" >Abrir <i class="fa fa-{{{fa}}}" aria-hidden="true" ></i></a></p></div></div></div>';
<?php
if ($i3geomaster [0] ["usuario"] == "admin" && $i3geomaster [0] ["senha"] == "admin") {
echo "var men = '<div class=\'alert alert-danger\' >' + $" . "trad(19,g_traducao_init) + '</div>';";
} else {
echo "var men = '';";
}
?>
mostraBotoesBT(men);
$('.hidden').removeClass('hidden');
//carrega o TT
window.twttr = (function(d, s, id) {
var js, fjs = d.getElementsByTagName(s)[0],
t = window.twttr || {};
if (d.getElementById(id)) return t;
js = d.createElement(s);
js.id = id;
js.src = "https://platform.twitter.com/widgets.js";
fjs.parentNode.insertBefore(js, fjs);
t._e = [];
t.ready = function(f) {
t._e.push(f);
};
return t;
}(document, "script", "twitter-wjs"));
});
</script>
</body>
</html>