|
I would think it's do-able but I'm not sure where to begin or what to even search for. I have been asked to give a bid for a large project that would, among other things, involve synching data from a web-based program using SQL Server on the backend with a program that is self contained on a flash drive (thumb drive, memory key... what's the proper terminology these days). First question is, is this do-able? I would imagine that it should be. But then very next breath brings the question ... how?
Thanks in advance for whatever direction you can give me.
Denise "Hypermommy" Duggan
|
|
|
|
|
First things that spring to mind are java, sockets and (Programmed) ftp.
|
|
|
|
|
Okay, so it sounds like it's definitely do-able if all that springs to mind right away. But all of that would be new to me. Got any suggestions on where to start searching for an answer? Maybe I should just google up something like "java sync" (without the quotes, of course)?
Denise "Hypermommy" Duggan
|
|
|
|
|
Yeah download eclipse (java version). Install it. Run.
Go help -> software updates and add the following site:
http://visualswing4eclipse.googlecode.com/svn/trunk/org.dyno.visual.swing.site/
Download the software from that site, using the software updates form, called visual editor.
This will let you design the forms using a wysiwyg interface.
Then look up "java Ftp" and "programming sockets in java".
You may also need to code a page on your website to serve you the data you want (especially if its in a DB).
|
|
|
|
|
Pure HTML and Javascript cannot break out of the Browser Sandbox[^].
That said most browsers provide a component mechanism that provides hosting for native code to run in that is outside the sandbox. AFAIK, they all require the user to verify that they want this unsafe action to execute. This is what you need to access drives/USB on the local machine. Then of course you have to deal with communicating between your component and your server which is a completely different subject.
|
|
|
|
|
Well, that definitely gives me some direction. Now I just need to get out there and do some digging. But what you've given me is enough to ballpark a quote. Thanks!!!!!!!!!!!!!
Denise "Hypermommy" Duggan
|
|
|
|
|
If you are using an applet (Java) that is signed by a trusted party, than the user will not be asked if he wants to execute it...
|
|
|
|
|
Hi There I am new to using Javascript and have the need to create a "function" I think, that will display one of 8 images dependant on the content.vlaue of my recordset in asp. I know I need to use an if/else but how do I get the function to hold the img src and onclick link details and then display the relevant picture on my page. If someone could help me I would be very happy. Regards Ray
|
|
|
|
|
Not quite sure what you are trying to do. Please could you explain a little clearer (whats on the page and whats gonna happen when it's clicked).
I presume you mean thumbnails, and a main picture which changes when the thumbnails are clicked?
you will need something like this
In your <head> section:
<script type="text/javascript">
function updateImgSrc(filepath){
var mainImage = document.getElementById('mainImage'); //the big picture
mainImage.src = filepath; //set the src of the mainImage to the variable passed in
return;
}
</script>
In your <body> section:
<img id="mainImage" src="originalPic.jpg" height="800" width="900" />
And your thumgnails:
<img src="imageOneThumbnail.jpg" height="40" width="50" onClick="updateImgSrc('imageOne.jpg');"/>
Neonlight
|
|
|
|
|
Hi Neonlight, and thank you for answering I appreciate your time.
Basically when my page opens which includes a recordset, one of the fields in the recordset is "genre" i.e. artist, compilation, classical, ost and so on...
The code I have on my page at the moment for the image looks like this...
<a href="http://pictures.specialcounters.co.uk/covers/<%=(Recordset1.Fields.Item(" genre=").Value)%>/<%=(Recordset1.Fields.Item(" artist=").Value)%>/<%=(Recordset1.Fields.Item(" album=").Value)%>/back.jpg"><img src="http://pictures.specialcounters.co.uk/covers/<%=(Recordset1.Fields.Item(" genre=").Value)%>/<%=(Recordset1.Fields.Item(" artist=").Value)%>/<%=(Recordset1.Fields.Item(" album=").Value)%>/back.jpg" alt="" name="smallcover" width="168" height="168" id="smallcover" /></a>
what i need is information/help on how to set out in javascript an if/else statement so that when the page opens it asks, if "genre" = "artist" then the img src = as above ... else if "genre" = "compilation" then img src = as below
<a href="http://pictures.specialcounters.co.uk/<%=(Recordset1.Fields.Item(" genre=").Value)%>/<%=(Recordset1.Fields.Item(" album=").Value)%>/back.jpg"><img src="http://pictures.specialcounters.co.uk/<%=(Recordset1.Fields.Item(" genre=").Value)%>/<%=(Recordset1.Fields.Item(" album=").Value)%>/back.jpg" alt="" name="smallcover" width="168" height="168" id="smallcover" /></a>
else if and so on..
If you could help with information or even point into the right direction it would be much appreciated.
Thank you again for your response.
Regards
Ray
|
|
|
|
|
i wouldn't use javascript for this but php or asp.
-Store the GET url variables
-then a simple if else
-use headers (especially "content-type") to allow you to send the correct picture (this makes your asp file send itself as a jpeg or whatever
Google these if you are unsure.
|
|
|
|
|
Thanks again Neonlight
After a little searching and reading your advice paid off, and not only have I sorted that problem I had but also what would have been my next question
Thank you for your time much appreciated
Regards
Ray
|
|
|
|
|
Dammit, I think I might have put that code in the wrong type of block or whatever its called cos it seems to have disappeared off the screen...Sorry
|
|
|
|
|
May i know how to write javascript to ping to server and show how many users online on browser? This concept same like facebook online friends. I heard my senior said that if using javascript, it will cause heavy load since it will take a lot of resources while using actionscript wont have such issue since the server can respond to the browser.
I really dont have any idea how to write the javascript to check. Hopefully somebody here can give a helping hand. Thanks.
CodeBasic
|
|
|
|
|
I don't think you can do this with javascript seeing as javascript is client-side. You need to use server side code like php/asp
I would do the following.
A script that adds a users ip and time now to a csv file stored on the server in the format:
ip adresss, time,
ip adresss, time,
ip adresss, time,
If the user's ip is already in the file, update it with the new time.
And a second script that runs through the csv file and sees if any lines have a time greater than five minutes ago. If any are found, delete those lines.
Then you can just count the number of lines to get the number of users online.
|
|
|
|
|
neonlight27 wrote: A script that adds a users ip and time now to a csv file stored on the server in the format:
DO you have any reason why this can not be done in database? Why reinvent the wheel?
|
|
|
|
|
Yes it can be also be done in the database. I suggested CSV for reasons of simplicity & because I didnt know if he/she had a database to use. Where as CSV file handling will run on any system that php runs on.
Using a database is a perfectly valid option. However, using CSV isnt reinventing the wheel. There are plenty of free csv scripts available and for new coders they tend to be easier to work with (because you can see exactly what they do in simple text form - No SQL, or PHPMyAdmin or equivalents to deal with).
For larger sites (5,000+ concurrent users) a suggestion would be to use a script that only updates every 5 minutes or so to reduce the load on the server and use a database (Preferably an SQL Variant or at least one you can run SQL commands on) - CSV files do get a bit buggy as they get larger.
CSV is a poor mans database (often reffered to as a "flat file")
|
|
|
|
|
Dear Masters
Please help me to make a site / get codes of Google Map like this
site.
http://www.qiblalocator.com/
in this site;
There is a Direction Line spotted on the center of Qibla - Macca -
Saudi Arabia (A Holy Place for Muslims, where they have to make a
right direction to offer their Prayers) from one side and the other
side of line is always remain in the center of the Map window to find
the right direction from anywhere in the world to Macca.
I am not a programmer, so please help me to get codes like (or similar
to) above mentioned web site.
Hopefully waiting your early and positive response!
|
|
|
|
|
|
I don't just need my API Key/Code or not to add simple Map at my site, but I need how to customize Directional cosmetics at MAP.
Thanks
|
|
|
|
|
There is a lot more on that site than just basic code and API key. Read through the documentation. Look through the blogs, examples, etc. Try searching Google. What you are asking is quite specific - so you'll be very lucky if someone codes it for you. My suggestion, do a bit of research. I'm pretty sure you find what you need within the Google blogs.
|
|
|
|
|
Thanks for prompt response!
alternatively I have been searching for long time, as well as asking at forums, so Please remember if you find something like i need, then please share with me.
Because I don't know programming well, therefore I need a basic /initial tips related to my specific topic.
Thanks again!
Qayyom Ashraf
Karachi-PK
|
|
|
|
|
I have a PDF file in which when I click on a email link (mailto) the result opens up 2 Outlook email messages and it also opens up a new IE browser window with the mailto link in the address. How do I get this to open up only 1 new email message and stop opening up a browser window? I've tried a number of different ways to display the mailto link in the PDF and nothing works successfully.
mailto link example: myemailaddress@mycompany.com?subject=test
I've tried with and without the "?subject=test" portion and get the same result.
|
|
|
|
|
Have you tried making it a link without showing the address? Make sure you prepend "mailto:" to the link.
|
|
|
|
|
Hello,
Yes, i have tried both suggestions and neither has worked.
|
|
|
|