|
"Abusive" is not when your feelings are hurt
Bastard Programmer from Hell
"If you just follow the bacon Eddy, wherever it leads you, then you won't have to think about politics." -- Some Bell.
|
|
|
|
|
Good point. Some random things on the internet called me a liar. That hurts my feelings so much.
Social Media - A platform that makes it easier for the crazies to find each other.
Everyone is born right handed. Only the strongest overcome it.
Fight for left-handed rights and hand equality.
|
|
|
|
|
Obviously, and you've proven so by voting me for abuse
Bastard Programmer from Hell
"If you just follow the bacon Eddy, wherever it leads you, then you won't have to think about politics." -- Some Bell.
|
|
|
|
|
Eddy Vluggen wrote: abuse This site has rules and you need to follow them.
Social Media - A platform that makes it easier for the crazies to find each other.
Everyone is born right handed. Only the strongest overcome it.
Fight for left-handed rights and hand equality.
|
|
|
|
|
ZurdoDev wrote: This site has rules and you need to follow them. Agreed, so please try to do so.
As a reminder; it wasn't my thread that got locked
Bastard Programmer from Hell
"If you just follow the bacon Eddy, wherever it leads you, then you won't have to think about politics." -- Some Bell.
|
|
|
|
|
... are not programming questions since javascript is not a programming language
"If we don't change direction, we'll end up where we're going"
|
|
|
|
|
Most JavaScript threads I see are rants rather than questions, so...yeah?
|
|
|
|
|
snark snark
Never underestimate the power of human stupidity -
RAH
I'm old. I know stuff - JSOP
|
|
|
|
|
Javascript is a programming language. It can be used to write programs.
It is, however, a broken programming language.
It is the only one I know of that had to create a new equality operator (===) as the first attempt (==) was unusable.
|
|
|
|
|
Unlike VB.NET, which had to create new logical operators (AndAlso and OrElse ) because the existing ones from VB6 (And and Or ) didn't short-circuit, and they didn't want to introduce a breaking change.
"These people looked deep within my soul and assigned me a number based on the order in which I joined."
- Homer
|
|
|
|
|
Actually - === (and similar operators) exist in php as well.
It's because of the nature of the beast: both end up creating a lot of stuff for display in a browser so they, with very weak typing, will print the value 7 as the character 7 . Also allowed, but within limits, using such not-really-equal equals in conditionals. For what the languages do, it's really quite convenient. However - sometimes you want to maintain the intrinsic type for your comparison.
In it's way, isn't it a missing feature in many other languages? TRUE/FALSE and 0/not-0 are common in conditionals. What if, however, you really wanted 'FALSE' and not accept 0 (or even null at times)? For that matter, the default installation of SQL Server is case-insensitive for string matches and promotes between int and char types when it can.
Basically, a consequence of a trade-off between easier and more convenient most of the time and "gotcha!" .
Blessings and curses for such things depend upon what you need to do.
Ravings en masse^ |
---|
"The difference between genius and stupidity is that genius has its limits." - Albert Einstein | "If you are searching for perfection in others, then you seek disappointment. If you seek perfection in yourself, then you will find failure." - Balboos HaGadol Mar 2010 |
|
|
|
|
|
NeverJustHere wrote: unusable
It worked as intended.
Social Media - A platform that makes it easier for the crazies to find each other.
Everyone is born right handed. Only the strongest overcome it.
Fight for left-handed rights and hand equality.
|
|
|
|
|
statements about how JavaScript is not a programming language are implicit questions about programming languages, and, an invitation to post OT discussion on the Lounge.
«One day it will have to be officially admitted that what we have christened reality is an even greater illusion than the world of dreams.» Salvador Dali
|
|
|
|
|
All languages - including English (*) - are programming languages, and therefore statements in English are also prohibited in the Lounge.
(*) English is used in many places to program people.
Freedom is the freedom to say that two plus two make four. If that is granted, all else follows.
-- 6079 Smith W.
|
|
|
|
|
Genau!
"If we don't change direction, we'll end up where we're going"
|
|
|
|
|
|
Nice!
I don't know how practical this is (think of the ambiguities in English and most other natural languages), but it's certainly an idea worth playing with.
Freedom is the freedom to say that two plus two make four. If that is granted, all else follows.
-- 6079 Smith W.
|
|
|
|
|
Oh please do not advertise it ...
|
|
|
|
|
Hi, Dan,
fyi: my first response was tongue-in-cheek
I respectfully disagree: imho, all spoken human languages have nothing in common with so called computer "programming" languages ... even if their semantics are to some degree modeled on human languages. I take off the table such weird experiments as Esperanto, and Daniel Everett's linguistic hypothesis that the Piraha language has no ambiguity [^], [^].
I do think you could "fudge" the Sapir-Whorf linguistic hypothesis [^] to partially apply to the way that programmers who reach a high level of mastery in one computer dialect may tend to view learning a new paradigm in terms of what they have internalized ... which may lead to cognitive dissonance / "culture shock" ... I'm thinking of the rants you sometimes see as OO devotees bounce off FP, and the reverse.
I believe it is a serious mistake to use any other term than "finite instruction set" for what are called today computer "programming" languages
«One day it will have to be officially admitted that what we have christened reality is an even greater illusion than the world of dreams.» Salvador Dali
modified 4-Sep-20 2:53am.
|
|
|
|
|
Looking at the possibility of trying to post to a website with c# that has a wizard with multiple steps and I'm looking through the JS file and it is over 130,000 lines long when pretty-printed in Chome's dev tools.
130,000+ lines!!!
Of course it is a government website from Communist California, so that explains some of it.
If anyone has tips on how to use c# to post to a website with steps, to automate submitting something I'd love to hear it. I think it isn't even worth trying.
Social Media - A platform that makes it easier for the crazies to find each other.
Everyone is born right handed. Only the strongest overcome it.
Fight for left-handed rights and hand equality.
modified 2-Sep-20 15:59pm.
|
|
|
|
|
ZurdoDev wrote: JS file and it is over 130,000 lines long
So ridiculous!! For all those people who don't understand OOP. This is what OOP was for.
Do you mean something like the following?
from: How to: Send data by using the WebRequest class | Microsoft Docs[^]
using System;
using System.IO;
using System.Net;
using System.Text;
namespace Examples.System.Net
{
public class WebRequestPostExample
{
public static void Main()
{
WebRequest request = WebRequest.Create("http://www.contoso.com/PostAccepter.aspx ");
request.Method = "POST";
string postData = "This is a test that posts this string to a Web server.";
byte[] byteArray = Encoding.UTF8.GetBytes(postData);
request.ContentType = "application/x-www-form-urlencoded";
request.ContentLength = byteArray.Length;
Stream dataStream = request.GetRequestStream();
dataStream.Write(byteArray, 0, byteArray.Length);
dataStream.Close();
WebResponse response = request.GetResponse();
Console.WriteLine(((HttpWebResponse)response).StatusDescription);
using (dataStream = response.GetResponseStream())
{
StreamReader reader = new StreamReader(dataStream);
string responseFromServer = reader.ReadToEnd();
Console.WriteLine(responseFromServer);
}
response.Close();
}
}
}
|
|
|
|
|
raddevus wrote: Do you mean something like the following? Sort of. I have done that before; however, what I need is a website that has multiple steps which means I have to somehow check the response after simulating the next button and figure out how it all works. I think I also have to include any cookies the site wants to include.
I feel like it's way more work than it's worth, unless I am missing something.
And then of course, if they ever change their site then my code would break.
Social Media - A platform that makes it easier for the crazies to find each other.
Everyone is born right handed. Only the strongest overcome it.
Fight for left-handed rights and hand equality.
|
|
|
|
|
raddevus wrote: So ridiculous!! For all those people who don't understand OOP. This is what OOP was for.
That's actually just the preferred deployment method these days. The source code is indeed OOP. The code will be and it will rely on various plug-ins that will be OOP too. When it comes to deploying the site a process like webpack is used which takes all of the code in all of the linked js files, so both your code and also all the plug-ins you use, it then minifies the code and puts it all in a single file. So the file itself might be large, but it's the amalgamation of all the source js files stuck together. webpack does other shenanigans too which protects your plug-ins from each other and enforces a far more granular and modular way of coding.
|
|
|
|
|
F-ES Sitecore wrote: a process like webpack is used which takes all of the code in all of the linked js files, so both your code and also all the plug-ins you use, it then minifies the code and puts it all in a single file
That's a very good point. That probably is what is happening.
|
|
|
|
|
There are probably only 200 lines of unique code and a lot of cut and paste.
"Time flies like an arrow. Fruit flies like a banana."
|
|
|
|