Live Betting Exchange Platform

I’m building a customised betting-exchange need betfair samr volume where users can place their own bets and watch odds refresh in real time, just as they would on a professional trading terminal. The… (Budget: ₹37500 – ₹75000 INR, Jobs: API, API Development, Backend Development, Database Management, Frontend Development, JavaScript, MySQL, PHP, Software Architecture, Web Development)

Read more here:: https://www.freelancer.com/projects/api-developmet/Live-Betting-Exchange-Platform.html

      

Complete frontend and backend migration of base44 app (database Superbase)

Looking for someone who has previouly migrated base44 apps to Migrate my base44 app (front and back end) to my local server . MIgration of database to Supabase Let me know your planned approach and… (Budget: $30 – $250 USD, Jobs: API Development, Backend Development, Cloud Computing, Database Administration, Database Management, Database Programming, Frontend Development, MySQL, PHP, Supabase)

Read more here:: https://www.freelancer.com/projects/backend-development/Complete-frontend-backend-migration-base.html

      

Launch React-WordPress Site & Chatbot

The site is already sitting in GitHub on a React template, backed by WordPress for content and automated through n8n. Design, graphics, page structure, and most links are in place; we are roughly 75 % done… (Budget: $250 – $750 AUD, Jobs: Chatbot, HTML, n8n, PHP, Web Design, Web Development, Website Design, WordPress)

Read more here:: https://www.freelancer.com/projects/chatbot/Launch-React-WordPress-Site-Chatbot.html

      

Cleaning Service App & Dashboard

I want to give Luminous Cleaning Singapore customers the same smooth, on-demand feeling they get from Uber, wrapped in a professional, clean interface that matches our brand. Phase 1 focuses on a customer-facing… (Budget: $1500 – $3000 SGD, Jobs: Android, Android App Development, API Development, iOS Development, iPhone, Mobile App Development, PHP, Web Development)

Read more here:: https://www.freelancer.com/projects/web-development/Cleaning-Service-App-Dashboard.html

      

Long-Term Support Partnership

I need a reliable freelancer I can turn to week after week for a variety of small-to-medium tasks. The exact mix will shift over time—some months we may focus on fresh content, graphics, or social scheduling;… (Budget: $25 – $50 USD, Jobs: App Development, Content Creation, Content Marketing, Graphic Design, Mobile App Development, PHP, Project Management, Social Media Management, Website Design, Website Development)

Read more here:: https://www.freelancer.com/projects/content-creation/Long-Term-Support-Partnership.html

      

Instalando Laravel Framework

laravelLaravel utiliza o composer para gerenciar suas dependências. Então, antes de usar o Laravel, você precisa ter o composer instalado em sua máquina. Caso não tenha veja como fazer a instalação neste post anterior: Instalando Composer

 

1. Baixe o instalador do laravel via composer

php composer.phar global require "laravel/installer=~1.1"

 

2. Criar projeto

php composer.phar create-project laravel/laravel phpConference 4.2 --prefer-dist

 

3. Configurar ambiente laravel

Nesses arquivos você poderá configurar a URL para os diferentes ambientes como também o local, timezone, chave para criptografia, entre outros.

Produção:

phpConference/app/config/app.php

Local:

phpConference/app/config/local/app.php

 

4. Permitir escrita ao servidor web para o seguinte diretório:

phpConference/app/storage

 

Requisitos:

PHP >= 5.4
Extensão PHP MCrypt
Modulo apache mod_rewrite

Referência: http://laravel.com/docs/4.2

Instalando Composer

composer
Composer: ferramenta para gerenciamento de dependências em PHP. Ele permite que você declare as bibliotecas dependentes que seu projeto precisa e vai instalá-los.

Pré-Requisito: versão minima do PHP 5.3.2.

Para instalar a última versão do composer digite a seguinte linha no terminal do Linux/Unix/OSX.

Instalação via cURL:

curl -sS https://getcomposer.org/installer | php

Ou instalação via PHP:

php -r "readfile('https://getcomposer.org/installer');" | php

 

Referencia: https://getcomposer.org/doc/00-intro.md

Instalando PHPUnit no Windows com XAMPP

Partindo do principio de que o XAMPP já está instalado e configurado abra o painel de controle do XAMPP (XAMPP Control Panel) e clique no botão Shell.

Painel de controle do XAMPP
Painel de controle do XAMPP

 

 

 

 

 

 

 

 

 

Quando abrir o terminal/prompt de comando digite os seguintes comandos:

pear config-set auto_discover 1
pear install pear.phpunit.de/PHPUnit
pear install phpunit/PHPUnit_SkeletonGenerator

Pronto ao final destes três comandos deverá retornar a mensagem: install ok

Para verificar se o PHPUnit está executando e qual a versão digite o comando abaixo:

phpunit --version

 

Agora você já pode começar a escrever seus testes.

Somar dias em uma data

/**
 * função pra somar dias em uma data
 * @param string $date formato YYYY-MM-DD
 * @param integer $dias quandidade de dias que deseja somar
 * @param string $tipo formato do retorno
 * @return string
 */
function SomaDiasData($date, $dias, $tipo) { 
	if ($date != '') {
		$sel_dia  = substr($date, 8, 2); # retorna dia
		$sel_mes  = substr($date, 5, 2); # retorna mes	
		$sel_ano  = substr($date, 0, 4); # retorna ano

		//$result	= $sel_dia."/".$sel_mes;
		$result	= date($tipo, mktime(12, 0, 0, $sel_mes, $sel_dia + $dias, $sel_ano));

	} else {
		$result = "";
	}
	return $result; 
    }