« first day (2849 days earlier)      last day (2116 days later) » 

12:00 AM
@Fabby you know PHP?
 
12:30 AM
why is JS so inconsistent in where it requires semi-colons?
 
12:50 AM
@TheWanderer overloads?
 
someFunction(someVariable = false) {}
I think that's what it's called...
 
1:01 AM
I just always use semicolons after every statement and end-brace. It doesn't make anything fail to have an extra one. It can lead to unexpected behavior to leave one off.
 
 
1 hour later…
2:09 AM
@RobotHumans PHPStorm yells at me
 
2:22 AM
@TheWanderer
I am here.
And aptX low-latency is amazing.
 
Sup @NathanOsman - the php question is about listing the contents of a folder. I put in a reply here chat.stackexchange.com/transcript/message/45698543#45698543 that solves the problem. A foreach loop that generates uls with a scandir call.
Anything interesting going on?
 
@NathanOsman u is late
I already got things working in PHP
 
2:38 AM
wtf
why is CSS top,right,bottom,left?
 
to make float calculation easier. if you have a float, you need to know its righthand offset to see if it pushes something to the next row first. then you need to know bottom to know how far down the next row goes. then you need to know left to see if it pushes it 1px over the limit (it usually doesn't)
 
but every programming language I know of goes left,top,right,bottom
and I know CSS isn't a programming language
but it should still follow norms
 
it's an optimization. even if it's different, it's an optimization.
sup @Mateo long time no see
 
2:54 AM
hi, how are things @RobotHumans
I've been busy with work, and on the fun side I've been playing with ubuntu phone stuff mostly
 
heyyyy it's been a while mateo!
@NathanOsman turns out a friend had a spare portal 2 key lying around
:D
 
@Mateo got fired the other day for asking what the pay schedule was after the boss ducked on payday. have a couple of things on the line, so not that serious. still irritating. other than that, things are pretty good
 
@RobotHumans sounds like you might have dodged a bullet there anyway
or got partially grazed? idk
 
yikes
well, I guess sooner rather then later if they werent planning on paying
 
@Seth Eh. Probably. He was stealing 2 paychecks per year at minimum with a 14 day billing cycle and a 15 day pay cycle. Then dodging payday and wanting to pay on tuesday or thursday only to skew it a few more days, so the last visible billing cycle could be on the 17th even though if the check came out on the 15th it would be obvious it should be the previous billing cycle. So, that makes it short at least 3 full pay periods the last year.
No double checks for those 2 three paycheck months anyone who has worked biweekly pay cycles is familiar with. So, yes. Dodged a bullet and slightly grazed.
out of professionalism, i haven't mentioned a company name
anywho moving on. on a positive, working on a course for udemy to point out gotchas that bit us when i was at the last job as a "the webdev course you should have had in college"
 
3:05 AM
 
Nice on the doctor who wallpaper
 
@RobotHumans is it a company we'd be likely to run into?
 
@TheWanderer Not unless you live where I do. But the primary employees were college student temps that wouldn't catch the accounting discrepancy and move on before it became a pattern.
 
shouldn't this be reported to something?
 
It should, but I haven't cashed my last check yet. So, I have to wait for my last check to clear (that has been mailed to the wrong address even though my 1099 got here just fine)
my last two checks were mailed as opposed to picked up on site at employer request and were both mailed to incorrect addresses - thankfully i know that neighbor and they'll give me a mailbox key
 
3:11 AM
this sounds like a really shady company
 
Yeah. It does doesn't it. And every ex-employee is the devil. And all the new employees are awesome.
 
wat
well I actually do have a question @NathanOsman depending on how much JS you know
 
All ex-employees are badmouthed. All new employees are great. The day I called out the pay discrepancy to 1)the project manager, 2)another guy that picks up his check locally, and 3) a guy that offered to get me reimbursed if something i hosted on my free amazon instance hit my credit card due to usage is the day I got fired.
@TheWanderer i may or may not be able to answer it. i worked with js for the last year and a half.
 
alright
so I have this block of HTML that I'm dynamically adding to the document
one of the elements in the block calls a function onClick
the problem is that the console complains that function doesn't exist
it's in the same js file as the function adding the block
 
is it added to the main DOM or a shadowDOM
 
3:16 AM
uh
I'm just doing document.getElementById()
and adding to that element's innerHTML
 
I'ld have to see the code. It sounds like it's in the main dom and the problem is the code, not some dynamic rewrite framework.
 
assets/js/triggerdownloads.js and index.html
live site
 
what are you clicking to get the rewrite that doesn't work?
 
the Download button
 TypeError: download is not a function
    at HTMLAnchorElement.onclick ((index):1)
 
I'ld fix the lack of semicolons in the triggerDownloads.js file first and see if it magically works.
As previously stated, I use them after every statement and end-brace
 
3:26 AM
nada
 
I haven't seen this syntax before:
    $.post(
        "/addtodownloads.php"
    ).done(
but it could be correct-ish.
 
it works
go to the live site
 
I'm on the live site zwander.tk/#downloads
 
so you can see that that code block words
otherwise all those files wouldn't be there
it's just the download that's weird
I notice it adds a new (index) in the Sources tab on Chrome when I click
 
the files are listed, but the interesting part is download is not a function
so parsing error on the include
 
3:32 AM
?
 
kneejerk was count braces to see if counts match. count () to see if they match. fix semicolons.
 
semicolons are all in
 
your triggerdownloads.js file is broken in some way.
 
and I'm using PHPStorm, which tells me if there's a syntax error
 
JS is funny that way. Code checkers don't find everything. I've had code validate and still be screwed. It gets pulled in 200 OK in the network view in the tab and browses right. The problem is in that file somewhere, and it's breaking the parser.
 
3:43 AM
used a lint, it just complained about the lambdas and template strings
 
The direct download from the download.php seems to be working if slowly. It at least stalls. The problem is defs in that js file
ramdisk.img only returns 316 bytes though, and it's empty
 
so it looks like I can't use download for the function name
I had to change the name
unfortunately, now just nothing happens
 
open wireshark, and see if it hits zwander.tk/download.php - then you fixed one problem and found another one
all downloads appear to be taking forever, but returning empty sets and 200 OK
 
Undefined index: file_name
 
it was oneword no underscore in some other code. consistency.
 
3:49 AM
no that was the js variable name
the Ajax field name is file_name
 
no, that's the field name your php sends
 
am I supposed to use $_GET?
 
poop. my bad i read it wrong. and no it's a post
using get would just put file names and other junk in the url for logs. i like using posts even when i'm supposed to use gets to keep things out of the url string
Okay, so the POST works. It just takes 40 forevers to complete
 
I probably need to change the method it uses to download or something
it still doesn't work for me though
 
I just pulled ramdisk.img using post. technically, the spec says to use gets to download something, but then you put the filename in the url. I'm a fan of deviating from spec a little and using post instead, so you don't slip up sometime and leak something you didn't mean to leak
I didn't mean the site worked, I meant it worked in postman.
I don't use PHP, so I can't say 100%, but it's probably a mime-type or something where the browser doesn't know it's a download as opposed to just data
 
4:15 AM
oh I think the POST is workng
leave the page long enough and it crashes
 
 
1 hour later…
5:23 AM
@ThomasWard what are the conditions for the "Move this discussion to chat" link to appear to normal users?
 
1
Q: 100C CPU temperature in Ubuntu's "sensors", but 39C in BIOS, which one is correct?

AnnaI have MSI x470 gaming motherboard and AMD ryzen 2600x and running Ubuntu 18.04. The issue is, when I type "sensors" in terminal it gives me output on CPU temperature to be 90-108C degrees (only browsing the internet, few tabs opened), but when I quickly reboot PC and open BIOS, it says CPU tempe...

 
6:00 AM
0
Q: How do I install GLIBCXX?

sjaakI'm trying to install this software called Skedler. Their documentation mentions GLIBCXX library dependencies but they couldn't be bothered providing installation instructions. GLIBCXX libraries Skedler has dependency on libstdc++ library. Following are the GLIBCXX versions the code depends...

 
6:33 AM
@TheWanderer XMLHttpRequests cannot really do downloads, it ignores the attachment disposition
Although blobs have been introduced later, they still put the entire file into memory first and it seems like you're hosting large files so that'll be a problem
I suggest submitting a form to a _blank iframe
the content is sent fine
 
7:20 AM
@AmithKK maybe this helps. I thought that the link only appeared if both users have enough reputation (based on my experience) , but if this was implemented it's not very well documented on MSE!
 
Can someone star this:
3
21 hours ago, by blade19899
> "Put on your tux! It's time to get fancy with our new Linux book bundle from No Starch Press. Get How Linux Works, The Linux Programming Interface, Think Like a Programmer, and lots more. (Penguin suit not actually required.)" - Humble Book Bundle: Linux Geek by No Starch Press
 
7:59 AM
@blade19899 can't star quotes
 
8:10 AM
This sounds like fun to play with:
1
Q: Why raspbian lite powers off when doing `sudo cat /dev/char/10:130`?

GarmekainI did on a terminal sudo cat /dev/char/10:130, which in the uevent has name of watchdog, and it outputs a message from the kernel saying that watchdog did not stop !, and after a couple of second it powers off, why? What am I exactly doing? I'm running Raspbian lite on a Raspberry 3b+.

:X
 
 
1 hour later…
9:28 AM
i have dual boot ubuntu 16.04 LTS and win 7 ,my win 7 is not booting saying some disk error ,so i want to know that is it possible to check error through fsck command using terminal because i am not capable of booting win 7
thank you !
 
68
Q: Fix corrupt NTFS partition without Windows

NemoMY NTFS Partition has gotten corrupt somehow (it's a relic from the days when I had Windows installed). I'm putting the debug output of fdisk and blkid here. At the same time, any OS is unable to mount my root partition, which is located next to my NTFS partition. I'm not sure if this has an...

But the error may come from something else... can you access the Windows partition from Ubuntu?
 
10:00 AM
@user716691 "some disk error"? That can be a very wide range from hibernation to an actual broken disk.
and no fsck can not be used
"i am not capable of booting win 7" windows 7 does not have a rescue mode?
 
10:15 AM
@Rinzwind It can't?
 
@terdon Nah. There is ntfsfix but for more than fixing the bad state from hibernation I would use native windows tools :P
fsck will error out with "Bad magic number in super-block" on ntfs :-)
 
Hello :)
 
boxy! :)
 
Rinzy ! :)
Hi terdon :)
 
@cl-netbox That would be Terdy. And when he is late Tardy :=)
 
10:22 AM
groan
and hi
 
@Rinzwind not sure if he would like it ... :D
 
@Rinzwind Really? So fsck.ntfs can never fix ntfs errors?
 
@terdon fsck.ntfs does not exist :P That's a link to ntfsfix.
 
Huh. Oh well, that's what I get for not having touched windows in so many years :)
 
11:19 AM
:D
 
Hmm so how should i proceed
how to go to terminal in windows if its not even booting
 
@user716691 from a bootable windows installer :)
 
oh ok thank you ,let me try it first ,if stuck i will seek further help ,thanks again :)
 
12:23 PM
0
Q: Swap content between screens

guillem caboi'm using Opensuse 15. I use two monitors(Small one on the left and big one in front of me) and sometimes i will like to change all the programs from my left screen to the other one and vice-versa by pressing a shortcut instead of dragging windows with the mouse. EX: I have mozilla in the centr...

 
 
2 hours later…
2:17 PM
@RobotHumans works! \o/
I had to use GET (well, manual URL stuff)
 
0
Q: Can't read from serial port after added to dialout group

MilanI attach a device that is periodically sending data over usb port. I tried to read data from port with "cat < /dev/ttyUSB0" and got permission denied. So I changed user to root and managed to see the data in terminal. So I wanted to be able to read data without being root, and added myself to dia...

 
 
3 hours later…
5:01 PM
0
Q: Ubuntu - Root user cannot see $JAVA_HOME variable expanded to $PATH

ha9u63arI have created a variable $JAVA_HOME in `/etc/environment' JAVA_HOME="/usr/lib/jvm/jdk" PATH="...bla bla bla:$JAVA_HOME/bin" I also edited /etc/profile to have source /etc/environment so that all users get java home. and the directory itself has been made 755 for access. The printout as root ...

 
 
1 hour later…
6:24 PM
0
Q: How do i assign Ubuntu 18.04 a static ip, its in a virtuual machine using VMware and host is Windows

user1871I've tried for hours to statically assign a ip but nothing works. Does the network adapter in Vmware have to be set to Nat or Bridged, when i try bridged i never get internet connection. also i read Ubuntu 17+ uses Netplan? Someone please ppoint me in the correct direction.

 
7:08 PM
@TheWanderer I've had to change 1 error on a website coded in PHP 15 years ago, so the short answer is: No! (but I will if I have to) ;-)
 
feh
 
@TheWanderer Feh (interjection), Yiddish interjection possibly the root of the interjection "meh"...
(had to google that though)
 
 
1 hour later…
8:33 PM
Hi all!
user image
4
 
@DavidFoerster :D :D :D Starred!
 
also AI and machine learning
 
@DavidFoerster People are begging for your opinion
 
9:02 PM
@Fabby sigh ok…
 
0
Q: Unable to install kubuntu - installation freezes at random points

Raiden616I am trying to install Kubuntu 18.04 on my Lenovo Thinkpad P50s from a live USB. I have tried going direct into the installer and installing from "Try Kubuntu". The installation fails at various points, but the failure usually takes the form of the wizard simply not advancing to the next screen a...

 
 
2 hours later…
11:20 PM
7
Q: How to search AU for a string containing “$”?

dessertToday I tried to search for this answer, but the only thing I could remember from it was $_, so I tried to search for this term: https://askubuntu.com/search?q=%24_ To my surprise the result page claimed to search for a single underscore only and didn’t find a single post: results found cont...

It’s a shame… :(
 

« first day (2849 days earlier)      last day (2116 days later) »