用php循环处理数据

发布于 2024-12-21 04:24:49 字数 169 浏览 0 评论 0原文

有一个具有指定行数的文件和处理数据的 php 脚本。问题是我应该在此脚本中手动定义字符串以进行如下处理: $ url = 'http://text.ru';而是 http://text.ru 我们如何添加自动循环文件中的所有行? 谢谢。

There is a file with a specified number of rows and php-script that processes the data. The problem is that I should define manually string in this script to process like this:
$ url = 'http://text.ru'; instead http://text.ru
How we can add to it looping all the rows from the file automatically?
Thanks.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

流绪微梦 2024-12-28 04:24:49

您可以使用 php 中提供的文件处理 API 来读取文件。只需从文件中一次读取一行并处理它。请看下面的链接。

PHP 文件处理

You can use the file handling API available in php to read from a file. Just read one line at a time from the file and process it. Look at the following link.

PHP File Handling

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文