Web Development

What’s the best language to learn for data site backend?

I’m thinking of learning a language to develop some data related websites, may involving, stock charts, data quarry from DB, data visualization. So what’s the best choice here? Host expenses, maintained difficulty, development difficulty, what else to consider? I heard node.js is quite fast, is it true here? What PHP can’t do that python can? Some people said java was more efficient, while some said java cost more resources. How about go?

submitted by /u/blue-meteor
[link] [comments]
Categories: Web Development

Talk Me Off the Ledge: Overcoming Beginner's Slump

webdev: reddit for web developers - 23 min 32 sec ago

About 8 months ago, I set out to teach myself web development and starting from a basic understanding of HTML, worked my way through the MDN Learn Web Development docs and moved onto paid online courses. At this point, I think I have a good, though novice, grasp on the technologies, how the web works, how to build small things both from scratch and using frameworks, and have some basic programming skills which I've been working on improving with sites like CodeWars and LeetCode, etc.

But after 8 months (which admittedly is a very short amount of time) I feel overwhelmed by how much there is to learn, and what I do know seems miniscule and trivial. In the beginning I was chugging along, learning a lot but after I dove deep into JS and programming, I feel like I stepped into a massive universe where what I knew amounted to almost nothing. I'm still working through tutorials, doing code challenges every day, and I see myself improving but it feels like there's always something else I need to learn to get to where I want to go and the finish line keeps moving further and further away.

When you were starting, how did you power through? How long did it take you to move out of the sandbox and into the real world?

submitted by /u/brodega
[link] [comments]
Categories: Web Development

Drupal 8 frustrations

I have been getting more and more frustrated with drupal lately, it seems like things are changing faster than I would like.

My current frustration is that I can no longer update drupal with drush, it seems as though I have to use composer to update.

I am actually considering switching to wordpress where updates are very very simple.

submitted by /u/bloomt1990
[link] [comments]

How to build a website that can purchase cryptocurrency?

webdev: reddit for web developers - 33 min 37 sec ago

Looking at building a website that will have some functionality involved in purchasing Litecoin, and we're at the research stage right now. Does anyone have any experience with cryptocurrency? Would using an API from an exchange like https://docs.gdax.com/#api be the way to go?

submitted by /u/J_ron
[link] [comments]
Categories: Web Development

Learning and starting to use webpack, few noob questions.

webdev: reddit for web developers - 41 min 53 sec ago

So I've implemented the usage of webpack and its optimization plugins for images and such and was able to cut down my requests on my basic portfolio by more than half and reduce the mb transferred from 8mb to 4mb (mainly image reduction).

  1. My first question is, when I call the css in my JS file it puts it inline in the header when the index file is produced, is that wrong or better than calling it from a CSS file? i.e. Do I want it to be inline or external and how would I make it external if so.

  2. My second question is, how would I apply this to wordpress, right now I transfer my sites over to wordpress so when it comes to deploying more pages or do SEO work I just use the addons and it makes life easy. My sites aren't particularly wordpress but I do split them up so my header.php and footer.php include the navbar and footer so when i create a new page it takes out the copy paste work.

I think I can enqueue the bundle.js file in the functions.php file but I'd have to input the html myself rather than generate it and have it optimized with webpack. Even then I'm not sure if that would work with the way it loads the css.

submitted by /u/toonwarrior
[link] [comments]
Categories: Web Development

The Ultimate Guide to Headless CMS

CSS-Tricks - 48 min 53 sec ago

(This is a sponsored post.)

The World Has Changed—So Must the CMS

Having a responsive website is no longer enough. Your audience expects a seamless and personalized customer experience across all their devices—the age of headless technology is coming.

Headless CMS is the next generation in content management for brands that want to stay ahead of the curve by engaging customers through the growing number of channels.

Download The Ultimate Guide to Headless CMS ebook for a deep look into what headless CMS is, and why it should be at the top of your list when choosing a new CMS.

Download the ebook now!

Direct Link to ArticlePermalink

The Ultimate Guide to Headless CMS is a post from CSS-Tricks

Categories: Web Development

Is there a way to make Chrome easier to drag with tabs open? The hit area is so small.

webdev: reddit for web developers - 1 hour 31 min ago

With multiple tabs you have to be so precise when you want to move the window. Is there a setting or extension that makes the top area bigger? Or at least the hit area bigger?

submitted by /u/Mike
[link] [comments]
Categories: Web Development

What else except GIT

webdev: reddit for web developers - 1 hour 50 min ago

Hi guys, I manage a web app, and the développement is done on a different domain setup identically to the production one. Would like to know what kind of tools to use besides GIT to improve efficiency when doing versioning. How do you do it?

submitted by /u/IAmCristian
[link] [comments]
Categories: Web Development

What's a good alternative to Medium to write tutorials on?

webdev: reddit for web developers - 2 hours 14 min ago

Up to now I've just used Medium to write tutorials or code-related posts on, but it's obviously not been built with that in mind.

Can anyone please recommend a good alternative that has convenience features like more customisability with syntax highlighting, commenting, showing diffs, code sandbox, etc?

submitted by /u/NSGSanj
[link] [comments]
Categories: Web Development

Live Update with YouTube API + JS... is it built in?

webdev: reddit for web developers - 2 hours 34 min ago

JS is not my strong suit these days. Except for a little bit here and there, I haven't used it since before JQuery existed. The only experience I've had with the YouTube API is putting together a class that displays a notification on our site if we are broadcasting live.

Currently I'm working with the YouTube API and PHP to display the notification. What I have right now does everything we need... except for one thing: display the notification without having to refresh the page.

Is this something that could be done easily with JS and the YouTube API? I'm wondering if I could just do something like query the API every 60 seconds.

submitted by /u/flipjargendy
[link] [comments]
Categories: Web Development

How do you manage files that need to be different for different environments? (Apache/PHP)

webdev: reddit for web developers - 2 hours 37 min ago

Hey all, I have a Apache/PHP site on a Linux server and we're attempting to build local dev environments on each of our Windows computers so we don't have to make changes to the live site. However, several files need to be different between the local version and the version on the server. (eg. .htaccess, <base> element in the head, widgets that create a wordpress blog instance, etc)

I can get around this by putting if ($_SERVER['SERVER_NAME'] == 'mywebsite.com') {} else {} but this seems really sloppy. Is there a more acceptable/best practices way of doing something like this?

Thanks!

submitted by /u/tsunami141
[link] [comments]
Categories: Web Development

Can you help me to install SASS in Linux?

webdev: reddit for web developers - 2 hours 40 min ago

I'm using vagrant/virtualbox virtual machine running a distro named ubuntu-trusty-64 which I assume is Ubuntu 14.04.5 LTS (Trusty Tahr). It is the distro used by Laravel Homestead.

When I run sudo gem install sass I get this error

$ sudo gem install sass Fetching: rb-fsevent-0.10.2.gem (100%) Fetching: ffi-1.9.18.gem (100%) Building native extensions. This could take a while... ERROR: Error installing sass: ERROR: Failed to build gem native extension. /usr/bin/ruby1.9.1 extconf.rb Gem files will remain installed in /var/lib/gems/1.9.1/gems/ffi-1.9.18 for inspection. Results logged to /var/lib/gems/1.9.1/gems/ffi-1.9.18/ext/ffi_c/gem_make.out submitted by /u/thinsoldier
[link] [comments]
Categories: Web Development

Alignment / flex box help

webdev: reddit for web developers - 2 hours 49 min ago

Ok so basically im trying to get 2 div elements to sit under another 2 elements "photo1, photo2, and photo3, photo4" using flex box. This will be used as a image gallery style page.

Any help is appreciated ! sorry for the basic question.

HTML :

<div class="nav"> <div class="logo"> <img src="/images/slade-logo.png"> </div> <div class="menu"> <ul> <li> <a href="/index.html"> Home </a> </li> <li> <a href="/index.html"> Typography </a> </li> <li class="selected"> <a href="photography/index.html"> Photography </a> </li> <li> <a href="/about/index.html"> About </a> </li> <li> <a href="/contact/index.html"> Contact </a> </li> </ul> </div> </div> <div class="photo-container"> <div class="photo-box"> <div id="photo1"> </div> <div id="photo2"> </div> <div id="photo3"> </div> <div id="photo4"> </div> </div> </div> </body>

CSS:

/* Photography */

.photo-container { width: 100%; height: 1000px; background-color: aquamarine; display: flex; align-items: center; justify-content: center; }

.photo-box { width: 80%; height: 1000px; background-color: plum; display: flex; justify-content: center; }

photo1 { width: 50%; height: 200px; background-color: palegoldenrod; display: flex; align-items: center; justify-content: center; margin-top: 20px; margin-right: 10px; margin-bottom: 10px; margin-left: 20px;

}

photo2 { width: 50%; height: 200px; background-color: palegoldenrod; display: flex; align-items: center justify-content: center; margin-top: 20px; margin-right: 20px; margin-bottom: 10px; margin-left: 10px;

}

photo3 { width: 50%; height: 200px; background-color: palegoldenrod; display: flex; align-items: center; justify-content: center; margin-top: 20px; margin-right: 10px; margin-bottom: 10px; margin-left: 20px;

}

photo4 { width: 50%; height: 200px; background-color: palegoldenrod; display: flex; align-items: center justify-content: center; margin-top: 20px; margin-right: 20px; margin-bottom: 10px; margin-left: 10px;

}

submitted by /u/ImSlade
[link] [comments]
Categories: Web Development

Get Ready for `display: contents;`

CSS-Tricks - 2 hours 51 min ago

Last year I asked, "Will we be flattening our HTML for CSS Grids?"

The issue is that the only way for elements to participate in the same CSS grid together (or flexbox for that matter) is for them to be siblings. So, in some cases we might be incentivized to forego HTML semantics for the benefit of layout (not great).

One answer to this is display: contents;—a magical new display value that essentially makes the container disappear, making the child elements children of the element the next level up in the DOM.

Fast forward to today, Chrome is shipping it, WebKit is shipping it, and Firefox has shipped it. Vote for it in Edge here.

Wanna understand it better? Rachel Andrew wrote "Vanishing boxes with display contents" and clarifies how it all works:

This value becomes useful if you want to add some element because it makes sense in terms of document semantics, but doesn’t in terms of display. Perhaps you have some content that makes sense marked up as an article, that article is then a flex item in your layout BUT the elements you really would like to be flex items are nested inside that article. Rather than flattening your markup and remove the article element to enable these inner elements to be part of the flex layout, you could remove the boxes generated by article using display: contents. You then get the best of both worlds, semantic markup plus the visual display your design requires. That sounds good to me.

Manuel Rego takes a stab at explaining it as well:

display: contents makes that the div doesn’t generate any box, so its background, border and padding are not rendered. However the inherited properties like color and font have effect on the child (span element) as expected.

There is also a very related subject to all this: subgrids. Probably literally display: subgrid;. It's probably less important in terms of maintaining semantics than display: contents; but also different.

Eric Meyer called subgrids essential:

Grid layout is the first serious candidate to fill that hole in the past two decades, and I don’t want to see them hamstrung from the outset. Subgrids are essential to the adoption of grids. I hope they’ll be implemented as soon as possible

And to understand the difference, Rachel Andrew also wrote "Why display: contents is not CSS Grid Layout subgrid":

You won’t get far through a conversation about subgrid in CSS Grid Layout without someone suggesting that display: contents solves most of the problems anyway, so do we really need subgrid? This really isn’t the case, display: contents does indeed solve a class of problems, but these are different problems to those that subgrid would help us with.

Get Ready for `display: contents;` is a post from CSS-Tricks

Categories: Web Development

Is there a URL directory?

webdev: reddit for web developers - 3 hours 2 min ago

I can't think of the right google/reddit search to find what I'm thinking of.

Is there some sort of HTML system, whereby I can have one file that acts like a central directory for URLs for my site?

For example, I have a persistent navbar at along the top of every page, with the same links, such as "home", "contact", "about" etc. One each page, I have the URL links for each other page. Is there a way that I can just have;

href="contact page"

where this "contact page" directs to the central URL directory? Instead of the literal URL link typed each time, like;

href="contact.html"

And then if all of the URLs are in one centralised location, I can change it once there, instead of changing it on each page?

I think I used something like this in Rails a few years ago, but I can't remember or figure out what it is or what it is called.

Thanks for your help!

submitted by /u/gunnerrec
[link] [comments]
Categories: Web Development

Pages