« first day (599 days earlier)      last day (4339 days later) » 

5:00 PM
@MattMcDonald would shit himself.
 
My god :D
 
@MG1 dude, you need to at least try to write maintainable readable code; Pro Tip
 
MG1
@rlemon sorry, is it that terrible?
 
yes yes it is
lol maybe functional... but extreme rageification when I open it
 
horizontal scroling is bad
do you see horizontal scroll in your text editor?
 
5:02 PM
your big ass block of inline HTML in your js is better suited for a template engine maybe?
jQuery now offers client side templating iirc
 
MG1
sorry man... I'm willing take suggestions as to how to make it better
 
well as a discontinued plugin
 
Hi all
 
though I wouldn't mind if they replaced animation with templating
 
either way... that inline HTML is just hard to read and maintain.
 
5:03 PM
@rlemon wow wth is that?!?
 
Matt this is not just node as it has to ultimately handle javascript its kind of both C++ and JS
 
@Neal it's @MG1's code
 
and i am talking in C++ And JS
 
@rlemon W
T
 
we're helping him sort it out :P and giving suggestions.
 
5:04 PM
F
@rlemon ahhh haaa
 
on node IRC those who can help are too busy and others are .. Hey i dk i just write js
 
it's not that bad, just not that readable or maintainable.
 
@MG1 do not do that :-P
 
lol at irc... #javascript @freenode is complete noobfest
 
MG1
@rlemon so any ideas why the object attribute assignment isn't working?
 
5:05 PM
@MG1 another tip;
        var prevCardCode = '';
        var newDiv;
        var NewDiv2;
        var NewDiv3;
        var InvoiceInfo;
        var count;
        var DeliveryMethod;
        var PaymentFormat;
can be written as
        var prevCardCode = '',
               count = 1,
               newDiv, NewDiv2, NewDiv3, InvoiceInfo, DeliveryMethod, PaymentFormat;
@MG1 i'll get to that
trying to help you for the future my friend.
do you understand the difference between == and ===
 
MG1
@rlemon thank you! I really appreciate it
 
is that a rhetorical quesiton
 
because i'm seeing a lot of == where === would be more appropriate
 
MG1
no I don't know the difference
 
== converts types.
=== checks types
0===0; // true
"0"===0;// false
"0"==0;// true
 
5:07 PM
in javascript the rules for == conversions are manageable in normal human memory though
 
" CSS WG formally allows browser vendors to unprefix CSS 3 Transforms, Transitions, Animations " good to know
 
yea
but hugely misunderstood if you didn't know what it was to begin with
element['PmtRec']['PmtMethod'] == 'CHK'// if the value of element['PmtRec']['PmtMethod'] is also a string use ===
 
MG1
@rlemon ok
 
and WHY U SWITCH BETWEEN DOT NOTATION AND BRACKETS!?!?!?!?!
 
== 'CHK' should be pretty safe, I don't know anything other than that exact string that would pass
 
5:09 PM
@Esailija i know but i'm trying to teach here :P
element.PmtRec.PmtFormat === element['PmtRec']['PmtFormat']
either use [] or .
both is again, going to be confusing and less manageable.
 
MG1
@rlemon I thought . is used when assigning and [] when referencing
 
@MG1 both do both
 
MG1
ok got it
@rlemon are you still teaching /
 
class is in session
 
MG1
5:18 PM
:)
 
obj.a = 'a';

obj.a; // 'a'
obj['a']; // 'a'

var x = 'a';
obj.x; // undefined
obj['x'] // undefined
obj[x] // 'a'
 
MG1
@Oleg thanks got it
 
Did someone already try to instal the Windows 8 preview into a virtual machine ?
 
@DieVarDump One of our admins did.
 
MG1
@Oleg but my object assignment is still not working
 
5:21 PM
The screams and squeals of horror were being heard for like half an hour.
 
Gmail not responding !
 
Ah into VM? Not sure about VM.
 
Screams ?
Why ?
 
@MG1 By the way: element.PmtRec.PmtFormat = PaymentFormat; won't work if you don't have element.PmtRec previously defined as Object.
@DieVarDump He didn't like it...
 
user1385191
@rlemon I wouldn't be spewing fecal matter, but if in a position of power, I would send someone home for the day
 
5:26 PM
@MG1 Do you have any errors in the console?
 
MG1
@Oleg there are no errors, and I changed it to element['PmtRec']['PmtFormat'] = PaymentFormat; for consistancy
 
the metro interface is quite cool i think. Surely better than the new Ubuntu one
Really annoying
 
@MG1 Can you add an output of your csv.php into the fiddle?
 
Metro is awesome
but i am happy with my fedora 17 and Gnome 3
 
MG1
@Oleg What box should I put it into?
 
5:29 PM
iPage just told me that they refunded the 'pre paid' card i told them i threw out when I cancelled and now they are like "well the refund went through and there is no note on the account you wanted it mailed in a cheque"
 
i didn't checked at Fedora since maybe the 11
 
and now they cannot do anything for me!??!?!?!
company of trolls
all of them
 
idk how to SS on fedora on windows i had nice lil prnscr
 
@MG1 to javascript: var data = JSON.parse('...your json here...');
 
RAGGGGGGGGGGGGEEEEEEEEEEEEEEEEEEEEEEEEEEEE
 
5:31 PM
this week, i'll take time to test this. And windows 8 + ie10
 
:D
dont test it on VM i beg you
install a seperate Multi Boot
 
I know i won't do it, but if, and only if, i don't feel too lazy, I'll
 
LOL:
 
MG1
@Oleg 1 seconds
 
user1385191
5:39 PM
time to test out the DOM 0 test
 
:-o
 
user1385191
if I ditch Utils.raise and remove the try/catch, it should run in IE 4
 
user1385191
probably NN 4.8 too
 
MG1
@Oleg I added it jsfiddle.net/m2zWZ/6
@rlemon you're not teaching me anymore?
 
5:49 PM
no i was raging at iPage
 
0
Q: Sudden drop of pageviews/visit and increase of bounce rate in Analytics

TebbGoogle analytics stats: 04 june 2012 Visits: 4.423 Unique visitors: 3.558 Pageviews: 77.352 Pageviews / visit: 17,49 Visit length: 00:06:26 Bounce rate: 1,09% 05 june 2012 Visits: 4.652 Unique visitors: 3.825 Pageviews: 45.087 Pageviews / visit: 9,69 Visit length: 00:06:45 Bounce rate: 19,...

 
i got my hosting package and prepaid a year on a pre-paid CC... then when i demanded the refund and didn't have the CC they said ok, we will mail you a cheque... cool.... called today (45 days later) asking where the cheque was and they say they refunded the CC and can't help me. so i bitch and tell them that it was prepaid and they knew this and were supposed to send me a cheque and they tell me now "well you can contact Mastercard and see if they will send you the money"
PFFT for a card I have no proof I owned, purchased like 2 years ago from some random ass gas station, cut up the same day I purchased the hosting.
and not to mention this entire thing is only an issue because someone on their end screwed up
now I have to suffer
so full of rage
 
MG1
call iPage company, not support and speak to the head of marketing
they will make sure things are fixed very quickly
 
yea doesn't quite work for a company that large
i got escalated to the top I could get too.
there are over 4K employees in like 30 countries.
iPage is huge, although IDK why their service is horrible.
 
MG1
yeah I heard they're pretty bad
 
5:54 PM
i now have a "high priority support ticket for the billing department"
lets see what happens.
 
MG1
haha.. Good Luck!
 
how do feed a json array to jquery autocomplete?
 
don't use this, update a datalist instead
 
update a datalist?
 
it's the future!
 
5:56 PM
@MG1 Take a look at this: jsfiddle.net/m2zWZ/9 and tell me what doesn't work there?
 
1
Q: jQuery Autocomplete plugin - How to dynamically update data list?

davemI am using the jQuery autocomplete plugin for a smart input box. I want the first parameter in the input box to be autocompleted from one dataset, then once that has been selected change the dataset for the second parameter. So if I have the following: var foo = ['a','b','c']; var bar =...

 
that's not what I meant
doesn't work on google chrome
 
MG1
@Oleg when payment format is changes, the object doesn't update
 
works on ff though
 
lol was about to say...
 
5:59 PM
it's just... I like the UI btw
it's totally what autocomplete should be
 
loads up FF
 
it's natural autocomplete
you can look at the source too, it's really simple
 
bug
 
type Python, click off, click back on, highlight the word, mouse over the only option (Python) and hit delete on your keyboard
focus is still in the text input boys... clear my input please
finding bugs like a bauce!
 
6:02 PM
uh? I got no bug :/
works fine for me ;<
maybe you're using FF3.5? :x
btw, you like it?
it is what autocomplete should be, right?
 
it's buggy for me
i'm making video
hold up
it's processing
 
@MG1 Well, your if (element['PmtRec']['PmtMethod'] === 'CHK') is always true... and you only assign your change event when it's not.
 
ugh please use element.PmtRec.PmtMethod over element['PmtRec']['PmtMethod']
dot notation is so much easier to read
@FlorianMargaine ok that vid is ready
 
haven't got this bug
report it
 
first off, the filtered list does not appear consistently. if I click on Python input, it appears, but if I quickly highlight it nothing happens.
i see what you are saying it looks nice and the HTML source is uber simple
 
MG1
6:09 PM
@Oleg well there are about 15 records there... the one I added is a DAC .. just to use as an example
 
functionality wise I cannot talk; because it doesn't work as expected for me
 
yeah, because you're just messing around :p
but yeah, as you say, it looks nice, the html is uber simple (so ajax-updating it is uber simple too), and it's shimmable, although the shims don't look like they work :/
 
MG1
@Oleg I updated the current string to be 'DAC'
 
by messing around you mean; I typed in P, selected Python, then wanted to type in ASP so I highlighted the word, didn't notice my cursor slip down to the option and hit Del then was all "WTF it didn't delete!"
 
@MG1 jsfiddle.net/m2zWZ/13 what about this? Take a look at the console. It outputs different values on change.
 
user1385191
6:12 PM
DOM 0 test gracefully degrades to a 100% score in Opera 5
 
hhh
@user973810 Sorry fell asleep, using Vim and Google Chrome.
 
@hhh why do you use <!-- --> in your js
/* */ is not only prettier is easier to write :P
j/w is all
 
hhh
@rlemon It is NerdCommenter, does it automatically -- depends on the mode.
 
ahh
i don't like it.. (personal opinion)
 
hhh
(yes it is a bit bad-looking but haven't yet tuned or found better)
 
user1385191
6:17 PM
100% for Opera 6 as well
 
check if your linkedin password was leaked
mine apparently was not..
 
user1385191
Netscape 6.10 is actually a pretty decent browser
 
user1385191
same results as FF 1.0
 
MG1
@Oleg I'm testing...
@Oleg element['PmtRec']['PmtFormat'] = PaymentFormat; //this is what's not changing in the json
 
What happens when you splice the last object from an array
does the array become null?
 
MG1
6:29 PM
@Oleg I added more data to make it easier to understand
 
user1385191
no
 
user1385191
the key is deleted
 
user1385191
you're usually left with an array with no elements
 
user1385191
i.e. []
 
MG1
@rlemon I enjoyed your class while it lasted...
Can someone help me figure out why this object assignment isn't working for a change event?
 
6:46 PM
!!>var arr = [0]; arr.splice(0,1); arr;
@Zirak ReferenceError: arr is not defined
@Zirak [object Array] []
@ErikDolor That happens. You're left with an empty array. Why would it become null?
 
Yea, i just realised it'd probably become an empty array :X
 
user986408
can anyone here tell me how i can get the degree/scale lvl of an element when using:
https://github.com/alexgibson/WKTouch/blob/master/WKTouch.js

like:
var element1 = new WKTouch('element_id').init();

now everything is set up and i can drag it, rotate the div or even scale it.. but there's no api on how i can acces those values.. because i want to persist changes into a json
 
user986408
console.log(element1) returns undefined.. thought i can do "element1.rotation" -.-
 
@MG1 what do you mean "not changing"?
Take a look at the console output.
 
MG1
@Oleg I added more data for testing.. but the value is really not changing
 
6:57 PM
@MG1 When you change your Payment Format take a look at the bottom of the page, you'll see some elements added with different values... here: jsfiddle.net/m2zWZ/17
 
MG1
@Oleg yes, but that's not where I need it to be added
 
ugh linkedin - great, now I have to go changing all my freaking passwords.
bastards
 
@MG1 Then it's a totally different question.
 
I'm not sure of my linkedin password
 
Your data does change. It's just being displayed incorrectly.
 
7:04 PM
ahaha it's one of the password i never use
 
Every time your select triggers a change event, you are creating a new element and append it to the end of newDiv3
 
what's strange is they did not send a mail to everyone
 
linked in is one of like 4 sites I use that haven't adopted OpenID
 
By the way, in your each loop, what do you think newDiv3 = $('<div/>').addClass('hd').appendTo(newDiv); does?
 
user1385191
aaaaa
 
user1385191
7:06 PM
is document.createElement("div") that difficult to use?
 
creates the div, adds the class, appends it to the newDiv element, then spits your back a pointer to the element? (i'm seriously guessing i'm not that in tune with jQuery)
@MattMcDonald yes
 
user1385191
then you can toss that object into the jQuery blender
 
user1385191
the only $ "needed" there is the addClass call
 
The problem is that newDiv3 is not in the same scope...
 
If I'm trying to see if an element exists and know the element is empty, would Element.length still work?
 
$(document.getElementById('foo')); is 30x faster than $("#foo"); but you will see me getting scolded for writing the first
 
user1385191
yes, because the entire library is silly
 
user1385191
but somewhat sane code will minimize the damage
 
if( element && !element.hasChildNodes() )
// I exist, but have no children
 
Yes guys, jQuery is silly.
By the way, JavaScript is silly too.
And C++
Let's all get back to vanilla Assembler
 
7:08 PM
Assembly level programming... that is where it is at!
 
It's like FTW
 
for you rlemon
 
user1385191
I have to wonder how many people actually read source code these days
 
user1385191
Hacker News is full of idiots that fawn over shiny demos with bad code
 
i really like the queen
 
7:09 PM
it's been soo long since i've had to write MOV ax,CR0
 
user1385191
for anyone who cares, Utils is going to have its alpha release today on CLJ
 
@DieVarDump I don't get it
 
It'd be interesting to try this method http://7habitsofhighlyeffectivehackers.blogspot.no/2012/05/using-twitter-to-build-password.html on the leaked hashes from LinkedIn, and see what the success rate is
 
user1385191
farewell
 
just the image for your meme
 
user986408
7:10 PM
can anyone explain how i can access those values starting at line 141 ?
https://github.com/alexgibson/WKTouch/blob/master/WKTouch.js

apparently they are stored ..
 
@ThatWebNerd window.WKTouch.scale doesn't work?
 
user986408
but if i have like:

var element1 = new WKTouch('box1').init();
var element2 = new WKTouch('box2').init();
 
user986408
which scale will your line return ?
 
@DieVarDump ahhh i seee
 
@ThatWebNerd element1.scale doesn't help?
 
7:13 PM
Hello! Is the syntax ok here? div.removeChild(lastChild.previousElementSibling) I want to remove the last child and the previous element of my div.
previous element of that LastChild
 
user986408
@Oleg console.log(element1.scale); tells me that element1 is undefined.. alltough i can drag/scale/rotate the thing on the ipad
 
previousElementSibling isn't cross compat iirc
 
user986408
so it kinda works.. but i cant access the attributes
 
var element1 = new WKTouch('box1');
element1.init();
element1.scale; // try this?
 
user986408
7:16 PM
tried that one too..
 
user986408
nope :/
 
user986408
wait
 
@rlemon, So better to not use it? What if I will just block the users with old browsers? A message about upgrading the browser will be welcome. What do you think?
 
user986408
it works
 
yohho
 
user986408
7:17 PM
i dont understand why the hell it works ATM.. but hell thanks
 
Now time to go home, 'night gentlemen.
 
user986408
n8
 
@Hypn0tizeR it's easily shimmed
 
So there are no problems with it) What about the syntax? div.removeChild(lastChild.previousElementSibling) everything right here? Cause it does not work
 
function nextElementSibling( el ) {
    do { el = el.nextSibling } while ( el && el.nodeType !== 1 );
    return el;
}
so you just want to remove the second last child of the element?
 
7:20 PM
I want to remove the last Child of the div and the previous of the last Child
Thank you for SHIM!
 
ok.
div.removeChild(div.lastChild); // last child
div.removeChild(div.lastChild); // look the second last child is now the last, so lets remove it too
 
Ohh! :DD
 
would still need to check for text nodes or comment nodes
if you know they exist
maybe not text nodes
check the docs on lastChild
 
Thank you, I always try the hardest ways :D
There are no Comment nodes
So it's great )
 
> The last_child returned is a node. If its parent is an element, then the child is generally an Element node, a Text node, or a Comment node.
Text Nodes (whitespace) will also pick up
 
7:24 PM
Hi, anyone care to look into the jQuery plugin jsTree? We are stuck at some point with making it to work with checkboxes
 
so yea, use the shim and your code there is wrong still.
 
lastChild is not defined What would it be?
if (totalDivs > divsLimit) {
totalDivs.removeChild(totalDivs.lastChild);
totalDivs.removeChild(totalDivs.lastChild);
}
 
div.removeChild(lastChild.previousElementSibling) // i remove only the second last element. if the last element is a text node the 'previousElementSibling' probably isn't what you want.
this is a jQuery objecT?
how do you get totalDivs
 
pure JS
 
and it looks like totalDivs is a integer
not an array
or a HTML Element
 
7:26 PM
var totalDivs = divsTable.GetElementsByClassName('div').length;
 
so yea, lastChild does not exist.
.length returns an integer
s/GetElementsByClassName/getElementsByClassName/
 
if (totalDiscs > discsLimit) {
discsTable.removeChild(discsTable.lastChild);
discsTable.removeChild(discsTable.lastChild);
}
This is my real code
discsTable is my "div"
Why may be lastChild undefined?
wait
I didn't refreshed the page, Oh god, my fault, sorry
 
var divs = divsTable.getElementsByClassName('div'); // are you sure you don't want getElementsByTagName???????
if( divs.length > divsLimit ) {
     divsTable.removeChild(divs[divs.length-1]);
     divsTable.removeChild(divs[divs.length-1]);
}
 
I slept to less
:D
@rlemon, everything works! I just didn't refreshed the page)
Thank you
 
my latest update probably makes the most sense.
 
7:31 PM
ok, taking a look
 
you have a nodelist of nodes in a container... if the node list is larger than your limit remove the last two elements in the nodelist from the container.
 
Got you! It makes sense
Thank you!
 
hi, anyone has a clue how to make jstree to work with the checkboxes plugin?
 
what checkboxes plugin ?
 
I found some days ago that if I add custom checkboxes by JS they don't work
is this what you mean Jean Paul?
 
7:38 PM
for jsTree.. the jstree.com/demo the documentation is horrible.. I can only get and barely the remove function to remove elements with the checkboxes selections.
no, I actually can render the checkboxes.. I meant the problem is to make it work with those selections.. for example I get obj.children is not a function
[Break On This Error]

w1 = obj.children("ins").width(),

jquery.jstree.js (line 1267
that is when I trigger the rename function with the checkboxes, has anyone worked with it that plugin jstree before?
I am using PHP/mySQL, and have many divs with trees pulled from the DB, but this is actually a JS problem, because the bindings are done front-end
 
FFS OpenAtrium (drupal distro) ships with jQuery 1.2.4 but the installer and product is horribly broken unless you update to 1.3.6
but if you upgrade PAST 1.3.6 it breaks again
 
.bind("rename.jstree", function (e, data) {

$.post(
"./js/jsTree/server.php?cat=d",
{
"operation" : "rename_node",
"id" : data.rslt.obj.attr("id").replace("node_",""), /*data.rslt.obj.attr("id").replace("node_",""),*/
"label" : data.rslt.new_name
},
function (r) {
if(!r.status) {
$.jstree.rollback(data.rlbk);
}
}
);
 
and it's not like i'm taking out dated source... 1.4 (latest stable??) was released 7 May 2012
 
Anything useful here?
 
@JeanPaul place your focus in the input area, press up twice, press CTRL + K, press enter
Please
 
7:45 PM
I have a function which gives custom style to checkboxes, and it is called on window.onload. If I add checkboxes Dynamically on my page by JS, I can't check them. How could I fix it?
 
@rlemon: is that to quite to chatroom or to format something?
 
formats your code
now you will have to hit up three times
and you have a time limit to edit posts in the chat
unformatted walls of code generally results in RAGE in the chats
;)
 
ohhh...:0
 
hehe, now you know
 
ohhh got cha sorry
 
7:47 PM
is that true about @Abhishek gf?
 
and knowing is half the battle
 
if so.. poor guy
GI JOOEEee
 
he's one of the lucky ones... he no longer has to deal with the "You're still on the computer!" nagging.
also he is young, and will find another fish in the sea.
 
MG1
@Oleg are you still here?
 
hhh
How can I debug this (pic below) for this? console.log(JSON.stringify(li)) fires some JSON err that I cannot understand.
 
7:50 PM
you are stringifying a HTML element which is wrapped in the $ turd?
for what purpose?
you are trying to JSON.stringify([object Object]);
but that object is a jQuery wrapped HTMLElement
what would the outcome be?
 
hhh
because the next commented-out section is wrong.
 
@hhh ugh, what information do you expect to appear in the JSON
{"nodeType":"LI","textContent":"Hello World"}
 
Perhaps is easier to link to my question as ell?
 
0
Q: jstree pre1.0 fix + checkbox plugin - How to bind operations?

Jean PaulI can get to alert the checkboxes selected but I'm having a hard time to get working the binding of operations such as create, remove, move, rename, etc. I have a div containing the menu items, in my case they are images for create, rename, cut, etc... I'm editing this answer because I know that ...

if you link a site question and just post the link (nothing else) it oneboxes it
dude that is a lot of code
you should warn people
 
7:56 PM
I'm new to the chats here, I was used to use mIRC back in the days.. is there a FAQ that I can read about all these rules?
 
hhh
I don't know, I tried to understand why the LI stays empty despite response.data[i].id is not empty.

li.data('uid', response.data[i].id);
 
hahaha, no but mainly the part that bugs me is that if I try to make it work like the remove function then as well gives problems, so basically I'm stuck and can;t really work on it right now because the client is looking at the demo
 
@JeanPaul lol it's not a rule... just curtious. also if you do these things you'll have a much better time getting help.
 
mIRC is just a client
irritates me when people think mIRC is irc
 
people like live demo's, reading very little, and not having to visit too many third party sites
 
hhh
7:58 PM
@rlemon Basically I am trying to dig into DOM manipulatino...
 
@hhh ok so you're wondering why the text content in the LI is not updating?
 
MG1
@rlemon are you available to help me? I'm still experiencing the same problem I asked about a few hrs. ago.
 

« first day (599 days earlier)      last day (4339 days later) »