Beranda | Obengkumana.Net
facebook twitter gplus
Breaking News
Loading...
Minggu, 30 Desember 2012

AhadPos

Ahadpos merupakan aplikasi opensource yg bisa kita pergunakan sebagai billing / aplikasi penjualan

langsung saja ke TKP
yg blm tau lighttpd, klik dimari n yg masih bingung PHP klik dimari

pacakages:
- lighttpd
- lighttpd-mod-cgi
- php5 dkk



instalasi;
dengan asumsi, "ahadpos" ditaruh di /srv/www/ahadpos

root@Obengkumana:~# mysql -u root -p
mysql> create database ahadpos;
mysql> use mysql;
mysql> INSERT INTO user (Host,User,Password) VALUES('%','ahadpos',PASSWORD('ahadpos'));
mysql> grant usage on *.* to ahadpos@localhost identified by 'ahadpos';
mysql> grant all privileges on *.* to ahadpos@localhost;
mysql> quit
root@Obengkumana:~# cd /srv/www/ahadpos
root@Obengkumana:/srv/www/ahadpos# mysql -u root -pxxxxxxx ahadpos <init-db-ahadpos.sql


edit /srv/www/ahadpos/config/config.php
----------------------------------------------------------------
$server = "127.0.0.1";
$username = "root";
$password = "xxxxxxx";
$database = "ahadpos";

--------------------------------------------------------------
edit /etc/lighttpd/lighttpd.conf, tamabh baris berikut
--------------------------------------------------------------
$SERVER["socket"] == ":7890" {
server.document-root = "/srv/www/ahadpos"
cgi.assign = ( ".pl" => "/usr/bin/perl", ".cgi" => "/usr/bin/perl",
".php" => "/usr/bin/php-cgi", ".sh" => "/usr/bin/perl" )
}
root@Obengkumana:~# /etc/init.d/lighttpd restart

silahkan login:
192.168.xxx.xxx:7890/ahadpos
user: admin
pass : admin
klu keluar error:

"Call to undefined function session_register() in" bla bli blu,
edit /srv/www/ahadpos/sistem/cek_login.php line 31 jd sprti di bawah ini:
--------------------------------------------------------------
$ketemu=mysql_num_rows($login);
//$ketemu = 1;
$r=mysql_fetch_array($login);

// Apabila username dan password ditemukan
if ($ketemu > 0){
session_start();
//session_register("idUser");
//session_register("namauser");
//session_register("passuser");
// session_register("leveluser");
// session_register("uname");

$_SESSION[namauser] = $r[namaUser];
$_SESSION[iduser] = $r[idUser];
$_SESSION[leveluser]= $r[levelUser];
$_SESSION[uname] = $r[uname];

Done ...

0 komentar:

Posting Komentar

 
Toggle Footer