gitflow | git |
---|---|
git flow init |
git init |
git commit --allow-empty -m "Initial commit" |
|
git checkout -b develop master |
This file contains 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
#!/bin/bash | |
# Customers | |
php aritsan import:customers | |
echo Customers Done | |
# Products | |
php aritsan import:products | |
echo Products Done | |
# Orders | |
counter=1 | |
while [ $counter -le 3 ] |
This file contains 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 namespace App\Controllers; | |
class Upload extends BaseController | |
{ | |
public function index() | |
{ | |
return view('upload_form'); | |
} | |
public function doupload() |
This file contains 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
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<title>Welcome to CodeIgniter 4!</title> | |
<meta name="description" content="The small framework with powerful features"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<link rel="shortcut icon" type="image/png" href="/favicon.ico"/> | |
<!-- STYLES --> |
This file contains 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 | |
defined('BASEPATH') OR exit('No direct script access allowed'); | |
//Location: application/controllers/Post.php | |
class Post extends CI_Controller { | |
public $perPage = 3; | |
public function index() | |
{ |
This file contains 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 | |
defined('BASEPATH') OR exit('No direct script access allowed'); | |
class Upload_Controller extends CI_Controller { | |
public function __construct() { | |
parent::__construct(); | |
$this->load->helper('url', 'form'); | |
} |
This file contains 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 | |
(PHP_SAPI !== 'cli' || isset($_SERVER['HTTP_USER_AGENT'])) && die('cli only'); | |
$baseDir = dirname(dirname(__FILE__)); | |
print $baseDir; | |
require_once($baseDir.'/app/Mage.php'); | |
umask(0); |
This file contains 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 | |
$product = Mage::getModel ( 'catalog/product' ); | |
$product_id = $product->getIdBySku ( $sku); | |
$product->load ( $product_id ); | |
/** | |
* BEGIN REMOVE EXISTING MEDIA GALLERY | |
*/ | |
$attributes = $product->getTypeInstance ()->getSetAttributes (); | |
if (isset ( $attributes ['media_gallery'] )) { |
This file contains 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 | |
$filePath = dirname(__FILE__).'/hq.png'; | |
$image = imagecreatefrompng($filePath); | |
$bg = imagecreatetruecolor(imagesx($image), imagesy($image)); | |
imagefill($bg, 0, 0, imagecolorallocate($bg, 255, 255, 255)); | |
imagealphablending($bg, TRUE); | |
imagecopy($bg, $image, 0, 0, 0, 0, imagesx($image), imagesy($image)); | |
imagedestroy($image); |
NewerOlder