Python3 url with vaules print me + instead of %20 (space) - Printable Version +- Kodi Community Forum (https://forum.kodi.tv) +-- Forum: Development (https://forum.kodi.tv/forumdisplay.php?fid=32) +--- Forum: Add-ons (https://forum.kodi.tv/forumdisplay.php?fid=26) +---- Forum: Python 3 migration (https://forum.kodi.tv/forumdisplay.php?fid=281) +---- Thread: Python3 url with vaules print me + instead of %20 (space) (/showthread.php?tid=364776) |
Python3 url with vaules print me + instead of %20 (space) - Kangool - 2021-10-04 hi i try to make a little plugin to get stalker portals working it reads the streamadress from a file (cachefile) as example "cmd":"ffmpeg http://localhost/ch/162691_ the code is this
the result is : type=itv&action=create_link&cmd=ffmpeg+http%3A%2F%2Flocalhost%2Fch%2F162691_ but this + sign between ffmpeg and http should be %20 for space so how i can change the + to %20 RE: Python3 url with vaules print me + instead of %20 (space) - Kangool - 2021-10-04 it also create the link to play the stream http://s1.nasaservers.com:8080/SKLcYWDZwa/Eyl314AQ28/162765?play_token=OCtIGjHqsg so all works correct only the + sing is the problem error i got "list index out of range" RE: Python3 url with vaules print me + instead of %20 (space) - M89SE - 2021-10-10 Use urllib quote to translate the path: https://docs.python.org/3/library/urllib.parse.html#urllib.parse.quote py3
|