Tuesday, January 3, 2012

Re: Opening something like href="/css/gray.css" from an online html file

Al 28/12/11 11:28, En/na Tony Mechelynck ha escrit:
> On 27/12/11 16:50, Peng Yu wrote:
>> Hi,
>>
>> vim can open something like http://.... But it doesn't open some other
>> files like href="/css/gray.css" that is embedded in a html file by
>> default. Is there a way to allow this to happen?
>>
>> Regards,
>> Peng
>>
>
> That's a relative link, it is relative to the folder containing the HTML
> file. Now in order to display a remote HTML file, Vim has to download it
> to a temporary location on your HD, and that breaks all relative URLs.
> Even for a local HTML file I don't think the solution would be trivial;
> but Dr.Chip may have an idea...

Maybe you can try somethig like (untested):

:let g:netrw_http_cmd='wget -r'


...but probably you will need to review wget options to limit
recursivity levels.


Check for:

:help netrw
:!man wget

--
Joan Miquel Torres__________________________________
Linux Registered User #164872
http://www.mallorcaweb.net/joanmiquel
BULMA: http://bulma.net http://breu.bulma.net/?l2301

--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

No comments: