Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.javascript > #36966 > unrolled thread

Firefox changed IFRAME behaviour - I need a remedy??

Started bydr.j.r.stockton@gmail.com
First post2019-07-20 12:53 -0700
Last post2019-08-04 11:27 +0200
Articles 20 on this page of 43 — 9 participants

Back to article view | Back to comp.lang.javascript


Contents

  Firefox changed IFRAME behaviour - I need a remedy?? dr.j.r.stockton@gmail.com - 2019-07-20 12:53 -0700
    Re: Firefox changed IFRAME behaviour - I need a remedy?? Andrew Poulos <ap_prog@hotmail.com> - 2019-07-21 15:15 +1000
    Re: Firefox changed IFRAME behaviour - I need a remedy?? "Michael Haufe (TNO)" <tno@thenewobjective.com> - 2019-07-22 03:07 -0700
    Re: Firefox changed IFRAME behaviour - I need a remedy?? Martin Honnen <martin.honnen@gmx.de> - 2019-07-22 16:20 +0200
      Re: Firefox changed IFRAME behaviour - I need a remedy?? dr.j.r.stockton@gmail.com - 2019-07-30 08:20 -0700
    Re: Firefox changed IFRAME behaviour - I need a remedy?? "Michael Haufe (TNO)" <tno@thenewobjective.com> - 2019-07-30 18:24 -0700
      Re: Firefox changed IFRAME behaviour - I need a remedy?? dr.j.r.stockton@gmail.com - 2019-07-31 04:14 -0700
        Re: Firefox changed IFRAME behaviour - I need a remedy?? dr.j.r.stockton@gmail.com - 2019-07-31 05:32 -0700
          Re: Firefox changed IFRAME behaviour - I need a remedy?? "R.Wieser" <address@not.available> - 2019-07-31 18:22 +0200
            Re: Firefox changed IFRAME behaviour - I need a remedy?? dr.j.r.stockton@gmail.com - 2019-08-02 02:37 -0700
              Re: Firefox changed IFRAME behaviour - I need a remedy?? "R.Wieser" <address@not.available> - 2019-08-02 13:38 +0200
                Re: Firefox changed IFRAME behaviour - I need a remedy?? dr.j.r.stockton@gmail.com - 2019-08-02 05:59 -0700
                  Re: Firefox changed IFRAME behaviour - I need a remedy?? "R.Wieser" <address@not.available> - 2019-08-02 17:55 +0200
                  Re: Firefox changed IFRAME behaviour - I need a remedy?? "Michael Haufe (TNO)" <tno@thenewobjective.com> - 2019-08-02 15:57 -0700
                    Re: Firefox changed IFRAME behaviour - I need a remedy?? dr.j.r.stockton@gmail.com - 2019-08-03 06:11 -0700
                    Re: Firefox changed IFRAME behaviour - I need a remedy?? Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2019-08-04 11:44 +0200
                Re: Firefox changed IFRAME behaviour - I need a remedy?? "Michael Haufe (TNO)" <tno@thenewobjective.com> - 2019-08-02 15:10 -0700
                  Re: Firefox changed IFRAME behaviour - I need a remedy?? "R.Wieser" <address@not.available> - 2019-08-03 08:59 +0200
                  OT: Re: Firefox changed IFRAME behaviour - I need a remedy?? dr.j.r.stockton@gmail.com - 2019-08-03 05:18 -0700
                    Re: OT: Re: Firefox changed IFRAME behaviour - I need a remedy?? "Evertjan." <exxjxw.hannivoort@inter.nl.net> - 2019-08-03 15:27 +0200
                      Re: OT: Re: Firefox changed IFRAME behaviour - I need a remedy?? dr.j.r.stockton@gmail.com - 2019-08-03 09:28 -0700
                        Re: OT: Re: Firefox changed IFRAME behaviour - I need a remedy?? "Evertjan." <exxjxw.hannivoort@inter.nl.net> - 2019-08-04 12:32 +0200
                  Re: Firefox changed IFRAME behaviour - I need a remedy?? Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2019-08-04 11:30 +0200
                    Re: Firefox changed IFRAME behaviour - I need a remedy?? "Michael Haufe (TNO)" <tno@thenewobjective.com> - 2019-08-04 15:31 -0700
                      Re: Firefox changed IFRAME behaviour - I need a remedy?? Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2019-08-05 13:48 +0200
                        Re: Firefox changed IFRAME behaviour - I need a remedy?? "Michael Haufe (TNO)" <tno@thenewobjective.com> - 2019-08-05 16:51 -0700
                          Re: Firefox changed IFRAME behaviour - I need a remedy?? Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2019-08-07 01:42 +0200
                            Re: Firefox changed IFRAME behaviour - I need a remedy?? "Michael Haufe (TNO)" <tno@thenewobjective.com> - 2019-08-07 01:47 -0700
                              Re: Firefox changed IFRAME behaviour - I need a remedy?? Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2019-08-08 20:56 +0200
                                Re: Firefox changed IFRAME behaviour - I need a remedy?? "Michael Haufe (TNO)" <tno@thenewobjective.com> - 2019-08-08 13:16 -0700
                                  Re: Firefox changed IFRAME behaviour - I need a remedy?? Martin Leese <please@see.Web.for.e-mail.INVALID> - 2019-08-08 23:57 -0600
                                  Re: Firefox changed IFRAME behaviour - I need a remedy?? Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2019-08-09 12:48 +0200
                      Re: Firefox changed IFRAME behaviour - I need a remedy?? dr.j.r.stockton@gmail.com - 2019-08-05 06:37 -0700
                        Re: Firefox changed IFRAME behaviour - I need a remedy?? John G Harris <niam@jghnorth.org.uk.invalid> - 2019-08-05 18:46 +0100
                          Re: Firefox changed IFRAME behaviour - I need a remedy?? dr.j.r.stockton@gmail.com - 2019-08-06 03:39 -0700
                        Re: Firefox changed IFRAME behaviour - I need a remedy?? "Michael Haufe (TNO)" <tno@thenewobjective.com> - 2019-08-05 17:30 -0700
              Re: Firefox changed IFRAME behaviour - I need a remedy?? "Michael Haufe (TNO)" <tno@thenewobjective.com> - 2019-08-02 15:05 -0700
        Re: Firefox changed IFRAME behaviour - I need a remedy?? "Michael Haufe (TNO)" <tno@thenewobjective.com> - 2019-07-31 18:58 -0700
          Re: Firefox changed IFRAME behaviour - I need a remedy?? dr.j.r.stockton@gmail.com - 2019-08-02 05:01 -0700
            Re: Firefox changed IFRAME behaviour - I need a remedy?? "Michael Haufe (TNO)" <tno@thenewobjective.com> - 2019-08-02 16:07 -0700
              Re: Firefox changed IFRAME behaviour - I need a remedy?? dr.j.r.stockton@gmail.com - 2019-08-03 08:19 -0700
                Re: Firefox changed IFRAME behaviour - I need a remedy?? "Michael Haufe (TNO)" <tno@thenewobjective.com> - 2019-08-03 18:42 -0700
                  Re: Firefox changed IFRAME behaviour - I need a remedy?? Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2019-08-04 11:27 +0200

Page 2 of 3 — ← Prev page 1 [2] 3  Next page →


#37034 — Re: OT: Re: Firefox changed IFRAME behaviour - I need a remedy??

Fromdr.j.r.stockton@gmail.com
Date2019-08-03 09:28 -0700
SubjectRe: OT: Re: Firefox changed IFRAME behaviour - I need a remedy??
Message-ID<8c844e7a-38bf-4a52-9898-e44faf164586@googlegroups.com>
In reply to#37032
On Saturday, 3 August 2019 14:27:39 UTC+1, Evertjan.  wrote:
> JRS wrote on 03 Aug 2019 in comp.lang.javascript:
> 
> > But the variable names and the comment were all in Hungarian,
> > which did not help us to understand the algorithm itself.
> 
> Did they sound like <https://youtu.be/LdH1hSWGFGU?t=7>? 

Well, the audible words were identical, being empty sets.

But "Thank You", as I thought to check whether that work was in
my Culture List, and found that my List was completely Lisztless,
which I have now remedied by adding that work.

-- 
  (c) John Stockton, near London, UK.  Using Google Groups.           |
 Mail: J.R.""""""""@physics.org - or as Reply-To, if any.             |

[toc] | [prev] | [next] | [standalone]


#37041 — Re: OT: Re: Firefox changed IFRAME behaviour - I need a remedy??

From"Evertjan." <exxjxw.hannivoort@inter.nl.net>
Date2019-08-04 12:32 +0200
SubjectRe: OT: Re: Firefox changed IFRAME behaviour - I need a remedy??
Message-ID<XnsAAA17F9596DF9eejj99@194.109.6.166>
In reply to#37034
dr.j.r.stockton@gmail.com wrote on 03 Aug 2019 in comp.lang.javascript:

> On Saturday, 3 August 2019 14:27:39 UTC+1, Evertjan.  wrote:
>> JRS wrote on 03 Aug 2019 in comp.lang.javascript:
>> 
>> > But the variable names and the comment were all in Hungarian,
>> > which did not help us to understand the algorithm itself.
>> 
>> Did they sound like <https://youtu.be/LdH1hSWGFGU?t=7>? 
> 
> Well, the audible words were identical, being empty sets.
> 
> But "Thank You", as I thought to check whether that work was in
> my Culture List, and found that my List was completely Lisztless,
> which I have now remedied by adding that work.

btw:

Rhapsody
from Greek Raps[h]ooidia ["songs sewed together"]
from rháptoo [to sew] + oideh, oodeh [song]
oodeh from aeido [to sing] (cf audio)


-- 
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)

[toc] | [prev] | [next] | [standalone]


#37039

FromThomas 'PointedEars' Lahn <PointedEars@web.de>
Date2019-08-04 11:30 +0200
Message-ID<1783375.m5R59jPM9B@PointedEars.de>
In reply to#37026
Michael Haufe (TNO) wrote:

> [..] Hungarian Notation [..] is reasonable in programming languages
> without a sufficient type system (like modern JavaScript) […]

Are you saying that you think that “modern JavaScript” would have a 
“sufficient type system”?

-- 
PointedEars
FAQ: <http://PointedEars.de/faq> | <http://PointedEars.de/es-matrix>
<https://github.com/PointedEars> | <http://PointedEars.de/wsvn/>
Twitter: @PointedEars2 | Please do not cc me./Bitte keine Kopien per E-Mail.

[toc] | [prev] | [next] | [standalone]


#37042

From"Michael Haufe (TNO)" <tno@thenewobjective.com>
Date2019-08-04 15:31 -0700
Message-ID<4d37f8fe-1e46-4eac-8e1b-df9756377688@googlegroups.com>
In reply to#37039
On Sunday, August 4, 2019 at 4:30:55 AM UTC-5, Thomas 'PointedEars' Lahn wrote:
> Michael Haufe (TNO) wrote:
> 
> > [..] Hungarian Notation [..] is reasonable in programming languages
> > without a sufficient type system (like modern JavaScript) […]
> 
> Are you saying that you think that “modern JavaScript” would have a 
> “sufficient type system”?

No. By "sufficient" I mean expressive enough to represent and enforce the semantic meaning of what the notation represents. Example:

var imgBird;

vs.

var bird: Image; 

JavaScript still lacks any meaningful syntactic means of such representation. There not even anything significant on the road map[1].

[1] https://github.com/tc39/proposals

[toc] | [prev] | [next] | [standalone]


#37043

FromThomas 'PointedEars' Lahn <PointedEars@web.de>
Date2019-08-05 13:48 +0200
Message-ID<1676946.idUJCsOoGn@PointedEars.de>
In reply to#37042
Michael Haufe (TNO) wrote:

> On Sunday, August 4, 2019 at 4:30:55 AM UTC-5, Thomas 'PointedEars' Lahn
> wrote:
>> Michael Haufe (TNO) wrote:
>> > [..] Hungarian Notation [..] is reasonable in programming languages
>> > without a sufficient type system (like modern JavaScript) […]
>> 
>> Are you saying that you think that “modern JavaScript” would have a
>> “sufficient type system”?
> 
> No. By "sufficient" I mean expressive enough to represent and enforce the
> semantic meaning of what the notation represents. Example:
> 
> var imgBird;
> 
> vs.
> 
> var bird: Image;

But that is merely your *opinion*.  Apparently more people think that the 
current ECMAScript type system is sufficient than not, either because they 
do not care; because they are using ECMAScript implementations like Dart, 
TypeScript, and Flow that have static type-checking natively; or because
they use precompilers or some other way to enforce types.

<https://www.freecodecamp.org/news/why-use-static-types-in-javascript-part-1-8382da1e0adb/>

<https://developerhowto.com/2019/01/05/statically-typed-javascript-why-and-how/>

And the JavaScripts (sic) are not alone in this approach of *dynamic* type-
checking, and *implicit* type conversion.  Example: Python.

It is a matter of approach, not an objective measure of sufficiency.
 
> JavaScript still lacks any meaningful syntactic means of such
> representation. There not even anything significant on the road map[1].

That depends on what you consider “JavaScript” to be, but it is mostly true.
 
-- 
PointedEars
FAQ: <http://PointedEars.de/faq> | <http://PointedEars.de/es-matrix>
<https://github.com/PointedEars> | <http://PointedEars.de/wsvn/>
Twitter: @PointedEars2 | Please do not cc me./Bitte keine Kopien per E-Mail.

[toc] | [prev] | [next] | [standalone]


#37046

From"Michael Haufe (TNO)" <tno@thenewobjective.com>
Date2019-08-05 16:51 -0700
Message-ID<b3cfd873-a37c-49ab-a64a-82335b6bb137@googlegroups.com>
In reply to#37043
On Monday, August 5, 2019 at 6:48:40 AM UTC-5, Thomas 'PointedEars' Lahn wrote:
> Michael Haufe (TNO) wrote:
> 
> > On Sunday, August 4, 2019 at 4:30:55 AM UTC-5, Thomas 'PointedEars' Lahn
> > wrote:
> >> Michael Haufe (TNO) wrote:
> >> > [..] Hungarian Notation [..] is reasonable in programming languages
> >> > without a sufficient type system (like modern JavaScript) […]
> >> 
> >> Are you saying that you think that “modern JavaScript” would have a
> >> “sufficient type system”?
> > 
> > No. By "sufficient" I mean expressive enough to represent and enforce the
> > semantic meaning of what the notation represents. Example:
> > 
> > var imgBird;
> > 
> > vs.
> > 
> > var bird: Image;
> 
> But that is merely your *opinion*.  Apparently more people think that the 
> current ECMAScript type system is sufficient than not, either because they 
> do not care; because they are using ECMAScript implementations like Dart, 
> TypeScript, and Flow that have static type-checking natively; or because
> they use precompilers or some other way to enforce types.

It is less of an opinion than you think. You've even admitted so without realizing it:

1. You can't make a claim about sufficiency either way if you don't care about using a proper level of abstraction. I could name every variable with a single letter and get by. For example, look at Mentifakes code. This is a non-argument.

2. If you're using a superset or an alternative language for your medium of expression then you've admitted an insufficiency.

Either your language can represent and enforce your domain or discourse, or it can't. 

Also, since when is Dart an ECMAScript implementation?

> And the JavaScripts (sic) are not alone in this approach of *dynamic* type-
> checking, and *implicit* type conversion.  Example: Python.
> 
> It is a matter of approach, not an objective measure of sufficiency.

You're making an orthogonal argument. Type conversion and dynamic checking is irrelevant. You have information encoded inside of a variable name. This is the same smell as using Stringly Typed programming: The meaning of the program is not part of the program.

> > JavaScript still lacks any meaningful syntactic means of such
> > representation. There not even anything significant on the road map[1].
> 
> That depends on what you consider “JavaScript” to be, but it is mostly true.

I'm referring to "JavaScript" primarily as ES3 -> ES2019 and the common implementations thereof without extensions.

[toc] | [prev] | [next] | [standalone]


#37053

FromThomas 'PointedEars' Lahn <PointedEars@web.de>
Date2019-08-07 01:42 +0200
Message-ID<2255007.fJ7HjIvnrp@PointedEars.de>
In reply to#37046
Michael Haufe (TNO) wrote:

> On Monday, August 5, 2019 at 6:48:40 AM UTC-5, Thomas 'PointedEars' Lahn
> wrote:
>> Michael Haufe (TNO) wrote:
>> > No. By "sufficient" I mean expressive enough to represent and enforce
>> > the semantic meaning of what the notation represents. Example:
>> > 
>> > var imgBird;
>> > 
>> > vs.
>> > 
>> > var bird: Image;
>> 
>> But that is merely your *opinion*.  Apparently more people think that the
>> current ECMAScript type system is sufficient than not, either because
>> they do not care; because they are using ECMAScript implementations like
>> Dart, TypeScript, and Flow that have static type-checking natively; or
>> because they use precompilers or some other way to enforce types.
> 
> It is less of an opinion than you think.

It is more of an opinion than *you* think.

> You've even admitted so without
> realizing it:
> 
> 1. You can't make a claim about sufficiency either way if you don't care
> about using a proper level of abstraction. I could name every variable
> with a single letter and get by. For example, look at Mentifakes code.
> This is a non-argument.

Fallacy: Slippery slope.
 
> 2. If you're using a superset or an alternative language for your medium
> of expression then you've admitted an insufficiency.

Fallacy: Affirming the antecedent.
 
> Either your language can represent and enforce your domain or discourse,
> or it can't.

Fallacy: False dilemma.
 
> Also, since when is Dart an ECMAScript implementation?

Apparently it is not, and the author of the cited article has confused the 
fact that it is also an Ecma standard with the idea that it were also an 
ECMAScript implementation.

<https://dart.dev/guides/language/specifications/DartLangSpec-v2.2.pdf>
 
>> And the JavaScripts (sic) are not alone in this approach of *dynamic*
>> type-checking, and *implicit* type conversion.  Example: Python.
>> 
>> It is a matter of approach, not an objective measure of sufficiency.
> 
> You're making an orthogonal argument.

Not at all.

> Type conversion and dynamic checking is irrelevant.

No, it is not.  First of all, I said “*implicit* type conversion”; and 
second, in many cases these two features *are* sufficient to implement
an algorithm.

> You have information encoded inside of a variable name.

In a well-written program you have *always* information “encoded [_in_] […] 
a variable [_identifier_]”.  That is the *purpose* of a variable identifier.

<https://github.com/airbnb/javascript#naming--descriptive>

And Hungarian notation was *your* idea as the *only* alternative to static 
type-checking.  It is not.

> This is the same smell as using Stringly Typed programming: The meaning of
> the program is not part of the program.

That is another fallacy.  This time I leave it to you to find out the type.
 
>> > JavaScript still lacks any meaningful syntactic means of such
>> > representation. There not even anything significant on the road map[1].
>> That depends on what you consider “JavaScript” to be, but it is mostly
>> true.
> 
> I'm referring to "JavaScript" primarily as ES3 -> ES2019 and the common
> implementations thereof without extensions.

That is much too broad a statement, then.

-- 
PointedEars
FAQ: <http://PointedEars.de/faq> | <http://PointedEars.de/es-matrix>
<https://github.com/PointedEars> | <http://PointedEars.de/wsvn/>
Twitter: @PointedEars2 | Please do not cc me./Bitte keine Kopien per E-Mail.

[toc] | [prev] | [next] | [standalone]


#37054

From"Michael Haufe (TNO)" <tno@thenewobjective.com>
Date2019-08-07 01:47 -0700
Message-ID<e3fbff47-c5f1-47fb-b8a4-e8c071ea0146@googlegroups.com>
In reply to#37053
On Tuesday, August 6, 2019 at 6:42:49 PM UTC-5, Thomas 'PointedEars' Lahn wrote:
> Michael Haufe (TNO) wrote:
> 
> > On Monday, August 5, 2019 at 6:48:40 AM UTC-5, Thomas 'PointedEars' Lahn
> > wrote:
> >> Michael Haufe (TNO) wrote:
> >> > No. By "sufficient" I mean expressive enough to represent and enforce
> >> > the semantic meaning of what the notation represents. Example:
> >> > 
> >> > var imgBird;
> >> > 
> >> > vs.
> >> > 
> >> > var bird: Image;
> >> 
> >> But that is merely your *opinion*.  Apparently more people think that the
> >> current ECMAScript type system is sufficient than not, either because
> >> they do not care; because they are using ECMAScript implementations like
> >> Dart, TypeScript, and Flow that have static type-checking natively; or
> >> because they use precompilers or some other way to enforce types.
> > 
> > It is less of an opinion than you think.
> 
> It is more of an opinion than *you* think.
> 
> > You've even admitted so without
> > realizing it:
> > 
> > 1. You can't make a claim about sufficiency either way if you don't care
> > about using a proper level of abstraction. I could name every variable
> > with a single letter and get by. For example, look at Mentifakes code.
> > This is a non-argument.
> 
> Fallacy: Slippery slope.

Missapplied categorization.

You've defined "sufficient" as a function of not caring or as a property of some alternative language. This is not even wrong [1]

> > 2. If you're using a superset or an alternative language for your medium
> > of expression then you've admitted an insufficiency.
> 
> Fallacy: Affirming the antecedent.

Modus Ponens is an inference rule, not a fallacy. You stated the proposition, I stated the implication.

> > Either your language can represent and enforce your domain or discourse,
> > or it can't.
> 
> Fallacy: False dilemma.

You can't be half pregnant nor half stupid. If you think this is not a binary choice, present another.
 
> > Also, since when is Dart an ECMAScript implementation?
> 
> Apparently it is not, and the author of the cited article has confused the 
> fact that it is also an Ecma standard with the idea that it were also an 
> ECMAScript implementation.
> 
> <https://dart.dev/guides/language/specifications/DartLangSpec-v2.2.pdf>

...and you did not do your due diligence before using it as reference. 
Given your anal-retentiveness on the topic and how much you attack other group members over it, I hope this becomes a learning moment.

 
> > Type conversion and dynamic checking is irrelevant.
> 
> No, it is not.  First of all, I said “*implicit* type conversion”; and 
> second, in many cases these two features *are* sufficient to implement
> an algorithm.

This is still irrelevant to the topic of Hungarian Notation. 
An algorithm has nothing to do with it, and a type system is also directly irrelevant to that.

> > You have information encoded inside of a variable name.
> 
> In a well-written program you have *always* information “encoded [_in_] […] 
> a variable [_identifier_]”.  That is the *purpose* of a variable identifier.

Bonus points for misunderstanding Hungarian Notation and the point I made.

Yes, variable names have semantic meaning to the programmer. 
Hungarian Notation extends this with extra-linguistic typing information such as 'intAge'.

This is a problem because the developer is now playing the role of type checker instead of the language.
How do I know that 'Age' is an 'int'? Because I said so, or because the language said so?
Does that mean the developer is wrong to do so? Only if there are lingustic mechanisms available to fulfill this role.

> And Hungarian notation was *your* idea as the *only* alternative to static 
> type-checking.  It is not.

Quote me where I said this. This is FUD.

> > This is the same smell as using Stringly Typed programming: The meaning of
> > the program is not part of the program.
> 
> That is another fallacy.  This time I leave it to you to find out the type.

It's called "Lahn's false assumption"

> >> > JavaScript still lacks any meaningful syntactic means of such
> >> > representation. There not even anything significant on the road map[1].
> >> That depends on what you consider “JavaScript” to be, but it is mostly
> >> true.
> > 
> > I'm referring to "JavaScript" primarily as ES3 -> ES2019 and the common
> > implementations thereof without extensions.
> 
> That is much too broad a statement, then.

I could have made it broader and still be accurate. Though I still wouldn't have included Dart in my list...

[1] https://en.wikipedia.org/wiki/Not_even_wrong

[toc] | [prev] | [next] | [standalone]


#37058

FromThomas 'PointedEars' Lahn <PointedEars@web.de>
Date2019-08-08 20:56 +0200
Message-ID<2492403.mvXUDI8C0e@PointedEars.de>
In reply to#37054
Michael Haufe (TNO) wrote:

> On Tuesday, August 6, 2019 at 6:42:49 PM UTC-5, Thomas 'PointedEars' Lahn
> wrote:
>> Michael Haufe (TNO) wrote:
>> > You've even admitted so without
>> > realizing it:
>> > 
>> > 1. You can't make a claim about sufficiency either way if you don't
>> > care about using a proper level of abstraction. I could name every
>> > variable with a single letter and get by. For example, look at
>> > Mentifakes code. This is a non-argument.
>> Fallacy: Slippery slope.
> 
> Missapplied categorization.
> 
> You've defined "sufficient" as a function of not caring or as a property
> of some alternative language. This is not even wrong [1]

Nonsense.  What is deemed “sufficient” obviously means different things for 
different people.

>> > 2. If you're using a superset or an alternative language for your
>> > medium of expression then you've admitted an insufficiency.
>> 
>> Fallacy: Affirming the antecedent.
> 
> Modus Ponens is an inference rule, not a fallacy. You stated the
> proposition, I stated the implication.

This was not /modus ponens/.
 
>> > Either your language can represent and enforce your domain or
>> > discourse, or it can't.
>> Fallacy: False dilemma.
> 
> You can't be half pregnant nor half stupid. If you think this is not a
> binary choice, present another.

Something can be satisfactory or sufficient (the two words are synonymous) 
in one aspect, but not in another; and it is also possible that it can be 
that for one person, but not another.
  
>> > Also, since when is Dart an ECMAScript implementation?
>> 
>> Apparently it is not, and the author of the cited article has confused
>> the fact that it is also an Ecma standard with the idea that it were also
>> an ECMAScript implementation.
>> 
>> <https://dart.dev/guides/language/specifications/DartLangSpec-v2.2.pdf>
> 
> ...and you did not do your due diligence before using it as reference.

I said “apparently”.

> Given your anal-retentiveness on the topic

In addition to that I take exception to your characterization,
I strongly recommend that you update your knowledge about psychology.

>> > Type conversion and dynamic checking is irrelevant.
>> 
>> No, it is not.  First of all, I said “*implicit* type conversion”; and
>> second, in many cases these two features *are* sufficient to implement
>> an algorithm.
> 
> This is still irrelevant to the topic of Hungarian Notation.

A solution that *you* introduced to the discussion.  There is no requirement 
for Hungarian notation.

> An algorithm has nothing to do with it,

Yes, it does.

> and a type system is also directly irrelevant to that.

No, it is not.  In fact, there is a greater variety of algorithms that can 
be implemented, and a greater flexibility and ease in implementing 
algorithms, if the implementation is not required to satisfy a more rigid 
type system.

That is one reason why, for example, C++ introduced template classes, why 
J2SE 5.0+ finally has generics, and why they were added to C# and VB .NET a 
year later.
 
>> > You have information encoded inside of a variable name.
>> 
>> In a well-written program you have *always* information “encoded [_in_]
>> […]
>> a variable [_identifier_]”.  That is the *purpose* of a variable
>> identifier.
> 
> Bonus points for misunderstanding Hungarian Notation and the point I made.

Unfortunately, it turns out that your introduction of Hungarian notation 
into the discussion was basically a red herring to push your false dichotomy 
down people’s throats.  And I do not bite. 

> [tl;dr]
 
-- 
PointedEars
FAQ: <http://PointedEars.de/faq> | <http://PointedEars.de/es-matrix>
<https://github.com/PointedEars> | <http://PointedEars.de/wsvn/>
Twitter: @PointedEars2 | Please do not cc me./Bitte keine Kopien per E-Mail.

[toc] | [prev] | [next] | [standalone]


#37060

From"Michael Haufe (TNO)" <tno@thenewobjective.com>
Date2019-08-08 13:16 -0700
Message-ID<9c462603-c7b4-4174-9d0d-7c3fee35a3c7@googlegroups.com>
In reply to#37058
On Thursday, August 8, 2019 at 1:56:08 PM UTC-5, Thomas 'PointedEars' Lahn wrote:
> Michael Haufe (TNO) wrote:
> 
> > You've defined "sufficient" as a function of not caring or as a property
> > of some alternative language. This is not even wrong [1]
> 
> Nonsense.  What is deemed “sufficient” obviously means different things for 
> different people.

Read your own damned words:

On Monday, August 5, 2019 at 6:48:40 AM UTC-5, Thomas 'PointedEars' Lahn wrote:
> But that is merely your *opinion*.  Apparently more people think that the
> current ECMAScript type system is sufficient than not, either because
> they do not care; because they are using ECMAScript implementations like
> Dart, TypeScript, and Flow that have static type-checking natively; or

Anyway, onto more foot-in-mouth:

> >> > 2. If you're using a superset or an alternative language for your
> >> > medium of expression then you've admitted an insufficiency.
> >> 
> >> Fallacy: Affirming the antecedent.
> > 
> > Modus Ponens is an inference rule, not a fallacy. You stated the
> > proposition, I stated the implication.
> 
> This was not /modus ponens/.

<https://en.wikipedia.org/wiki/Affirming_the_antecedent>
<https://www.thefreedictionary.com/Affirming+the+antecedent>

You were saying?

> >> > Either your language can represent and enforce your domain or
> >> > discourse, or it can't.
> >> Fallacy: False dilemma.
> > 
> > You can't be half pregnant nor half stupid. If you think this is not a
> > binary choice, present another.
> 
> Something can be satisfactory or sufficient (the two words are synonymous) 
> in one aspect, but not in another; and it is also possible that it can be 
> that for one person, but not another.

In other words meaningless as a term. That's why I gave an explicit definition.
Responding to my definition by saying: "But it can mean something else" is just noise, especially when no alternative definition is provided.

> >> > Also, since when is Dart an ECMAScript implementation?
> >> 
> >> Apparently it is not, and the author of the cited article has confused
> >> the fact that it is also an Ecma standard with the idea that it were also
> >> an ECMAScript implementation.
> >> 
> >> <https://dart.dev/guides/language/specifications/DartLangSpec-v2.2.pdf>
> > 
> > ...and you did not do your due diligence before using it as reference.
> 
> I said “apparently”.

You shifted the blame.

> > Given your anal-retentiveness on the topic
> 
> In addition to that I take exception to your characterization,
> I strongly recommend that you update your knowledge about psychology.

Fair enough. From <https://en.wikipedia.org/wiki/Anal_retentiveness>:

"...a person who pays such attention to detail that it becomes an 
obsession and may be an annoyance to others, potentially to the 
detriment of the anal-retentive person."

Let's find an existence proof of this to see if the characterization fits:

<https://groups.google.com/forum/#!searchin/comp.lang.javascript/there$20is$20no$20such$20thing$20as$20javascript%7Csort:date/comp.lang.javascript/XXjok6stN8s/uazYtjPswRUJ>

I also found Scott's picture:

<https://i.imgur.com/5UhdL.png>

So draw your own conclusion.

> >> > Type conversion and dynamic checking is irrelevant.
> >> 
> >> No, it is not.  First of all, I said “*implicit* type conversion”; and
> >> second, in many cases these two features *are* sufficient to implement
> >> an algorithm.
> > 
> > This is still irrelevant to the topic of Hungarian Notation.
> 
> A solution that *you* introduced to the discussion.  There is no requirement 
> for Hungarian notation.

1. I didn't introduce it, I named it in response to Stockton's initial confusion and Weiser's description.
2. I didn't say it was required, nor suggested it was a solution. I supported Wieser's decision

<https://groups.google.com/d/msg/comp.lang.javascript/jOKBKMi6Bvw/OSn-Ia4jEQAJ>

> > An algorithm has nothing to do with it,
> 
> Yes, it does.

Then demonstrate.

> > and a type system is also directly irrelevant to that.
> 
> No, it is not.  In fact, there is a greater variety of algorithms that can 
> be implemented, and a greater flexibility and ease in implementing 
> algorithms, if the implementation is not required to satisfy a more rigid 
> type system.

Again, demonstrate how this is relevant in any way to Hungarian Notation...

> That is one reason why, for example, C++ introduced template classes, why 
> J2SE 5.0+ finally has generics, and why they were added to C# and VB .NET a 
> year later.

And why dogs with square assholes shit bricks. Again, what's the relevancy to Hungarian Notation?

> Unfortunately, it turns out that your introduction of Hungarian notation 
> into the discussion was basically a red herring to push your false dichotomy 
> down people’s throats.  And I do not bite. 

No, it was you dipping into the Kool-Aid and not knowing the flavor.

[toc] | [prev] | [next] | [standalone]


#37063

FromMartin Leese <please@see.Web.for.e-mail.INVALID>
Date2019-08-08 23:57 -0600
Message-ID<qij20k$rkb$1@dont-email.me>
In reply to#37060
Michael Haufe (TNO) wrote:
...
> I also found Scott's picture:
> 
> <https://i.imgur.com/5UhdL.png>

Thank you for that.

-- 
Regards,
Martin Leese
E-mail: please@see.Web.for.e-mail.INVALID
Web: http://members.tripod.com/martin_leese/

[toc] | [prev] | [next] | [standalone]


#37069

FromThomas 'PointedEars' Lahn <PointedEars@web.de>
Date2019-08-09 12:48 +0200
Message-ID<5274396.DvuYhMxLoT@PointedEars.de>
In reply to#37060
Michael Haufe (TNO) wrote:

> On Thursday, August 8, 2019 at 1:56:08 PM UTC-5, Thomas 'PointedEars' Lahn
> wrote:
>> Michael Haufe (TNO) wrote:
>> > You've defined "sufficient" as a function of not caring or as a
>> > property of some alternative language. This is not even wrong [1]
>> Nonsense.  What is deemed “sufficient” obviously means different things
>> for different people.
> 
> Read your own damned words:
> 
> On Monday, August 5, 2019 at 6:48:40 AM UTC-5, Thomas 'PointedEars' Lahn
> wrote:
>> But that is merely your *opinion*.  Apparently more people think that the
>> current ECMAScript type system is sufficient than not, either because
>> they do not care; because they are using ECMAScript implementations like
>> Dart, TypeScript, and Flow that have static type-checking natively; or

Your point being?
 
> Anyway, onto more foot-in-mouth:
> 
>> >> > 2. If you're using a superset or an alternative language for your
>> >> > medium of expression then you've admitted an insufficiency.
>> >> 
>> >> Fallacy: Affirming the antecedent.
>> > 
>> > Modus Ponens is an inference rule, not a fallacy. You stated the
>> > proposition, I stated the implication.
>> This was not /modus ponens/.
> 
> <https://en.wikipedia.org/wiki/Affirming_the_antecedent>
> <https://www.thefreedictionary.com/Affirming+the+antecedent>
> 
> You were saying?

Ah yes, I meant *the fallacy* instead, affirming the _consequent_.

>> >> > Either your language can represent and enforce your domain or
>> >> > discourse, or it can't.
>> >> Fallacy: False dilemma.
>> > You can't be half pregnant nor half stupid. If you think this is not a
>> > binary choice, present another.
>> 
>> Something can be satisfactory or sufficient (the two words are
>> synonymous) in one aspect, but not in another; and it is also possible
>> that it can be that for one person, but not another.
> 
> In other words meaningless as a term.

Not at all.

> That's why I gave an explicit definition.

You gave *your* definition *of* what would be sufficient.  Do you see the 
difference?

> Responding to my definition by saying: "But it can mean something else"

I did NOT say that.

> is just noise,

No.

> especially when no alternative definition is provided.

Irrelevant.
 
>> >> > Also, since when is Dart an ECMAScript implementation?
>> >> 
>> >> Apparently it is not, and the author of the cited article has confused
>> >> the fact that it is also an Ecma standard with the idea that it were
>> >> also an ECMAScript implementation.
>> >> 
>> >> <https://dart.dev/guides/language/specifications/DartLangSpec-v2.2.pdf>
>> > 
>> > ...and you did not do your due diligence before using it as reference.
>> 
>> I said “apparently”.
> 
> You shifted the blame.

Not at all.
 
Given your attitude, there is no point to continue discussing from here.

-- 
PointedEars
FAQ: <http://PointedEars.de/faq> | <http://PointedEars.de/es-matrix>
<https://github.com/PointedEars> | <http://PointedEars.de/wsvn/>
Twitter: @PointedEars2 | Please do not cc me./Bitte keine Kopien per E-Mail.

[toc] | [prev] | [next] | [standalone]


#37044

Fromdr.j.r.stockton@gmail.com
Date2019-08-05 06:37 -0700
Message-ID<6ae11803-5816-487b-8392-f76513fe423a@googlegroups.com>
In reply to#37042
On Sunday, 4 August 2019 23:31:25 UTC+1, Michael Haufe (TNO)  wrote:
> On Sunday, August 4, 2019 at 4:30:55 AM UTC-5, Thomas 'PointedEars' Lahn wrote:
> > Michael Haufe (TNO) wrote:
> > 
> > > [..] Hungarian Notation [..] is reasonable in programming languages
> > > without a sufficient type system (like modern JavaScript) […]
> > 
> > Are you saying that you think that “modern JavaScript” would have a 
> > “sufficient type system”?
> 
> No. By "sufficient" I mean expressive enough to represent and enforce the semantic meaning of what the notation represents. Example:


There is a possible extension to the idea of type checking/notation - it applies only to variables of type Number (and for completeness possibly those which can be coerced into a Number), and it is Dimension Checking.  

Thirty years ago. the language AMPERE had it.

Years ago, I wrote

8<---

Search results, 2007-03-25 :-

An IoP page "European Journal of Physics / Volume 11, Number 3,
May 1990" includes :-

163  AMPERE: a programming language for physics
     M Babout, H Sidhoum and L Frecon
     Abstract  |  References       Full text:  Acrobat PDF (684 KB)

but that PDF is subscribers-only. The Abstract is accessible at
IoP. Abstract and References is accessible at UIUC.
Bibliographic Reference :- M Babout et al 1990 Eur. J. Phys. 11 163-171.
AMPERE: un langage de programmation pour la physique. Michel Babout, Hafid Sidhoum et Louis Frecon.

At CNRS :- Résumé - Conception et compilation du langage Ampère 2: langage modulaire pour la programmation physique. That is catalogue entry for a different paper, authors given as "Sidhoum Hafid ; Frecon Louis".

--->8

That contained 4 links; today, 3 are 404 and the other is at
best asleep.


Think back to school elementary mechanics.

Tell a compiler that :
Distance is a Number of Metres
Time is a Number of Seconds

It is not sensible to add/subtract one of each, and an Ampere
compiler would reject that; but they can be divided in two ways,
to get Speed in M/S or Sloth in S/M; and they can be multiplied
to get M.S which is potentially meaningful.

One could also use it in finance : Men * Hours * PayRate = Earnings
Etc : Men / Hours * ConversionFactor = DoorWidth



https://iopscience.iop.org/article/10.1088/0143-0807/11/3/007/pdf
https://www.theses.fr/1991ISAL0053

A truly francophone Googler might be able to locate a full, free
copy of the paper by said authors.


-- 
  (c) John Stockton, near London, UK.  Using Google Groups.           |
 Mail: J.R.""""""""@physics.org - or as Reply-To, if any.             |

[toc] | [prev] | [next] | [standalone]


#37045

FromJohn G Harris <niam@jghnorth.org.uk.invalid>
Date2019-08-05 18:46 +0100
Message-ID<sqqgkehlpqustvkst5nl4mh5kui5tga2uq@4ax.com>
In reply to#37044
On Mon, 5 Aug 2019 06:37:24 -0700 (PDT), dr.j.r.stockton@gmail.com
wrote:

  <snip>
>There is a possible extension to the idea of type checking/notation - it applies only to variables of type Number (and for completeness possibly those which can be coerced into a Number), and it is Dimension Checking.  
>
>Thirty years ago. the language AMPERE had it.
  <snip>

Modern C++ can do that as well. See Stroustrup, 4th ed, section 28.7.

  John

[toc] | [prev] | [next] | [standalone]


#37050

Fromdr.j.r.stockton@gmail.com
Date2019-08-06 03:39 -0700
Message-ID<e2f3c3b3-b157-4aea-b272-657b06321237@googlegroups.com>
In reply to#37045
On Monday, 5 August 2019 18:46:59 UTC+1, John G Harris  wrote:
> On Mon, 5 Aug 2019 06:37:24 -0700 (PDT), JRS wrote:
> 
>   <snip>
> >There is a possible extension to the idea of type checking/notation - it applies only to variables of type Number (and for completeness possibly those which can be coerced into a Number), and it is Dimension Checking.  
> >
> >Thirty years ago. the language AMPERE had it.
>   <snip>
> 
> Modern C++ can do that as well. See Stroustrup, 4th ed, section 28.7.

Alas, my Stoustrup is only Second Edition, and lacks an Update button.


Another extension, which I myself implemented in Borland Pascal many years ago, would be to represent the accuracy and confidence of the value of a Number.  I can recall the essence of how I did it, but not the details.

I'll describe it in pseudo-EcmaScript3.

Firstly, write the calculation in the normal way.  Then replace all of the operators with function calls (which can be overloaded on to the operators, rendering the difference invisible) and all of the Number variables with
a constructed type, X, of Object variables.

An X would contain, as Number elements[*], the Value itself, the RMS Uncertainty, the Arithmetic Uncertainty, anything else useful, and the Trustworthiness (represented by a simple sortable type such as a Byte).

Any of the aforementioned functions would return a result of type X, in which the Trustworthiness would be the least of those of its inputs, the Value would be calculated as in the normal way, and the Uncertainties would be calculated by the well-established rules.

Trustworthiness could include :-
  Invalid - for testing output layout disregarding the numeric values
  Exact   - an integer of undisputable value
  Certain - an integer of unproven value
  Typical - for test, a plausible value
  Close   - any real number which is exactly known but is not exactly
            represented as an IEEE Double, e.g. Pi and the charge of
            an electron, exactly 1.602176634×10^−19 from 2019-05-20
  Correct - Good but not TNS
  TNS     - Traceable to National Standards

That is not a definitive or sufficient list of Trustworthiness.
Close elements would be initialised with uncertainties of half an LSB or more.

One needs also an output procedure which represents, sufficiently completely, the content of an X.  For on-screen Trustworthiness, I used the colour.


[*] That could be extended to X-or-Number elements, if thought useful.
[+] https://en.wikipedia.org/wiki/2019_redefinition_of_the_SI_base_units

-- 
  (c) John Stockton, near London, UK.  Using Google Groups.           |
 Mail: J.R.""""""""@physics.org - or as Reply-To, if any.             |

[toc] | [prev] | [next] | [standalone]


#37047

From"Michael Haufe (TNO)" <tno@thenewobjective.com>
Date2019-08-05 17:30 -0700
Message-ID<86dd15a4-63d6-4304-b068-47a06a73564b@googlegroups.com>
In reply to#37044
On Monday, August 5, 2019 at 8:37:30 AM UTC-5, dr.j.r...@gmail.com wrote:

> There is a possible extension to the idea of type checking/notation - it applies only to variables of type Number (and for completeness possibly those which can be coerced into a Number), and it is Dimension Checking.  

Dimensional Analysis is the term I see used most often. 

I believe it was Alan Kay who said that Units of Measure are the type system of the physical world.

I've actually spent a significant amount of time on this topic and have been working on an encoding using Object Algebras[1]. If you follow the work of Guy Steele you can find a significant number of resources related to this topic. For example:

"Object-Oriented Units of Measurement"
<https://web.archive.org/web/20060315063332/http://research.sun.com/projects/plrg/p109-allen.pdf>

> Thirty years ago. the language AMPERE had it.

There are many languages with this feature. Most popular perhaps being F# right now.

F#: <https://docs.microsoft.com/en-us/dotnet/fsharp/language-reference/units-of-measure>

[1] <http://www.cs.utexas.edu/~wcook/Drafts/2012/ecoop2012.pdf>

[toc] | [prev] | [next] | [standalone]


#37025

From"Michael Haufe (TNO)" <tno@thenewobjective.com>
Date2019-08-02 15:05 -0700
Message-ID<6b0cfc14-692f-438f-88f7-a0677db5a93c@googlegroups.com>
In reply to#37020
On Friday, August 2, 2019 at 4:37:19 AM UTC-5, dr.j.r...@gmail.com wrote:

> I use http://wsh2.uw.hu/index.html which is for both VBscript
> and JScript; it is undoubtedly comprehensive (for its time)
> but I find its presentation uncongenial.  But, now I know
> the answer to my question, I'm virtually certain that I could
> easily find the answer there.

The latest version of the documentation (which also old relatively speaking) is the WSH 5.6 Documentation:

<http://download.microsoft.com/download/winscript56/Install/5.6/W982KMeXP/EN-US/scrdoc56en.exe>

[toc] | [prev] | [next] | [standalone]


#37013

From"Michael Haufe (TNO)" <tno@thenewobjective.com>
Date2019-07-31 18:58 -0700
Message-ID<b146df57-cd21-4621-9385-f38b3de47299@googlegroups.com>
In reply to#37009
On Wednesday, July 31, 2019 at 6:14:15 AM UTC-5, dr.j.r...@gmail.com wrote:
> On Wednesday, 31 July 2019 02:24:10 UTC+1, Michael Haufe (TNO)  wrote:
> > I had three different answers for you, but before I could finish each one a new question comes up. Ultimately: Why do you not want to use IIS? It takes minutes to get your site running. Is it only because of distribution? Are these other machines on a shared network? Context, context. What is this project?
> 
> Well, there is a simple answer to the first question - to the best of my recollection, this is the first time I've heard of such a thing being part of Windows.
> 
> I wrote LINXCHEK.HTM for me, to run on my main PC (and I want it to run on any machine I designate as "main" - and late last year I had to redesignate, as my main machine's C hard drive had failed).  I had, IIRC, coded LINXCHEK to be disabled before doing anything useful if loaded from my Web site, since for bandwidth reasons I did not want anyone to download it very frequently (anyone could disable that bit of code; but they would not be able to put the page in MY website) - therefore, I don't know what changes might be needed to make it run fully from a server).
> 
> Other machines might be on networks, but don't share with me.
> 
> The page LINXCHEK.HTM runs a local spider.
> 
> Way back when I had only dial-up Internet, I wanted to be able to check links and anchors on the local master copy of my Web site; I wrote a Borland Pascal 7 program (CHEKLINX.PAS, 16-bit EXE) to empirically parse an HTM page (to help it, I write in a large subset of HTML), get the links and anchors, and check; and it would follow local links to HTM pages, recursively.  When I got Delphi 3 I made a CHEKLINX.EXE (32-bit) with it - and that still runs.
> 
> But when I discovered that HTML has IFRAME, and IFRAME has contentDocument.body, I realised that I can spider the properly-parsed bodies of my local INDEX.HTM page and all local pages that can be reached from it, and do the above much better with many added features (such as checking YYYY-MM-DD DoW) to see if DoW is calendrically correct <g>).  That is  LINXCHEK.HTM.
> 
> And, now that the C drive is a solid-state disc, Firefox processes^Hd  over 200 pages in about 20 seconds.
> 
> LINXCHEK.HTM starts by reading a Directory File, essentially as obtained by previously running Prompt>DIR /b /s > $DIR.TXT .
> 
> 
> For (much) more description, see an older version of the page itself at
> https://web.archive.org/web/20140809171940/http://www.merlyn.demon.co.uk/linxchek.htm
> 
> That will not run when loaded from that server, as the GO-type button is disabled; but one can read the page, and one can download it with Save As and then run it (after making a suitable Directory File).  It would like a stylesheet and an include file, but (IIRC) neither is really needed.
> 
> 
> 
> I've gutted a copy of one of the HTAs that you helped me to write, and intend next to see what happens if I get it to read a whole HTM page into a string
> and assign that string to the innerHTML of a DIV.  If I get a DOM-like tree in the DIV, I can proceed ...
> 
> 
> Must stop, routine medical appointment imminent.
> 
> Thanks, regards,

IIS has been part of windows [1] since Windows NT 3.51. I highly suggest
you use it.

1. Navigate to C:\inetpub\wwwroot.
2. Create a folder for your application/website and copy/move your files there.
   - example: 'merlyn.local'
3. Open the start menu and type "iis". You'll see the application. open it.
  - Assuming Windows 10
  - If on older version of windows, from the Start -> Run command type: "inetmgr" and hit ENTER.
4. On the left side you'll see a tree. Expand it and locate the "Sites" folder
5. Right click on the folder and select "Add Website..."
6. Fill out the form (example entries):
  - Site name: 'merlyn.local'
  - Physical path: The path from step 2: 'C:\inetpub\wwwroot\merlyn.local'
  - Host name: 'merlyn.local'
7. update hosts file for your website
  - Open (as an administrator) 'C:\Windows\System32\drivers\etc\hosts'
  - Follow the example and add a new line to this file:
	127.0.0.1	merlyn.local
  -  save and close. Agai, you need to be an administrator to do this
8. Open your web browser and navigate to: 'http://merlyn.local'
	- or if you are missing an index.html page: 'http://merlyn.local/foo.html'

DONE!

You now have a static website on your machine. You also have an option for server side programming as well.

You can host this as is for free in a number of places. For example on Azure.

If you choose Azure as your hosting provider, you'd have a website like:
<http://merlyn.azurewebsites.net/>

For example if you don't want or can't afford a host name of your own.

Github pages is another free option, but you'll have to understand and use Git.
<https://pages.github.com/>

Other people in the group may have other options for hosting.

Now on to your original problem:

You should be able to display your files like you used to since you now have a proper domain instead of <file://...>.

In regards to checking links, you can use the DOM instead of the file system:

<script>
// This is impressionistic, and not meant for usage as-is
let visited = new Set()

function crawlSite(url) {
    fetch(url).then(function(response){
        // Assuming textual response
        return response.text()
    }).then(function(htmlText){
        var parser = new DOMParser();
        var doc = parser.parseFromString(htmlText, "text/html");
        var links = Array.from(doc.querySelectorAll('a'))
        return links
    }).then(function(links) {
        // Only crawl links inside your own website
        var filteredLinks = links.filter(function(link){
            return link.hostname === document.location.hostname 
                && !visited.has(link.href)
        })
        return filteredLinks
    }).then(function(filteredLinks){
        filteredLinks.forEach(function(link){
            visited.add(link.href)
            crawlSite(link.href)
        })
    }).catch(function(error){
        // report error where appropriate
        console.log('Failed to fetch page: ', err);  
    })
}

//start at root
crawlSite(document.location.hostname)

</script>

You'll want to do this as a Breadth First Search so you don't look at the same page more than once, and additionally you'll want to filter the links to stay in your own domain. Also in my impressionistic example I left out other checks and such to keep it relatively clear. I'm certain other group members can point out bugs and such in my pseudo-code where appropriate

[1] https://en.wikipedia.org/wiki/Internet_Information_Services

[toc] | [prev] | [next] | [standalone]


#37022

Fromdr.j.r.stockton@gmail.com
Date2019-08-02 05:01 -0700
Message-ID<3fed033b-8e62-4d2c-8ebf-5b93cb20971d@googlegroups.com>
In reply to#37013
On Thursday, 1 August 2019 02:58:06 UTC+1, Michael Haufe (TNO)  wrote:
> On Wednesday, July 31, 2019 at 6:14:15 AM UTC-5, dr.j.r...@gmail.com wrote:
> > On Wednesday, 31 July 2019 02:24:10 UTC+1, Michael Haufe (TNO)  wrote:
> > > I had three different answers for you, but before I could finish each one a new question comes up. Ultimately: Why do you not want to use IIS? It takes minutes to get your site running. Is it only because of distribution? Are these other machines on a shared network? Context, context. What is this project?
> > 
> > Well, there is a simple answer to the first question - to the best of my recollection, this is the first time I've heard of such a thing being part of Windows.
> > 
> > I wrote LINXCHEK.HTM for me, to run on my main PC (and I want it to run on any machine I designate as "main" - and late last year I had to redesignate, as my main machine's C hard drive had failed).  I had, IIRC, coded LINXCHEK to be disabled before doing anything useful if loaded from my Web site, since for bandwidth reasons I did not want anyone to download it very frequently (anyone could disable that bit of code; but they would not be able to put the page in MY website) - therefore, I don't know what changes might be needed to make it run fully from a server).
> > 
> > Other machines might be on networks, but don't share with me.
> > 
> > The page LINXCHEK.HTM runs a local spider.
> > 
> > Way back when I had only dial-up Internet, I wanted to be able to check links and anchors on the local master copy of my Web site; I wrote a Borland Pascal 7 program (CHEKLINX.PAS, 16-bit EXE) to empirically parse an HTM page (to help it, I write in a large subset of HTML), get the links and anchors, and check; and it would follow local links to HTM pages, recursively.  When I got Delphi 3 I made a CHEKLINX.EXE (32-bit) with it - and that still runs.
> > 
> > But when I discovered that HTML has IFRAME, and IFRAME has contentDocument.body, I realised that I can spider the properly-parsed bodies of my local INDEX.HTM page and all local pages that can be reached from it, and do the above much better with many added features (such as checking YYYY-MM-DD DoW) to see if DoW is calendrically correct <g>).  That is  LINXCHEK.HTM.
> > 
> > And, now that the C drive is a solid-state disc, Firefox processes^Hd  over 200 pages in about 20 seconds.
> > 
> > LINXCHEK.HTM starts by reading a Directory File, essentially as obtained by previously running Prompt>DIR /b /s > $DIR.TXT .
> > 
> > 
> > For (much) more description, see an older version of the page itself at
> > https://web.archive.org/web/20140809171940/http://www.merlyn.demon.co.uk/linxchek.htm
> > 
> > That will not run when loaded from that server, as the GO-type button is disabled; but one can read the page, and one can download it with Save As and then run it (after making a suitable Directory File).  It would like a stylesheet and an include file, but (IIRC) neither is really needed.
> > 
> > 
> > 
> > I've gutted a copy of one of the HTAs that you helped me to write, and intend next to see what happens if I get it to read a whole HTM page into a string
> > and assign that string to the innerHTML of a DIV.  If I get a DOM-like tree in the DIV, I can proceed ...
> > 
> > 
> > Must stop, routine medical appointment imminent.
> > 
> > Thanks, regards,


 
> IIS has been part of windows [1] since Windows NT 3.51. I highly suggest
> you use it.
> 
> 1. Navigate to C:\inetpub\wwwroot.
> 2. Create a folder for your application/website and copy/move your files there.
>    - example: 'merlyn.local'
> 3. Open the start menu and type "iis". You'll see the application. open it.
>   - Assuming Windows 10
>   - If on older version of windows, from the Start -> Run command type: "inetmgr" and hit ENTER.
> 4. On the left side you'll see a tree. Expand it and locate the "Sites" folder
> 5. Right click on the folder and select "Add Website..."
> 6. Fill out the form (example entries):
>   - Site name: 'merlyn.local'
>   - Physical path: The path from step 2: 'C:\inetpub\wwwroot\merlyn.local'
>   - Host name: 'merlyn.local'
> 7. update hosts file for your website
>   - Open (as an administrator) 'C:\Windows\System32\drivers\etc\hosts'
>   - Follow the example and add a new line to this file:
> 	127.0.0.1	merlyn.local
>   -  save and close. Agai, you need to be an administrator to do this
> 8. Open your web browser and navigate to: 'http://merlyn.local'
> 	- or if you are missing an index.html page: 'http://merlyn.local/foo.html'
> 
> DONE!


But I want to be able to run my process on an "as delivered"
computer, without having to "install" little-known software,
even if that is actually already present.  To that end, for
example, while my page LINXCHEK.HTM contains references to
an include file and a CSS file, I have ensured that neither
of those is necessary for operation.


> You now have a static website on your machine. You also have an option for server side programming as well.
> 
> You can host this as is for free in a number of places. For example on Azure.
> 
> If you choose Azure as your hosting provider, you'd have a website like:
> <http://merlyn.azurewebsites.net/>
> 
> For example if you don't want or can't afford a host name of your own.
> 
> Github pages is another free option, but you'll have to understand and use Git.
> <https://pages.github.com/>
> 
> Other people in the group may have other options for hosting.
> 
> Now on to your original problem:
> 
> You should be able to display your files like you used to since you now have a proper domain instead of <file://...>.
> 
> In regards to checking links, you can use the DOM instead of the file system:


I don't follow. My Pascal CHEKLINX.EXE knows nothing about the
DOM, because I knew nothing about the DOM when I wrote it. But
LINXCHEK.HTM relies on the DOM in the IFRAME.


> <script>
> // This is impressionistic, and not meant for usage as-is
> let visited = new Set()
> 
> function crawlSite(url) {
>     fetch(url).then(function(response){
>         // Assuming textual response
>         return response.text()
>     }).then(function(htmlText){
>         var parser = new DOMParser();
>         var doc = parser.parseFromString(htmlText, "text/html");
>         var links = Array.from(doc.querySelectorAll('a'))
>         return links
>     }).then(function(links) {
>         // Only crawl links inside your own website
>         var filteredLinks = links.filter(function(link){
>             return link.hostname === document.location.hostname 
>                 && !visited.has(link.href)
>         })
>         return filteredLinks
>     }).then(function(filteredLinks){
>         filteredLinks.forEach(function(link){
>             visited.add(link.href)
>             crawlSite(link.href)
>         })
>     }).catch(function(error){
>         // report error where appropriate
>         console.log('Failed to fetch page: ', err);  
>     })
> }
> 
> //start at root
> crawlSite(document.location.hostname)
> 
> </script>

That contains too much grammar that I'm not familiar with.
And I had no idea that DOMParser existed, apart from a thought
that it would be nice if it did.  I've found descriptions of
how to call DOMParser, but nothing about just what its result
is.

 
> You'll want to do this as a Breadth First Search so you don't look at the same page more than once,
?  I don't follow.  The pages being scanned are of course from
 tree structure, but the links-and-anchors which connect them are
a network.  I just work through the links collection of a page
recursing into only those destinations not yet visited - and I
think yours does similarly.  I keep (I think) the anchors
collection of each page found, since a page found subsequently
may want to check an anchor of a previously found page.

> and additionally you'll want to filter the links to stay in your own domain. Also in my impressionistic example I left out other checks and such to keep it relatively clear. I'm certain other group members can point out bugs and such in my pseudo-code where appropriate.

I'm sure that your code would be an excellent restarting point
if I needed to return to square one, and it would very probably
take less time than my equivalent.  But I'm confident that the
majority of the run time is taken in the actual fetching and
parsing of the pages being scanned.


> [1] https://en.wikipedia.org/wiki/Internet_Information_Services


-- 
  (c) John Stockton, near London, UK.  Using Google Groups.           |
 Mail: J.R.""""""""@physics.org - or as Reply-To, if any.             |

[toc] | [prev] | [next] | [standalone]


#37028

From"Michael Haufe (TNO)" <tno@thenewobjective.com>
Date2019-08-02 16:07 -0700
Message-ID<bed82b0f-f6db-4fbe-be76-bb56f353fffd@googlegroups.com>
In reply to#37022
On Friday, August 2, 2019 at 7:01:31 AM UTC-5, dr.j.r...@gmail.com wrote:

> But I want to be able to run my process on an "as delivered"
> computer, without having to "install" little-known software,
> even if that is actually already present.  To that end, for
> example, while my page LINXCHEK.HTM contains references to
> an include file and a CSS file, I have ensured that neither
> of those is necessary for operation.

I think I'm missing some of the use-cases and requirements then:

1: You have 1+ html pages which want arbitrary access to the filesystem
Q1: What is the nearest common parent folder for these files?

2. You want to distribute this site/application to other users.
Q2: Are all of these users on the same network?

3. You have an optional include file
Q3: What is its purpose?

[toc] | [prev] | [next] | [standalone]


Page 2 of 3 — ← Prev page 1 [2] 3  Next page →

Back to top | Article view | comp.lang.javascript


csiph-web