• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 215
  • Last Modified:

reload problem

I have one problem and question
I have this small function in JS

function stream_selection() {
       var index = document.physical_update.streamId.selectedIndex;
       id_meet = "meeting=" + document.physical_update.meetingId.value;
       id = "stream=" + document.physical_update.streamId.options[index].value;
       alert('id_meet is '+id_meet +'id is '+id)  //until here i m getting both value correctly
       top.details.location = "physical_update.php?"+id_meet &id ;
      // top.details.location = "physical_update.php?"+id;

in that meeting id I m getting from some other file and with the help of that meeting id I m filling ids of physical streams now what I want when I select one stream id it should give me selected id with the help of that physical stream id I can get some details.

so for that I made this function and I put this in ONCHANGE for physical stream, but when I do this I lose my meeting id because it refresh the page and i lost my meeting id.
so is there any way to keep my meeting id and get stream id also. I was thinking to pass both values in the function.

So do u any body know how I can do this.
1 Solution
I would rewrite your function like this:

function stream_selection() {
  id_meet = document.physical_update.meetingId.value;
  id = document.physical_update.streamId.options[document.physical_update.streamId.selectedIndex].value;
  top.details.location = "physical_update.php?meeting="+id_meet+"&stream="+id ;

manish14Author Commented:
thankx now it works

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now