Wednesday, December 28, 2011

How to intall Joomla linux

1.Install mysql
2.Install apache web server.
3.Install php5.
4.Download Joomla
5.Untar the Joomla installation and copy the files to
/var/www/joomla-basic directory

6.In the browser type localhost/joomla-basic and the home page will appear
7.Follow the instructions

Friday, August 29, 2008

exit() vs _exit() system call

Note on exit() vs _exit(): The C library function exit() calls the kernel system call _exit() internally. The kernel system call _exit() will cause the kernel to close descriptors, free memory, and perform the kernel terminating process clean-up. The C library function exit() call will flush I/O buffers and perform aditional clean-up before calling _exit() internally. The function exit(status) causes the executable to return "status" as the return code for main(). When exit(status) is called by a child process, it allows the parent process to examine the terminating status of the child (if it terminates first). Without this call (or a call from main() to return()) and specifying the status argument, the process will not return a value.

#include

void exit(int status);



#include

void _exit(int status);

Wednesday, August 27, 2008

cin problem c++

The solution to the problem is to add two statements before cin.Those are

cin.clear();
cin.ignore();

Thursday, August 14, 2008

LINUX HOW TOS

how to install debian linux using internet and thumb drive

Requirements:
thumbdrive
a machine running debian linux

step1: insert the thumbdrive and check the device name
ex:sda,sdb,sdc
step2:download boot.img.gz from debian site
step3:Execute #zcat boot.img.gz > /dev/sdc ,if the device name is sdc.Contents of the thumb drive will be lost when doing this operation.valuable data should be saved before doing this.
step4:download netinstall or business card images fron this location
step5:mount the thumb drive using #mount /dev/sdc /mnt.Copy the .iso image to the thumb drive.
step6:unmount the thumbdrive using #umount /dev/sdc
step7:unplug the thumbdrive and plug it on the new machine where you want to install and reboot that machine.
step8:follow the instructions or use the installation guide in the debian site.

s bitread write execute permissions in linux

browsers in linux
w3m,links
mc

Tuesday, August 12, 2008

microsoft assembly language-MASM

if you want an in depth knowledge of assembly language click here

editing a program in assembly language

An assembly language program can be entered using a text editor available.
ex:notepad,edit,ne

The edited file should be saved with the extension .asm
ex:abc.asm,test.asm

assebling a .asm program

An assembler converts assembly language program to its object code.
masm assembler is masm.exe.usually it is located at c:\masm611\bin
Suppose that your program is in a directory c:\abc and the program name is abc.asm.
Before calling the assembler set the path using

c:\abc\path=%path%;c:\masm611\bin

After setting your path assemble your program using

c:\abc\masm abc.asm
or
c:\abc\masm abc;

If there are errors in the program abc.asm the assembler will display the errors with line numbers.The programmer has to correct the errors and save it.Try to assemble the program again.If the program is error free, it will be converted to an object file, abc.obj.

linking the program

The following commands can be used to link the object program to an executable file abc.exe

c:\abc\link abc.obj
or
c:\abc\link abc;

executing a program

If linking is successful, you can execute the program using the following command line.

c:\abc\abc.exe
or
c:\abc\abc


Your first program("hello.asm")
Program to display "Hello World".

data segment
msg db "Hello world$"
data ends
code segment
start:mov ax,data
mov ds,ax
lea dx,msg
mov ah,9
int 21h
mov ah,4ch
int 21h
code ends
end start

code snippet to read a character from the keyboard

mov ah,1
int 21h

After the execution of the interrupt AL register will hold the ASCII value of the keypressed.

Ex:if you have pressed 0, the content of AL will be 30H

code snippet to print a character on the screen if it is printable and execute a control function if it is control character.

Ex: if you want to print 0 on the screen

mov dl,'0' //moving the character 0 to dl register
or
mov dl,30h
mov ah,2
int 21h

Ex: if you want to execute the carriage return function
mov dl,0dh
mov ah,2
int 21h

code snippet to read a number(less than 255)
in the data segment there is a variable var1 to store the number
ie var1 db 0

in the code segment
l1:mov ah,1
int 21h
cmp al,0dh
jz l2
sub al,30h
mov bl,al
mov bh,var1
mov al,10
mul bh
add al,bl
mov var1,al
jmp l1
l2: