Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Having just started to loo at Java,

Status
Not open for further replies.

tedsmith

Programmer
Nov 23, 2000
1,762
AU
Having just started to loo at Java, is it possible to (using some form of Java alone) make what appears to be a stand alone application such as would run in an keyboard-less passive infomation kiosk to display graphics, avi files in a window and large size text?
This would not be connected to the web at all but would display new information every hour such as changing movie theatre times.
The info would be held in a database that was independently updated by a network from a central office.

Any advice as to what programs would be required and how they would be stored and activated in the unmanned conputer would be appreciated.

I have written such a program using vb6 but would like to try it so there doesn't have to be a specific exe application installed in the display computer - just the standard browser that comes with windows (if this is possible)
 
1.) Yes, you can accomplish this with virtually any language that can compile (or script) a program to run on that computer.

2.) As you mentioned being new to "Java"... what language are you wanting to write this in? Are you interested in Java (compiled, platform-independant apps), or <I>JavaScript</i> (scripting language; only vaguely related to Java)? Java apps can run on any machine with a Java environment installed, like a vb, c, or pascal app writen for tje machine's platform; JavaScript can run as (or in) a web-page (which can be stored locally on the computer), or it can run as a system-script on a computer with an OS javascript interpreter installed. As a web-page type script can work well with CSS for doing what you need, provided the database entries to direct it are, or can be made to be, compatible with the limited filesystem access afforded to web page scripts (for obvious security reasons). As a system script, I simply don't have much experience with those interpreters, so I'm just not sure.

We can help any direction you want to take this; but first we need to figure out which direction uou need/want to go to get there.

I hope this helps;
robherc
 
The problem is that I dont know yet and I am a bit hazy as to whether either form of "java" would give me what I need!

I want the data to be displayed with the minimum of special programs or intervention on the part of the computer displaying the information. It has to run daily completely unmanned and keyboasrdless
I think it would be similar to say the home page of Yahoo that continues to show advertisments while it is open.
Is this sort of thing done using java or javascript?

Once you have called it up, it continues to receive and display new information sent by the server.
The data would be large text readable at a distance on a large LCD screen, jpg's and videos such as flash or Mp4 inserts.

I understand how to do make up a web page using Frontpage but have never specifically used either form of "java"

I don't want any special applications to have to be installed at the displaying end except perhaps run a batch file or script only on startup to start and set the brower to full screen without any toolbars etc. if this cant be included in the actual data received.

I particularly want it to automatically install from a USB stick in any Win7/8 computer if the original computer fails and has to be swapped with a brand new computer in the field.

I can handle the server side easily with a special editor I would write in a language I already understand like vb.
 
Actually; since you can reprogram the servee easily enough; wjy not just use a <meta refresh> html tag in the <head> of the page. Then you could simply have the server set up as an http host; with each client simply loading the self-refreshing page in a full-screen browser...set it to refresh the page after whatever length of time you want that specific ad/page playing for; then the only real programming labor involved is in building each ad page, which you have to do anywise.

p.s. a quick google search will give you everything you need to know about using <meta> tags to refresh an html page on a timer.

I hope this helps;
robherc
 
It is building up the page into the right configuration that I was assuming I would use javascript to do - or maybe I am wrong.

I thought javascript or java or whatever was used to create and display the shapes and moving effects of a complicated looking web page as opposed to ordinary html - but maybe I am wrong?

I can make a page with a web editor like Frontpage but that is no good for this purpose.
The page has to be automatically formatted from data in various fields of a number of database tables.
The picture filename text could be in one database and the text data in another.
The various changing text would be sent at intervals (or called up by the client) and the different pictures changed say every 10 seconds like a slideshow while other movie windows might run for 15 minutes and repeat.

How do I get the client browser to accept each new batch of data without a special application to tell the browser to retrieve each new thing regularly?

In the present system I use a server TCPIP winsock and send the data from the server to a client winsock. The dataarrival sub of this simply refreshes the screen with the new data when it receives the complete data block. How do I do it with HTML (or java) using only the browser? Is there some sort of javascript I can run on computer startup?
 
Ok, now we're getting a bit more involved with this than I had at first guessed...one thing I might suggest, if you'd like, is that we take parts of this conversation to a different medium (these forums are excellent for less involved tasks, but phone calls & webconferences work better when you get into a more involved exchange of information). If you'd like to do that; you can send an email to [tt]my username here AT my username here DOT com[/tt]

Anywise; let me try to answer each section of your question as best I can with what info we have so far:

I thought javascript or java or whatever was used to create and display the shapes and moving effects of a complicated looking web page as opposed to ordinary html - but maybe I am wrong?

-JavaScript is often involved in the pages you're describing; along with HTML (obviously), CSS (Cascading StyleSheets ... affect the way HTML is displayed, and work very well synergistically with JavaScript), Flash (Adobe proprietary animation & interactivity stuff), and some other technologies.
-JavaScript was originally intended to make web pages capable of being more interactive, and that is still where it is most applicable, though it is also useful for many non-interactive functions, which can include timer-activated events; hiding/revealing and moving objects around a page; etc.
-Java, on the other hand, is a compiled language (not unlike vb) that is special in that the compiled binaries are cross-platform executable (i.e. no need to recompile/install the program to run on a mac, a windows box, and a unix/linux box...just send the executable over, run it, and it just works) on any machine that has a working Java Runtime Environment installed.

The page has to be automatically formatted from data in various fields of a number of database tables.
The picture filename text could be in one database and the text data in another.

-OK, this may be the hardest part for us, using JavaScript. ...since JavaScript is intended as primarily a web page interactivity engine, it has some fairly strict limits on its file handling capabilities. In most cases, these are VERY beneficial to you, as you would NOT want someone to be able to design a web page that automatically uploaded your CC info, planted a virus on your system, then deleted some random files on your HDD, simply by your having loaded the page! For our purposes here, though, it will make things slightly more difficult for us, as we'll need to redo your databases as JavaScript *.js files in order to be able to read & utilize them to affect the rendering of our web pages.
-This is where I'm not sure if you'll end up wanting to go with a "pure" JavaScript (client-side processing) approach; or maybe use some server-side scripting to help the process along (i.e. having your database server generate the web pages from the databases, then the client/kiosk computers simply have to request the pages at appropriate times). Either method can accomplish what you're asking for, the primary differences are in computer processor loading (if there are a LOT of kiosk terminals, the server-side loading could become a bottleneck), and where you want to spend your programming energy (server-side HTML generation may be a more complicated original program, while JavaScript requires stricter formatting of the database files).

The various changing text would be sent at intervals (or called up by the client) and the different pictures changed say every 10 seconds like a slideshow while other movie windows might run for 15 minutes and repeat.

-This should be the easiest part for us. It can either be done using a JavaScript [tt]onLoad[/tt] event that starts a timer; or a [tt]<meta refresh="...">[/tt] tag. Either way, refreshing/redirecting a page at any specified interval is a fairly trivial task :)

In the present system I use a server TCPIP winsock and send the data from the server to a client winsock. The dataarrival sub of this simply refreshes the screen with the new data when it receives the complete data block. How do I do it with HTML (or java) using only the browser? Is there some sort of javascript I can run on computer startup?

-Actually, this could be another easy(est) part. Simply set each kiosk system to open the browser on system startup (i.e. in most Windows machines, you can place a link to the browser in the "Start" directory, or add a line to the [tt]autoexec.bat[/tt] file that opens the browser); set the browser to open in fullscreen mode; then set the homepage of the browser to point to a static page (or script) that can then redirect to whatever information should be being displayed at the time it's retrieved (i.e. "static" meaning the page FILENAME never changes, but the server automatically changes the contents to point the kiosk system's browser to wherever it needs to go in order to "catch up").


Sorry for the long post, but it's quite a bit of information to try to communicate in a forum post.

I hope this helps;
robherc
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top