- Buka Notepad++/dreamweaver/script editor lainnya
- tag Pembuka php di mulai dengan <?php
- tag penutup di akhiri dengan ?>
- nama file di akhiri dengan .php
- contoh : file1.php
<?php
tempat mengetik kode- kode
?>
6. Satu baris kode php di tutup dengan tanda titik koma ( ; )
7. Penempatan kode-kode php ada 2 cara
1.di dalam file php
2.di dalam file html
- Menjalankan Web Server :
Start =>program=>xampp for windows =>xampp control panel =>klik star pada baris apache
- Direktori kerja : tempat menyimpan file-file html/php,gambar,video,dll
- Membuat direktori kerja
- Buka C:\xampp\htdocs(dengan windows explorer)
- klik file =>klik new=>klik folder
- beri nama dengan format: latihan
- enter
Direktori kerja : C\xampp\htdocs(document root)
http//localhost/=>C:\xampp\htdocs
C:\xampp\latihan => http://localhost//latihan
Tidak ada komentar:
Posting Komentar