Thursday, December 22, 2011

Solusi Menghindari Error Division By Zero

Seringkali ketika kita membuat perhitungan untuk mendapatkan nilai dari sebuah prosentasi kita menggunakan rumus (totalnilai/jumlah)*100. Jika totalnilai atau jumlah lebih dari nol mungkin tidak menjadi masalah, namun terkadang jika isi dari variabel totalnilai atau jumlah bernilai nol akan menimbulkan pesan error Warning: Division by zero in dikarenakan pembagiannya bernilai nol. Lalu bagaimana mengatasinya? Kita bisa menggunakan kondisi untuk mengecek apakah nilai nol atau tidak, jika nol maka dipaksakan hasil akhirnya adalah nol.
Contoh :
$rata=($totalnilai!=0)?($totalnilai/$jumlah) * 100:0;
dengan menggunakan perintah if ternary di atas jika nilai $totalnilai berisi nol, maka perintah pembagian ($totalnilai/$jumlah) tidak dijalankan dan nilai variabel $rata=0;
semoga bermanfaat

Wednesday, December 21, 2011

Cara Menampilkan Super Hidden akibat virus melalui CMD

untuk melakukan hal tersebut sebernarnya kita dapat menggunakan program bawaan Windows yaitu Command Prompt (cmd) dengan menggunakan sedikit script yang tidak terlalu sulit untuk dipelajari jika kita ada kemauan.
  • buka cmd melalui run (Winlogo+R) ketik cmd atau Start»AllPrograms»Accessoris»Command Prompt
  • Setelah itu, pilih drive yang file²nya telah ter-superhidden, misalkan ada pada drive F, ketik f: kemudian enter
  • kemudian ketik attrib -s -h -r *.* /s /d dan tunggu untuk beberapa saat (kursor kedap-kedip) hingga muncul drive F kembali
  • kemudian coba Anda buka drive atau folder yang file² nya tidak nampak kemudian refresh
  • ajaib file² yang ter-superhidden telah kembali seperti semula

Monday, December 12, 2011

Internal error 2738

Saat install program dan dapat error berikut ini:
Internal Error 2738
Untuk Mengatasinya Maka lakukan langkah berikut ini:
1. Click Start > Run
2. ketik “regsvr32 vbscript.dll” (tanpa tanda petik)
Setelah dll nya teregister maka silakan install programnya lagi.

Monday, December 5, 2011

DAFTAR 43 HOSTING GRATIS TERBAIK DAN TERPOPULER

Pada postingan kali ini, saya mencoba untuk share kepada pengunjung setia 1001script tentang 43 hosting gratisan yang bisa anda gunakan untuk mencoba mengonlinekan situs anda atau hanya sekedar meringankan beban situs anda. free web hosting ( hosting gratis an ) yang bisa kita gunakan untuk belajar membuat website , free web hosting / hosting gratis ini mempunyai banyak fitur,  juga berbeda – beda spesifikasinya,  jadi anda harus pandai – pandai memilih free web hosting / hosting gratis yang sesuai dengan kebutuhan, daftar free web hosting / hosting gratis tersebut diantaranya :

Thursday, October 13, 2011

Tips membuat aplikasi Visual Basic lebih cepat

Berikut ini adalah cara- cara membuat hasil program berjalan lebih cepat.
1. gunakan len(text)=0 daripada menggunakan text = ””
2. gunakan string function dengan menggunakan $ diakhir nama function
3. gunakan operator * dibandingkan operator ^
4. gunakan Asc(text) dibandingkan Left$(text,1)
5. gunakan image dibanding picture
6. gunakan intrinsik control dibandingkan control dari luar
7. jangan gunakan tipe data variant
8. gunakan byVal dibanding byRef
9. saat menggunakan banyak kontrol grafis seperti line, circle, point set properti ClipControls menjadi false
Sumber dari buku Programming Microsoft Visual Basic.
Semoga bermafaat.

Tuesday, September 20, 2011

Xampp Apache Tidak Bisa Start

Siapa yang tak tahu xampp? Software paket-an ini memang paling populer. Selain penggunaannya yang kompleks, semua paket bisa terintegrasi dengan software pendukungnya. Disini, saya berbagi kisah tentang apache yang tidak bisa start saat melakukan penginstalan. Ada beberapa hal yang bisa menyebabkan hal. Dan saya menemukan 2 solusi untuk menyelesaikan masalah itu :
Yang pertama, penyebab paling umum, adalah bahwa beberapa aplikasi lain yang menggunakan port 80 pada PC Anda. Dan disini saya menemukan masalah pada Skype. Jika Anda membuka Skype, dan lihat menu Tools-> Options ... dan klik pada 'Advanced' kemudian 'connection', periksa apakah menggunakan port 80 dan 443 sebagai alternatif untuk opsi koneksi masuk' dicentang. Jika demikian, hapus centang, dan pastikan nomor port di dalam kotak di atas tidak 80.

Atau anda bisa mencoba melihat semua port yang aktif melalui menu 'Commant Prompt' dengan mengetikkan :
netstat -a –no
Kemudian tekan enter. Carilah 127.0.0.1:80 atau 192.168.1.100:80. Jika Anda dapat melihat salah satu, sangat mungkin bahwa lain proses yang menggunakan port 80. Catat nilai pada kolom PID (Process ID). Kemudian ketik berikut di 'Command Prompt' :

tasklist
Dan tekan enter. Anda kemudian harus mampu mencocokkan dengan PID file eksekusi yang menggunakan port tersebut. Mungkin jelas dari nama file yang menyebabkan aplikasi. Atau anda juga bisa langsung memberhentikan program itu langsung melalui task manager, tapi resiko ditanggun sendiri yah! hehehe...
Oia, download juga versi terbaru XAMPP 1.7.4, supaya tidak ketinggalan, download aja langsung dari http://www.apachefriends.org/en/xampp-windows.html

Tuesday, June 21, 2011

Adding Syntax Highlighting to Blogger

(Note: This article is somewhat dated because SyntaxHighlighter 2.0 was released in February 2009.  However, this article is still valid for those who prefer the older 1.5.x version or who don't want to upgrade)

As we all know, any self-respecting blogger needs some kind of syntax-highlighting plug-in before posting source code on a blog. I've been amiss in this regard, but decided it was high time to correct this particular deficiency.

go back history dengan javascript di ASP.Net MVC 3

pusing setengah hari google dan tanya forum untuk mencari perintah go back di ASP .Net MVC3,
eh ternyata ni dia scriptnya: capekkk....

@Html.Raw("Back")

Monday, June 13, 2011

Remove Joomla! is Free Software released under the GNU/GPL License.

To change or remove the "Joomla! is Free Software released under the GNU/GPL License." links from the joomla administration area we need to edit 3 files:
administrator/templates/khepri/cpanel.php
administrator/templates/khepri/index.php
administrator/templates/khepri/login.php

Thursday, May 26, 2011

How To Change and Make Writing Copyright in Joomla

Copyright writing is usually located on the footer or the bottom of a site. If you are still using the default template provided by the joomla, then the default standard joomla copyright writing is usually like this.
Powered by Joomla!. valid XHTML and CSS.
To replace and modify to your liking, the steps are as follows:
Log into your Joomla Administrator page.
Select menu extensions >>> template manager .
Select and tick the check box template you use. Then click Edit .
Click edit HTML , then you will go to the Template page HTML Editor.
Then try to find the following code. (How to find a brief press shortcut: alt + f and enter text below)
id = "power_by"

Monday, May 16, 2011

Remove "Powered by Phoca Gallery" Text

Phoca Gallery is a fantastic open source extension for Joomla. It is a full featured photo gallery that is fairly easy to use. Phoca Gallery is open source GPL. By default Phoca Gallery puts a "Powered by Phoca Gallery" copyright line in the footer of every Phoca page. If it's your own website you might not mind giving credit to the developer as they deserve then it might be ok but when I've used it on a client website I have always been asked to remove it as it does look unprofessional. If you are going to remove it I would also suggest making a donation to Phoca Gallery as I have. This method shows how to remove the copyright from the 2.7.6 version of Phoca Gallery.
Youll need to install Phoca Gallery and navigate to your website folders via FTP...
1. Open the file administrator\components\com_phocagallery\front\views\category\view.html.php
Search for the long string around line 165 that begins with

Remove Powered by Phoca Guestbook

Best on My experience in developing websites with Joomla CMS some time ago that requires using the guestbook makes me have to find a suitable component guestbook. After a few components that I try so I made sure to use the Phoca Guestbook, but the results are less satisfactory because of the persistence of the words “Powered By Phoca Guestbook“, I do not miss going to Remove Powered By Phoca Guestbook for Phoca Guestbooks look more attractive.
Pocha Guestbook is the product of Pocha.cz, is one of the joomla component that serves to increase the Guestbook facility on the web that use Joomla CMS.

Thursday, May 12, 2011

How To Remove Help Menu From Joomla Administrator's Menu

The First Thing to do this is:
Just go to the folder ...administrator >> modules >>mod_menu

Second thing :

Modify the file 'Helper.php'

For e.g. If you want to delete the 'Help Menu'
Go to /* Help SubMenu */ section of Helper.php file
Delete the text -->'Help'
$menu->addChild(new JMenuNode(JText::_('')), true);

This will hide Help Menu....

You can also change links, text...
For e.g.

$menu->addChild(new JMenuNode(JText::_('Your text'), 'http://www.anysite.com', 'class:help'));


I hope that these "tricks" help you along the way.....

Tuesday, April 12, 2011

Moodle Installation Tutorial

  1. Download and Extract the files MoodleWindowsInstaller-latest-20.zip
  2. Open the folder that has been in the extract, then open the folder moodle server and copy the folder to your xampp htdocs folder
  3. Then open your web browser and run http://localhost/moodle
  4. In step 1 and 2 click next
  5. Step 3, complete filling Database Settings and click next
  6. Step 4, 5 and 6, click continue
  7. Step 7, the complete filling main admin moodle data that you created, then click Update Profile
  8. Step 8, the complete charging data to the main page of the website, then click Save Changes
  9. Moodle Install process finished

Monday, April 11, 2011

Install Package ASP .Net 2010 with Console

gimana cara install package ASP .Net 2010 dengan console ternyata mudah:
PM > Install-Package [nama package]
contoh: PM> Install-Package EntityFramework
tunggu deh, sampai muncul konfirmasi
Successfully installed 'EntityFramework 4.1.10311.0'
Successfully added 'EntityFramework 4.1.10311.0' to [nama projek]

Friday, April 8, 2011

MVC

Model-View-Controller or MVC is a method to create an application with separate data (Model) from the view (View) and the way how to process it (Controller). In most implementation framework in the application site is based on MVC architecture. MVC separates the application development based on the major components that build an application such as data manipulation, user interface, and part of a control in a web application.
Part of the MVC