Sunday 30 August 2015

Curcol di hari minggu

Hari ini gw churching and i see there are woman using hijab sit at corner with her boss and the kids, hal itu yang buat sebagian orang bertanya-tanya dan sempat melihat seperti ada malaikat but who's care karena pandangan itu berubah ketika acara anak sekolah minggu pindah ke lantai 2 dan dia juga ikut ke lantai dua,

dari hal di atas bisa saya simpulkan, dia adalah seorang pekerja dari anak yang di temani dan setelah mengamati ternyata boss nya adalah orang yang punya dari segi tampilan kn bisa kita simpulkan ya then you know what ? there is something in my mind need to disscuss, jadi ke tepok bapak sebelah ku

Me        : Pak, coba tengok deh that woman using hijab, what do you think ?
Temen  : ah biasa aja selama tidak fanatik ya tidak apa-apa ?
Me        : oh iya, maksud nya bukan itu point nya, maksud nya begini itu kan ikut boss nya jadi secara                 tidak langsung si boss itu memaksakan kehendak bahwa si perempuan itu harus kenal                           Tuhan Yesus !
Temen  : hmmm ya tidak apa-apa kan dia mau ikut, gak mungkin jadi boss maksa kn dia bisa nolak,                   nah kehadiran dia disini adalah bukti bahwa dia mau ?
Me        : Oke (Senyum Sinis, belum puas dapat jawaban yang pas)


Well based on the story above ntah kenapa itu jadi bahan gw untuk berpikir bahwaas Christian boleh gak seperti itu tapi ntah lah dilain sisi ada saja pikiran buruk dalam diri ane bahwa kita tidak bisa mengajak pekerja untuk ikut ke gereja no matter how rich we are, karena apa permintaan boss itu tidak akan sopan jika di tolak oleh anak buah so rasa di situ ada sedikit unsur paksaan but it's oke as long never hurt her lah intinya.

Selamat hari minggu dan Tuhan Yesus memberkati.


Salam Lappet :v

Friday 28 August 2015

MULTIPLE DELETE IMAGES IN FOLDER ALSO IN DATABASE

Tutorial about delete multiple images in folder also in database, let's quick

Here is Controller

 public function hapus($tes_id)  
   {  
   $images= $this->db->query("SELECT * FROM `testimonial` tes_id='$tes_id'")->row_array();  
    $image=$images['tes_image'];  
   $image1=$images['testi_img1'];  
   $image2=$images['testi_img2'];  
   $image3=$images['testi_img3'];  
   $image4=$images['testi_img4'];  
   $image5=$images['testi_img5'];  
   $image6=$images['testi_img6'];  
   $image7=$images['testi_photo'];  
   $image8=$images['tes_beforeafter'];  
    $file = array($image,$image1,$image2,$image3,$image4,$image5,$image6,$image7,$image8);  
   $arrlength = count($file);  
  for($x = 0; $x < $arrlength; $x++) {  
  unlink('uploads/testimoni/' . $file[$x]);  
  }  
  $this->testimoni_model->hapus($tes_id);//  
  redirect ('admin/testimonial');   
 }  

Here is Model
 function hapus($tes_id)  
 {  
  $this->db->where('tes_id',$tes_id);  
  $this->db->delete('testimonial');  
 }   

Thanks for visiting me, hope this help your projects !

Regards !

Tuesday 18 August 2015

Simple Routing In Codeignter with example

Hi this is my short documentation about routing in codeignter

This is my router.php change as you needed
 /*router for front end artikel*/  
 $route['trend'] = 'welcome/trend';  
 $route['studikasus'] = 'welcome/studikasus';  
 $route['berita'] = 'welcome/berita';  

as you can see i just only one controller which is Welcome.php so here is my controller


and this is view welcome_mesagge.php
 load->view('welcome_message');  
  }  
 public function trend()  
  {  
  echo "studikasus";  
  }  
 public function studikasus()  
  {  
  echo "studikasus";  
  }  
 public function berita()  
  {  
  echo "berita";  
  }  
 }  

All you can need to understand is here


 $route['trend'] = 'welcome/trend'; //trend is calling from view then codeignter will direct to welcome/trend  
Thanks for visiting me,

Tuesday 11 August 2015

Berdoa bisa mengubah segalanya Tong

Akhir-akhir ini ntah kenapa sulit untuk ngucap syukur bro ? gw inget beberapa waktu yang lalu makan malam dengan teman seh dan gak tahu apa yang buat gw tersentuh i see he was praying before eat ? ntah kenapa hal itu buat gw tersentuh kapan terakhir ngucap syukur atas apa yang udah di kasih Tuhan.

Ada perbedaan malam ini sewaktu makan, dia tampak menikmati makan nya bro ntah kenapa enak banget liat dia makan nah gw kok biasa aja, mungkin benar sesuatu yang di dasari dengan syukur akan terlihat beda dengan yang lain, ada tangan Tuhan yang menambhakan cita rasa di makanan itu.

Terakhir ge berdoa sewaktu cari kerjaan and you know what masa-masa penganggurang yang di iringi dengan doa itu terasa enteng bro walau emak udah kayak artis rock and roll tiap hari nyuruh cari kerjaan tapi bener aja itu lebih enteng.

Jujur aja deh i'm trying to force my self to pray something worth in my life ? pasti nebak nya masalah jodoh, hahahaha. itu mah salah satu nya bro but bible said

"Masuk dalam Kamar dan Berdoa lah"



Well selama ini gw gak ngerasa ada hal-hal yang Tuhan sudah kasih dalam hiduo gw dimana dulu ada point-point dimana gw lagi on-fire dengan Tuhan (Cie lah bahasa nya udah kayak pendeta mau sidang)., Serius deh gw gak ngerasa How Great our God.


1. Berdoa adalah Nafas Orang Percaya

Mungkin case di atas yang ane ceritakan itu bisa jadi bukti bahwa dengan doa itu kita tampak berbeda, dengan berdoa hati jadi tenang bro gak gusar kalau kata mamak gw lalap holan heppot dengan bahasa internasionalnya !


2. Doa mengubah Segalanya (Ngomong ya kalau udah muntah karena bahasanya)

Jelas and i feel it too, dengan doa kita terlihat exciting and read again my story above ya bro. Sebejat-bejatnya orang pasti pernah ngerasain kalau dia pernah kosong and to pray to God, pernah gw berdoa (bukan tentang jodoh ) di pagi hari dan tahu gw serasa orang yang seger banget bro udah kayak sarapan makanan yang paling mahal, dan berasa kalau ada yang ngajakin lari keliling jakarta gw siap.

cuma akhir-akhir setahun belakang ini susah buat ucap syukur, atau faktor susahnya nyari cewek ya, wkwkwkwkwkwkwwkwkwwkwkwkw

Karena faktor punya cewek juga kn yang mempangaruhi tingkat Keimanan kita, lol. ignore it gak lah masa karena masalah sepele itu yang sebab kan susah berdoa,


Masih belajar cara berdoa dengan hati tulus tanpa ada nego dengan Tuhan,


Thanks for reading ya,

Monday 10 August 2015

How to save link in variable using codeignter

Hello this morning i will give short tutorial when you want to echo same href in your file.php i use codiegnter by the way, so here is my simple tutorial to make some href in echo


num_rows() < 3)
{
 echo "Tambah Data";
}
else
{
 echo "Tambah Data"; 
}
?>



Thanks for visiting me !


Friday 7 August 2015

PREVENT BACK BUTTON AFTER LOGOUT USING CODIEGNTER

Hello i found my problem in my project and then solved, so i posted here hope someone will help from this post i found this easy tutorial here

 So i reblog in here First create this name it sukasukalo_helper.php and then put in your helper

output->set_header('Last-Modified: ' . gmdate("D, d M Y H:i:s") . ' GMT');
  $CI->output->set_header('Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0');
  $CI->output->set_header('Pragma: no-cache');
  $CI->output->set_header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
 }

then go to your config/autoload.php load it by autoload so you will not wasting time load many time


$autoload['helper'] = array('sukasukalo');

then put it in every function in your controller to prevent back after users log out

{ 
  //here calling the function in helper
  backButtonHandle();
  //to make your web secure put this check session, if session empty will throw to default controller
  if (($this->session->userdata('nama')=="")  and ($this->session->userdata('username')=="")) {
   redirect('welcome');
  }
  //it's just my simple project setting as you need i
  $name = $this->session->userdata('name');
  $data['name'] = $this->model_user->login($name)->row_array();
  $data['dataarticle'] = $this->model_article->all();
  $this->admin->load('template','admin-article',$data);
 }

If you feel this helpfull please share and if you any another way to make more secure and efisien just feel free to disccuss here Thanks for visitng me !

Monday 3 August 2015

Close Current Page using Javascript

Hi all this is my first tutorial in august, quick tutorial you read that title if you familiar with coding you know it ! let say you have page index.html and you need that to be close without click close button from browser but need click a link in your page so here is the code give it name index.html and bellow the code !

 
 Here is close tab with javascript
 

 
  Close the page
 


Thanks for visiting me !

Saturday 1 August 2015

REMOVE FOLDER PUBLIC IN LARAVEL

Hi this is my second post about LARAVEL just learn new things feel bored with same activity coding over and over so i try lear new thing.

For people new in laravel will feel stuck at the first time while developing projects but that's a normal every new hard, After you success download laravel in your localhost, follow my instruction

Create a folder locale inside your directory then copy all file from laravel and paste to inside folder locale



Cut all file inside public then paste out side folder locale



  1. Go to index.php came from public which has move then find this script 



and change to be like this
This explanantion caming from this url http://stackoverflow.com/questions/28364496/laravel-5-remove-public-from-url Thanks for visiting me ! if you have some question about laravel feel free to drop message or email me, cheers !