/wdg/ - Web Development General

>Previous thread
>Free resources to get started
Get a good understanding of HTML, CSS and JavaScript.
developer.mozilla.org/en-US/docs/Learn - a good introduction (independent of your browser choice)
developer.mozilla.org/en-US/docs/Web - General documentation for HTML, CSS & JavaScript
freecodecamp.com/
codecademy.com/

>Further resources
github.com/iRaul/awesome-portfolios - Portfolio examples
github.com/kamranahmedse/developer-roadmap - Roadmap
stackoverflow.com/ - Developers asking questions and helping each other

>Tools
jsfiddle.net/ - Use this and post a link, if you need help with your code
caniuse.com/ - Check browser support for front-end web technologies

Other urls found in this thread:

jsfiddle.net/exwLds7r/
symfony.com/4
learnbchs.org/index.html.
sparkjava.com/
jsfiddle.net/w51Lyzbx/2/
learnxinyminutes.com/docs/javascript/
developer.mozilla.org/en-US/docs/Web/JavaScript/A_re-introduction_to_JavaScript
twitter.com/NSFWRedditGif

threadly reminder to not fall the vue shills

How do you deal when you design a nice looking modern and responsive website and it looks great on all the major browsers except on ie and edge? I hate it when my art and creativity are limited by philistines that still use those two.

>since ~1 year ago
>React downloads up by ~180%
>Vue downloads up by ~300%
Thanks user, but I don't do JSX.
Gotta get back to my .vue single file components.

By doing console.log(average(scores2)) I am basically placing the scores2 variable into the second function right?

The way the code on the left is written makes a thousand times more sense to me and the one on the right makes no sense at all

Am I just autistic or what? They both work exactly the same

>disregard bitches
>acquire currency

I'm building a personal website using Erlang (cowboy server). Am I doing it right Sup Forums?

ha, just checked my project with edge and IE.
Edge apparently can't handle referrerpolicy html directive and fucks up image proportions with object-fit css.
IE doesn't display half the content and the rest is messed up, because it can't handle flexbox.

As long as everything works in Chrome and FF I am fine with it.

I don't get it.
They are the same, except the one on the left won't work, since 'total' always remains 0?

>Am I just autistic or what?
Not nearly autistic enough, I'm afraid.

Look at what's being added to what. On the left, you're adding the total (which always remains 0 since you never add anything to it) to each value from the array. On the right, you're adding each value in the array to the total.

>They both work exactly the same
The left side shouldn't ever return anything besides 0, so I dunno wtf r u doin.

he just didn't dare to say
>i am retarded and don't know why the left isn't working, please halp

good luck rendering new dom components

I thought it was working because this shitty IDE was giving me the right answer every time I called the file

But I understand now anyway

what's the endgame here exactly

uuuugh

wtf am I doing wrong here

set "whitespace: nowrap" on the 's

Looks like the dropdown is oriented on the bottom left corner of the parent above, while you would want it attached to the bottom right instead I think.
Hard to tell without the css

.dropdown-content {
display: none;
position: absolute;
padding: 15px 17.5px 2px 55px;
text-align: right;
z-index: 1;
background: #545454;
}

But yes, that is precisely what I am struggling to do

just lookup what browser is running and print a warning message to user with unsupported browsers

similar to this?
jsfiddle.net/exwLds7r/

If net neutrality is gone won't it just crash our plane with no survivors?.... :(

wrong thread, faggot

Elm needs to be on here, I want to watch it grow.

got ya fampai

kek :3

Whats a good not bloated Java framework?

React.

what about ramdajs?

Pls

Not much worse than vue.

Who needs Elm if we have miso?

the answer ended up being
>set parent div to position: relative;
>add top: 0; right: 0; to dropdown content css

Tamper Data no longer works on firefox. What is a good alternative?

What stacks are used for web dev?

Is asp.net Sup Forums approved? Or are you all linux cucks?

postman

if you like working with it and if it gets the job done, then why not.

Don't use forEach(), use map(). Have the map return the total since that makes more sense.

you mean .reduce() ?
With that you can even make it a readable one-liner.

Not .map(), .reduce()


"use strict";

function average(scores) {
if (!Array.isArray(scores)) {
throw new Error("Must provide an Array");
}
if (scores.length {
return prev + curr;
}, 0);
return Math.round(total / scores.length);
}

const scores = [90, 98, 89, 100, 100, 86, 94];

console.log(average(scores));

Yes, brain fart

If you don't care about type checking and want to be as obtusely concise as possible:

function average2(scores) {
return Math.round(scores.reduce((prev, curr) => prev + curr, 0) / scores.length);
}
[/code>

I'd probably break that onto multiple lines, but other than that I don't see how it's obtuse. It's just declarative style.

Is symfony 4 going to destroy the reign of laravel?
symfony.com/4

>some php shit
Who cares?

I care!!

i fucking love that emscripten supports SDL

Is emscripten the best option for WA right now?
I am a webassemblylet

Noob question.What server side scripting language should i use? also which database? I need something fast and secure. I was thinking of going with the typical php and mysql combo but i want to hear it from you guys.

But what are other options, user? I heard only about emcc and cheerp

Would you learn a completely new language, just because someone dropped the name of a backend on here?
>fast and secure
then it would make sense to use what you are already familiar with.
What languages do you usually use?

It's still better than the slow python or the buggy nodejs and golang is a meme.

php 7.2 > python 3.7 > node.js 9.x

It depends entirely on your use case. Do you want to iterate quickly? Use a nosql database to prototype like mongo. Do you need enterprise level resiliency and scale? What languages do your devs already know? Will they also be working on the front-end?

Your back-end is also completely dependent on your use-case. I'd suggest node.js because I'm familiar with it and it is also easily iterable, but you can use anything from J2EE, Go, PHP, to what the fuck ever. They all have good sides and bad sides. They all have database bindings.

Again, I like node because it's easy to get something up and running really quickly and environment setup is easy as well. Go is nice, but I'm getting more and more irritated with its opinionated syntax. J2EE will always be way too verbose for me. I think it's because I usually inherit decade old WAS configurations that make me want to die. I PHP code gets written badly too often so I don't want to recommend that either.

Just learn Python and be done with it.

Why not C? Simple and efficient!

What's an easy, simple way to implement this on a mobile web page? Top box has a list of strings, you can click to highlight one, then press the button below to add it to the bottom box and remove it from the top box, and vice versa.

Javascript or native mobile API.

>Would you learn a completely new language, just because someone dropped the name of a backend on here?
Yes, if it's good enough for my taste.
>What languages do you usually use?
I'm a webdev noob, I only know html/css bit of php and no javascript what so ever.

I might just stick to php man. I gotta stop wasting time and get on with it. There is a lot of documentation for php and mysql, i might just go with that since I'm a noob.

I heard about this learnbchs.org/index.html. I was really intrigued but I'm a noob at this webdev shit so i'm gonna stay back

I'm using Javascript. Is it easy to make it from scratch?

Any of you enjoy running wordpress blogs/being an editor/writing? I have this set up and pasted some random content but very busy with HT and a bunch of other stuff. 70/30 rev share in your favor if I can find someone to work with.

I would recommend to get the basics of JS down first, since it's such an integral part of webdev and then you can still decide, if you want your backend in PHP or JS.
What have you done so far?
It's a matter of getting the element with a click and .appendChild it to the other list.

>basics of JS down first
No, fuck js. I'm sticking with php.

Where is "Foo $foo" coming from? What is this even supposed to be? I've only seen this when I work with Laravel when you receive a request and pass it into a method by using "Request $req". What is this formally called or what is even happening here?

samefag here. i just realized i kinda sounded dumb by saying "what is this even supposed to be". I meant that in reference to the "Foo $foo" not this example--i know this is an example of interfaces

You are the kind of person who will end up posting these kind of questions

servlets

sparkjava.com/

spring boot is comfy

Is using Cloudflare the only way to hide my contact information if I want to host a domain on Heroku?

And slow as hell.

there's nothing comfy about spring. it's a mess.

does your domain provider not offer domain privacy?

>spend hours searching for an ssl error
>all links are https so it should be working as intended
>eventually find out I accidentally used a www link somewhere, while the ssl doesn't cover that subdomain
sigh

fake news

well it's slow to startup and spring is indeed a clusterfuck, but it's still nice to use

>No, fuck js. I'm sticking with php.

JavaScript is pretty much the only language you can use if you want to make rich front-ends. Flash, SilverLight, ShockWave, Java Applets and every other 3rd party plugin based rendering component is dead. JS and at some point in the distant future, WebASM, are your only options.

Sure, you can make sites devoid of XHR (which require JS); in fact, it's a novel goal that you should hope for, but if you want people to think that your site was made after 2004, you're going to need to learn JS so that you can do progressive enhancement and leverage the nice parts of JavaScript.

This is of course only the case if you want your code to be browser based. If you're making a native app that people will have to download, you can use whatever you want. Java for Android, Swift for iOS.

well, at least they know how to sell their framework.

>What have you done so far
In terms of what I'm asking? Nothing so far, but I haven't done it before.
What's wrong with my question?

>deprecated tomorrow
I don't understand where this rhetoric comes from.

Well, it's freenom, I haven't tried it yet.

jsfiddle.net/w51Lyzbx/2/

Crux of it is this:

function swapFactory(fromSelect, toSelect) {
return function() {
if (fromSelect.selectedIndex >= 0) {
const optionToMove = fromSelect.options[fromSelect.selectedIndex];
toSelect.appendChild(optionToMove.cloneNode(true));
fromSelect.removeChild(optionToMove);
}
}
}
const selects = Array.from(document.querySelectorAll("select")),
buttons = Array.from(document.querySelectorAll("button"));
buttons[0].addEventListener("click", swapFactory(selects[1], selects[0]));
buttons[1].addEventListener("click", swapFactory(selects[0], selects[1]));

well no offense,
but that's a really basic problem and you would 100% be able to solve that on your own searching for the proper functions to use on mdn or w3.
Seems lazy to ask for help, if you didn't even try out any code at all yet.

>deprecated tomorrow

wut?

Exactly what I was looking for, thanks.
True, but I get lonely and I like to talk to you guys.

what do you mean

Sup guys. You know of any good refresher courses on JS? I took a break for like 2 months for work, school, and to finish up some writing projects. I just returned to my WD course in JS Functions and I feel like I forgot most of what I learned.

Does anyone else hate it when a website/software is "candid" and "personal"? I know I'm being autistic, but it's like:

>Oops! We messed up something on our end, don't worry, we'll fix it!
>Hey, that link is gone!
>We'll guide you through this whole process
>Do us a favor and share this with your friends?

Instead of simple, mature communications, it's annoying and friendly. And who the fuck is "We"? I noticed this with a lot of Windows 10 when setting it up for people

>We're setting up Windows 10 for you
>We have new features you'll love

Fuck right off. Who even makes the call on these annoying fucking decisions?

learnxinyminutes.com/docs/javascript/
developer.mozilla.org/en-US/docs/Web/JavaScript/A_re-introduction_to_JavaScript

maybe the 'you dont know js' book series online

Thanks user!

Help me create a multi step angular 2+ form, the catch is that the steps are undefined until I get data from the server, all the tutorials I see use a defined number of form steps

I appreciate these hibikes.

Dear anyone, can I display cmd process in web/php ?

yes

I have to use PHP as part of a work project. Does anyone know of a PHP server side graphing library? I'm using JPGraph for now, but it's very basic. I need a little more, like being able to control where the y-value label appears relative to the displayed data point.

I've already seen the lavachart and google API think but they're more focused on client side since they work with a javascript API.

How? Example i want to see output process ping an address in realtime

Any recommendations on places to learn php 7 and Node.js?

I did a introductory web dev subject in school like 3 years ago, it wasn't very good. They told me to just use w3schools, which was horrible advice. I still got an HD.
How do I learn web dev?
I think that freecodecamp is bad. I went through hundreds of exercises in a few hours and it was rubbish.
I'm tired of dealing with bad resources. What's the best way to learn webdev?
Should I just go through MDN? is there something better?

Web Developer Bootcamp on udemy is what people were recommending last thread

shills out in full force

check yourself faggot

yeah it's there hence "shills out in full force"

Ok /wdg/ so i've got a client who wants a website but also wants to be able to make small edits once im gone? There a complete normie so whats the best approch? blog site?

I fucking loath the state of front-end web development. It literally demotivates me from wanting to continue in the field of web development in general, as I run my own business and do full stack dev and IT.