I am trying to make a program which, for individual countries, it will get a word which is typed in by the user through a text field.
I want to find an easy way to store this and constantly update and load this into a div without refreshing the page.
Does anyone have any ideas?
I was thinking it might be possible in AngularJS or JQuery or something but not sure.
Getting and retrieving text to div constantly
Post a Reply
|Oldest Newest Rating|
· April 15, 2015
Not a problem dude, sorry I only get on here late at night when the part of my brain that fully understands things has already called it a day.....
Forgive me if I am wrong, but I am see this as you want people to type in there country and it gets added to a list of countries where every viewer can see that list?
If this is the case you will have to collect the users input then post it back to your server where it is stored into a database that can be retrieved at a later point then displayed to every one who views your page.
To do this you'll need to use a language such as PHP or NodeJS to collect post variables to the server.
then a Database like MySql or MongoDB to store them.
· April 15, 2015
Partially what I'm looking for thanks! But I need everyone who views the webpage to see these words
· April 14, 2015
Is this what you are after?
then get the value like and place it into a global var then your display element like so.
If you need longer term storage ie, longer the the life of the page you will need to look into cookies and html5 local storage.
Having said this i recommend using a select tag for dealing with country input.
which if you do decide to go that way here is a pre coded select list with all our earths magnificent countries
Hope this is what you where looking for and good luck!