Results 1 to 2 of 2
  1. #1
    Transparent Wall Technician crazed 9.6's Avatar
    Join Date
    Nov 2014
    Posts
    15,650
    Rep Power
    447

    The Playlists - m3u editing

    Editing of an m3u file, simply with Notepad or Wordpad or many other text editors will do the job.
    M3U or M3U8 are not formats, like mp3 or mp4 or etc are formats.
    The m3u designation is just a name of a certain text file encoded correctly, and with all the info your chosen Player needs is included in the text.

    C/P may explain it better. thnx Lifewire
    'A file with the M3U file extension is an Audio and or Video Playlist file that stands for MP3 URL. It is not an actual audio/video file in and of itself.
    An M3U file just points to audio (and sometimes video) files so that a media player can queue them for playback. These text-based files can contain URLs and/or absolute or relative path-names to the media files and/or folders.
    M3U files that are UTF-8 encoded are instead saved in the M3U8 file format.'

    end c/p

    This is easy to do.
    Simply open the m3u file with Notepad or WordPad on your PC and start editing, cause it is a text file/document, just encoded specifically.
    Afterwards, when you save the file, ensure that it is saved as UTF-8 encoded (you will see this option at the bottom of that 'save' menu).
    After has been saved and closed, right click on the file itself, and then click Properties and check in there that the file type is in fact .m3u or .m3u8

    Okay, with the file open, you will then see a bunch of lines of information, hundreds of lines with a very large Playlist.

    *Shown further down below in this tutorial, is an actual working M3U Playlist (not rockets thou)
    These shown here are just some old 1950's movies, but the concept is the same for Live TV m3u Playlists.

    Couple things to take note of here.
    The Playlist always begins it's syntax or script with #EXTM3U
    Each separate channel line begins with #EXTINF:x,

    Those are called 'Directives'

    Shown below is an example of one full channel line ...
    Code:
    #EXTINF:0,The Admiral Was A Lady 1950
    http://archive.org/download/TheAdmiralWasaLadyEdmondOBrien1950mooorip/TheAdmiralWasaLadyEdmondOBrien1950mooorip_512kb.mp4
    When it comes to deleting a channel from your playlist, simply delete the full channel line script.
    Do not worry about any blank lines as they will disappear once your doc has been saved and reopened. But if you want blank lines seen on your playlist when viewing thru a Player, then add that Directive as a blank line header.. just a trick to know
    Or to arrange channels, you would copy the channel line and then paste it where ever you want in the Playlist order.

    Easy peasy right ?

    Problem is that it is not so easy doing all that copy and pasting and if you have a very large Playlist (such as the Rocket full Playlists are), then it becomes difficult picking out the channel name in amoungst all that info. And the channel names can be short and hard to pin-point with any kind of efficiency and it is lots of work just arranging a few channels....as far as editing is concerned.

    The Playlist shown below is a very tiny list compared to Rocket list, but you may be able to see what I mean when it comes to editing and pin-pointing channels, if you are doing lots of editing.
    This is a working m3u Playlist too,. Just copy the text to a blank template and transfer to VLC and vola.
    These movies are in the 'open source' (they never were copywrighted and so available to all freely).
    You might be surprised to know that The Night of the Living Dead falls under this catagory, not listed here but it's available online.
    *
    Code:
    #EXTM3U
    #EXTINF:0,The Admiral Was A Lady 1950
    http://archive.org/download/TheAdmiralWasaLadyEdmondOBrien1950mooorip/TheAdmiralWasaLadyEdmondOBrien1950mooorip_512kb.mp4
    #EXTINF:0,Love Island 1950
    http://archive.org/download/love_island/love_island_512kb.mp4
    #EXTINF:0,Behave Yourself 1951
    http://archive.org/download/behave_yourself_ipod/behave_yourself.mp4
    #EXTINF:0,Mr.Imperium 1951
    http://archive.org/download/Mr.Imperium/Mr.Imperium_512kb.mp4
    #EXTINF:0,You Asked For It - Bela Lugosi 1952  
    http://archive.org/download/YouAskedForIt_BelaLugosi/DUMONT_YouAskedForIt_Lugosi_512kb.mp4
    #EXTINF:0,Kansas Pacific 1953 -in color
    http://archive.org/download/KansasPacific/KansasPacific_512kb.mp4
    #EXTINF:0,Yongary, Monster From The Deep 1967 
    http://archive.org/download/Yongary-MonsterFromTheDeep/Yongara_512kb.mp4
    #EXTINF:0,Love Happens ??
    http://37.58.68.221/index.php?file=1324&start=0&hd=0&auth=19691719ec1afa62ec2c141667&type=flv&tv=0
    So, a good way to help with editing a Playlist would be with a Playlist Player/Editor.
    There are a few out there that you can run on your desktop.
    VLC, Perfect Player, Fobar2000, wimamp and a couple more that I do not recall off hand.
    MediaMonkey is great Editor and Player, only problem is that it does not stream video from m3u source (for local sources it will, but not streamed from online). It can be used to edit an m3u8 file (txt only with no video streaming at same time, like VLC Player/Editor would do).
    I mention media monkey thou because it is a very powerful Editor.. I take advantages of some of it's functions when editing an m3u file

    Okay, we will need a few things now.
    Get a fresh copy of the Generic_M3u_Plus_'with options' Playlist.
    Put that Playlist on your desktop. Then right click it and copy and then paste the new copy on desktop too.
    Now open the Copy and we want to make a blank template.
    To get a blank template , simply open an m3u8 file with notepad and select all channel lines and delete all channel lines.
    Next go back to your original Playlist and copy that header line, which is a 'Directive' (#EXTM3U) and then paste that Directive onto your now blank template.
    Before we go further, make a couple more blank templates of that m3u8 file. This time thou, copy the copy and then the header will also be included in the new blank copies.
    Or simply open new notepad docs each time and paste that header Directive onto each, also ensuring the doc is saved in correct encoding (UTF-8)

    Now back to your original Playlist and being careful to leave the Playlist header alone (#EXTM3U), but copy all the channel lines up to where the VOD movies start. When you copy these channel lines, use the Cut option instead of the Copy option, then that way they do 'copy' but they are also erased (cut) from the txt document and not left behind. We do not want them left because this 'original' template will eventually become our VOD only movies template.

    We want to just grab all those Live TV channels, no matter weather foreign language or adults or what ever they are, we want them all off our original template and without any adoe.. and copied and pasted somewhere else for editing later.
    Copy all channel lines right up to where the VOD start ( there are sometimes 3 lines labeled as Test ,,, , that will indicate the start of the VOID and there are some other indicators, such as the .mp4 or .ts ending in the channel lines. And the tv tags
    LiveTV channel lines take up maybe 10% of the content, so judge that when searching the ending.

    So then paste them copied/cut channel lines onto your new template.
    Then save and rename as TV Channels (or something to identify the Playlist with).
    Now you have a Playlist with only the Live TV channels.
    Set that aside for now and we can edit that further at a latter time.

    Ok, back to your original template, which should now be missing the Live TV channels.

    Next thing to do is decide weather to start organizing what is left on that original template or you can open an empty template along side this original template and copy and paste the foreign VODs onto this new template, or a third template for TV Series, or a fourth blank template for adults and etc..
    You could also do some kind of organization with the original list first, then that way when it comes time to copy and pasting certain content to a new template, you can copy many, many lines at once.
    Either way thou, it can be time consuming
    Open your original template on VLC and delete unwanted channels first before you start any organization or any editing, then that way your list will be shorter with them unwanted channels removed first and VLC makes short work when it comes to identifying and deleting channels.
    Okay, thats the simple stuff involved in editing.
    I also like to have either VLC or Perfect player open and running these Playlists at same time. Reason being is that some times these Player Editors can help in moving channels, or deleting channels is best. You can readily see each channel and not like viewing thru notepad trying to get a bead on the individual channels.

    Perfect Player has function to move multiple channel lines at once, while VLC does not have that function.
    MediaMonkey does also have that function.

    Open list on VLC, scroll list and hit delete on any channel you want deleted, do this before you start organizing and then your list will be that much shorter with all the stuff not wanted already removed.

    Save edited list in VLC thru the Media tab.

    You can even take a channel line from that old movies Playlist (from above) and add it to your Rocket Playlist and it will work, as long as the channel address is still valid. You can make any kinda Playlist you want with channel addresses from different sources, it does not matter, as long as each channel line is valid, they will work.

    And when ever there are new movies added to the server, simply get another list and copy the new movies onto your original VODs Plylist you already made.

    This is when using an m3u file thru USB.
    Getting the content thru Playlist URL will not work like this, but you do have the Players categories to use then.

    I like to use edited m3u8 Playlist so the option to completely remove certain channels is there. Like for your children, you can make a Playlist for them with no adult channels and therefore no chance they might come across them.
    That is one purpose of an edited Playlist, among others.



    Okay, now lets say I want to make a VOD playlist from the Rockets main Playlist, and I want to share my work.
    Remember that a Playlist is just a collection of web addresses and ports and certain tags added to each channel line (like an epg or logo tag).
    And so to make anyone's Playlist my own, I would just need to change a couple things in each channel line.

    Code:
    #EXTINF:-1 tvg-id="" tvg-name="Last Vegas" tvg-logo="http://p2.iptvprivateserver.tv/xxxxxx_xxxxxxx/screenshots/xx/xxxx.jpg" group-title="Movies",Last Vegas
    http://p2.iptvprivateserver.tv:xx/movie/jadjadjad/jadjadjad/xxxx.mp4
    So in the above example I would need to change the server URL and the Username and Password.
    p2.iptvprivateserver.tv
    jadjadjad/jadjadjad

    And that needs to be done in each and every channel line.
    You might think that wow... that is an undertaking that just can not be done.
    There is an easy way to do this thou

    Open the Playlist that you want to make your own.
    Open it with Notepad or Wordpad this time, or any good text editor you prefer.
    Wordpad sometimes will not save your work correctly and you will loose your work.
    I tend to not use Wordpad for this reason.
    Notepad works flawlessly.

    Find the 'Replace" function and open that.
    It will ask you what you want to find.
    In example above I need my URL to be p5. and not p2.
    So I don't need the full URL replaced because its that same except the p5. thing.

    So enter p2. in as what you want to find (we want at least the two digits and that dot, because if you just enter a 2 there, then all 2's in the doc will be replaced and we don't want that. So use a string that is only found in the URL and no where else ..... like (p2.)

    Okay, then check the box to MATCH WHOLE WORD
    Then use the REPLACE ALL function and give it a few seconds and vola all will be replaced as needed.
    Next do this same thing with the username and password.
    In the example, jadjadjad to be replaced with your username and password. Don't try to 'Find' jadjadjad/jadjadjad, because that is more data the program needs to use and will take longer. So just 'Find' and replace jadjadjad
    That will save valuable seconds but more importantly it may save a system crash and is same reason why I just 'find' and replace (p2.) instead of the complete URL (p2.iptvprivateserver.tv)
    Unless the full URL is a Rocket URL as appossed to a nfps URL , then no need to find/replace the full URL



    Now you should have a pre-edited Playlist that works with your code.
    Save and check it for results.

    With VLC Player open on Desktop, simply drag and drop your Playlist onto VLC. It will open on a channel,but there can be a list function shown in the bottom icon menus (might have to allow that thru View or Media tab functions, found up top)
    Check VLC sub forums for detailed VLC functions explained.
    I use VLC Media Player as a tool here to check my work via my laptop, as I go along. And is why I often mention to open it on VLC , but you can open it on any Player you have preference for.
    To open a Player on Desktop it must be an .exe program and not an ARM or other android program formatted.
    VLC and Perfect Player can be found in .exe or a 'portable' version that can be kept on USB drive, or any drive.

    kens has a pre-edited template posted here in this forum section with some of this also explained.
    Try it out

    For a more detailed look at m3u files...
    Lifewire - What is an M3U File?
    Code:
    https://www.lifewire.com/m3u-file-2621955
    Text Editor's... (Core Text Edit v3.0 is also another good text Editor and Windows NotePad works nicely for what we want here).
    Code:
    https://www.lifewire.com/best-free-text-editors-4155819
    Playlist Creator application...
    Code:
    http://www.oddgravity.de/app-opc.php


    **
    warning
    When editing a Playlist with VLC and after it has been saved as Media Playlist, then the tags seem to be erased.
    That's the logo and epg tags that are found with a Plus Generic M3u Playlist.
    So don't edit a playlist with VLC unless these tags do not matter to you.
    Or save a copy of a good list and edit that copy thru VLC to test this for yourself.

    This seems to be the case with using WordPad as well, and editing an M3u 'Plus' Playlist.
    If you arrange channels thru Wordpad then after it has been saved, you will loose all the logo ID tags and Movie description tags and other tags.
    You can however use WordPad's 'Find' and 'Replace' functions and your tags will not be affected.

    Notepad++ or Notepad, do not effect these logo or epg or description tags thou.... so use Notepad to arrange or delete or paste channels onto your Playlists
    Last edited by crazed 9.6; 08-15-2018 at 01:19 AM.
    "The illusion of freedom will continue for as long as it's profitable to continue the illusion. At the point where the illusion becomes too expensive to maintain, they will take down the scenery, move the tables and chairs out of the way, then they will pull back the curtains and you will see the brick wall at the back of the theater."
    - Frank Zappa

  2. #2
    Member Waylotul's Avatar
    Join Date
    Jan 2016
    Location
    yes i do
    Posts
    183
    Rep Power
    22
    This is an awesome detailed explanation. I have been wanted to getting into some alternate players.

 

 

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •