LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 819|回复: 3

sh問題救助!

[复制链接]
发表于 2004-8-23 14:10:49 | 显示全部楼层 |阅读模式
怎樣寫一個sh,
獲得指定網址的內容?
我試過
#!/bin/sh
@file="wget http://www.storngd.net:81/"
cat @file

但失敗了~大佬幫幫手。

還有。怎樣讀一個文件的內容!

先謝謝~
发表于 2004-8-23 14:32:12 | 显示全部楼层
用PHP可以

[php]
<?php
$str=join("",file("http://www.strong.net"));
print $str;
[/php]
 楼主| 发表于 2004-8-23 15:09:26 | 显示全部楼层
但我想用sh寫啊!
发表于 2004-8-23 15:21:53 | 显示全部楼层
php也可以写shell
您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表