Jump to content

Matej

Members
  • Posts

    185
  • Joined

  • Last visited

Posts posted by Matej

  1. Yes thanks :)

     

    I'm aware of all of those things , the biggest reason for me to want to find lightbox tutorial is to understand logic of animations behind it (well you can do pretty"one image lightbox" - without slides with just :target in css)

  2. I would like to "master"/"learn" javascript without using libraries so i can master/learn it properly. Of course i'm planning to learn jquery and some others libaries/frameworks eventually , but in my opinion pure(plain) JS skill>libraries , (and i dont like "$" it just irritates me :D)

     

    //

    and also i feel like i dont learn anything and im just copying someone's work when i just search JQ plug in/script and just copy paste it (modife it a little)

  3. Hi , how can i create for example element (using plain javascripit) which stays on page after refresh (basicly "forever") , i know its possible using AngularJs , but angular is just javascript library so it should be possible with plain javascript too. I cant find any answer/tutorial , thanks for answers

  4. Hello , i recently started digging in canvas and i'd like to ask some questions about it.

    Here is nice mozilla example http://jsfiddle.net/mpxestqw/2/;

     

    So my question is , how does save() works? Does it work like i set translate(0,0,50,50) and save it , than i set again translate(0,0,50,50) = which means translate is now(0,0,100,100) , and when i set restore() , translate is again translate(0,0,50,50)?;

     

    Also does clearRect() remove also translate() or only "picture"?

     

    Thanks for answers , have a nice day.

  5. Hi , i have question , why does function like this

     

    Array.sort(function(a,{return a-b})

    and

     

    function showPosition(position) {    lat = position.coords.latitude;    lon = position.coords.longitude;    latlon = new google.maps.LatLng(lat, lon)    mapholder = document.getElementById('mapholder')    mapholder.style.height='250px';    mapholder.style.width='500px';     var myOptions={    center:latlon,zoom:14,    mapTypeId:google.maps.MapTypeId.ROADMAP,    mapTypeControl:false,    navigationControlOptions:{style:google.maps.NavigationControlStyle.SMALL}    }        var map = new google.maps.Map(document.getElementById("mapholder"),myOptions);    var marker = new google.maps.Marker({position:latlon,map:map,title:"You are here!"});}

    work , even tho we set arguments , but we dont define them , when you do that in normal function . it breaks the code

    (it writes"function isnt deffined")

    so how are function like this special?

  6. i don't understand what do you mean.

     

    var input=document.getElementById("input"); // text input

    and i set

    window[input.value]="hello world" => if input values is "one" than its window["one"] which is the same thing as var one="hello world"

  7. i think it was somewhere on codeacademy ,not sure if in their tutorials or on forum as response, what is so bad on it?

    (well yea in this case it have input.value as name but whats bad on it overall?)

  8. Hi , how can i storage object in sessionStorage?

     

    function setIt(){var kek=document.getElementById("kek"); //text inputwindow[kek.value]={};window[kek.value].name = "name";sessionStorage.setItem(kek.value ,window[kek.value])}function getIt(){alert(sessionStorage.getItem(kek.value.name))} /this allerts null

    i also tried to parse it

     

    var one=sessionStorage.getItem(kek.value);var two=JSON.parse(one);alert(two.name)

    it also didnt work

×
×
  • Create New...