Showing posts with label tutorial. Show all posts
Showing posts with label tutorial. Show all posts

Sunday, March 20, 2011

Remove duplicate values in array and reindexing - php.



You have an array that contain duplicates value, but you don't want any duplication. The best way to remove duplicates value in array is by used array_unique() function. Let say you have an array $your_array;

$your_array = Array ( [0] => 2 [1] => 4 [2] => 4 [3] => 4 [4] => 5 [5] => 6)

In that array, element in index 1,2 and 3 have same value which is 4. You want to remove this duplicate values. You need to used array_unique().
array_unique($your_array);
array_unique() only remove duplicates value but the index of array is maintain. Your array will be like this;
Array ( [0] => 2 [1] => 4 [4] => 5 [5] => 6 )
You need to reset the index in array. To reset the index, you need to use foreach() function.
Before that, you need to create a variable that hold a value to represent the new index in array. Let say the variable is;

$new_index=0;
$new_index will be used in foreach() function. This value will be increased and replaced with the index value of array.
$new_index=0;
foreach($your_array as $key=>$value){
    $your_array_new[$new_index]=$value;
    $new_index++;
}//foreach


This will reset the index in array. Your array will be like this;
Array ( [0] => 2 [1] => 4 [2] => 5 [3] => 6 )

Wednesday, July 22, 2009

Run java Netbeans using Command Prompt


For two days i has been search how to run a program written in java language by using Command Prompt. Below is the tutorial about how to that....

1) create a directory with src\ and tests\ in it (the tests is optional if you are not using JUnit).

2) assuming you have "package myjava;" at the top of your files (and make sure that this is what your prof wants, it becomes a pain to mark things if they are not in the right place), make a src\myjava directory (and if you are doing junit a tests\myjava directory).


3) copy your files into the src\myjava directory


4) delete your NetBeans project and recreate it as a new on with exising sources. When you are setting up the src (and optional test) directories add the src\ (and optionally the tests) directory. DO NOT add the src\myjava directory or it won't work in NetBeans.


5) make a directory called classes\ (so you you have src\ classes\, and maybe \tests all in the same place)


6) on the command line type javac -d classes -cp classes src/myjava/*.java * -d tells the compiler where to put the .class files * -cp tells the compiler where to look for classfiles * src/myjava/*.java tells it to compile all of the .java files in src/myjava

7) run it via java -cp classes myjava.Main
* -cp classes tells it to look in the classes directory for the .class files * myjava.Main is the name of the class to run

Thursday, December 11, 2008

Macromedia FreeHand


Macromedia FreeHand is a computer application for creating two-dimensional vector graphics (use of geometrical primitives such as points, lines, curves, and polygons to represent images, also known as geometric modeling), oriented to the professional desktop publishing market. It is available in versions for Microsoft Windows and Mac OS X.

FreeHand is very similar in scope, intended market, and functionality to Adobe Illustrator. It was created by Altsys and licensed to Aldus, which released versions 1 to 4. When Aldus merged with Adobe Systems, because of the overlapping of market with Illustrator, Adobe returned FreeHand to Altsys soon after the merger (after some legal wrangling, and intervention by the Federal Trade Commission). Altsys was later bought by Macromedia, which released FreeHand 5.0, 5.5 (Mac only), 7, 8, 9, 10 and 11/MX. In 2005 Adobe acquired Macromedia, thus returning the FreeHand product to Adobe.

A flexible application, it is used for page layout (especially since version 4 which was based on Altsys Virtuoso for NeXTstep and had multi-page capabilities) as well as the creation and editing of vector graphic files for print and the Web.

Its current version, FreeHand 11, is marketed as FreeHand MX, which shows its integration with the Macromedia MX line of products, which also includes Macromedia Flash, Macromedia Dreamweaver and Macromedia Fireworks and more.

Below is the screen shot about Macromedia FreeHand.
Figure 1.

Figure 2

Here I've share tutorial about how to use Macromedia FreeHand. You can download and learn it. This tutorial is teach you step by step. Dummies also can learn from this tutorial.
Click download icon below to download this tutorial.
Click to download

source:http://en.wikipedia.org/wiki/Macromedia_FreeHand
tags: macromedia FreeHand, wikipedia, learn freehand, tutorial

Monday, September 15, 2008

Download from Rapidshare using Internet Download Manager(FDM) and Free Download Manager(FDM)


A lots of my friend ask me how to download from rapidshare using download manager.. Here I give you all simple tutorial using Internet Download Manager(FDM) and Free Download Manager(FDM) if you want to download from rapidshare.. It is a simple step. Dummies also can understand from this tutorial.

Using Internet Download Manager(FDM)
1. Open IDM and go to Download menu. From Download, choose Option. You can look like figure below.
2. After you choose Option, it will appear window Internet Download Manager Configuration. Choose tab Sites Logins. Like figure below.
3. After that, click to the New Button to enter the server,username and password configuation. You can look like picture below..


4. After you have enter it, you can download from rapidshare using IDM..



Using Free Download Manager(FDM)
1. Open FDM and go to Downloads menu. From Download menu, choose Create new download. Like figure below.

2.After that, it will appear Add Download window like figure below.


3.Then you click to User name and password required. After that, enter your username and password like figure below. Then you can proceed to download...



for me, i prefer use IDM rather used fmd...hope you got what i give to you.. happy download.. :) so that is simple step right.??if you have any question or anything to ask, pelase e-mail me or comment to this entry.

Monday, August 11, 2008

Avira AntiVir PersonalEdition Premium


This time I've share key AntiVir PersonalEdition Premium. This key is valid until 14/4/2014..You can download it with clicking download icon below.

Key License
Click to download
code:



Installer AntiVir PersonalEdition Premium
Avira web

Tutorial to install AntiVir PersonalEdition Premium
1. Double click the installer that you have download from avira site.
2. Install by clicking next-next-next..until you find like picture below



3. This meant it asking you for the key product. Click the HBEDV.KEY and point in to the KEY directory that you have been download before.
4. After that, you will notice that the license will working until 2014. Just look like picture below. I've install in my pc..


If for any reason this key someday will be blocked you can help you out with this link:

https://license.avira.com/en/promotion-t0q1aatr05zwftftgnqr

Go there and register using a fake username and fake email. The next screen will allow you to download the key (just click on the button to go to the next screen), and then click on small key icon to begin the download. It will be activated for 1 month. You can repeat this process every month. However till 2014 we are done with it ;-)

p.s. AVIRA AntiVir is the best antivirus today! 0-day threat detection! AntiVir is regularly awarded for its very high detection results.


Tuesday, July 22, 2008

How to off-line update AVG antivirus


This time i will teach you about the way to off-line update avg antivirus. Off line update mean you update you antivirus without the internet connection. You will do this if you pc not connect to the internet. Okay without wasting time you can read the simple tutorial below..

1. First you must download the updater from the avg web site. http://free.avg.com/ww.download-update
2. Below is the figure that show the file that you must download. You must download 4 file that is;
  • Windows: 8.0.138
  • Link Scanner DB: 8.0.49
  • AVI: 270.5.4
  • IAVI: / 1566

3. After you download that file, you must open AVG antivirus. From the menu, select Tools and choose the Update from directory...(like figure below)


4. After the, it will appear a windows that prompt you to choose folder that you save you updater/download. After that, click Ok.(figure below)


5. After you click Ok, the the AVG antivirus will tell you about the file that contain in the folder. Then you must click Update button to proceed the process update. (figure below)


6. Once you click the Update Button, the proses update is running. it shown in figure below.


7. After the proses of the installation successful, click the close button to end the process..like figure below.

8. After that, you anvtivirus is update..

Hope you enjoy the simple tutorial that i've made to you.. Thanks for visiting this site.. :).



Untuk manual cara-cara update avg secara offline/update avg secara manual, anda boleh memuat turun manual/panduan terus kedalam pc anda. anda boleh memuat turun dengan klik pada ikon download di bawah.

Klik untuk download

Friday, July 18, 2008

SERANGAN VIRUS : W32/Nyxem.e @ W32/Blackmal @ W32/MyWife


Virus ini akan menjalankan aksinya menghapus semua fail dengan sambungan (jenis fai) *.doc, *.xls, *.mdb, *.mde, *.ppt, *.pps, *.zip, *.rar, *.pdf dan *.psd pada 3hb setiap bulan. Oleh itu, biasakan untuk secara teratur melakukan Backup data-data penting anda dan simpan pada media yang terpisah seperti cdrom atau USB drive. Virus ini dibuat menggunakan program bahasa “Visual Basic” dan dimampatkan menggunakan UPX dengan ukuran fail sebesar 94 KB [setelah fail dikembangkan] atau 131 KB [jika belum dikembangkan]. Lebih kurang 30 minit selepas virus ini aktif, ia akan mencuba untuk menulis semula semua fail yang mempunyai sambungan di bawah ini dengan menambahkan text DATA Error [47 0F 94 93 F4 K5]":

1. -DOC
2. -XLS
3. -MDB
4. -MDE
5. -PPT
6. -PPS
7. -ZIP
8. -RAR
9. -PDF
10. -PSD
11. -DMP


Sekiranya anda menggunakan perisian antivirus Norton Antivirus, Kaspersky Lab atau Panda Software, virus ini akan menambahkan ikon antivirus tersebut pada Syatem Tray dengan memaparkan mesej "Update Please wait".

Jika komputer anda telah dijangkiti, sila ikuti langkah-langkah berikut untuk memulihkan kembali komputer anda dari serangan virus ini;

1.Download dan simpan fail FxBmalB.exe ke dalam cakera keras anda.
2.Putuskan sambungan ke internet.
3.Boot ke persekitaran Safe Mode (Tekan kekunci F8 semasa proses boot).
4.Cari fail NyahBmalB.exe menggunakan Windows Explorer atau My Computer, "Double-Click" pada fail tersebut untuk janakannya.
5.Klik pada butang Start dan tunggu hingga proses scan dan pembasmian selesai.
6.Buka Scheduled Tasks dan hapuskan semua kerja yang dibuat oleh virus ini.
7.Tutup semua program yang telah dibuka dan reboot komputer.
8.Sambungkan kembali talian internet.
9.Update perisian antivirus anda (PASTIKAN PERISIAN ANTIVIRUS ANDA SENTIASA DIKEMASKINI). Scan dan bersihkan komputer dari virus. Waspada selalu. Selamat Menangani Virus.

sumber:cict,utm..

Thursday, July 10, 2008

How to update Microsoft Office.



Here I've share tutorial how to update Microsoft Office. You can download it by simply clicking to the download icon below.. Gud Luck..

Click to download

Monday, June 16, 2008

Kamus Bahasa Melayu dalam Microsoft Office


Perisian ini adalah sebagai kamus yang tertanam di didalam microsoft office words apabila di pasang ke dalam komputer anda. Perisian ini amat berguna sekiranya kita hendak menulis laporan di dalam bahasa melayu. Ia akan memaparkan kesalahan ejaan dengan garisan merah di bawah kesalahan tersebut dan seterusnya membetulkan kesalahan itu. Anda boleh memuat turun perisian ini dengan klik pada gambar download di bawah.

p/s: perisian ini hanya berfungsi pada microsoft words 2003. Tetapi untuk menggunakan pada microsoft words 2007, anda hendaklah terlebih dahulu memasang microsoft words 2003 ke dalam komputer anda, kemudian memasang perisian ini. selepas itu, anda perlu membuang perisian microsoft words 2003, maka kamus ini boleh digunakan pada microsoft words 2007.

klik untuk download
Cara-cara untuk menggunakan perisian ini.

1. Buka perisian Microsoft Office 2007. Dan perhatikan pada bahagian bawah di sebelah kanan, anda akan mendapati penggunaan bahasa secara lalai (default) adalah di dalam English(USA). cuba anda taipkan satu perkataan di dalam bahasa melayu dan english. anda akan dapat perhatikan, perkataan di dalam bahasa melayu akan terdapat garisan di bawah, manakala pada English tidak terdapat garisan (ini menandakan bahawa bahasa yang dipilih adalah English.) contoh dapat dilihat pada rajah dibawah. (Klik pada rajah untuk paparan penuh dan besar).

klik untuk gambar jelas

2. Setelah itu,klik 2 kali(double click) pada perkataan English(U.S). Ini adalah untuk menukarkan penggunaan bahasa. Anda boleh melihat pada gambar di bawah. (Klik pada rajah untuk paparan penuh dan besar).

klik untuk gambar jelas

3. Akan muncul satu kekotak dialog yang meminta pemilihan bahasa seperti pada rajah di bawah. Anda perlu mencari Malay(Malaysia) untuk memilih penggunaan bahasa melayu. (Klik pada rajah untuk paparan penuh dan besar).
klik untuk gambar jelas

4. Setelah anda memilih Malay(Malaysia), maka anda telah memilih bahasa melayu dalam penulisan anda. Untuk mencuba fungsi ini menjadi atau tidak, cuba anda menulis kembali perkataan bahasa melayu yang anda tulis sebelum ini. Anda akan dapati tiada garisan merah seperti perkataan yang anda tulis tadi. Rajah di bawah menunjukkan perkataan yang telah saya tulis, dan ia menjadi. (Klik pada rajah untuk paparan penuh dan besar).

klik untuk gambar jelas

Di harap tutorial ini dapat membantu anda. Selamat mencuba dan gudLuck..

Thursday, June 12, 2008

Cara-cara nak buang virus New Folder.exe


tentu korang penah hadapai prob. mcm task manager takleh bukak, run takde kat start menu, folder option tetibe ilang and etc.. problems tu terjadi sebab pc korang telah kene virus new folder.exe.. virus tue mmg menyusahkan kite kalo pc kite kene virus tue. biasanye virus tue merebak melalui pendrive or external hard disk... org yang create virus nie akan menempelkan satu koding kat pendrive or external hard disk dalam file aurtorun.inc. so antivirus takleh nak buang sebab file autorun tu mmg file windows..

okes kat sini aku de sharekan satu software yang leh clean pc korang..die leh buang virus tue and mengembalikan pc seperti sediakala (bagi wujud balik run, taks manager and folder option). korang leh donwload software tu kat link bawah..


>download here<


okes skang aku nak ajar cara-cara nak guna software nie..

1.korang double klik kat file yang korang download tue..
2.pastu akan muncul la windows seperti rajah kat bawah..


3. Pastu klik kat button Yes.
4. Then akan muncul windows seperti rajah di bawah.


5. pastu korang klik pada butang Restore Windows Default Setting.. kemudian akan keluar seperti paparan rajah di bawah.


6. Selepas tu, tick pada semua kotak seperti rajah diatas. dan kemudian klik Ok.
7. selepas klik ok, akan keluar satu dialog box yang menyatakan proses telah berjaya seperti rajah di bawah.

8. kemudian tekan ok dan software tersebut akan memberitahu untuk restart balik pc seperti dalam rajah di bawah..


9. so pc korang telah kembali seperti sedia kala sebelum terkena virus tersebut...
diharap tutorial ini membantu anda dalam membuang virus tersebut..

Monday, May 26, 2008

Install Linux dalam USB Pendrive..


kena install linux tp xmau buang windows?
nak isntall linux just dalam pendrive jer?
anda boleh!
hehe

requirment:
1.pendrive >512mb,preferrably >1gb
2.donlod donlod


nak tau lebih lanjut?ha,tgk nie
[knoppix linux] 1gb
http://www.pendrivelinux.com/2007/01/01/usb-knoppix-510

[pxlinuxos] 512mb
http://www.pendrivelinux.com/2006/09/19/all-in-one-usb-pclinuxos-minimezip

cara nak format balik pendrive incase xberkenan
http://www.pendrivelinux.com/2007/07/19/restoring-your-usb-key-partition/

credit to azwan a.k.a wan ensem..





tags: linux, pendrive, install linux dalam pendrive,
knoppix linux, azwan, wan

Friday, May 23, 2008

cara-cara nak update avira secara manual



hmm..kali nie aku nak ajor care-care nak update antivirus avira secara manual..kepada sape-sape yang da teror tu, kalo nak bace,aku alu-alukan..this tutorial untuk org yang tak bape tau pasai komputer nie.. tutorial yang aku ajar nie takde ler susah ngat.simple je..lagipon cara nak update bukan nye susah pon..okes, kat sini aku sertakan fail dalam bentuk pdf. so korang leh la donload tutorial tu ek..pastu ikot step-step yang aku ajar tue..
okes..selamat mencube..

download manual -> download here
laman web avira- > http://www.avira.com/en/pages/index.php
link donload updater antivirus: -> download updater

tags- cara-cara update antivirus, manual update antivirus, avira, update avira, updater avira, antivirus
Related Posts Plugin for WordPress, Blogger...