Grow your CSS skills. Land your dream job.

HTML batch edit

  • # May 9, 2013 at 7:02 am

    Long shot – I need to delete all markup on a page apart from a div with an id of content (which contains the main content for that page).

    Sounds easy… but there is 250 pages to do this to. Tell me there’s something I can do?

    # May 9, 2013 at 7:23 am

    Can’t think of anything.

    # May 9, 2013 at 11:33 am

    I’m sure there’s some sort of regex. Just not my specialty.

    # May 9, 2013 at 5:49 pm

    @iknowdavehouse – Are you on windows? If so I just made a console app for this: http://www.filedropper.com/htmlelementempty

    Just put the exe in the directory of .html files double-click and type in the id that you want to empty.
    It will then loop through all the html files looking for the element with the said id and if it finds it clears it out.

Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.

*May or may not contain any actual "CSS" or "Tricks".