What do you think about doing JS-Free sites?

What so phpbb and the like are client javascript? That's disappointing.

To be fair, it could be all the extensions and plugins that administrators decide to enable that provide most of the javascript. I think by default phpbb only has some live notification stuff using JS.
 
I don't care about economical & reasonable usage of JavaScript, if it works well, does not boost the CPU frequency to maximum & provides me a better usability of the web app. Before you use PHP, watch out for more modern & better alternatives, e.g. Plone/Zope (Python). PHP is ugly, error-prone & not much more than a sequence of security flaws. PHP mixes application & UI logic, which is bad for principle reasons, thus it can not be a good thing. Get rid of it!
 
PHP is ugly, error-prone & not much more than a sequence of security flaws.
It's ugly and error prone but good programmers can code secure applications with it. It all depends on the programmer if it's secure or not.

PHP mixes application & UI logic, which is bad for principle reasons, thus it can not be a good thing.
There are a lot of MVC frameworks written in PHP so i can't follow your statement. Care to elaborate?
 
I don't care about economical & reasonable usage of JavaScript, if it works well, does not boost the CPU frequency to maximum & provides me a better usability of the web app. Before you use PHP, watch out for more modern & better alternatives, e.g. Plone/Zope (Python). PHP is ugly, error-prone & not much more than a sequence of security flaws. PHP mixes application & UI logic, which is bad for principle reasons, thus it can not be a good thing. Get rid of it!
I can't agree with you. If developer don't care about security, design, escaping sql parameters or strictly checking user input - it does not matter which language he use for it application. And if he care about security and has enough skills to good development - he can do excellent app in any case.
 
Not using JS means using HTML forms

It is when people use Javascript to simulate HTML forms it makes me laugh. Use the correct tool for the job and if a kid doen't know how to use HTML forms, they should learn it and use it.

I used to think PHP was insecure but then realized that any dynamic web app (PHP, Python, JSP, ASP.NET) is a risk because you are executing code on your server based on unknown user input and you basically can't trust your average developer regardless of language they use.

I highly recommend if performance allows using plain CGI (rather than mod_php and fastcgi) within a Jail. That way even if your program gets completely compromised, they can't do anything. If you do this, then even Microsoft Visual Basic 6 is fine.

But if the project allows, plain generated static websites all the way! XD
 
It is when people use Javascript to simulate HTML forms it makes me laugh.
Yes, semantic HTML is important.

I once had a colleague who used a table with a single row and th tag for headings rather than h1-tags because it "was bold too". (All wrapped in a function called makeHeader(). I lol'd.)
 
  • Like
Reactions: a6h
There are a lot of MVC frameworks written in PHP so i can't follow your statement. Care to elaborate?

In professional web development, separating UI from business logic is a way of protecting one's investments, but it also has an enormous advantage in terms of scalability and resources usage.
When you mix business logic with UI code (which was the case with typical PHP / ASP / JSP development), you have to keep session data on the server, which dramatically increases memory usage and limits scalability (you have to replicate session data across all servers of the cluster).
This is why this style of development has been abandoned 10+ years ago.
You can still use PHP if you like to implement business logic (in the form of REST services), but your UI will be created using VueJS, React or Angular, those frameworks making web UI development much easier and more reliable / maintainable.
 
This is why JavaScript is nowadays a REQUIREMENT for professional web development.
Not using JS means using HTML forms - which were great 40 years ago compared to using a mainframe terminal.
Yes, it is REQUIREMENT, but sadly "professional development" novadays is not mean "correct development", and not synonim for "good skills" for developer.
In bad hands any JS can stuck browser. But novadays number of developers knows many JS frameworks, but don't know JS at level for example "make own framework" - are too much. And web are very slow too often.
 
  • Like
Reactions: a6h
In professional web development, separating UI from business logic is a way of protecting one's investments, but it also has an enormous advantage in terms of scalability and resources usage.

True but at the same time you don't need to use different languages to separate UI from business logic. You also don't need the UI to be client side to separate either.

The main benefit I can see is you can add "fancy gimmicks" and of course the UI logic is distributed (your server doesn't need to do as much work).
 
Yes, it is REQUIREMENT, but sadly "professional development" novadays is not mean "correct development", and not synonim for "good skills" for developer.

If you develop for someone else, which is the case of all professional developers, your users define what is "correct development" in terms of functional (the purpose of the application) and non-functional requirements (e.g. ergonomics, scalability). Then, as an IT professional, you choose the best tools and technologies to achieve what your users defined.

Anything else is not IT, but religion. It's fine too, it just needs to be clearly stated.
 
goshanecr I had a project idea a while back (can't find the exact thread it was in):


Basically a forum software that would make lynx and other text browsers a "first class citizen". Or at least provides a great experience on lighter browsers like NetSurf. Perhaps this interests you? Or perhaps you have already done similar?
 
Yes, it is REQUIREMENT

I believe in around 20 years, HTML, CSS and Javascript will not be provided by the browser. Instead it only supports WebAssembly binaries. Then it is up to the developer if they want to use HTML, CSS and Javascript or a different technology stack entirey, they upload the implementations.

Either this will go two ways. HTML and CSS will almost disappear as everyone decides that Javascript-only apps are superior. Or, Javascript will disappear once people realize that another language is more appropriate.
 
Either this will go two ways. HTML and CSS will almost disappear as everyone decides that Javascript-only apps are superior.

"JavaScript" applications do nothing more than controlling the DOM. A "JavaScript" web application cannot exist without HTML and CSS because it is run inside a web browser.
 
Think about the difference of Web Page and Web Application. For a WP where user interaction is limited to clicking on links, you most probably won’t need JS. If you tend to build an interactive WA, you better learn JS and become comfortable with its dynamic HTTP request system.

Role depending example:

If a user loads one of my BLog pages, he/she sees static HTML+CSS only, with one exception that I show banners of my software in a side bar, and the table of contents iframe adjusts its height on loading. This I consider a Web Page and I could even do it without JS, only I see no reason why (I know all the arguments against, and I still see no reason why).

If an author loads one of my BLog pages, it loads the ContentTools frontend of Anthony Blackshaw (all JS) and this allows together with my ContentCGI backend (all in C) authoring by WYSIWYG editing directly on the web site. This I consider a Web Application and this would even remotely not be possible without JS.

I know JS adversaries will tell me that the only correct way of authoring web pages is by using vi(1). I am tending not to hear this.
Authoring with ContentTools:ContentCGI.png
 
It's ugly and error prone but good programmers can code secure applications with it. It all depends on the programmer if it's secure or not. There are a lot of MVC frameworks written in PHP so i can't follow your statement. Care to elaborate?
PHP entices to errorneous programming. It's much easier to produce & overlook a bug in plain PHP than in a MVC application leveraging the sophisticated facilities of e.g. Plone/Zope or Java ServerPages. And here IMHO Python is superior to Java; both are mature, platform-independant, mature libraries for all kinds of tasks are available, but Python allows for mixed programming paradigms & is less error-prone (e.g. you see a wrong indentation, but it's easy to overlook a missing semicolon). Compare the security history of Plone vs. PHP-based competitors. Yes, with some discipline, of course you can write secure & correct code in any language. And for a small project with limited functionality, a framework like Plone/Zope might be overkill and you're better off doing it quick & dirty, because if it's small it's manageable. But once it grows, you bite your ass to not have choosen the "right" way.
 
"JavaScript" applications do nothing more than controlling the DOM. A "JavaScript" web application cannot exist without HTML and CSS because it is run inside a web browser.

Currently but that is easy to change. For example if I upload a WebAssembly binary (i.e compiled via Emscripten C++), I can call into functions from it with Javascript.

I guess what I am predicting is that the DOM will not be provided by browsers anymore. The developer will provide that as a WebAssembly binary. Lots of multimedia application (such as games) don't need the DOM if the functionality of Canvas is exposed via EGL for example.
 
  • Like
Reactions: a6h
I know JS adversaries will tell me that the only correct way of authoring web pages is by using vi(1). I am tending not to hear this.

There are many editors available. Why you choose to not use any of them (and instead use a web browser) is beyond me! j/k

I tend to use version control for everything (even blog posts) so it would be more of a faff to use web authoring only to download them again to commit but I do see your workflow being preferable to i.e ssh and vi or VNC + gedit, etc. You could also do this without Javascript however, it would just be more of a basic experience (admittedly I prefer that).

Though i suppose I could recommend Vim.js as your authoring editor ;)
 
Currently but that is easy to change. For example if I upload a WebAssembly binary (i.e compiled via Emscripten C++), I can call into functions from it with Javascript.

I guess what I am predicting is that the DOM will not be provided by browsers anymore. The developer will provide that as a WebAssembly binary. Lots of multimedia application (such as games) don't need the DOM if the functionality of Canvas is exposed via EGL for example.
Well, not everything's a game, and Canvas is part of the DOM. Accessing the DOM is slow but I don't know what they can do about that. On the one hand, they can speed up the native browser code to access it. On the other hand, they can build some other method as I think you are suggesting. But that would break the web, if implemented immediately, and take decades to switch to.
 
But that would break the web, if implemented immediately, and take decades to switch to.

Absolutely. I think they will provide "compat" HTML/CSS/JS support for a long while but as you probably know, the average stack overflow developer likes to use "the very latest stuff" any chance they get.

Well, not everything's a game

No, but to me it seems that heavy multimedia content sites share many similarities. Loads of sites no longer use <input> components and instead opt to provide their own fancy ones instead using the Canvas. Ones that provide fade effects and movement just like you would implement in a game.

I wonder how long it will be until many websites start just having a single DOM element, (a fullscreen canvas element) and just drawing everything using WebGL (under layers of libraries)? Hopefully it will never happen but I certainly won't be surprised if it did! :( If enough do this, then I am sure browser developers will allow that EGL "DOM bypass" I mentioned.

Ever used one of those sites which was really just one big Adobe Flash player... Welcome to 2040 (Oh god I hope not! XD)
 
Back
Top