Time lapse web interface [closed] - javascript

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 7 years ago.
Improve this question
Hello and thanks in advance for looking at my problem. I'm trying to create a web interface for a time lapse project I'm doing right now, but I don't know exactly where to start with this.
What I have
A website, obviously;
A lot of pictures, made every 15 minutes;
Stored in folders (/mm-yy), saved as dd-mm-yy_hhmm.jpg.
What I'm looking for
I want to be able to select a date with a datepicker, which returns all the pictures taken on that particular day so I can show only those pictures on the site.
I've been searching around but I have troubles finding out what the best solution is and where to start. I don't have a lot of experience with JavaScript. I thought maybe create a JSON-file with all the images (regenerated every 15 minutes) and use that in some way with a datepicker?
Any ideas, tips and/or tricks?

There are numerous ways to approach this but since you tagged php my first impulse would be something akin to:
Walk the directory tree to find all represented months
For a given month build your date list using regex - this will let you pull out the date matches you need
Create your date picker using one of the many, many javascript options
IIWM I wouldn't mess about with a separate file the gets regenerated. Do your population when the page opens.

Related

Simple Questions/Answer Games [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 3 years ago.
Improve this question
Thank you for taking the time reading this!
A quick disclaimer, I have never coded anything in my life!
I know some basics terms so you can communicate your response without defining them.
Anyways, my project is a simple game.
You press [START]
You hear a "random" word
You have a type-in box,
if you fill it right you get +5 points and get a random word .... and so on.
You fill it wrong, you lose immediately [gameover]
Although, I would deeply appreciate to code the whole game, for some of you it is relatively simple - I wish to do it myself for the learning experience and sense of accomplishment!
For now, I only need a push in the right direction.
I aim to use it on my tablet or phone (both run android)
Best,
haz
You should start by learning the fundamentals of JavaScript and HTML (should also learn CSS if you want the app to look nice). There are many sites (other than SO) that have multiple tutorials and/or full documentation (i.e. MDN, W3Schools). You could also use online teaching platforms for that.
Here are a couple of things you should consider after getting a grasp of the basic concepts:
When do you want to check if the user inserted the right input (timer, on enter, a submit button)?
Where will the sounds be stored and how will you retrieve them (a collection of sounds of files, a database with a server, a single big sound file containing all of the words)?
Regardless of how you store the sounds you will need a way to map text to the sound and the random number (Math.random()) to one of the two.
Finally create a JavaScript function that resets the text and gets a new word every time the user gets the word right or when the initial start button is clicked.
Once you reach any questions on the actual coding, search for the problem in SO (odds are it has been asked before). If you can't find an answer to your question create a new question (you should read How to ask first).

How to make next page link when document size reaches to specific length? [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 6 years ago.
Improve this question
I have built an Admin section where i can see all the contents from database in a table. everything is fine but if the database table has thousands of rows I have to scroll down very deep. is there any way I can make links like `1,2,3.Next the way google search results do? or is there any even better way?
Isn't is going to be something like:
if($(document).height>2000){
//what should i do?
}
Looks like you are using jquery. If you are going to implement everything on your own it may be time consuming - although it would be fun!
To save some time, there are quite a few plugins available to achieve this. Refer:
https://datatables.net/
http://www.jqueryscript.net/table/Client-side-HTML-Table-Pagination-Plugin-with-jQuery-Paging.html
Since you may have huge data you should be using server side pagination instead of client side. Here is another SO link which explains the difference between them : Pagination: Server Side or Client Side?

Best way to display huge 2d array [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 7 years ago.
Improve this question
I want to display 1000x1000 array in some way. Array element would either be black or white, depending on boolean value. For this job I am thinking about either javascript or winforms, but before I jump into, I wanted to hear what could be drawbacks for these choices. I am much more familiar with javascript than winforms though. As for winforms, I tought that there could be too many GDI objects to handle. Any ideas, suggestions?
I'm not familiar with win-forms but the first idea that came to mind was just a plain old html table. It would be a lot of html though to have 1000 x 1000. Second thing that came to mind would be an SVG. You can manipulate an SVG with JavaScript as shown here http://tutorials.jenkov.com/svg/scripting.html. Theres also this post which shows how to create tables with SVG.You would probably want to generate the SVG before hand to save the application from doing a lot of work and then set the colors using a loop. You can even use photoshop and save as SVG and then open the file in an editor to get the SVG code.

Generating random id using current date [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 7 years ago.
Improve this question
I'm doing a bank oriented project. I have to generate Account Number using current date.
Example:
account no-20150409001.
'2015'-Year,
'04'-Month,
'09'-Date,
'001'-represents the number of the new member opening the account on that particular date
This number should change in every branch to avoid same account number.
How to do so?
and this is my code
http://jsfiddle.net/Jegannath/z9na41o5/#&togetherjs=ynHxlyDeO1
If this is really a bank related project, do not rely on client side JavaScript for something as critical as the account number generation.
Is there a reason for the "random" number requirement? If not, stick with a sequence, it is a lot easier to ensure uniqueness.
On the server side, using a branch prefix as suggested by #kuldeep.kamboj should cover collision.
You can use something like yyyyMMddBBnnnn where yyyy = year, MM = month, dd = day, BB = branch number, and nnnn as a sequence that resets per day.
Not sure,this is correct advise,
Go with branch code prefix and timestamp in suffix, this might be developer friend also, because in future after 30 year easily you can tell his account created date with the help of timestamp.
As well timestamps is kind of random number.
advisable is server side code.

Classroom assessment tool [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 8 years ago.
Improve this question
I want to create an HTML file which pulls information from one of several possible databases.
The database will consist of students names and target grades and there will be one for each class.
The page created will effectively have a block/button for each student with a drop down box which contains a grade.
I would like to send this data to another database (one for each class) to track progress over time, effectively when submitting the classes grades I want to add a coloumn to the database
I have been learning programming for the last 12 months and have a reasonable understanding of HTML, JavaScript, Python (I have also just started leanring some jquery) . I dont want a full fledged solution but if someone could point me in the right direction I would be happy to do the hard work.
Primary question is what language do I need to learn to code read and write to the database? Any other suggestions about scripting are more than welcome.
I would use PHP and Javascript (jQuery is a easy to use framework). PHP can handle the "backend" operations like reading and writing to the database. HTML / CSS / Javascript can handle the view.
If you want to do all of this without the annoying page refreshes you can take a look at AJAX.
Some links to help you getting started
http://www.php.net/manual/en/getting-started.php
http://learn.jquery.com/javascript-101/getting-started/

Categories