Linux Commands:
1. To know the Version $ lsb_release -a
2.Last reboot $ last reboot
3.System temperature $ acpi -V
4.Multiple Terminal $sudo apt-get install terminator
$man terminator
Logo for Kanimozhi
கட்டற்ற (தமிழ்க்) கணிமை கூடுதல் பற்றிய விவரம் அடங்கிய தளத்திற்கான logo உருவக்கப்பட்டுள்ளது.
LOGO:
வலைப்பக்கம்: http://kanimozhi.info/
Uninstall KOHA
KOHA:
Koha is the first open-source Integrated Library System (ILS).
UNINSTALL KOHA
1. Drop or delete the Koha database, 2. Delete the koha-httpd.conf (/etc/koha/koha-httpd.conf) 3. Delete the koha installation folder (/usr/share/koha) and proceed for fresh installation.
Java Script
Redirect a page using confirm :
<script type=”text/Javascript”>
var url=”http://www.somesite.com”;
var redirect=confirm(“Do you want to be redirected to “+url);
if(redirect)
{
window.location.href=url;
}
</script>
Alert – “On Click”
You can place the JavaScript alert() function directly into a button element, then use the ‘onclick’ event to trigger it. Like this:
<input type=”button” value=”Click me…” onclick=”alert(‘Thanks… I feel much better now!’);” />
Alert – Before Page Loads
<html>
<head>
<body>
<div style=”text-align:center;padding:10px;”>
<h1>Amazing Web Page</h1>
<script type=”text/javascript”>
alert(‘But wait, there\’s more…’);
</script>
<p><a href=”JavaScript:self.close();”>Close This Page!</a></p>
</div>
</body>
</html>
Alert – After Page Loads
<html>
<head>
<script type=”text/javascript”>
function alertUser(msg) {
alert(msg);
}
</script>
</head>
<body onload=”alertUser(‘Welcome to this AMAZING web page!’)”>
<div style=”text-align:center;padding:10px;”>
<h1>Amazing Web Page.</h1>
<p><a href=”JavaScript:self.close();”>Close</a></p>
</div>
</body>
</html>
Alert – Within Another Function
<script language=”javascript” type=”text/javascript” >
function jumpto(x){
if (document.form1.jumpmenu.value != “null”) {
if (document.form1.jumpmenu.value != “http://www.quackit.com”) {
alert(‘Sorry to see you leaving Quackit. Hope to see you back soon!’);
}
document.location.href = x
}
}
</script>
<form name=”form1″>
<select name=”jumpmenu”
onChange=”jumpto(document.form1.jumpmenu.options[document.form1.jumpmenu.options.selectedIndex].value)”>
<option>Jump to…</option>
<option value=”http://www.quackit.com”>Quackit Homepage</option>
<option value=”http://www.zappyhost.com”>ZappyHost</option>
<option value=”http://www.code-generator.net”>Code Generator</option>
<option value=”http://www.natural-environment.com”>Natural Environment</option>
<option value=”http://www.great-workout.com”>Great Workout</option>
</select>
</form>
HTML
Button (onClick):
To open a file in a new window
<input type=”button” value=”Add” name=”cmdadd” onclick=”window.open(‘one.html”)” />
To open a file in the same window
<input type=”button” value=”Add” onclick=” location.href=’one.html’ ” name=”cmdadd” />
<input type=”button” value=”Add” onclick=”document. location.href=’one.html’ ” name=”cmdadd” />
How to install PostgreSQL Database Server on Fedora
Install Django
Download the python:
http://www.python.org/ or add/remove software
Download the Django:
http://www.djangoproject.com/download/
tar xzvf Django-1.1.tar.gz
cd Django-1.1.1
sudo python setup.py install
Install postgresql and postgresql-server packages:
$ yum install postgresql postgresql-server python-psycopg2
Configure PostgresSQL:
edit: /var/lib/pgsql/data/postgresql.conf
Uncomment this two line:
listen_addressses = ‘ ‘
port = 5432
or
listen_addresses=’localhost’
Start PostgreSQL Server:
service postgresql start OR /etc/init.d/postgresql start
Configuring Postgresql
Setting up Postgres Users
Changing the postgres users database password:
su postgres
psql template1
template1=# ALTER USER postgres WITH PASSWORD ‘password’;
template1=\q
Where “password” is the new password.
Changing the postgres user OS password:
sudo passwd -d postgres
sudo su postgres -c passwd
Setting up Postgres Users
How to install fonts
Ubuntu:
Copy the fonts to this directory /usr/share/fonts/truetype
Fedora:
Copy the fonts to this directory /usr/share/fonts/
For Both:
After copy the fonts to the directory then give this command in terminal
fc-cache -f -v
Latex
How to install latex on fedora :
$ sudo yum install texlive-latex
RUN:
Way 1:
#latex hello % hello is the filename,its gives the dvi file
#dvips hello.dvi -o hello.ps % converting to postscript
#dvipdf hello.dvi hello.pdf % converting to PDF
way 2:
#pdflatex hello.tex %convert the tex file directly to pdf.
Simple document using latex:(save hello.tex)
\documentclass[12pt]{article}
\begin{document}
hello world!
\end{document}
How to write letter using latex:
\documentclass[12pt]{letter}
\address{}
\date{\today}
\begin{document}
\begin{letter}
{To,\\
The Principal,\\
Little Flowers School,\\
Delhi.\\}
\opening{Dear Madam}
Subject:Application for leave of absence from 16-20th January.
My daughter,Priya,a student of Little Flowers School will
unable to attend school from 12-16th of this month due to some familial
problems.I hope you would grant her leave of absence for those days only.
\closing{Sincerely\\
R. S. Shanmugam}
\end{letter}
\end{document}
NOTES:
All latex command begin with a reverse slash.
1.\documentclass[12pt]{letter}
The document class belongs to letter. It have some option like article,report,book etc.,12pt is the text size.
2.\address{ from address}
The from address will display in the right hand side default, with current date.
3. \\
To start new line
4.\date{9 July 2007}
If you want put your own date give this command, or you want current date \data{\today} it will display American style month date year..
5.\opening { }
It represent the recipient
Dump and undump the database in mysql
DUMP:
mysqldump -u root -p dbname > db.sql
UNDUMP:
mysql -u root -p dbname < db.sql
July 14, 2010
