How to make a file freom putty ?

Status
Not open for further replies.

jasoothai

Active Member
171
2011
10
0
I typed
Code:
vi /var/www/html/info.php
in Putty
and got like this :
[SLIDE]http://i.imgur.com/LZUMp.jpg[/SLIDE]
i need to write :
Code:
<?php 
phpinfo(); 
?>
But nothing showing when writing. :(
 
8 comments
For create file using ssh follow this command
touch /var/www/html/info.php
then
vim /var/www/html/info.php
For make this file writable press i or [insert]
then paste this text by mouse right click .
then press [esc] after this :x [enter]
 
Nothing happened :(

centOS 5 32 bit

It looks like this

gPCon.png


---------- Post added at 01:51 PM ---------- Previous post was at 01:38 PM ----------

For create file using ssh follow this command
touch /var/www/html/info.php
then
vim /var/www/html/info.php
For make this file writable press i or [insert]
then paste this text by mouse right click .
then press [esc] after this :x [enter]

Worked, Thank you...
 
Last edited:
How about ^o)

Code:
echo "<?php phpinfo(); ?>" > /var/www/html/info.php

OR Use nano it's much more noob friendly:

Code:
yum install nano -y
nano /var/www/html/info.php
 
Last edited:
Agree also, but you know this topic maker asking question about specific thing, and we bound to solve his issue quickly without giving more extra things that make him more confused same like me before.
 
Status
Not open for further replies.
Back
Top