Solved

Emacs Question:  How to delete all occurances of <whatever> and </whatever>

Posted on 2004-10-06
2
237 Views
Last Modified: 2010-08-05
Hello everyone,

Using emacs, I'm trying to delete all tags of <whatever> and </whatever>  (whatever being any tags that start with < and end with > ).  So what I did was:

M-x query-replace-regexp
then typed without quotes  ' <.*?> '
and didn't type anything to replace it with.

This worked for all tags that were on the same line but for those that weren't, it did not delete.  Does anyone know what I could do to make this work?

Thanks for your help :)
0
Comment
Question by:justinmaurer
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 23

Accepted Solution

by:
brettmjohnson earned 500 total points
ID: 12241545
Try '<[^>]*>'  instead.

0
 

Author Comment

by:justinmaurer
ID: 12241625
thank you much!
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
SSH commands for Nas4free 21 506
Unix Question 19 53
to update from RHEL 6.0 to 6.8 anything needed other than "yum update"? 7 123
SCP a file to multiple machines using a script 4 83
Hello fellow BSD lovers, I've created a patch process for patching openjdk6 for BSD (FreeBSD specifically), although I tried to keep all BSD versions in mind when creating my patch. Welcome to OpenJDK6 on BSD First let me start with a little …
When you do backups in the Solaris Operating System, the file system must be inactive. Otherwise, the output may be inconsistent. A file system is inactive when it's unmounted or it's write-locked by the operating system. Although the fssnap utility…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question