├── README.md └── loja-fim-apos-exercicios ├── .DS_Store ├── adiciona-produto.php ├── altera-produto.php ├── banco-categoria.php ├── banco-produto.php ├── cabecalho.php ├── conecta.php ├── css ├── bootstrap-theme.css ├── bootstrap-theme.min.css ├── bootstrap.css ├── bootstrap.min.css └── loja.css ├── fonts ├── glyphicons-halflings-regular.eot ├── glyphicons-halflings-regular.svg ├── glyphicons-halflings-regular.ttf └── glyphicons-halflings-regular.woff ├── index.php ├── js ├── bootstrap.js └── bootstrap.min.js ├── produto-altera-formulario.php ├── produto-formulario.php ├── produto-lista.php ├── remove-produto.php └── rodape.php /README.md: -------------------------------------------------------------------------------- 1 | PHP, Mysql e Fundamentos da Web 2 | =============================== 3 | 4 | Alura: http://www.alura.com.br 5 | 6 | Curso: http://www.alura.com.br/cursos-online-introducao/php-mysql-e-fundamentos-da-web 7 | -------------------------------------------------------------------------------- /loja-fim-apos-exercicios/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alura-cursos/php-mysql-e-fundamentos-da-web/099c04caa78ca1a48e507d30eef04239d2da2211/loja-fim-apos-exercicios/.DS_Store -------------------------------------------------------------------------------- /loja-fim-apos-exercicios/adiciona-produto.php: -------------------------------------------------------------------------------- 1 | 16 |

O produto , foi adicionado.

17 | 20 |

O produto não foi adicionado:

21 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /loja-fim-apos-exercicios/altera-produto.php: -------------------------------------------------------------------------------- 1 | 17 |

O produto , foi alterado.

18 | 21 |

O produto não foi alterado:

22 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /loja-fim-apos-exercicios/banco-categoria.php: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Minha Loja 5 | 6 | 7 | 8 | 9 | 10 | 24 | 25 | 26 |
27 |
28 | -------------------------------------------------------------------------------- /loja-fim-apos-exercicios/conecta.php: -------------------------------------------------------------------------------- 1 | li > a:hover, 188 | .dropdown-menu > li > a:focus { 189 | background-color: #e8e8e8; 190 | background-image: -webkit-gradient(linear, left 0%, left 100%, from(#f5f5f5), to(#e8e8e8)); 191 | background-image: -webkit-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%); 192 | background-image: -moz-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%); 193 | background-image: linear-gradient(to bottom, #f5f5f5 0%, #e8e8e8 100%); 194 | background-repeat: repeat-x; 195 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff5f5f5', endColorstr='#ffe8e8e8', GradientType=0); 196 | } 197 | 198 | .dropdown-menu > .active > a, 199 | .dropdown-menu > .active > a:hover, 200 | .dropdown-menu > .active > a:focus { 201 | background-color: #357ebd; 202 | background-image: -webkit-gradient(linear, left 0%, left 100%, from(#428bca), to(#357ebd)); 203 | background-image: -webkit-linear-gradient(top, #428bca 0%, #357ebd 100%); 204 | background-image: -moz-linear-gradient(top, #428bca 0%, #357ebd 100%); 205 | background-image: linear-gradient(to bottom, #428bca 0%, #357ebd 100%); 206 | background-repeat: repeat-x; 207 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff428bca', endColorstr='#ff357ebd', GradientType=0); 208 | } 209 | 210 | .navbar-default { 211 | background-image: -webkit-gradient(linear, left 0%, left 100%, from(#ffffff), to(#f8f8f8)); 212 | background-image: -webkit-linear-gradient(top, #ffffff 0%, #f8f8f8 100%); 213 | background-image: -moz-linear-gradient(top, #ffffff 0%, #f8f8f8 100%); 214 | background-image: linear-gradient(to bottom, #ffffff 0%, #f8f8f8 100%); 215 | background-repeat: repeat-x; 216 | border-radius: 4px; 217 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#fff8f8f8', GradientType=0); 218 | filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); 219 | -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15), 0 1px 5px rgba(0, 0, 0, 0.075); 220 | box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15), 0 1px 5px rgba(0, 0, 0, 0.075); 221 | } 222 | 223 | .navbar-default .navbar-nav > .active > a { 224 | background-image: -webkit-gradient(linear, left 0%, left 100%, from(#ebebeb), to(#f3f3f3)); 225 | background-image: -webkit-linear-gradient(top, #ebebeb 0%, #f3f3f3 100%); 226 | background-image: -moz-linear-gradient(top, #ebebeb 0%, #f3f3f3 100%); 227 | background-image: linear-gradient(to bottom, #ebebeb 0%, #f3f3f3 100%); 228 | background-repeat: repeat-x; 229 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffebebeb', endColorstr='#fff3f3f3', GradientType=0); 230 | -webkit-box-shadow: inset 0 3px 9px rgba(0, 0, 0, 0.075); 231 | box-shadow: inset 0 3px 9px rgba(0, 0, 0, 0.075); 232 | } 233 | 234 | .navbar-brand, 235 | .navbar-nav > li > a { 236 | text-shadow: 0 1px 0 rgba(255, 255, 255, 0.25); 237 | } 238 | 239 | .navbar-inverse { 240 | background-image: -webkit-gradient(linear, left 0%, left 100%, from(#3c3c3c), to(#222222)); 241 | background-image: -webkit-linear-gradient(top, #3c3c3c 0%, #222222 100%); 242 | background-image: -moz-linear-gradient(top, #3c3c3c 0%, #222222 100%); 243 | background-image: linear-gradient(to bottom, #3c3c3c 0%, #222222 100%); 244 | background-repeat: repeat-x; 245 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff3c3c3c', endColorstr='#ff222222', GradientType=0); 246 | filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); 247 | } 248 | 249 | .navbar-inverse .navbar-nav > .active > a { 250 | background-image: -webkit-gradient(linear, left 0%, left 100%, from(#222222), to(#282828)); 251 | background-image: -webkit-linear-gradient(top, #222222 0%, #282828 100%); 252 | background-image: -moz-linear-gradient(top, #222222 0%, #282828 100%); 253 | background-image: linear-gradient(to bottom, #222222 0%, #282828 100%); 254 | background-repeat: repeat-x; 255 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff222222', endColorstr='#ff282828', GradientType=0); 256 | -webkit-box-shadow: inset 0 3px 9px rgba(0, 0, 0, 0.25); 257 | box-shadow: inset 0 3px 9px rgba(0, 0, 0, 0.25); 258 | } 259 | 260 | .navbar-inverse .navbar-brand, 261 | .navbar-inverse .navbar-nav > li > a { 262 | text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); 263 | } 264 | 265 | .navbar-static-top, 266 | .navbar-fixed-top, 267 | .navbar-fixed-bottom { 268 | border-radius: 0; 269 | } 270 | 271 | .alert { 272 | text-shadow: 0 1px 0 rgba(255, 255, 255, 0.2); 273 | -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25), 0 1px 2px rgba(0, 0, 0, 0.05); 274 | box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25), 0 1px 2px rgba(0, 0, 0, 0.05); 275 | } 276 | 277 | .alert-success { 278 | background-image: -webkit-gradient(linear, left 0%, left 100%, from(#dff0d8), to(#c8e5bc)); 279 | background-image: -webkit-linear-gradient(top, #dff0d8 0%, #c8e5bc 100%); 280 | background-image: -moz-linear-gradient(top, #dff0d8 0%, #c8e5bc 100%); 281 | background-image: linear-gradient(to bottom, #dff0d8 0%, #c8e5bc 100%); 282 | background-repeat: repeat-x; 283 | border-color: #b2dba1; 284 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdff0d8', endColorstr='#ffc8e5bc', GradientType=0); 285 | } 286 | 287 | .alert-info { 288 | background-image: -webkit-gradient(linear, left 0%, left 100%, from(#d9edf7), to(#b9def0)); 289 | background-image: -webkit-linear-gradient(top, #d9edf7 0%, #b9def0 100%); 290 | background-image: -moz-linear-gradient(top, #d9edf7 0%, #b9def0 100%); 291 | background-image: linear-gradient(to bottom, #d9edf7 0%, #b9def0 100%); 292 | background-repeat: repeat-x; 293 | border-color: #9acfea; 294 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9edf7', endColorstr='#ffb9def0', GradientType=0); 295 | } 296 | 297 | .alert-warning { 298 | background-image: -webkit-gradient(linear, left 0%, left 100%, from(#fcf8e3), to(#f8efc0)); 299 | background-image: -webkit-linear-gradient(top, #fcf8e3 0%, #f8efc0 100%); 300 | background-image: -moz-linear-gradient(top, #fcf8e3 0%, #f8efc0 100%); 301 | background-image: linear-gradient(to bottom, #fcf8e3 0%, #f8efc0 100%); 302 | background-repeat: repeat-x; 303 | border-color: #f5e79e; 304 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffcf8e3', endColorstr='#fff8efc0', GradientType=0); 305 | } 306 | 307 | .alert-danger { 308 | background-image: -webkit-gradient(linear, left 0%, left 100%, from(#f2dede), to(#e7c3c3)); 309 | background-image: -webkit-linear-gradient(top, #f2dede 0%, #e7c3c3 100%); 310 | background-image: -moz-linear-gradient(top, #f2dede 0%, #e7c3c3 100%); 311 | background-image: linear-gradient(to bottom, #f2dede 0%, #e7c3c3 100%); 312 | background-repeat: repeat-x; 313 | border-color: #dca7a7; 314 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2dede', endColorstr='#ffe7c3c3', GradientType=0); 315 | } 316 | 317 | .progress { 318 | background-image: -webkit-gradient(linear, left 0%, left 100%, from(#ebebeb), to(#f5f5f5)); 319 | background-image: -webkit-linear-gradient(top, #ebebeb 0%, #f5f5f5 100%); 320 | background-image: -moz-linear-gradient(top, #ebebeb 0%, #f5f5f5 100%); 321 | background-image: linear-gradient(to bottom, #ebebeb 0%, #f5f5f5 100%); 322 | background-repeat: repeat-x; 323 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffebebeb', endColorstr='#fff5f5f5', GradientType=0); 324 | } 325 | 326 | .progress-bar { 327 | background-image: -webkit-gradient(linear, left 0%, left 100%, from(#428bca), to(#3071a9)); 328 | background-image: -webkit-linear-gradient(top, #428bca 0%, #3071a9 100%); 329 | background-image: -moz-linear-gradient(top, #428bca 0%, #3071a9 100%); 330 | background-image: linear-gradient(to bottom, #428bca 0%, #3071a9 100%); 331 | background-repeat: repeat-x; 332 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff428bca', endColorstr='#ff3071a9', GradientType=0); 333 | } 334 | 335 | .progress-bar-success { 336 | background-image: -webkit-gradient(linear, left 0%, left 100%, from(#5cb85c), to(#449d44)); 337 | background-image: -webkit-linear-gradient(top, #5cb85c 0%, #449d44 100%); 338 | background-image: -moz-linear-gradient(top, #5cb85c 0%, #449d44 100%); 339 | background-image: linear-gradient(to bottom, #5cb85c 0%, #449d44 100%); 340 | background-repeat: repeat-x; 341 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5cb85c', endColorstr='#ff449d44', GradientType=0); 342 | } 343 | 344 | .progress-bar-info { 345 | background-image: -webkit-gradient(linear, left 0%, left 100%, from(#5bc0de), to(#31b0d5)); 346 | background-image: -webkit-linear-gradient(top, #5bc0de 0%, #31b0d5 100%); 347 | background-image: -moz-linear-gradient(top, #5bc0de 0%, #31b0d5 100%); 348 | background-image: linear-gradient(to bottom, #5bc0de 0%, #31b0d5 100%); 349 | background-repeat: repeat-x; 350 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de', endColorstr='#ff31b0d5', GradientType=0); 351 | } 352 | 353 | .progress-bar-warning { 354 | background-image: -webkit-gradient(linear, left 0%, left 100%, from(#f0ad4e), to(#ec971f)); 355 | background-image: -webkit-linear-gradient(top, #f0ad4e 0%, #ec971f 100%); 356 | background-image: -moz-linear-gradient(top, #f0ad4e 0%, #ec971f 100%); 357 | background-image: linear-gradient(to bottom, #f0ad4e 0%, #ec971f 100%); 358 | background-repeat: repeat-x; 359 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff0ad4e', endColorstr='#ffec971f', GradientType=0); 360 | } 361 | 362 | .progress-bar-danger { 363 | background-image: -webkit-gradient(linear, left 0%, left 100%, from(#d9534f), to(#c9302c)); 364 | background-image: -webkit-linear-gradient(top, #d9534f 0%, #c9302c 100%); 365 | background-image: -moz-linear-gradient(top, #d9534f 0%, #c9302c 100%); 366 | background-image: linear-gradient(to bottom, #d9534f 0%, #c9302c 100%); 367 | background-repeat: repeat-x; 368 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9534f', endColorstr='#ffc9302c', GradientType=0); 369 | } 370 | 371 | .list-group { 372 | border-radius: 4px; 373 | -webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.075); 374 | box-shadow: 0 1px 2px rgba(0, 0, 0, 0.075); 375 | } 376 | 377 | .list-group-item.active, 378 | .list-group-item.active:hover, 379 | .list-group-item.active:focus { 380 | text-shadow: 0 -1px 0 #3071a9; 381 | background-image: -webkit-gradient(linear, left 0%, left 100%, from(#428bca), to(#3278b3)); 382 | background-image: -webkit-linear-gradient(top, #428bca 0%, #3278b3 100%); 383 | background-image: -moz-linear-gradient(top, #428bca 0%, #3278b3 100%); 384 | background-image: linear-gradient(to bottom, #428bca 0%, #3278b3 100%); 385 | background-repeat: repeat-x; 386 | border-color: #3278b3; 387 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff428bca', endColorstr='#ff3278b3', GradientType=0); 388 | } 389 | 390 | .panel { 391 | -webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05); 392 | box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05); 393 | } 394 | 395 | .panel-default > .panel-heading { 396 | background-image: -webkit-gradient(linear, left 0%, left 100%, from(#f5f5f5), to(#e8e8e8)); 397 | background-image: -webkit-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%); 398 | background-image: -moz-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%); 399 | background-image: linear-gradient(to bottom, #f5f5f5 0%, #e8e8e8 100%); 400 | background-repeat: repeat-x; 401 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff5f5f5', endColorstr='#ffe8e8e8', GradientType=0); 402 | } 403 | 404 | .panel-primary > .panel-heading { 405 | background-image: -webkit-gradient(linear, left 0%, left 100%, from(#428bca), to(#357ebd)); 406 | background-image: -webkit-linear-gradient(top, #428bca 0%, #357ebd 100%); 407 | background-image: -moz-linear-gradient(top, #428bca 0%, #357ebd 100%); 408 | background-image: linear-gradient(to bottom, #428bca 0%, #357ebd 100%); 409 | background-repeat: repeat-x; 410 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff428bca', endColorstr='#ff357ebd', GradientType=0); 411 | } 412 | 413 | .panel-success > .panel-heading { 414 | background-image: -webkit-gradient(linear, left 0%, left 100%, from(#dff0d8), to(#d0e9c6)); 415 | background-image: -webkit-linear-gradient(top, #dff0d8 0%, #d0e9c6 100%); 416 | background-image: -moz-linear-gradient(top, #dff0d8 0%, #d0e9c6 100%); 417 | background-image: linear-gradient(to bottom, #dff0d8 0%, #d0e9c6 100%); 418 | background-repeat: repeat-x; 419 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdff0d8', endColorstr='#ffd0e9c6', GradientType=0); 420 | } 421 | 422 | .panel-info > .panel-heading { 423 | background-image: -webkit-gradient(linear, left 0%, left 100%, from(#d9edf7), to(#c4e3f3)); 424 | background-image: -webkit-linear-gradient(top, #d9edf7 0%, #c4e3f3 100%); 425 | background-image: -moz-linear-gradient(top, #d9edf7 0%, #c4e3f3 100%); 426 | background-image: linear-gradient(to bottom, #d9edf7 0%, #c4e3f3 100%); 427 | background-repeat: repeat-x; 428 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9edf7', endColorstr='#ffc4e3f3', GradientType=0); 429 | } 430 | 431 | .panel-warning > .panel-heading { 432 | background-image: -webkit-gradient(linear, left 0%, left 100%, from(#fcf8e3), to(#faf2cc)); 433 | background-image: -webkit-linear-gradient(top, #fcf8e3 0%, #faf2cc 100%); 434 | background-image: -moz-linear-gradient(top, #fcf8e3 0%, #faf2cc 100%); 435 | background-image: linear-gradient(to bottom, #fcf8e3 0%, #faf2cc 100%); 436 | background-repeat: repeat-x; 437 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffcf8e3', endColorstr='#fffaf2cc', GradientType=0); 438 | } 439 | 440 | .panel-danger > .panel-heading { 441 | background-image: -webkit-gradient(linear, left 0%, left 100%, from(#f2dede), to(#ebcccc)); 442 | background-image: -webkit-linear-gradient(top, #f2dede 0%, #ebcccc 100%); 443 | background-image: -moz-linear-gradient(top, #f2dede 0%, #ebcccc 100%); 444 | background-image: linear-gradient(to bottom, #f2dede 0%, #ebcccc 100%); 445 | background-repeat: repeat-x; 446 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2dede', endColorstr='#ffebcccc', GradientType=0); 447 | } 448 | 449 | .well { 450 | background-image: -webkit-gradient(linear, left 0%, left 100%, from(#e8e8e8), to(#f5f5f5)); 451 | background-image: -webkit-linear-gradient(top, #e8e8e8 0%, #f5f5f5 100%); 452 | background-image: -moz-linear-gradient(top, #e8e8e8 0%, #f5f5f5 100%); 453 | background-image: linear-gradient(to bottom, #e8e8e8 0%, #f5f5f5 100%); 454 | background-repeat: repeat-x; 455 | border-color: #dcdcdc; 456 | filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffe8e8e8', endColorstr='#fff5f5f5', GradientType=0); 457 | -webkit-box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.05), 0 1px 0 rgba(255, 255, 255, 0.1); 458 | box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.05), 0 1px 0 rgba(255, 255, 255, 0.1); 459 | } -------------------------------------------------------------------------------- /loja-fim-apos-exercicios/css/bootstrap-theme.min.css: -------------------------------------------------------------------------------- 1 | /*! 2 | * Bootstrap v3.0.1 by @fat and @mdo 3 | * Copyright 2013 Twitter, Inc. 4 | * Licensed under http://www.apache.org/licenses/LICENSE-2.0 5 | * 6 | * Designed and built with all the love in the world by @mdo and @fat. 7 | */ 8 | 9 | .btn-default,.btn-primary,.btn-success,.btn-info,.btn-warning,.btn-danger{text-shadow:0 -1px 0 rgba(0,0,0,0.2);-webkit-box-shadow:inset 0 1px 0 rgba(255,255,255,0.15),0 1px 1px rgba(0,0,0,0.075);box-shadow:inset 0 1px 0 rgba(255,255,255,0.15),0 1px 1px rgba(0,0,0,0.075)}.btn-default:active,.btn-primary:active,.btn-success:active,.btn-info:active,.btn-warning:active,.btn-danger:active,.btn-default.active,.btn-primary.active,.btn-success.active,.btn-info.active,.btn-warning.active,.btn-danger.active{-webkit-box-shadow:inset 0 3px 5px rgba(0,0,0,0.125);box-shadow:inset 0 3px 5px rgba(0,0,0,0.125)}.btn:active,.btn.active{background-image:none}.btn-default{text-shadow:0 1px 0 #fff;background-image:-webkit-gradient(linear,left 0,left 100%,from(#fff),to(#e0e0e0));background-image:-webkit-linear-gradient(top,#fff 0,#e0e0e0 100%);background-image:-moz-linear-gradient(top,#fff 0,#e0e0e0 100%);background-image:linear-gradient(to bottom,#fff 0,#e0e0e0 100%);background-repeat:repeat-x;border-color:#dbdbdb;border-color:#ccc;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff',endColorstr='#ffe0e0e0',GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false)}.btn-default:hover,.btn-default:focus{background-color:#e0e0e0;background-position:0 -15px}.btn-default:active,.btn-default.active{background-color:#e0e0e0;border-color:#dbdbdb}.btn-primary{background-image:-webkit-gradient(linear,left 0,left 100%,from(#428bca),to(#2d6ca2));background-image:-webkit-linear-gradient(top,#428bca 0,#2d6ca2 100%);background-image:-moz-linear-gradient(top,#428bca 0,#2d6ca2 100%);background-image:linear-gradient(to bottom,#428bca 0,#2d6ca2 100%);background-repeat:repeat-x;border-color:#2b669a;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff428bca',endColorstr='#ff2d6ca2',GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false)}.btn-primary:hover,.btn-primary:focus{background-color:#2d6ca2;background-position:0 -15px}.btn-primary:active,.btn-primary.active{background-color:#2d6ca2;border-color:#2b669a}.btn-success{background-image:-webkit-gradient(linear,left 0,left 100%,from(#5cb85c),to(#419641));background-image:-webkit-linear-gradient(top,#5cb85c 0,#419641 100%);background-image:-moz-linear-gradient(top,#5cb85c 0,#419641 100%);background-image:linear-gradient(to bottom,#5cb85c 0,#419641 100%);background-repeat:repeat-x;border-color:#3e8f3e;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5cb85c',endColorstr='#ff419641',GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false)}.btn-success:hover,.btn-success:focus{background-color:#419641;background-position:0 -15px}.btn-success:active,.btn-success.active{background-color:#419641;border-color:#3e8f3e}.btn-warning{background-image:-webkit-gradient(linear,left 0,left 100%,from(#f0ad4e),to(#eb9316));background-image:-webkit-linear-gradient(top,#f0ad4e 0,#eb9316 100%);background-image:-moz-linear-gradient(top,#f0ad4e 0,#eb9316 100%);background-image:linear-gradient(to bottom,#f0ad4e 0,#eb9316 100%);background-repeat:repeat-x;border-color:#e38d13;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff0ad4e',endColorstr='#ffeb9316',GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false)}.btn-warning:hover,.btn-warning:focus{background-color:#eb9316;background-position:0 -15px}.btn-warning:active,.btn-warning.active{background-color:#eb9316;border-color:#e38d13}.btn-danger{background-image:-webkit-gradient(linear,left 0,left 100%,from(#d9534f),to(#c12e2a));background-image:-webkit-linear-gradient(top,#d9534f 0,#c12e2a 100%);background-image:-moz-linear-gradient(top,#d9534f 0,#c12e2a 100%);background-image:linear-gradient(to bottom,#d9534f 0,#c12e2a 100%);background-repeat:repeat-x;border-color:#b92c28;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9534f',endColorstr='#ffc12e2a',GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false)}.btn-danger:hover,.btn-danger:focus{background-color:#c12e2a;background-position:0 -15px}.btn-danger:active,.btn-danger.active{background-color:#c12e2a;border-color:#b92c28}.btn-info{background-image:-webkit-gradient(linear,left 0,left 100%,from(#5bc0de),to(#2aabd2));background-image:-webkit-linear-gradient(top,#5bc0de 0,#2aabd2 100%);background-image:-moz-linear-gradient(top,#5bc0de 0,#2aabd2 100%);background-image:linear-gradient(to bottom,#5bc0de 0,#2aabd2 100%);background-repeat:repeat-x;border-color:#28a4c9;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de',endColorstr='#ff2aabd2',GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false)}.btn-info:hover,.btn-info:focus{background-color:#2aabd2;background-position:0 -15px}.btn-info:active,.btn-info.active{background-color:#2aabd2;border-color:#28a4c9}.thumbnail,.img-thumbnail{-webkit-box-shadow:0 1px 2px rgba(0,0,0,0.075);box-shadow:0 1px 2px rgba(0,0,0,0.075)}.dropdown-menu>li>a:hover,.dropdown-menu>li>a:focus{background-color:#e8e8e8;background-image:-webkit-gradient(linear,left 0,left 100%,from(#f5f5f5),to(#e8e8e8));background-image:-webkit-linear-gradient(top,#f5f5f5 0,#e8e8e8 100%);background-image:-moz-linear-gradient(top,#f5f5f5 0,#e8e8e8 100%);background-image:linear-gradient(to bottom,#f5f5f5 0,#e8e8e8 100%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff5f5f5',endColorstr='#ffe8e8e8',GradientType=0)}.dropdown-menu>.active>a,.dropdown-menu>.active>a:hover,.dropdown-menu>.active>a:focus{background-color:#357ebd;background-image:-webkit-gradient(linear,left 0,left 100%,from(#428bca),to(#357ebd));background-image:-webkit-linear-gradient(top,#428bca 0,#357ebd 100%);background-image:-moz-linear-gradient(top,#428bca 0,#357ebd 100%);background-image:linear-gradient(to bottom,#428bca 0,#357ebd 100%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff428bca',endColorstr='#ff357ebd',GradientType=0)}.navbar-default{background-image:-webkit-gradient(linear,left 0,left 100%,from(#fff),to(#f8f8f8));background-image:-webkit-linear-gradient(top,#fff 0,#f8f8f8 100%);background-image:-moz-linear-gradient(top,#fff 0,#f8f8f8 100%);background-image:linear-gradient(to bottom,#fff 0,#f8f8f8 100%);background-repeat:repeat-x;border-radius:4px;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff',endColorstr='#fff8f8f8',GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false);-webkit-box-shadow:inset 0 1px 0 rgba(255,255,255,0.15),0 1px 5px rgba(0,0,0,0.075);box-shadow:inset 0 1px 0 rgba(255,255,255,0.15),0 1px 5px rgba(0,0,0,0.075)}.navbar-default .navbar-nav>.active>a{background-image:-webkit-gradient(linear,left 0,left 100%,from(#ebebeb),to(#f3f3f3));background-image:-webkit-linear-gradient(top,#ebebeb 0,#f3f3f3 100%);background-image:-moz-linear-gradient(top,#ebebeb 0,#f3f3f3 100%);background-image:linear-gradient(to bottom,#ebebeb 0,#f3f3f3 100%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffebebeb',endColorstr='#fff3f3f3',GradientType=0);-webkit-box-shadow:inset 0 3px 9px rgba(0,0,0,0.075);box-shadow:inset 0 3px 9px rgba(0,0,0,0.075)}.navbar-brand,.navbar-nav>li>a{text-shadow:0 1px 0 rgba(255,255,255,0.25)}.navbar-inverse{background-image:-webkit-gradient(linear,left 0,left 100%,from(#3c3c3c),to(#222));background-image:-webkit-linear-gradient(top,#3c3c3c 0,#222 100%);background-image:-moz-linear-gradient(top,#3c3c3c 0,#222 100%);background-image:linear-gradient(to bottom,#3c3c3c 0,#222 100%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff3c3c3c',endColorstr='#ff222222',GradientType=0);filter:progid:DXImageTransform.Microsoft.gradient(enabled=false)}.navbar-inverse .navbar-nav>.active>a{background-image:-webkit-gradient(linear,left 0,left 100%,from(#222),to(#282828));background-image:-webkit-linear-gradient(top,#222 0,#282828 100%);background-image:-moz-linear-gradient(top,#222 0,#282828 100%);background-image:linear-gradient(to bottom,#222 0,#282828 100%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff222222',endColorstr='#ff282828',GradientType=0);-webkit-box-shadow:inset 0 3px 9px rgba(0,0,0,0.25);box-shadow:inset 0 3px 9px rgba(0,0,0,0.25)}.navbar-inverse .navbar-brand,.navbar-inverse .navbar-nav>li>a{text-shadow:0 -1px 0 rgba(0,0,0,0.25)}.navbar-static-top,.navbar-fixed-top,.navbar-fixed-bottom{border-radius:0}.alert{text-shadow:0 1px 0 rgba(255,255,255,0.2);-webkit-box-shadow:inset 0 1px 0 rgba(255,255,255,0.25),0 1px 2px rgba(0,0,0,0.05);box-shadow:inset 0 1px 0 rgba(255,255,255,0.25),0 1px 2px rgba(0,0,0,0.05)}.alert-success{background-image:-webkit-gradient(linear,left 0,left 100%,from(#dff0d8),to(#c8e5bc));background-image:-webkit-linear-gradient(top,#dff0d8 0,#c8e5bc 100%);background-image:-moz-linear-gradient(top,#dff0d8 0,#c8e5bc 100%);background-image:linear-gradient(to bottom,#dff0d8 0,#c8e5bc 100%);background-repeat:repeat-x;border-color:#b2dba1;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdff0d8',endColorstr='#ffc8e5bc',GradientType=0)}.alert-info{background-image:-webkit-gradient(linear,left 0,left 100%,from(#d9edf7),to(#b9def0));background-image:-webkit-linear-gradient(top,#d9edf7 0,#b9def0 100%);background-image:-moz-linear-gradient(top,#d9edf7 0,#b9def0 100%);background-image:linear-gradient(to bottom,#d9edf7 0,#b9def0 100%);background-repeat:repeat-x;border-color:#9acfea;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9edf7',endColorstr='#ffb9def0',GradientType=0)}.alert-warning{background-image:-webkit-gradient(linear,left 0,left 100%,from(#fcf8e3),to(#f8efc0));background-image:-webkit-linear-gradient(top,#fcf8e3 0,#f8efc0 100%);background-image:-moz-linear-gradient(top,#fcf8e3 0,#f8efc0 100%);background-image:linear-gradient(to bottom,#fcf8e3 0,#f8efc0 100%);background-repeat:repeat-x;border-color:#f5e79e;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffcf8e3',endColorstr='#fff8efc0',GradientType=0)}.alert-danger{background-image:-webkit-gradient(linear,left 0,left 100%,from(#f2dede),to(#e7c3c3));background-image:-webkit-linear-gradient(top,#f2dede 0,#e7c3c3 100%);background-image:-moz-linear-gradient(top,#f2dede 0,#e7c3c3 100%);background-image:linear-gradient(to bottom,#f2dede 0,#e7c3c3 100%);background-repeat:repeat-x;border-color:#dca7a7;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2dede',endColorstr='#ffe7c3c3',GradientType=0)}.progress{background-image:-webkit-gradient(linear,left 0,left 100%,from(#ebebeb),to(#f5f5f5));background-image:-webkit-linear-gradient(top,#ebebeb 0,#f5f5f5 100%);background-image:-moz-linear-gradient(top,#ebebeb 0,#f5f5f5 100%);background-image:linear-gradient(to bottom,#ebebeb 0,#f5f5f5 100%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffebebeb',endColorstr='#fff5f5f5',GradientType=0)}.progress-bar{background-image:-webkit-gradient(linear,left 0,left 100%,from(#428bca),to(#3071a9));background-image:-webkit-linear-gradient(top,#428bca 0,#3071a9 100%);background-image:-moz-linear-gradient(top,#428bca 0,#3071a9 100%);background-image:linear-gradient(to bottom,#428bca 0,#3071a9 100%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff428bca',endColorstr='#ff3071a9',GradientType=0)}.progress-bar-success{background-image:-webkit-gradient(linear,left 0,left 100%,from(#5cb85c),to(#449d44));background-image:-webkit-linear-gradient(top,#5cb85c 0,#449d44 100%);background-image:-moz-linear-gradient(top,#5cb85c 0,#449d44 100%);background-image:linear-gradient(to bottom,#5cb85c 0,#449d44 100%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5cb85c',endColorstr='#ff449d44',GradientType=0)}.progress-bar-info{background-image:-webkit-gradient(linear,left 0,left 100%,from(#5bc0de),to(#31b0d5));background-image:-webkit-linear-gradient(top,#5bc0de 0,#31b0d5 100%);background-image:-moz-linear-gradient(top,#5bc0de 0,#31b0d5 100%);background-image:linear-gradient(to bottom,#5bc0de 0,#31b0d5 100%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de',endColorstr='#ff31b0d5',GradientType=0)}.progress-bar-warning{background-image:-webkit-gradient(linear,left 0,left 100%,from(#f0ad4e),to(#ec971f));background-image:-webkit-linear-gradient(top,#f0ad4e 0,#ec971f 100%);background-image:-moz-linear-gradient(top,#f0ad4e 0,#ec971f 100%);background-image:linear-gradient(to bottom,#f0ad4e 0,#ec971f 100%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff0ad4e',endColorstr='#ffec971f',GradientType=0)}.progress-bar-danger{background-image:-webkit-gradient(linear,left 0,left 100%,from(#d9534f),to(#c9302c));background-image:-webkit-linear-gradient(top,#d9534f 0,#c9302c 100%);background-image:-moz-linear-gradient(top,#d9534f 0,#c9302c 100%);background-image:linear-gradient(to bottom,#d9534f 0,#c9302c 100%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9534f',endColorstr='#ffc9302c',GradientType=0)}.list-group{border-radius:4px;-webkit-box-shadow:0 1px 2px rgba(0,0,0,0.075);box-shadow:0 1px 2px rgba(0,0,0,0.075)}.list-group-item.active,.list-group-item.active:hover,.list-group-item.active:focus{text-shadow:0 -1px 0 #3071a9;background-image:-webkit-gradient(linear,left 0,left 100%,from(#428bca),to(#3278b3));background-image:-webkit-linear-gradient(top,#428bca 0,#3278b3 100%);background-image:-moz-linear-gradient(top,#428bca 0,#3278b3 100%);background-image:linear-gradient(to bottom,#428bca 0,#3278b3 100%);background-repeat:repeat-x;border-color:#3278b3;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff428bca',endColorstr='#ff3278b3',GradientType=0)}.panel{-webkit-box-shadow:0 1px 2px rgba(0,0,0,0.05);box-shadow:0 1px 2px rgba(0,0,0,0.05)}.panel-default>.panel-heading{background-image:-webkit-gradient(linear,left 0,left 100%,from(#f5f5f5),to(#e8e8e8));background-image:-webkit-linear-gradient(top,#f5f5f5 0,#e8e8e8 100%);background-image:-moz-linear-gradient(top,#f5f5f5 0,#e8e8e8 100%);background-image:linear-gradient(to bottom,#f5f5f5 0,#e8e8e8 100%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff5f5f5',endColorstr='#ffe8e8e8',GradientType=0)}.panel-primary>.panel-heading{background-image:-webkit-gradient(linear,left 0,left 100%,from(#428bca),to(#357ebd));background-image:-webkit-linear-gradient(top,#428bca 0,#357ebd 100%);background-image:-moz-linear-gradient(top,#428bca 0,#357ebd 100%);background-image:linear-gradient(to bottom,#428bca 0,#357ebd 100%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff428bca',endColorstr='#ff357ebd',GradientType=0)}.panel-success>.panel-heading{background-image:-webkit-gradient(linear,left 0,left 100%,from(#dff0d8),to(#d0e9c6));background-image:-webkit-linear-gradient(top,#dff0d8 0,#d0e9c6 100%);background-image:-moz-linear-gradient(top,#dff0d8 0,#d0e9c6 100%);background-image:linear-gradient(to bottom,#dff0d8 0,#d0e9c6 100%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdff0d8',endColorstr='#ffd0e9c6',GradientType=0)}.panel-info>.panel-heading{background-image:-webkit-gradient(linear,left 0,left 100%,from(#d9edf7),to(#c4e3f3));background-image:-webkit-linear-gradient(top,#d9edf7 0,#c4e3f3 100%);background-image:-moz-linear-gradient(top,#d9edf7 0,#c4e3f3 100%);background-image:linear-gradient(to bottom,#d9edf7 0,#c4e3f3 100%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9edf7',endColorstr='#ffc4e3f3',GradientType=0)}.panel-warning>.panel-heading{background-image:-webkit-gradient(linear,left 0,left 100%,from(#fcf8e3),to(#faf2cc));background-image:-webkit-linear-gradient(top,#fcf8e3 0,#faf2cc 100%);background-image:-moz-linear-gradient(top,#fcf8e3 0,#faf2cc 100%);background-image:linear-gradient(to bottom,#fcf8e3 0,#faf2cc 100%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffcf8e3',endColorstr='#fffaf2cc',GradientType=0)}.panel-danger>.panel-heading{background-image:-webkit-gradient(linear,left 0,left 100%,from(#f2dede),to(#ebcccc));background-image:-webkit-linear-gradient(top,#f2dede 0,#ebcccc 100%);background-image:-moz-linear-gradient(top,#f2dede 0,#ebcccc 100%);background-image:linear-gradient(to bottom,#f2dede 0,#ebcccc 100%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2dede',endColorstr='#ffebcccc',GradientType=0)}.well{background-image:-webkit-gradient(linear,left 0,left 100%,from(#e8e8e8),to(#f5f5f5));background-image:-webkit-linear-gradient(top,#e8e8e8 0,#f5f5f5 100%);background-image:-moz-linear-gradient(top,#e8e8e8 0,#f5f5f5 100%);background-image:linear-gradient(to bottom,#e8e8e8 0,#f5f5f5 100%);background-repeat:repeat-x;border-color:#dcdcdc;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffe8e8e8',endColorstr='#fff5f5f5',GradientType=0);-webkit-box-shadow:inset 0 1px 3px rgba(0,0,0,0.05),0 1px 0 rgba(255,255,255,0.1);box-shadow:inset 0 1px 3px rgba(0,0,0,0.05),0 1px 0 rgba(255,255,255,0.1)} -------------------------------------------------------------------------------- /loja-fim-apos-exercicios/css/loja.css: -------------------------------------------------------------------------------- 1 | body { 2 | padding-top: 50px; 3 | } 4 | .principal { 5 | padding: 40px 15px; 6 | text-align: center; 7 | } -------------------------------------------------------------------------------- /loja-fim-apos-exercicios/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alura-cursos/php-mysql-e-fundamentos-da-web/099c04caa78ca1a48e507d30eef04239d2da2211/loja-fim-apos-exercicios/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /loja-fim-apos-exercicios/fonts/glyphicons-halflings-regular.svg: -------------------------------------------------------------------------------- 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 | 229 | -------------------------------------------------------------------------------- /loja-fim-apos-exercicios/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alura-cursos/php-mysql-e-fundamentos-da-web/099c04caa78ca1a48e507d30eef04239d2da2211/loja-fim-apos-exercicios/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /loja-fim-apos-exercicios/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/alura-cursos/php-mysql-e-fundamentos-da-web/099c04caa78ca1a48e507d30eef04239d2da2211/loja-fim-apos-exercicios/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /loja-fim-apos-exercicios/index.php: -------------------------------------------------------------------------------- 1 | 2 |

Bem vindo!

3 | 4 | -------------------------------------------------------------------------------- /loja-fim-apos-exercicios/js/bootstrap.js: -------------------------------------------------------------------------------- 1 | /*! 2 | * Bootstrap v3.0.1 by @fat and @mdo 3 | * Copyright 2013 Twitter, Inc. 4 | * Licensed under http://www.apache.org/licenses/LICENSE-2.0 5 | * 6 | * Designed and built with all the love in the world by @mdo and @fat. 7 | */ 8 | 9 | if (typeof jQuery === "undefined") { throw new Error("Bootstrap requires jQuery") } 10 | 11 | /* ======================================================================== 12 | * Bootstrap: transition.js v3.0.0 13 | * http://getbootstrap.com/javascript/#transitions 14 | * ======================================================================== 15 | * Copyright 2013 Twitter, Inc. 16 | * 17 | * Licensed under the Apache License, Version 2.0 (the "License"); 18 | * you may not use this file except in compliance with the License. 19 | * You may obtain a copy of the License at 20 | * 21 | * http://www.apache.org/licenses/LICENSE-2.0 22 | * 23 | * Unless required by applicable law or agreed to in writing, software 24 | * distributed under the License is distributed on an "AS IS" BASIS, 25 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 26 | * See the License for the specific language governing permissions and 27 | * limitations under the License. 28 | * ======================================================================== */ 29 | 30 | 31 | +function ($) { "use strict"; 32 | 33 | // CSS TRANSITION SUPPORT (Shoutout: http://www.modernizr.com/) 34 | // ============================================================ 35 | 36 | function transitionEnd() { 37 | var el = document.createElement('bootstrap') 38 | 39 | var transEndEventNames = { 40 | 'WebkitTransition' : 'webkitTransitionEnd' 41 | , 'MozTransition' : 'transitionend' 42 | , 'OTransition' : 'oTransitionEnd otransitionend' 43 | , 'transition' : 'transitionend' 44 | } 45 | 46 | for (var name in transEndEventNames) { 47 | if (el.style[name] !== undefined) { 48 | return { end: transEndEventNames[name] } 49 | } 50 | } 51 | } 52 | 53 | // http://blog.alexmaccaw.com/css-transitions 54 | $.fn.emulateTransitionEnd = function (duration) { 55 | var called = false, $el = this 56 | $(this).one($.support.transition.end, function () { called = true }) 57 | var callback = function () { if (!called) $($el).trigger($.support.transition.end) } 58 | setTimeout(callback, duration) 59 | return this 60 | } 61 | 62 | $(function () { 63 | $.support.transition = transitionEnd() 64 | }) 65 | 66 | }(window.jQuery); 67 | 68 | /* ======================================================================== 69 | * Bootstrap: alert.js v3.0.0 70 | * http://getbootstrap.com/javascript/#alerts 71 | * ======================================================================== 72 | * Copyright 2013 Twitter, Inc. 73 | * 74 | * Licensed under the Apache License, Version 2.0 (the "License"); 75 | * you may not use this file except in compliance with the License. 76 | * You may obtain a copy of the License at 77 | * 78 | * http://www.apache.org/licenses/LICENSE-2.0 79 | * 80 | * Unless required by applicable law or agreed to in writing, software 81 | * distributed under the License is distributed on an "AS IS" BASIS, 82 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 83 | * See the License for the specific language governing permissions and 84 | * limitations under the License. 85 | * ======================================================================== */ 86 | 87 | 88 | +function ($) { "use strict"; 89 | 90 | // ALERT CLASS DEFINITION 91 | // ====================== 92 | 93 | var dismiss = '[data-dismiss="alert"]' 94 | var Alert = function (el) { 95 | $(el).on('click', dismiss, this.close) 96 | } 97 | 98 | Alert.prototype.close = function (e) { 99 | var $this = $(this) 100 | var selector = $this.attr('data-target') 101 | 102 | if (!selector) { 103 | selector = $this.attr('href') 104 | selector = selector && selector.replace(/.*(?=#[^\s]*$)/, '') // strip for ie7 105 | } 106 | 107 | var $parent = $(selector) 108 | 109 | if (e) e.preventDefault() 110 | 111 | if (!$parent.length) { 112 | $parent = $this.hasClass('alert') ? $this : $this.parent() 113 | } 114 | 115 | $parent.trigger(e = $.Event('close.bs.alert')) 116 | 117 | if (e.isDefaultPrevented()) return 118 | 119 | $parent.removeClass('in') 120 | 121 | function removeElement() { 122 | $parent.trigger('closed.bs.alert').remove() 123 | } 124 | 125 | $.support.transition && $parent.hasClass('fade') ? 126 | $parent 127 | .one($.support.transition.end, removeElement) 128 | .emulateTransitionEnd(150) : 129 | removeElement() 130 | } 131 | 132 | 133 | // ALERT PLUGIN DEFINITION 134 | // ======================= 135 | 136 | var old = $.fn.alert 137 | 138 | $.fn.alert = function (option) { 139 | return this.each(function () { 140 | var $this = $(this) 141 | var data = $this.data('bs.alert') 142 | 143 | if (!data) $this.data('bs.alert', (data = new Alert(this))) 144 | if (typeof option == 'string') data[option].call($this) 145 | }) 146 | } 147 | 148 | $.fn.alert.Constructor = Alert 149 | 150 | 151 | // ALERT NO CONFLICT 152 | // ================= 153 | 154 | $.fn.alert.noConflict = function () { 155 | $.fn.alert = old 156 | return this 157 | } 158 | 159 | 160 | // ALERT DATA-API 161 | // ============== 162 | 163 | $(document).on('click.bs.alert.data-api', dismiss, Alert.prototype.close) 164 | 165 | }(window.jQuery); 166 | 167 | /* ======================================================================== 168 | * Bootstrap: button.js v3.0.0 169 | * http://getbootstrap.com/javascript/#buttons 170 | * ======================================================================== 171 | * Copyright 2013 Twitter, Inc. 172 | * 173 | * Licensed under the Apache License, Version 2.0 (the "License"); 174 | * you may not use this file except in compliance with the License. 175 | * You may obtain a copy of the License at 176 | * 177 | * http://www.apache.org/licenses/LICENSE-2.0 178 | * 179 | * Unless required by applicable law or agreed to in writing, software 180 | * distributed under the License is distributed on an "AS IS" BASIS, 181 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 182 | * See the License for the specific language governing permissions and 183 | * limitations under the License. 184 | * ======================================================================== */ 185 | 186 | 187 | +function ($) { "use strict"; 188 | 189 | // BUTTON PUBLIC CLASS DEFINITION 190 | // ============================== 191 | 192 | var Button = function (element, options) { 193 | this.$element = $(element) 194 | this.options = $.extend({}, Button.DEFAULTS, options) 195 | } 196 | 197 | Button.DEFAULTS = { 198 | loadingText: 'loading...' 199 | } 200 | 201 | Button.prototype.setState = function (state) { 202 | var d = 'disabled' 203 | var $el = this.$element 204 | var val = $el.is('input') ? 'val' : 'html' 205 | var data = $el.data() 206 | 207 | state = state + 'Text' 208 | 209 | if (!data.resetText) $el.data('resetText', $el[val]()) 210 | 211 | $el[val](data[state] || this.options[state]) 212 | 213 | // push to event loop to allow forms to submit 214 | setTimeout(function () { 215 | state == 'loadingText' ? 216 | $el.addClass(d).attr(d, d) : 217 | $el.removeClass(d).removeAttr(d); 218 | }, 0) 219 | } 220 | 221 | Button.prototype.toggle = function () { 222 | var $parent = this.$element.closest('[data-toggle="buttons"]') 223 | 224 | if ($parent.length) { 225 | var $input = this.$element.find('input') 226 | .prop('checked', !this.$element.hasClass('active')) 227 | .trigger('change') 228 | if ($input.prop('type') === 'radio') $parent.find('.active').removeClass('active') 229 | } 230 | 231 | this.$element.toggleClass('active') 232 | } 233 | 234 | 235 | // BUTTON PLUGIN DEFINITION 236 | // ======================== 237 | 238 | var old = $.fn.button 239 | 240 | $.fn.button = function (option) { 241 | return this.each(function () { 242 | var $this = $(this) 243 | var data = $this.data('bs.button') 244 | var options = typeof option == 'object' && option 245 | 246 | if (!data) $this.data('bs.button', (data = new Button(this, options))) 247 | 248 | if (option == 'toggle') data.toggle() 249 | else if (option) data.setState(option) 250 | }) 251 | } 252 | 253 | $.fn.button.Constructor = Button 254 | 255 | 256 | // BUTTON NO CONFLICT 257 | // ================== 258 | 259 | $.fn.button.noConflict = function () { 260 | $.fn.button = old 261 | return this 262 | } 263 | 264 | 265 | // BUTTON DATA-API 266 | // =============== 267 | 268 | $(document).on('click.bs.button.data-api', '[data-toggle^=button]', function (e) { 269 | var $btn = $(e.target) 270 | if (!$btn.hasClass('btn')) $btn = $btn.closest('.btn') 271 | $btn.button('toggle') 272 | e.preventDefault() 273 | }) 274 | 275 | }(window.jQuery); 276 | 277 | /* ======================================================================== 278 | * Bootstrap: carousel.js v3.0.0 279 | * http://getbootstrap.com/javascript/#carousel 280 | * ======================================================================== 281 | * Copyright 2013 Twitter, Inc. 282 | * 283 | * Licensed under the Apache License, Version 2.0 (the "License"); 284 | * you may not use this file except in compliance with the License. 285 | * You may obtain a copy of the License at 286 | * 287 | * http://www.apache.org/licenses/LICENSE-2.0 288 | * 289 | * Unless required by applicable law or agreed to in writing, software 290 | * distributed under the License is distributed on an "AS IS" BASIS, 291 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 292 | * See the License for the specific language governing permissions and 293 | * limitations under the License. 294 | * ======================================================================== */ 295 | 296 | 297 | +function ($) { "use strict"; 298 | 299 | // CAROUSEL CLASS DEFINITION 300 | // ========================= 301 | 302 | var Carousel = function (element, options) { 303 | this.$element = $(element) 304 | this.$indicators = this.$element.find('.carousel-indicators') 305 | this.options = options 306 | this.paused = 307 | this.sliding = 308 | this.interval = 309 | this.$active = 310 | this.$items = null 311 | 312 | this.options.pause == 'hover' && this.$element 313 | .on('mouseenter', $.proxy(this.pause, this)) 314 | .on('mouseleave', $.proxy(this.cycle, this)) 315 | } 316 | 317 | Carousel.DEFAULTS = { 318 | interval: 5000 319 | , pause: 'hover' 320 | , wrap: true 321 | } 322 | 323 | Carousel.prototype.cycle = function (e) { 324 | e || (this.paused = false) 325 | 326 | this.interval && clearInterval(this.interval) 327 | 328 | this.options.interval 329 | && !this.paused 330 | && (this.interval = setInterval($.proxy(this.next, this), this.options.interval)) 331 | 332 | return this 333 | } 334 | 335 | Carousel.prototype.getActiveIndex = function () { 336 | this.$active = this.$element.find('.item.active') 337 | this.$items = this.$active.parent().children() 338 | 339 | return this.$items.index(this.$active) 340 | } 341 | 342 | Carousel.prototype.to = function (pos) { 343 | var that = this 344 | var activeIndex = this.getActiveIndex() 345 | 346 | if (pos > (this.$items.length - 1) || pos < 0) return 347 | 348 | if (this.sliding) return this.$element.one('slid', function () { that.to(pos) }) 349 | if (activeIndex == pos) return this.pause().cycle() 350 | 351 | return this.slide(pos > activeIndex ? 'next' : 'prev', $(this.$items[pos])) 352 | } 353 | 354 | Carousel.prototype.pause = function (e) { 355 | e || (this.paused = true) 356 | 357 | if (this.$element.find('.next, .prev').length && $.support.transition.end) { 358 | this.$element.trigger($.support.transition.end) 359 | this.cycle(true) 360 | } 361 | 362 | this.interval = clearInterval(this.interval) 363 | 364 | return this 365 | } 366 | 367 | Carousel.prototype.next = function () { 368 | if (this.sliding) return 369 | return this.slide('next') 370 | } 371 | 372 | Carousel.prototype.prev = function () { 373 | if (this.sliding) return 374 | return this.slide('prev') 375 | } 376 | 377 | Carousel.prototype.slide = function (type, next) { 378 | var $active = this.$element.find('.item.active') 379 | var $next = next || $active[type]() 380 | var isCycling = this.interval 381 | var direction = type == 'next' ? 'left' : 'right' 382 | var fallback = type == 'next' ? 'first' : 'last' 383 | var that = this 384 | 385 | if (!$next.length) { 386 | if (!this.options.wrap) return 387 | $next = this.$element.find('.item')[fallback]() 388 | } 389 | 390 | this.sliding = true 391 | 392 | isCycling && this.pause() 393 | 394 | var e = $.Event('slide.bs.carousel', { relatedTarget: $next[0], direction: direction }) 395 | 396 | if ($next.hasClass('active')) return 397 | 398 | if (this.$indicators.length) { 399 | this.$indicators.find('.active').removeClass('active') 400 | this.$element.one('slid', function () { 401 | var $nextIndicator = $(that.$indicators.children()[that.getActiveIndex()]) 402 | $nextIndicator && $nextIndicator.addClass('active') 403 | }) 404 | } 405 | 406 | if ($.support.transition && this.$element.hasClass('slide')) { 407 | this.$element.trigger(e) 408 | if (e.isDefaultPrevented()) return 409 | $next.addClass(type) 410 | $next[0].offsetWidth // force reflow 411 | $active.addClass(direction) 412 | $next.addClass(direction) 413 | $active 414 | .one($.support.transition.end, function () { 415 | $next.removeClass([type, direction].join(' ')).addClass('active') 416 | $active.removeClass(['active', direction].join(' ')) 417 | that.sliding = false 418 | setTimeout(function () { that.$element.trigger('slid') }, 0) 419 | }) 420 | .emulateTransitionEnd(600) 421 | } else { 422 | this.$element.trigger(e) 423 | if (e.isDefaultPrevented()) return 424 | $active.removeClass('active') 425 | $next.addClass('active') 426 | this.sliding = false 427 | this.$element.trigger('slid') 428 | } 429 | 430 | isCycling && this.cycle() 431 | 432 | return this 433 | } 434 | 435 | 436 | // CAROUSEL PLUGIN DEFINITION 437 | // ========================== 438 | 439 | var old = $.fn.carousel 440 | 441 | $.fn.carousel = function (option) { 442 | return this.each(function () { 443 | var $this = $(this) 444 | var data = $this.data('bs.carousel') 445 | var options = $.extend({}, Carousel.DEFAULTS, $this.data(), typeof option == 'object' && option) 446 | var action = typeof option == 'string' ? option : options.slide 447 | 448 | if (!data) $this.data('bs.carousel', (data = new Carousel(this, options))) 449 | if (typeof option == 'number') data.to(option) 450 | else if (action) data[action]() 451 | else if (options.interval) data.pause().cycle() 452 | }) 453 | } 454 | 455 | $.fn.carousel.Constructor = Carousel 456 | 457 | 458 | // CAROUSEL NO CONFLICT 459 | // ==================== 460 | 461 | $.fn.carousel.noConflict = function () { 462 | $.fn.carousel = old 463 | return this 464 | } 465 | 466 | 467 | // CAROUSEL DATA-API 468 | // ================= 469 | 470 | $(document).on('click.bs.carousel.data-api', '[data-slide], [data-slide-to]', function (e) { 471 | var $this = $(this), href 472 | var $target = $($this.attr('data-target') || (href = $this.attr('href')) && href.replace(/.*(?=#[^\s]+$)/, '')) //strip for ie7 473 | var options = $.extend({}, $target.data(), $this.data()) 474 | var slideIndex = $this.attr('data-slide-to') 475 | if (slideIndex) options.interval = false 476 | 477 | $target.carousel(options) 478 | 479 | if (slideIndex = $this.attr('data-slide-to')) { 480 | $target.data('bs.carousel').to(slideIndex) 481 | } 482 | 483 | e.preventDefault() 484 | }) 485 | 486 | $(window).on('load', function () { 487 | $('[data-ride="carousel"]').each(function () { 488 | var $carousel = $(this) 489 | $carousel.carousel($carousel.data()) 490 | }) 491 | }) 492 | 493 | }(window.jQuery); 494 | 495 | /* ======================================================================== 496 | * Bootstrap: collapse.js v3.0.0 497 | * http://getbootstrap.com/javascript/#collapse 498 | * ======================================================================== 499 | * Copyright 2013 Twitter, Inc. 500 | * 501 | * Licensed under the Apache License, Version 2.0 (the "License"); 502 | * you may not use this file except in compliance with the License. 503 | * You may obtain a copy of the License at 504 | * 505 | * http://www.apache.org/licenses/LICENSE-2.0 506 | * 507 | * Unless required by applicable law or agreed to in writing, software 508 | * distributed under the License is distributed on an "AS IS" BASIS, 509 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 510 | * See the License for the specific language governing permissions and 511 | * limitations under the License. 512 | * ======================================================================== */ 513 | 514 | 515 | +function ($) { "use strict"; 516 | 517 | // COLLAPSE PUBLIC CLASS DEFINITION 518 | // ================================ 519 | 520 | var Collapse = function (element, options) { 521 | this.$element = $(element) 522 | this.options = $.extend({}, Collapse.DEFAULTS, options) 523 | this.transitioning = null 524 | 525 | if (this.options.parent) this.$parent = $(this.options.parent) 526 | if (this.options.toggle) this.toggle() 527 | } 528 | 529 | Collapse.DEFAULTS = { 530 | toggle: true 531 | } 532 | 533 | Collapse.prototype.dimension = function () { 534 | var hasWidth = this.$element.hasClass('width') 535 | return hasWidth ? 'width' : 'height' 536 | } 537 | 538 | Collapse.prototype.show = function () { 539 | if (this.transitioning || this.$element.hasClass('in')) return 540 | 541 | var startEvent = $.Event('show.bs.collapse') 542 | this.$element.trigger(startEvent) 543 | if (startEvent.isDefaultPrevented()) return 544 | 545 | var actives = this.$parent && this.$parent.find('> .panel > .in') 546 | 547 | if (actives && actives.length) { 548 | var hasData = actives.data('bs.collapse') 549 | if (hasData && hasData.transitioning) return 550 | actives.collapse('hide') 551 | hasData || actives.data('bs.collapse', null) 552 | } 553 | 554 | var dimension = this.dimension() 555 | 556 | this.$element 557 | .removeClass('collapse') 558 | .addClass('collapsing') 559 | [dimension](0) 560 | 561 | this.transitioning = 1 562 | 563 | var complete = function () { 564 | this.$element 565 | .removeClass('collapsing') 566 | .addClass('in') 567 | [dimension]('auto') 568 | this.transitioning = 0 569 | this.$element.trigger('shown.bs.collapse') 570 | } 571 | 572 | if (!$.support.transition) return complete.call(this) 573 | 574 | var scrollSize = $.camelCase(['scroll', dimension].join('-')) 575 | 576 | this.$element 577 | .one($.support.transition.end, $.proxy(complete, this)) 578 | .emulateTransitionEnd(350) 579 | [dimension](this.$element[0][scrollSize]) 580 | } 581 | 582 | Collapse.prototype.hide = function () { 583 | if (this.transitioning || !this.$element.hasClass('in')) return 584 | 585 | var startEvent = $.Event('hide.bs.collapse') 586 | this.$element.trigger(startEvent) 587 | if (startEvent.isDefaultPrevented()) return 588 | 589 | var dimension = this.dimension() 590 | 591 | this.$element 592 | [dimension](this.$element[dimension]()) 593 | [0].offsetHeight 594 | 595 | this.$element 596 | .addClass('collapsing') 597 | .removeClass('collapse') 598 | .removeClass('in') 599 | 600 | this.transitioning = 1 601 | 602 | var complete = function () { 603 | this.transitioning = 0 604 | this.$element 605 | .trigger('hidden.bs.collapse') 606 | .removeClass('collapsing') 607 | .addClass('collapse') 608 | } 609 | 610 | if (!$.support.transition) return complete.call(this) 611 | 612 | this.$element 613 | [dimension](0) 614 | .one($.support.transition.end, $.proxy(complete, this)) 615 | .emulateTransitionEnd(350) 616 | } 617 | 618 | Collapse.prototype.toggle = function () { 619 | this[this.$element.hasClass('in') ? 'hide' : 'show']() 620 | } 621 | 622 | 623 | // COLLAPSE PLUGIN DEFINITION 624 | // ========================== 625 | 626 | var old = $.fn.collapse 627 | 628 | $.fn.collapse = function (option) { 629 | return this.each(function () { 630 | var $this = $(this) 631 | var data = $this.data('bs.collapse') 632 | var options = $.extend({}, Collapse.DEFAULTS, $this.data(), typeof option == 'object' && option) 633 | 634 | if (!data) $this.data('bs.collapse', (data = new Collapse(this, options))) 635 | if (typeof option == 'string') data[option]() 636 | }) 637 | } 638 | 639 | $.fn.collapse.Constructor = Collapse 640 | 641 | 642 | // COLLAPSE NO CONFLICT 643 | // ==================== 644 | 645 | $.fn.collapse.noConflict = function () { 646 | $.fn.collapse = old 647 | return this 648 | } 649 | 650 | 651 | // COLLAPSE DATA-API 652 | // ================= 653 | 654 | $(document).on('click.bs.collapse.data-api', '[data-toggle=collapse]', function (e) { 655 | var $this = $(this), href 656 | var target = $this.attr('data-target') 657 | || e.preventDefault() 658 | || (href = $this.attr('href')) && href.replace(/.*(?=#[^\s]+$)/, '') //strip for ie7 659 | var $target = $(target) 660 | var data = $target.data('bs.collapse') 661 | var option = data ? 'toggle' : $this.data() 662 | var parent = $this.attr('data-parent') 663 | var $parent = parent && $(parent) 664 | 665 | if (!data || !data.transitioning) { 666 | if ($parent) $parent.find('[data-toggle=collapse][data-parent="' + parent + '"]').not($this).addClass('collapsed') 667 | $this[$target.hasClass('in') ? 'addClass' : 'removeClass']('collapsed') 668 | } 669 | 670 | $target.collapse(option) 671 | }) 672 | 673 | }(window.jQuery); 674 | 675 | /* ======================================================================== 676 | * Bootstrap: dropdown.js v3.0.0 677 | * http://getbootstrap.com/javascript/#dropdowns 678 | * ======================================================================== 679 | * Copyright 2013 Twitter, Inc. 680 | * 681 | * Licensed under the Apache License, Version 2.0 (the "License"); 682 | * you may not use this file except in compliance with the License. 683 | * You may obtain a copy of the License at 684 | * 685 | * http://www.apache.org/licenses/LICENSE-2.0 686 | * 687 | * Unless required by applicable law or agreed to in writing, software 688 | * distributed under the License is distributed on an "AS IS" BASIS, 689 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 690 | * See the License for the specific language governing permissions and 691 | * limitations under the License. 692 | * ======================================================================== */ 693 | 694 | 695 | +function ($) { "use strict"; 696 | 697 | // DROPDOWN CLASS DEFINITION 698 | // ========================= 699 | 700 | var backdrop = '.dropdown-backdrop' 701 | var toggle = '[data-toggle=dropdown]' 702 | var Dropdown = function (element) { 703 | var $el = $(element).on('click.bs.dropdown', this.toggle) 704 | } 705 | 706 | Dropdown.prototype.toggle = function (e) { 707 | var $this = $(this) 708 | 709 | if ($this.is('.disabled, :disabled')) return 710 | 711 | var $parent = getParent($this) 712 | var isActive = $parent.hasClass('open') 713 | 714 | clearMenus() 715 | 716 | if (!isActive) { 717 | if ('ontouchstart' in document.documentElement && !$parent.closest('.navbar-nav').length) { 718 | // if mobile we we use a backdrop because click events don't delegate 719 | $(' 6 | 7 | 8 | 9 | 10 | --------------------------------------------------------------------------------