だから、ここに私のプログラムがあります。それは、私が参加しているフォーラムに新しい午後が表示されたときにテキストを送信することです。問題は、1 つだけを送信するのではなく、数百を送信することです。
これを修正するにはどうすればよいですか? 私は声明を想定してbreak
いますが、それを言葉にする方法がわかりません。
import urllib2
from twilio.rest import TwilioRestClient
webp=urllib2.urlopen("http://hackforums.net").read()
words = urllib2.urlopen("http://hackforums.net").read()
word = 'titled'
while True:
for word in words:
if word in words:
ACCOUNT_SID = "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXx"
AUTH_TOKEN = "XXXXXXXXXXXXXXXXXXXXXXXXXXXx"
client = TwilioRestClient(ACCOUNT_SID, AUTH_TOKEN)
message = client.sms.messages.create(to="XXXto", from_="XXXfrom",
body="You have a new PM")
それから私は使用しています:
import os
import time
while True:
os.system("python newway.py")
print 'done'
開きます。