Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
  • Aug 17 09:32
    User @bjorno43 unbanned @linkin-park
  • Jun 20 21:19
    @bjorno43 banned @shenerd140
  • Apr 25 17:13
    @mstellaluna banned @cmal
  • Jan 08 22:05
    @mstellaluna banned @dertiuss323
  • Nov 07 2018 04:42
    User @texas2010 unbanned @ows-ali
  • Nov 02 2018 16:25
    @texas2010 banned @ows-ali
  • Oct 12 2018 05:50
    @bjorno43 banned @NACH74
  • Oct 05 2018 23:02
    @mstellaluna banned @JomoPipi
  • Sep 16 2018 12:21
    @bjorno43 banned @yash-kedia
  • Sep 16 2018 12:16
    @bjorno43 banned @vnikifirov
  • Sep 05 2018 08:12
    User @bjorno43 unbanned @androuino
  • Sep 05 2018 07:38
    @bjorno43 banned @androuino
  • Aug 23 2018 16:57
    User @bjorno43 unbanned @rahuldkjain
  • Aug 23 2018 16:23
    @bjorno43 banned @rahuldkjain
  • Jul 29 2018 14:13
    User @bjorno43 unbanned @jkyereh
  • Jul 29 2018 01:00
    @bjorno43 banned @jkyereh
  • Jul 10 2018 22:09
    @bjorno43 banned @manafn
  • Jul 06 2018 15:20
    @texas2010 banned @imlegend19
  • Jul 03 2018 12:28
    @bjorno43 banned @vbvmatta
  • Jun 29 2018 13:54
    @bjorno43 banned @OGTechnoBoy
pragya1248
@pragya1248
not*
Fernando
@lestairon
image.png
pragya1248
@pragya1248
yes like this
thanku so much
how you did it?
Fernando
@lestairon
I changed something on the html and css, but i think it can be done better
Let me paste it
Pastebin since i don't want to spam the chat
pragya1248
@pragya1248
ok thank you a lot :)
Fernando
@lestairon
What i did was, i put the paragraphs on a div
The sign box make it position: absolute, change its position and with the paragraphs position: relative and change its position too
If you make it fixed it will stick to a position even if you scroll
pragya1248
@pragya1248
yeah actually i m designing a home page for crypto celebreties.
Fernando
@lestairon
Oh, that's cool
pragya1248
@pragya1248
so if i use fixed then also it will be fine right?
Fernando
@lestairon
do you still have your code?
pragya1248
@pragya1248
actually this is my first home page project.
Fernando
@lestairon
If you do, try to run your pen in the chat, look what happens
pragya1248
@pragya1248
yes i have
Fernando
@lestairon
When you try to scroll, the box is fixed to a position
pragya1248
@pragya1248
yes it is
Fernando
@lestairon
see?
pragya1248
@pragya1248
yeah
Is it good for a home page?? I am making it first time.So don't have much idea.
Fernando
@lestairon
Making it fixed?
If you make it fixed it wil overlap some text
Why is not working the toggle method? :worried:
Aditya
@ezioda004
@lestairon Which toggle method?
#cof event listener?
Fernando
@lestairon
?
Makarenkov Aleksandr
@trustedperson
Hi all!
Maybe someone can help me with my problem.
I need a mapped image, like this http://www.nevscom.ru/projects/ladozhsky-bereg/plan/?b=2&f=13 (see, plan with highlighted rooms).
First part i have done already - i created mapped image, and it works perfectly, and on hover user sees popup, all fine.
But i cant understand, how make highlighted areas? I tried canvas over my image, but in this case 'mouse hover' dosn`t work.
Can someone share solution?
Aditya
@ezioda004
@lestairon Nevemind I missed it, toggle() method has been removed from 1.9 and above
steve84
@raynor84
hi all, I'm stuck with the exercise diff two arrays
Fernando
@lestairon
Oh
So, what can i use instead?
Stephen James
@sjames1958gm
@raynor84 What code do you have?
steve84
@raynor84
don't have any I'm stuck on how to approach the algorithm
Fernando
@lestairon
I guess the best option now is make 2 if statements that check if the temperature is being displayed in ºC or ºF, right?
Stephen James
@sjames1958gm
@raynor84
Maybe start with trying to find all the values in arr1 not in arr2, using the suggested links.
@lestairon You would have to do that anyway so that you calculated the correct temperature.
Stephen James
@sjames1958gm
@lestairon I would create a variable
var isCelsius = true;
Then use that in your click handler
if (isCelsius) {
   // Change the display to F
   isCelsius = false;
}
else 
{
  // Change the display to C
  isCelsius = true;
}
steve84
@raynor84
still testing it though....

function diffArray(arr1, arr2) {
var newArr = [];
arr1.forEach(function(array, index) {
if(array[index]==arr2[index]) {
newArr = arr1.slice(index-1,index);
console.log(arr1.slice(index-1, index));
}
});

// Same, same; but different.
return newArr;
}

diffArray([1, 2, 3, 5], [1, 2, 3, 4, 5]);

Stephen James
@sjames1958gm
@raynor84 The function called by forEach is not called with an array it is called with a value from the array
arr1.forEach(function(value, index) {})
So you should be testing if value is in arr2 (irrespective of index) (consider indexOf function
steve84
@raynor84
'''
CamperBot
@camperbot
:bulb: to format code use backticks! ``` more info
steve84
@raynor84

'''

function diffArray(arr1, arr2) {
var newArr = [];
arr1.forEach(function(value, index) {
if(value==arr2[index]) {
newArr = arr1.slice(arr1.indexOf(value),arr1.indexOf(value) - 1);
}
});

// Same, same; but different.
return newArr;
}

diffArray([1, 2, 3, 5], [1, 2, 3, 4, 5]);
'''