2
私はpythonスクリプトを使用して、一連のウェブサイトURLを含むファイルを取り込み、それらをすべて新しいタブで開きます。しかし、私は最初のウェブサイトを開いて、エラーメッセージが出てい:これは私が得るものです:ウェブサイトオープナーのスクリプト
私のスクリプトは、これまでのようになります0:41: execution error: " https://www.pandora.com/ " doesn’t understand the “open location” message. (-1708)
:
import os
import webbrowser
websites = []
with open("websites.txt", "r+") as my_file:
websites.append(my_file.readline())
for x in websites:
try:
webbrowser.open(x)
except:
print (x + " does not work.")
私のファイルはの束で構成されていURLはそれぞれの行にあります。