Community

    • Login
    • Search
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search

    How to identify a line, then copy every line after it until the next </div> tag

    Help wanted · · · – – – · · ·
    1
    1
    482
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • minkshaman
      minkshaman last edited by

      I need to identify a line, then copy every line after it until the next </div> tag, into a similar space in the next view.

      The first line is <h2 class=“title”>1</h2> and the number after “title”> changes every section.

      In the 2nd file, the line that identifies where it needs to be copied to is:
      <div data-content=“1” class=“selected cd-tab”>

      I’m sure there’s a way to do this in Python, but I’ve only started figuring it out today.
      Can anyone help me out?

      Hopefully by writing the code for me to adjust as needed?

      1 Reply Last reply Reply Quote -1
      • First post
        Last post
      Copyright © 2014 NodeBB Forums | Contributors