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
1. Install Apache | |
sudo yum update httpd | |
sudo yum install httpd | |
sudo firewall-cmd --permanent --add-service=http | |
sudo firewall-cmd --permanent --add-service=https | |
sudo firewall-cmd --reload | |
sudo systemctl start httpd | |
sudo systemctl status httpd | |
2. Virtual Hosts |
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/sh | |
xrandr --output HDMI-1 --off --output DP-1 --mode 1366x768 --pos 1366x0 --rotate normal --output eDP-1 --primary --mode 1366x768 --pos 0x0 --rotate normal |
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\Providers; | |
use Illuminate\Foundation\AliasLoader; | |
use Illuminate\Support\ServiceProvider; | |
class AppServiceProvider extends ServiceProvider | |
{ | |
/** |
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
html2element: function(html) { | |
var $template, attributes = {}, | |
template = html; | |
$template = $(template(this.model.toJSON()).trim()); | |
if($template.get(0)) | |
{ | |
_.each($template.get(0).attributes, function(attr) { | |
attributes[attr.name] = attr.value | |
})}; |
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
// transpose it | |
// @param Array values Array multidimension one row | |
// @Result Array | |
function transpose(values){ | |
return Object.keys(values[0]).map( function (columnNumber) { | |
return values.map( function (row) { | |
return row[columnNumber]; | |
}); | |
}); |
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 | |
// FOCUS pada fungsi register() | |
namespace App\Http\Controllers\Auth; | |
use App\User; | |
use Validator; | |
use Illuminate\Http\Request; | |
use App\Http\Controllers\Controller; |
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 | |
class CatalogController extends Controller | |
{ | |
public function catalogLists() | |
{ | |
$subcatids = implode(',', $this->subcategoryIds()); | |
$subcategories = \App\Subcategory::whereIn('subcatid', $this->subcategoryIds()) | |
->orderByRaw("FIELD(subcatid, $subcatids)") | |
->get(); |
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 | |
protected $middlewareGroups = [ | |
'web' => [ | |
\App\Http\Middleware\EncryptCookies::class, | |
\Illuminate\Cookie\Middleware\AddQueuedCookiesToResponse::class, | |
\Illuminate\Session\Middleware\StartSession::class, | |
\App\Http\Middleware\LanguageMiddleware::class, | |
\Illuminate\View\Middleware\ShareErrorsFromSession::class, | |
\App\Http\Middleware\VerifyCsrfToken::class, |
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=""> | |
<head> | |
<meta charset="utf-8"> | |
<meta http-equiv="X-UA-Compatible" content="IE=edge"> | |
<meta name="viewport" content="width=device-width, initial-scale=1"> | |
<title>huiralb | home</title> | |
<!-- Bootstrap CSS --> | |
<link href="http://netdna.bootstrapcdn.com/bootstrap/3.1.1/css/bootstrap.min.css" rel="stylesheet"> |