Jump to content


  • Content Count

  • Joined

  • Last visited

Community Reputation

0 Neutral

About 2Radon

  • Rank
  1. Thanks, I checked out that requestAnimationFrame a bit, but it was probably too advanced for this time and I didn't quite understand how it could make this work like it works now. So I kept on with the setTimeout and followed my feeling that there had to be a way of looping all the setTimeout functions with one setInterval. I could have done the reptitive lines through loops, but that's for a remake in the future, I think. Passing an array as function argument didn't work, but I only have 5 elements anyway, luckily. $(document).ready(function() { var currentPosition = 0; var slideWidth = $
  2. I've gotten through that part. Now I'm trying to separate the slideshow delay times using values from a text file as milliseconds and creating a timeout before each animate() function. I've had no good luck with this loop and my Chrome debugger no longer tells me enough about this. This loop is inside a $.ajax POST function to get the delay times and the first 5 elements of the array should be applied to each slide consequently. variable currentPosition already tells which slide it's on. while (true) { if (currentPosition == numberOfSlides - 1) { currentPosition = 0; } else { currentPositi
  3. Alright, this could be interesting... I got it to work, but I wanted it to work with multiple iframe videos, so I used a couple arrays and another cycle counter to store the iframe sources to be used later, because as I found out, if I leave the urlReader() in the cycle, by the time it finishes its work, the cycle is on a different step, leaving the step, during which urlReader was initiated, empty. I'm sorry I lost the link to where I found this handleData() ajax solution, but it explained that the script won't wait for the response and it could be worked around by "promising" the ret
  4. I'm going to put the image aligning aside for future then. Decided to go with YouTube embeds for videos. I'm still clueless on how to use the YouTube API as I don't see a download or link, or anything... But I've changed the slidemaker() to have a loop now and change the element depending on if it finds the file name in dir.log is a .txt file or not. The .txt file contains the embed link and is then read and used as the source for the iframe element that is made with replaceWith(). Well, I first did it for one element, and then I decided to make it a loop and add var i to strings wher
  5. I've gotten to understand somewhat more those divs by using background colors and changing their sizes, but I still cannot figure out why, if I increate the .slide img CSS size any more they just stack in column, as you can see at around 40% they already stack. As if there was not enough space in their container, but I don't see which one no matter what I try. I know there's no float: up or down, but changing to left doesn't help anyway. #slideshow is the responsive portion of the page I want to have the slideshow appear in#slideshowWindow is the rectangle which will show the current port
  6. Hi, I am trying to make this webpage for posting and viewing news. It will be shown on a big screen in our Hub. I've been having a super hard time with putting a proper slideshow in the HubWeb_HubPage.php one. I've tried copying in code from two other pre-made slideshows, but best I've got was a misaligned slideshow that didn't fit the top right area properly. And I made an embedded YouTube video appear and reappear on top of it periodically. So I decided to learn and do a simple one myself. What could go wrong if I'm writing the thing inside my webpage myself, right? Nothing happens. See for
  • Create New...