/wdg/ - Web Development General

Death to PHPajeets!

Previous thread: >IRC Channel
#Sup Forumswdg @ irc.rizon.net
Web client: rizon.net/chat

> Discord
discord.gg/0qLTzz5potDFXfdT

>Learning material
codecademy.com/
bento.io/
programming-motherfucker.com/
github.com/vhf/free-programming-books/blob/master/free-programming-books.md
theodinproject.com/
freecodecamp.com/
w3schools.com/
developer.mozilla.org/
codewars.com/
youtube.com/watch?v=JxAXlJEmNMg&feature=youtu.be&list=PL7664379246A246CB - "Crockford on JavaScript" lecture series.

>Frontend development
github.com/dypsilon/frontend-dev-bookmarks

>Backend development
en.m.wikipedia.org/wiki/Comparison_of_web_application_frameworks
gist.github.com/dypsilon/5819528/

>Useful tools
pastebin.com/q5nB1Npt/
libraries.io/ - Discover new open source libraries, modules and frameworks and keep track of ones you depend upon.
developer.mozilla.org/en-US/docs/Web - Guides for HTML, CSS, JS, Web APIs & more.
programmableweb.com/ - List of public APIs

>NEET guide to web dev employment
pastebin.com/4YeJAUbT/

>How to get started
youtube.com/watch?v=pB0WvcxTbCA - "WATCH THIS IF YOU WANT TO BECOME A WEB DEVELOPER! - Web Development Career advice"
youtube.com/watch?v=zf_cb_Nw5zY - "JavaScript is Easy" - If you can't into programming, you probably won't find a simpler introduction to JavaScript than this.

>cheap vps hosting in most western locations
lowendbox.com
digitalocean.com/
linode.com/
heroku.com/
leaseweb.com

Other urls found in this thread:

codepen.io/user/pen/GoYEyj
fb.me/react-devtools'
github.com/Polyfiller/polyfiller
developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Regular_Expressions
twitter.com/NSFWRedditGif

The meems

Like I always say on these threads, you don't compete with Pajeet on a Pajeet-dominated environment. They charge that because they can actually live with that money (and have many of those gigs at the same time helps too).
Working locally is a great idea, keep doing that. If you want more work, wait for your clients to recommend you with other clients, from the same city or a near one.

>Are these bids even serious

Some of them are serious, some of them are absurdly low to catch clients, and then upsell, some of them are just some kind of scam or morons who don't know what their time is worth (or do know what their time is worth)

You get what you pay for.

>how would anyone recommend competing in this area of web dev.

You can't compete with them on price, but you can on quality. Plenty of clients are willing to pay more for a good developer that actually understands what they want and isn't going to just shit out spaghetti code. Also, if you charge more, it actually helps drive off the shitty clients and attract better ones.

>tfw no first world-only freelance site

>tfw no informed customers who understand that pajeets deliver low quality

>when you discover test-driven development

Why the fuck do people originally and still use PHP?

Hey webcucks, anyone using Flask? The request.form MultiDict behaves a bit like a hashmap so the arguments that were received are not stored in the same order, any way to fetch them as they were originally posted?

>Flask
This is why you should be using Django

Let's look it from another angle: Why do you want to receive the params in a specific order? What are you trying to do with that?

I'm writing a proper PayPal IPN which requires you to dial their servers back with cmd=_notify-validate parameter followed by parameters that were initially received.

And from their IPN documentation:
>the message must contain the same fields (in the same order) as the original message and be encoded in the same way as the original message.

Thanks guys for the response. :)

Give an example of the order of the multidict you receive, the form field's order, and your desired output message

see Basically I receive a POST request with a bunch of data, the web server parses it and passes it as a dictionary to the view handler, however, the dictionary, like in many interpreted languages, is a hash table alike which means the elements are in a different order than they were posted depending on the hashing function implementation. Reading through Werkzeug's source code right now if I can somehow hijack the original HTTP request so I can parse it out manually.

who /no-competence/ here?

>webdev courses in college
>teacher says work is great
>go through php, sql, DOM, jquery, xsd, xslt, html5, xhtml, bootstrap
>i can do all of it
>make nice looking websites
>show code to people
>"user this is shit"
>too afraid to do freelance work because i don't trust my security methods
>too afraid to do volunteer work because i don't know anything about hosting
>spend my time making homepages for myself and starving to death

It's a dictionary. Parse the keys in the way you want

>originally
PHP started out as sort of a collection of useful scripts that eventually grew into a programming language by accident.

>still

1. Basically every web server in the world will run PHP out of the box or with very little configuration. It's sort of a templating engine, ORM, and server framework rolled into one.

2. PHP is really easy for a beginner to get into and start making things. If you know html and some basic programming concepts, you can go from zero PHP knowledge to a functioning app in like 4 hours.

3. Wordpress, Drupal, Magneto, and countless other services use PHP. In a large company, it gets ridiculously expensive to switch to new technologies. It's why when you go to $localSupermarket they're still using those yellowed IBM point of sale systems. Businesses usually only replace tech stuff every 10-20 years, or longer if they can. Non-tech people, especially old timers aren't used to how fast the tech world moves, so they just don't understand why it's such a problem to use old stuff.

4. Being essentially an HTML templating engine with a bunch of extra features, PHP completely disrespects separation of concerns. Pajeets can just write their business logic right on the page, so they never learn to use MVC. Since you can't do that with other server frameworks, the switching cost is too high for them to learn something else, so they don't. and thus, the cycle continues.

You don't seem to understand, the web server parses the initial HTTP request and breaks it down (status code, mime types, headers, data and so on), then puts it into a dictionary and passes down to the request handler which then passes it to a matching route, I have no control over it.

If only you gave that example..

How is that going to help?

Say the remote server sends a request with POST parameters that go like this:
5=a&3=b&1=c

Now, the web server breaks it down into a request and passes me a dictionary within request that I can access through a request.form variable. If I try to iterate through the dictionary, I'll get 1=c, 3=b, 5=a respectively (could vary on the hashing algorithm), even though I'd like to iterate over it as 5=a, 3=b, 1=c, as it was in the original network packet.

Can't you just attach it together based on what PayPal requests?

Because dealing with clients is terrible. It's not about the tech stack you use or if you're making mobile apps. It's the act of making small websites/apps for small businesses. You get paid shit, you end up being responsible for everything, the work is trivial but draining and you're constantly looking for more work. It's not really freedom.

I'm not saying don't try to freelance, just don't go into "web design" or something similar.

That's what I want to achieve but I cannot just do:
params = '&'.join(['{}={}'.format(key, value) for key, value in request.form.items()])

Because the request.form.items() function will return an iterator with already parsed params put into a dictionary and I can't seem to a way to step back and get those before they have been parsed.

Does PayPal not give you the order you should parse it in? You don't need to use a generator unless you're using an OrderedDict

God, what do you not understand? The dictionary is created /BY THE INTERNAL WEB SERVER THAT HANDLES THE REQUESTS/ as I stated before, which means I cannot just tell it to give me an OrderedDict, that's why I'd like to hijack this request before the the dictionary is generated or through maybe some sort of official Flask API that I cannot find but maybe someone here knows.

>he fell for the "just make websites, it's easy and you can make good money" meme

>DOM
basic html shit

>jquery
Okay great, now learn real javascript

>xsd, xslt
What year is this? Have they put a man on the moon yet?

>html5
html5 isn't a new thing anymore. It's the current standard and has been for a while now.

>xhtml
Again, what year is this?

>bootstrap
Okay great, now actually learn css

>i can do all of it
Cool, can you go potty all by yourself, too? All of that is the most basic of basic shit.

>show code to people
>"user this is shit"
It probably is shit, that's why they're saying it. Learn from your mistakes and get better.

>too afraid to do freelance work because i don't trust my security methods
>too afraid to do volunteer work because i don't know anything about hosting
So practice until you git gud. When you get better, you'll start to feel more confident. Get a solid foundation in basic skills and try contributing to a few open source projects.

What I don't understand is why PayPal doesn't tell you the order you need, so you can piece it together in that order manually. Or how these values are generated in such a way that you can't grab it in the form you need it

can confirm, computer illiterate small business owners believe you should do everything from development to hosting. Even when you make it clear to them, that you don't do that. But that's nothing compared to them constantly moving the bar believing you should not charge more.

But if you make your pricing and terms and conditions very clear to them from the beginning, then you can avoid 80% of the disagreements. Freelance web dev is a bit like working in a retail complaints department. Anyone who has done that should know what I mean.

Failing is part of learning and getting better.

>What I don't understand is why PayPal doesn't tell you the order you need, so you can piece it together in that order manually.
They send them as part of the POST request and expect you to dial back with the same key & value pairs in the same order.

However I just found an API function called get_data() which returns pre-parsed byte array I assume so I'll give it a try.

Man, just use Paypal's Braintree like all the sane individuals

>Implying pajeet advertises himself as the poo he is
>Yes sir, I'm John Hansen, I'm living in Florida! 100% american! Do one thing: Do the needful and hire me. You will not regret. I will finish the programme fast and with very not that many bugs. I am certified Java devloper. Certified by? By the Java devloper certificate... group. Yes, is very reputationable.

And the average HR spastard is dumb enough to be fooled by this horrible acting.

It's a legacy code that needs some refreshing, I wouldn't even bother with it otherwise.

Ok. I guess my only other tip is to have a handy debugger around, like Pycharm's, so you can experiment executing different statements at any point in the code

> Do one thing: Do the needful and hire me.

Why aren't there applications like Sketch or Adobe XD on Windows? Been watching how they work and they seem miles better and more convenient at making mockups than Photoshop.

Can we just establish here, right now, that those modal pop ups trying to get you to sign up for newsletters or those that want you to sign in with your social media are the cancer of the internet.

I FUCKING HATE WORDPRESS AND EVERYTHING ASSOCIATED WITH IT. FOR THE LOVE OF FUCKING GOD WHEN CAN IT JUST DIE THE FUCK OUT.

Anyone here works with java as backend?
I have some experience with just good ol' java SE but I'm trying to get into EE and webdev and I'm trying to start from the ground up, but I would like to know what is actually useful to know from someone with experience. Some guideline of what is good and actually useful to know?

Like do I even bother learning stuff like dealing directly with JDBC or just get acquainted with Hibernate, Spring or whatever?

>Can we just establish here, right now, that those modal pop ups trying to get you to sign up for newsletters or those that want you to sign in with your social media are the cancer of the internet.

ad blockers, yo

>I FUCKING HATE WORDPRESS AND EVERYTHING ASSOCIATED WITH IT. FOR THE LOVE OF FUCKING GOD WHEN CAN IT JUST DIE THE FUCK OUT.

Welcome to the world of webdev. There are tons of sites out there still using flash and java applets. It'll never die, it'll just slowly become less popular as newer stuff comes along. Eventually it'll be unpopular enough that the core devs abandon it. Your grandma's shitty wordpress blog will still be around until she dies and the server fees eat all the way though her bank account though.

Redpill me on Magento /wdg/

When you can't even bring yourself to build a funny project for the lulz which would take you an hour, you know it's over.

I quit on trying to implement input slider... I'm probably just lazy but that's because everything is boring.

Ask Jeeves

God I give up. So I found a better way. You can override the storage mechanism for the data so you can plug-in an unordered dict just fine but after fiddling with it for a bit I've not succeeded. I keep getting "INVALID" reply instead of "VERIFIED".

I've read the documentation multiple times and tried various approaches and none of these worked. I'm pissed off but I'll try again tomorrow.

How long does it take to go from application -> employment?

Depends, but I'd say usually 1-2 weeks from application to interview, and from there, it could be anywhere from the next day to another couple weeks till you actually start.

Months, apparently, because I have yet to even get an interview.

I'm too stupid to make this codepen scrolling image repeat in a loop instead of just skipping to the beggining of the animation.
Can somebody help me?
codepen.io/user/pen/GoYEyj

Is your resume shit?
Do you have a portfolio?
Did you make sure to include a good cover letter?
Did you follow up after a week or so?
Do you ever go to local networking or tech events?
Do you have any notable contributions to open source?
Do you have some kind of criminal record or embarrassing but easily googlable baggage?
Are you a disguising autistic neckbeard?

Those are all things that affect whether or not you'll hear back.

Is your resume shit?
Nope, had it vetted by the Career Services department of my college.

Do you have a portfolio?
Yes, one major project and one..not so major. I'll be adding a third (another major one) in a few weeks.

Did you make sure to include a good cover letter?
See question 1.

Did you follow up after a week or so?
Nope, I probably should. I haven't followed up with any of them.

Do you ever go to local networking or tech events?
Yes, but rarely. Not much to do neither are there many people to meet here.

Do you have any notable contributions to open source?
Nope, only the projects on my Git.

Do you have some kind of criminal record or embarrassing but easily googlable baggage?
Nope, I barely exist on the internet outside of my LinkedIn, Git, and a few other accounts.

Are you a disguising autistic neckbeard?
Slight social anxiety and I suck at public speaking but that's about it. My social life is pretty tame but I'm far from unapproachable.

>Nope, had it vetted by the Career Services department of my college.
Was your resume reviewed by any IT people, or just HR grad students? If they aren't knowledgeable about tech stuff, they aren't going to be that much help. Getting the right mix of bullshit buzzwords (to get past HR) and important shit (to actually show off to the people you're going to be working for) is tricky business.

>Did you make sure to include a good cover letter?
>See question 1.
Make sure you're tailoring the cover letter (and to a lesser extent, the resume) to each job posting.

Also, try reaching out to your school's CS department (I assume you're in a CS major or similar). If there's any teachers you're friendly with, ask them to help you.

>Nope, had it vetted by the Career Services department of my college.
>hasn't had an interview in months

The purpose of a resume is to get you an interview. If you're not getting interviews, then your resume is shit.

Put more buzzwords, languages libraries, tools and frameworks on it. Trigger all those keywords.

Remember the only thing that stands between you and an interview is a recruiter who thinks that a computer is a magical Facebook machine. They only have a job until we make robots that can match keywords and then hold a phone conversation.

Don't waste space with a long rambling paragraph about about how you learned the value of hard work and teamwork during your job as a gas station attendant, or McDonalds. Nobody cares.

I need some cool projects to make because I don't have dick that's open source that I can show but I can't fucking think of anything.

Where did my creativity go

Thanks for the tips lads. I always thought since it was vetted I wouldn't need to do much, but I'll take it to my department chair (he's pretty chill) and ask him for tips.
Never really thought about following up either, so I'll email a few places I applied to 2 weeks ago.

It's useful due to its server-side nature. If you don't want to leak information you can have PHP generate the page.

The only serious problem with PHP is the speed of deprecation. Used any function in your code? Better not update.

If you didn't also have to take classes on security and coding structure you got cucked.

The internet sucked it dry

I'm having a CSS problem: getting a gif to animate.

The gif works fine anywhere but on this element. The html structure is as follows:


I'm trying to put the gif as the background image for the nested div with class="back".
The div with class="card" has the property transform-style: preserve-3d. If I remove that property, the gif will animate on the nested div correctly, but obviously it can no longer be manipulated in 3D the way I want it to be.

Anyone know why this is happening and if there's anything that can be done about it?

I've made an imageboard software. I think it looks pretty decent on the site I'm running it on. I'd like some formal opinions on it, but I don't want to post the link in here in case I get banned.
I'm looking for help mainly with the front-end. If anyone's interested in taking a look, email me at [email protected]

Tell us more about it. Are you using any particular front end libs or just plain html/css/js? What back end language and templating engine?

Convert the GIF to CSS animations and it will work.

Well, the software itself is called VIB, for vanilla imageboard. I wrote it with the intention to use as little third-party software as possible, because it's been a learning project. So far I haven't used anything I didn't write myself with the exception of the font (Roboto) and a bit of the image uploading script. I uploaded a screenshot with the last post.

Oh, and to answer your last question, the back-end is in php(7) and I'm using a mysql(mariadb) database to store posts and such.

Okay, I sent you an email.

>I've made an imageboard software
Yeah, just like 90% of the devs in these threads. How creative.

Depends on how many pahjeets live near you. I can't even get an interview because of the competition.

Eh. My aim is not to be creative, it's to do coding I enjoy and create something I'll enjoy using.

how can I remove text from canvas without clearRect?

Not opensourcing it?

Ruby on Rails or PHP?

Phoenix.

PHP

draw something over the text?

need design inspiration.

I want something simple like this, but not so bare.

what would you suggest adding to a basic technical log site? I'll probably add a bitcoin donation link and an about me page. anything else?

curves faggot, ppl like curves

user pls

React says: 'Download the React DevTools and use an HTTP server (instead of a file: URL) for a better development experience: fb.me/react-devtools'

What's the advantage to using a server rather than a file?

Real websites have curves.

some shit won't work from files

What won't?

hi /wdg/ I have just started making baas software.. I would like to know if my doing is a good practice?

So when user launch theprogram, the program will make a httpreq to my website to fetch some data for user to view..

then, when the user are eligible to insert their data, the program will make 3 http reqs to my website.. first one is for INSERT query, second will do the DELETE query, and the last will be SELECT (to display the latest set of data)..

What I am having trouble with, is ; is this a good practice? I mean, making multiple requests at one time.. is it bad? performance wise?

just change repeat-y to x

Complete shit for any kind of performance. Templating isn't bad, the admin area is powerful but they need an UI guy to sort that shit out.

Kills your performance, unless you are using HTTP/2.

Guys. How do you handle all this fucking incompatibilities with IE.

I created an entire website, but when it comes time to test on IE, its just bug after bug when it worked fine on chrome.

What are the bugs?
Stupid bullshit like "string.repeat" not existing.

Is there a js script I can include at the beginning of the head that'll add all the missing bullshit to ie, so that it'll behave like chrome and firefox?

yes, polyfills

I run an array of test strings with eval and load a bunch of polyfills, if even one fails.

github.com/Polyfiller/polyfiller

God damnit. Why does everything want me to use node these days? I don't know how to use node, and I don't have time to learn on this specific project. (which Im being paid for)

I'm using apache. I have a regular website. I want to be able to just include a js file client-side. I shouldn't have to have a fuck ton of npm packages and less files to just do some basic shit.


Good grief.

Did you even look at what that package does? There's a ton of ES6+ shit, of course it needs node.

Polly-filler didn't work, so I went and built a modernizer with EVERYTHING. Literally EVERYTHING checked.

Built the file.
Included it.
...And IE still reports breakages.

Like what the fuck?
Has somebody seriously not just created a one-off script that bridges the gap between IE and chrome?

You would think someone would've done this by now. It's fucking stupid that I should have to do all this extra bullshit just because IE can't keep up with the rest of the world. I just want to include a single file, and have IE "just work" the way it is with chrome and firefox.

Good gravy. I fucking hate cross-browser compatibility day.

>gets paid to use PHP
>complains at the opportunity to learn something to take him out of his PHP hole

What exactly are you creating? What does the code do?
Have you considered the possibility that you aren't following best practices when it comes to writing code, causing it to break in IE? Just curious.

I'm complaining because in the real world there are deadlines. Not everyone lives with mommy and has all the time in the world to learn every new piece of obscure bullshit.

I've got deadlines to meet. If I don't meet them, then I don't get paid.

I'll happily use php over node because its actually simple to use, and is fast to develop. That's why everyone uses it.

Joke all you want about "pajeet", but when "pajeet" has a bank account with $30,000 cash, and you're living in your mother's basement, then I'd say its safe to say "pajeet" is the one who's got it figured out. Not you.

Nobody gives a shit Pajeet. I'd rather be a non-retard who knows how to use something as simple as polyfills over your shitty PHP job at a company which must be pretty shit if they let you in.

We all have deadlines, but most of us have better jobs than you because we moved out of low-tier technologies.

Got $30,000? Good. Now learn something new and get a job with bigger challenges and reasonable deadlines.

Why are you even trying to support the five people in the world still using old versions of IE? Fuck 'em. It's unrealistic to expect an obsolete browser to be able to compete with something that gets updated constantly.

IE not being able to run anything is a good thing, because it'll force people to update to a modern browser.

>but most of us have better jobs
>most of us have jobs

Well fuck, I might be in the minority here.

how to build a regex with js that checks if a string has the same character two or more times next to it

aab -> true
aba -> false

Do your own homework, asshole

developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Regular_Expressions

Anyone have any experience with db-specific cloud hosting? Looking to setup a PG database.