2 ms·
"I have never encountered an archive.ph URL on HN where the site proxied, purportedly to avoid a "subscription block",^2 was not accessible without using the ar
by 1vuio0pswjnm7 4y ago
"I have never encountered an archive.ph URL on HN where the site proxied, purportedly to avoid a "subscription block",^2 was not accessible without using the archive.ph URL. For example, sometimes the issue is simply that Javascript needs to be disabled, or one needs to use an AMP URL without Javascript. (The later looks great in a text-only browsersuch as links.) Whereas submissions for articles on sites that are password-protected, e.g., ft.com, rarely or never have archive.ph URLs."
Correction: FT was wrong example
I had forgotten ft.com like many other sites sends the plain text of the article to non-subscribers. It can be read in the page HTML. There is no way for non-subscribers to "opt-out" of receiving the article text when they follow ("click") a URL for a FT article.
It is in fact common to find archive.ph URLs for ft.com submissions.
Here is short program to make reading the article in the ft.com HTML page easier. It discards everything but the article text and replaces "\n" with newline.
cat > 071.l
/* ft.com */
int fileno(FILE *);
#define jmp (yy_start) = 1 + 2 *
#define echo do{if(fwrite(yytext,(size_t)yyleng,1,yyout)){}}while(0)
%option noyywrap noinput nounput
%s xb
%%
\"articleBody\":\" jmp xb;
<xb>\",\"wordCount\" jmp 0;
<xb>\134\156 putchar(10);
<xb>\40\* putchar(32);
<xb>. echo;
\n|.
%%
int main(){ yylex();putchar(10);exit(0);}
^D
flex -8iCrf 071.l
cc-O3 -std=c89 -W -Wall -pedantic -pipe lex.yy.c -o yy071
#example usage
curl -4s https://www.ft.com/content/fa956177-5daa-43fd-8a64-79f5eebcc309|yy071
curl -4o 1.htm https://www.ft.com/content/fa956177-5daa-43fd-8a64-79f5eebcc309
yy071 < 1.htm