Parse Lines JS

A Pen created on CodePen.io. Original URL: https://codepen.io/jameso2/pen/LYxyqmY.

Input: Output:

Convert local images paths, to HTML IMG tags.
Now with more options for AUDIO tags, and more!

How to Use:

  1. First, Choose a Method that you want to use to convert your list using the dropdown menu above.
  2. Now, in your image folder on Windows Explorer, Select a bunch of images in a folder with your cursor.
    1. Hold SHIFT, and right-click on an image. This will bring up an extra hidden menu option: Copy as Paths
    2. Click "Copy as Paths" -- this generates a text list of the files you selected.
    3. Note: There is likely a similar method to get a text list of files on a Linux or Mac system, but I am not familiar with them.
  3. Paste the text into the large INPUT area on the left.
  4. Lastly, Click the "Convert" button. Your file list is converted to IMG tags (or an array, or video tags, or which ever option you chose).

Note: The path in the "htdocs Path" box will be replaced with the path in the "Live Path" box. You can leave it as "/" to use your server's ROOT. Or you could put any path in front, such as https://jameso2.neocities.org/ to make the paths absolute.


If you found this script useful, please consider dropping me a tip on Ko-Fi. I don't make much, and every little bit helps.

This page and script designed by JamesO2 (2020), for use with the NeoCities hosting platform. Click the Logo below to go back to my site!

jameso2.neocities.org

Last updated: 2021.04.21