/    Sign up×
Community /Pin to ProfileBookmark

JAvaScript Dynamic List

I dunno if thats the right title for what I am trying to do but I have been trolling around various websites to no avail.

I want to make a list that users can add to the list and it will stay from visit to visit and other users can see it. Its almost like a an online petition.

to post a comment
JavaScript

10 Comments(s)

Copy linkTweet thisAlerts:
@NedalsMar 11.2004 — You will need a server-side script to do this. It cannot be done with javascript.
Copy linkTweet thisAlerts:
@BlavekauthorMar 11.2004 — You gotta be kidding me.... You mean like perl? I don't wanna write any perl...

Isn't document.write(); supposed to append text to the document?
Copy linkTweet thisAlerts:
@NedalsMar 11.2004 — You gotta be kidding me.... You mean like perl? I don't wanna write any perl... [/quote]
Yep ?




The probem is not displaying the list, it's saving the list for other users to see.

[i]Originally posted by Blavek [/i]

[B]I want to make a list that users can add to the list and it will stay from visit to visit and other users can see it. Its almost like a an online petition. [/B][/QUOTE]


How is user B going to see what user A added to a list that's contained in his LOCAL javascript.
Copy linkTweet thisAlerts:
@BlavekauthorMar 11.2004 — [i]Originally posted by nedals [/i]

[B]Yep ?









The probem is not displaying the list, it's saving the list for other users to see.







How is user B going to see what user A added to a list that's contained in his LOCAL javascript. [/B]
[/QUOTE]


I understand that but why can't JS open a file from the server write to it and save it?

I really want it to be an itermediary file with no HTML formatting to be inserted into an HTML file.

How should I start to either research this issue or even get it going? Also as an added bit of info I am no stranger to coding or other things I just don't have time to learn yet another language.

Also I know C and Cpp so if there is a way to use that I am set. Also how do I cummincate with my serverside software from the client side front end?
Copy linkTweet thisAlerts:
@steelersfan88Mar 11.2004 — sorry to butt in ... try PHP forum

(or if fred could move it for you that be nice)
Copy linkTweet thisAlerts:
@NedalsMar 11.2004 — [i]Originally posted by Blavek [/i]

[B]I understand that but why can't JS open a file from the server write to it and save it?[/b][/quote]

It can, sortof! BUT you need the server-side script to deal with the file open and write operations.
[b]I really want it to be an itermediary file with no HTML formatting to be inserted into an HTML file.[/b][/quote]
It doesn't work like that. You make a request to the server and it returns a new HTML page with the updates. There are a few tricks, like iframes, that will make it LOOK like you are just updating a list, but you are actually returning an HTML page.
[b]Also I know C and Cpp so if there is a way to use that I am set. Also how do I cummincate with my serverside software from the client side front end? [/B][/QUOTE]
You can write in 'C' and MAKE the file if you are on a Linux Server. I suggest you start a new thread in the CGI forum using 'how do I cummincate with my serverside software'.

steelerfan88

I think we should leave the post here. It started with JS and it answers a pretty common question found on this forum. ?
Copy linkTweet thisAlerts:
@BlavekauthorMar 11.2004 — [i]Originally posted by nedals [/i]

[B]It can, sortof! BUT you need the server-side script to deal with the file open and write operations.



It doesn't work like that. You make a request to the server and it returns a new HTML page with the updates. There are a few tricks, like iframes, that will make it LOOK like you are just updating a list, but you are actually returning an HTML page.



You can write in 'C' and MAKE the file if you are on a Linux Server. I suggest you start a new thread in the CGI forum using 'how do I cummincate with my serverside software'.



steelerfan88

I think we should leave the post here. It started with JS and it answers a pretty common question found on this forum. ? [/B]
[/QUOTE]


ok... hmmmm how do I call a CGI or perl function or even a C function from JS? to open the file then pass the text parameter to it to write, and then close it?

Also What is it like to insert text in the middle of the document?
Copy linkTweet thisAlerts:
@NedalsMar 11.2004 — Blavek

Do me a favor and start a new thread in the CGI forum. This thread is going to quickly turn into a CGI issue if you are going to use 'C' or Perl.

I scan most of the forums, so I'll catch you there ?
Copy linkTweet thisAlerts:
@BlavekauthorMar 11.2004 — [i]Originally posted by nedals [/i]

[B]Blavek

Do me a favor and start a new thread in the CGI forum. This thread is going to quickly turn into a CGI issue if you are going to use 'C' or Perl.



I scan most of the forums, so I'll catch you there ? [/B]
[/QUOTE]


ok
Copy linkTweet thisAlerts:
@NedalsMar 11.2004 — Where's the CGI forum? ?

I guess the names have changed. Make that the Perl Forum!
×

Success!

Help @Blavek spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 6.17,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @nearjob,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,

tipper: @meenaratha,
tipped: article
amount: 1000 SATS,
)...