Re: Regex help - matching unique URLs and deleting HTML encoding

2020-01-27 Thread Sammy Banawan
This text is very predictable. Just a lot of lines with everything but the 
profile name unneeded. 

-- 
This is the BBEdit Talk public discussion group. If you have a feature request 
or need technical support, please email "supp...@barebones.com" rather than 
posting here. Follow @bbedit on Twitter: 
--- 
You received this message because you are subscribed to the Google Groups 
"BBEdit Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to bbedit+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/bbedit/25054297-95c7-4bcb-91dd-15337e17987e%40googlegroups.com.


Re: Regex help - matching unique URLs and deleting HTML encoding

2020-01-27 Thread 'Jeffrey Jones' via BBEdit Talk
On 2020 Jan 26, at 23:18, Sammy Banawan  wrote:
> 
> I figured out an even easier way - just search for anything in angle brackets 
> and delete it. <.*?> and replace with nothing. I should have thought of that 
> before. Thanks for the help!


If you want to remove ALL tags, try   Markup > Utilities > Remove Markup

-- 
This is the BBEdit Talk public discussion group. If you have a feature request 
or need technical support, please email "supp...@barebones.com" rather than 
posting here. Follow @bbedit on Twitter: 
--- 
You received this message because you are subscribed to the Google Groups 
"BBEdit Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to bbedit+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/bbedit/88AC8536-8315-4EAA-86D9-F1ABD236D46A%40me.com.


Re: Regex help - matching unique URLs and deleting HTML encoding

2020-01-27 Thread Ken Corey
Which is great if you don't have angle brackets in your text... And you *know* 
the html is uniform.

Is there a risk of multiple items on one line?  Or malformed html?

Regexps with html can be unpredictable...

-Ken

-- 
This is the BBEdit Talk public discussion group. If you have a feature request 
or need technical support, please email "supp...@barebones.com" rather than 
posting here. Follow @bbedit on Twitter: 
--- 
You received this message because you are subscribed to the Google Groups 
"BBEdit Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to bbedit+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/bbedit/b04154a7-c560-48db-b4d0-fbca456e7b13%40googlegroups.com.


Regex help - matching unique URLs and deleting HTML encoding

2020-01-27 Thread ctfishman
Find:
]+>(.*?)

Replace:
\1

This will find the a tag, followed by the shortest string possible, followed by 
the closing tag. If you don’t have the question mark it won’t work correctly if 
there is more than one link on a line. 

-- 
This is the BBEdit Talk public discussion group. If you have a feature request 
or need technical support, please email "supp...@barebones.com" rather than 
posting here. Follow @bbedit on Twitter: 
--- 
You received this message because you are subscribed to the Google Groups 
"BBEdit Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to bbedit+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/bbedit/c4519ee6-f6e4-42d5-a3c9-9ee0d490c9f7%40googlegroups.com.


Re: Regex help - matching unique URLs and deleting HTML encoding

2020-01-27 Thread Sammy Banawan
I figured out an even easier way - just search for anything in angle brackets 
and delete it. <.*?> and replace with nothing. I should have thought of that 
before. Thanks for the help!

-- 
This is the BBEdit Talk public discussion group. If you have a feature request 
or need technical support, please email "supp...@barebones.com" rather than 
posting here. Follow @bbedit on Twitter: 
--- 
You received this message because you are subscribed to the Google Groups 
"BBEdit Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to bbedit+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/bbedit/50b53e1c-986b-4bd4-aaca-edd831de6d8e%40googlegroups.com.


Re: Regex help - matching unique URLs and deleting HTML encoding

2020-01-26 Thread Christian Boyce
Hi Iain:

This works (maybe not the cleanest way but it works):

Search for this:

((.*)()

Replace with this:

\3



> On Jan 26, 2020, at 3:30 PM, Sammy Banawan  wrote:
> 
> I have  href="https://www.facebook.com/somename1?fref=profile_friend_listhc_location=profile_browser
>  
> "
>  
> data-gt="{engagement:{eng_type:1,eng_src:2,eng_tid:10180221704,eng_data:[]}}"
>  
> data-hovercard="/ajax/hovercard/user.php?id=10180221704extragetparams=%7B%22hc_location%22%3A%22profile_browser%22%7D"
>  data-hovercard-prefer-more-content-show="1">Some Name 1
> 
> and I just want to keep Some Name 1. The HTML I want to strip entirely.
> 
> Obviously, the file has 
>  href="https://www.facebook.com/somename2?fref=profile_friend_listhc_location=profile_browser
>  
> "
>  
> data-gt="{engagement:{eng_type:1,eng_src:2,eng_tid:10180221704,eng_data:[]}}"
>  
> data-hovercard="/ajax/hovercard/user.php?id=10180221704extragetparams=%7B%22hc_location%22%3A%22profile_browser%22%7D"
>  data-hovercard-prefer-more-content-show="1">Some Name 2
> 
> etc. as well.
> 
> I can't figure out the regex pattern for this. Any help would be appreciated. 


--
Christian Boyce
Christian Boyce and Associates
Mac, iPhone, and iPad Consultants

For appointments, please call the office: 424-354-3548.
We do not make appointments by email or text. We're old-fashioned that way.

Read our latest blog post: ‌How to rearrange the order of menubar icons on a 
Mac ‌

Current location and temperature: ‌‌‌
San Antonio, United States: ☀️ +59°F
‌

-- 
This is the BBEdit Talk public discussion group. If you have a feature request 
or need technical support, please email "supp...@barebones.com" rather than 
posting here. Follow @bbedit on Twitter: 
--- 
You received this message because you are subscribed to the Google Groups 
"BBEdit Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to bbedit+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/bbedit/B5579154-AA79-4AA8-95C1-1A6CD96CCAC7%40christianboyce.com.


Regex help - matching unique URLs and deleting HTML encoding

2020-01-26 Thread Sammy Banawan
I have https://www.facebook.com/somename1?fref=profile_friend_listhc_location=profile_browser;
 
data-gt="{engagement:{eng_type:1,eng_src:2,eng_tid:10180221704,eng_data:[]}}"
 
data-hovercard="/ajax/hovercard/user.php?id=10180221704extragetparams=%7B%22hc_location%22%3A%22profile_browser%22%7D"
 
data-hovercard-prefer-more-content-show="1">Some Name 1

and I just want to keep Some Name 1. The HTML I want to strip entirely.

Obviously, the file has 
https://www.facebook.com/somename2?fref=profile_friend_listhc_location=profile_browser;
 
data-gt="{engagement:{eng_type:1,eng_src:2,eng_tid:10180221704,eng_data:[]}}"
 
data-hovercard="/ajax/hovercard/user.php?id=10180221704extragetparams=%7B%22hc_location%22%3A%22profile_browser%22%7D"
 
data-hovercard-prefer-more-content-show="1">Some Name 2

etc. as well.

I can't figure out the regex pattern for this. Any help would be 
appreciated. 

-- 
This is the BBEdit Talk public discussion group. If you have a feature request 
or need technical support, please email "supp...@barebones.com" rather than 
posting here. Follow @bbedit on Twitter: 
--- 
You received this message because you are subscribed to the Google Groups 
"BBEdit Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to bbedit+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/bbedit/26f513f4-7c78-4a3a-ac90-6edf80869aa0%40googlegroups.com.