From: Harald Hanche-Olsen <hanche@math.ntnu.no>
To: help-gnu-emacs@gnu.org
Subject: Re: how to obtain a url and store it
Date: Mon, 03 Mar 2008 20:55:34 +0100 [thread overview]
Message-ID: <pcok5kjvayx.fsf@shuttle.math.ntnu.no> (raw)
In-Reply-To: 86f2ce2b-6682-4181-8540-78159776317b@z17g2000hsg.googlegroups.com
+ someusernamehere <someusernamehere@gmail.com>:
> Harald Hanche-Olsen escreveu:
>> > Hey, how I can get an url which is in some place in a paragraph and
>> > store it in a local var?
>>
>> You could start by looking at thing-at-point.
>
> yeah, but, how move the point where the url is in the paragraph?
Search for some regexp that will match the start of an URL?
Something along the lines of
\(https?\|ftp\|mailto\|gopher\|git\):
Extend with any protocol names you wish to cover.
(Gee, I haven't seen a gopher server in ages. Do they still exist?)
Perhaps you could just search for [a-z]: and then go to the match and
try thing-at-point to see if it will recognize it as an url or not.
--
* Harald Hanche-Olsen <URL:http://www.math.ntnu.no/~hanche/>
- It is undesirable to believe a proposition
when there is no ground whatsoever for supposing it is true.
-- Bertrand Russell
next prev parent reply other threads:[~2008-03-03 19:55 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-03-03 18:55 how to obtain a url and store it someusernamehere
2008-03-03 18:57 ` Harald Hanche-Olsen
2008-03-03 19:05 ` someusernamehere
2008-03-03 19:55 ` Harald Hanche-Olsen [this message]
2008-03-04 8:22 ` Tim X
2008-03-04 8:20 ` Tim X
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=pcok5kjvayx.fsf@shuttle.math.ntnu.no \
--to=hanche@math.ntnu.no \
--cc=help-gnu-emacs@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).