• RSS
  • Twitter
  • FaceBook

Security Forums

Log in

FAQ | Search | Usergroups | Profile | Register | RSS | Posting Guidelines | Recent Posts

color coding things in linux / php question

Users browsing this topic:0 Security Fans, 0 Stealth Security Fans
Registered Security Fans: None
Post new topic   Reply to topic   Printer-friendly version    Networking/Security Forums Index -> UNIX // GNU/Linux

View previous topic :: View next topic  
Author Message
delete852
Just Arrived
Just Arrived


Joined: 19 Nov 2002
Posts: 4
Location: Washington DC

Offline

PostPosted: Thu Jan 23, 2003 3:19 am    Post subject: color coding things in linux / php question Reply with quote

IN console it would help a bunch if you can color code different things like in ls if directories would be a different color that would be much easier to understand. They have it in mandrake and its pretty cool. How to do it in debian?

Second question is that I just installed apache with php (with which i had problems earlier) and when i make a small php scritp and go to it throught my windows box, it asks me to download it. And it doesn't execute it, how come?
Back to top
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger MSN Messenger
vlad902
Just Arrived
Just Arrived


Joined: 04 Jan 2003
Posts: 0


Offline

PostPosted: Thu Jan 23, 2003 4:36 am    Post subject: Reply with quote

1.) RTFM Wink. man ls shows thats it ls --color
2.) Are you sure PHP works? Post the part of your httpd.conf with the AddType part.
Back to top
View user's profile Send private message
ShaolinTiger
Forum Fanatic
Forum Fanatic


Joined: 18 Apr 2002
Posts: 16777215
Location: Kuala Lumpur, Malaysia

Offline

PostPosted: Thu Jan 23, 2003 11:49 am    Post subject: Reply with quote

1) RTFM Smile

Q: How do I get colors for 'ls'?

A: This assumes that you use bash, the standard shell in Debian. First check your ~/.bashrc, the necessary commands are probably already defined, but commented out (the have a # at the beginning of the line).

Remove that # in the line that says
Code:
alias ls='ls --color=auto'

If it doesn't exist, just add it. Feel free to comment out some of the other things in it, if you think you might like them. The next step is to make sure that all shells you start make use of that file. To achieve this, you have to edit your ~/.bash_profile and either add or uncomment
Code:
if [ -f ~/.bashrc ]; then
      source ~/.bashrc
   fi

After you did that, run the following command in all already open shells:
Code:
source ~/.bashrc

This will reread that file and add the alias to the running shell. If you are interested in other useful things you can do with that files, 'apt-get install bash-doc' and read /usr/share/doc/bash/examples/startup-files

2) You have php installed, but you don't have Apache set to use it and you might not have chmod +x it.

Google for "Using PHP with Apache" +Debian or something

P.S. Both of these questions can easily be answered with Google.
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   

Post new topic   Reply to topic   Printer-friendly version    Networking/Security Forums Index -> UNIX // GNU/Linux All times are GMT + 2 Hours
Page 1 of 1


 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

Community Area

Log in | Register