Skip to content

Instantly share code, notes, and snippets.

View mrrens1107's full-sized avatar

Rendra Saputra mrrens1107

  • Web & Mobile Dev
  • Banjarmasin
View GitHub Profile
@eduardoflorence
eduardoflorence / main.dart
Last active May 7, 2025 06:21
Getx - Sample Form
import 'package:flutter/material.dart';
import 'package:get/get.dart';
void main() {
runApp(GetMaterialApp(
initialRoute: '/login',
getPages: [
GetPage(
name: '/login',
page: () => LoginPage(),
@yesnik
yesnik / active_record.md
Last active November 1, 2024 14:49
Yii 1 Framework Cookbook

CActiveRecord methods

findAll()

Sort records

// Ascending order
Partner::model()->findAll(array('order' => 'company'));
@mul14
mul14 / 00_etc-hosts.md
Last active November 18, 2025 07:42
/etc/hosts for Vimeo, Reddit, Imgur, GitHub, DigitalOcean, dll

Unblock Steam, Vimeo, Reddit, Imgur, GitHub, DigitalOcean, NPM, PayPal, dll

Saya support Internet Positif untuk memblokir porn, situs judi, dan hal-hal ilegal lainnya. Tapi pemerintah dan ISP sangat konyol karena tidak mengizinkan akses ke Vimeo, Reddit, Imgur, Netflix--yang mana bukanlah situs dengan konten utama ilegal.

Linux / BSD / macOS

Tambahkan list di bawah ke /etc/hosts.

Windows

@bgallagh3r
bgallagh3r / DatabaseSeeder.php
Created January 30, 2014 04:07
Disable Foreign Key Constraints when Seeding DB with Artisan Migrate/DB Seed This prevents SQL from throwing errors when you try to do DB::table()->truncate() as TRUNCATE is disallowed when FK constraints are in place.
class DatabaseSeeder extends Seeder {
/**
* Run the database seeds.
*
* @return void
*/
public function run()
{
Eloquent::unguard();
@egulhan
egulhan / ajaxBtnInCButtonCol.php
Last active May 29, 2021 01:26
Usage of ajax button in CButtonColumn in Yii Framework.
<?php
...
array(
'class'=>'CButtonColumn',
'template'=>'{confirm}{delete}',
//'template'=>'{confirm}',
'deleteButtonUrl'=>'Yii::app()->createUrl("/account/disabledAccounts",array("op"=>"delete","id"=>$data["id"]))',
'deleteButtonLabel'=>Yii::t('common','Cancel request'),
'deleteConfirmation'=>Yii::t('warnings','The account will be accessable by this operation. Are you sure you want to do this?'),