This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* Defining the language */ | |
private function _define_language() | |
{ | |
$uri = $this->uri->segment(1); | |
if ( 'admin' != $uri ) | |
{ | |
if ( !empty($uri) ) | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class MY_Controller extends CI_Controller{ | |
public function __construct(){ | |
parent::__construct(); | |
} | |
} | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Este funciona: | |
$this->data['bsc'] = json_decode(file_get_contents(BAROMETRO_LINK . '/index.php/api/statistics/user/' . $this->data['user']->id)); | |
// Este não funciona: | |
$request = file_get_contents('https://sig.grupoch.pt:4443/ws/ws_server_contacts.php?method=getRadarInfoForUser&user=' . $this->data['user']->sig_id . '&authcode=HjO8mLKrTXxS_2NkX2xshmh!s94NJ5sF'); | |
Este reproduz o seguinte url: https://sig.grupoch.pt:4443/ws/ws_server_contacts.php?method=getRadarInfoForUser&user=158&authcode=HjO8mLKrTXxS_2NkX2xshmh!s94NJ5sF | |
Como pode ver o url funciona. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* CodeIgniter | |
* | |
* An open source application development framework for PHP 5.2.4 or newer | |
* | |
* This content is released under the MIT License (MIT) | |
* | |
* Copyright (c) 2014, British Columbia Institute of Technology | |
* |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class MY_Controller extends CI_Controller | |
{ | |
/* -------------------------------------------------------------- | |
* VARIABLES | |
* ------------------------------------------------------------ */ | |
/** | |
* The current request's view. Automatically guessed |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Large desktop */ | |
@media (min-width: 1200px) { | |
} | |
/* Portrait tablet to landscape and desktop */ | |
@media (min-width: 768px) and (max-width: 979px) { | |
} | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var map; | |
var andrecosta = new google.maps.LatLng(41.151217,-8.675815); | |
var MY_MAPTYPE_ID = 'custom_style'; | |
function initializeMap() { | |
var featureOpts = [ | |
{ | |
featureType: 'all', | |
elementType: 'all', | |
stylers: [ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php if(!defined("BASEPATH")){ exit("No direct script access allowed"); } | |
/** | |
* Multi-Upload | |
* | |
* Extends CodeIgniters native Upload class to add support for multiple | |
* uploads. | |
* | |
* @package CodeIgniter | |
* @subpackage Libraries |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); | |
class Project extends CI_Controller { | |
public function __construct() | |
{ | |
parent::__construct(); | |
require_once APPPATH . 'presenters/project_presenter.php'; | |
$this->data['project_ptr'] = new project_presenter(); | |
$this->load->model('project_model', 'project'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); | |
class Feed extends CI_Controller { | |
function __construct() { | |
parent::__construct(); | |
// load dependencies | |
$this->load->model('admin/articles_model', 'article'); | |
$this->load->helper('xml'); | |
$this->load->helper('text'); |
NewerOlder