Jump to content

maymann

Members
  • Posts

    26
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

maymann's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. SOLVED... Got it working... finally... Here is my working multisite index.php: <head> </head> <script type="text/javascript"> function setOptions(chosen){ var selbox = document.formName.ip; selbox.options.length = 0; if (chosen == " ") { selbox.options[selbox.options.length] = new Option('No site selected',' '); } if (chosen == "1") { selbox.options[selbox.options.length] = new Option(' ',' '); selbox.options[selbox.options.length] = new Option('HOSTNAME1','IP1'); selbox.options[selbox.options.length] = new Option('HOSTNAME2','IP2'); } if (chosen == "2") { selbox.options[selbox.options.length] = new Option(' ',' '); selbox.options[selbox.options.length] = new Option('HOSTNAME3','IP3'); selbox.options[selbox.options.length] = new Option('HOSTNAME4','IP4'); } } </script> <form name="formName" method="post" action="polycom-reboot.php"> Conference Phone Reboot <select name="site" size="1" onchange="setOptions(document.formName.site.options[document.formName.site.selectedIndex].value);"> <option value=" " selected="selected"></option> <option value="1">Site1</option> <option value="2">Site2</option> </select> <select name="ip" size="1" method="post" action="polycom-reboot.php"> <option value=" " selected="selected">No phone selected</option> </select> <input type="submit" value="Reboot..."/> </form> </body> </html>
  2. Please, can anyone help with this...? ~maymann
  3. Kicken, anyone... Thanks in advance :-) !
  4. Hi kicken, Thanks for your kind reply - this sounds/looks just like what i need...:-) To answer your questions: 1. you are right: passing, was the right word... 2. yes: IP is the value of each phone how do I make array in php... and how does this work now from web/shell ? I'm a bit confused - sorry for my php/java-script ignorance... Would it perhaps be possible for you to show me how/where this is done in my 2 files - I don't know how/where to edit this, eventhough you gave a nice explanation. Thanks in advance :-) ! ~maymann
  5. Please... can anyone help with this...?
  6. Can anyone help with this, please... Thanks in advance :-) ! ~maymann
  7. Can anyone help with parsing this java-script variable->PHP. Thanks in advance :-) ! ~maymann
  8. My new index.php actually doesn't give me an error..., but just "refreshes" and doesn't take me to polycom-reboot.php script as my old index.php does (showing the ip of the booting phone and a return button to take me back to index.php)
  9. I would like the same functionality as in my old index.php in my new index.php but with site+phone dropdowns (phones available should be dependent on what site you choose in the first dropdown) which is why i though of making it in javascript. My new index.php is failing, and therefore not doing its purpose, which is to reboot a VoIP phone... so what the script is doing wrong is actually kind of my question I guess... but my best guess is I'm not parsing [iP] the right way... Hope this sums it up. br. ~maymann
  10. Hi Scootstah, Thanks for your reply. I have already put all my scripts and briefly described what they do in my initial post...: 1. old index.php = working = single-site-phone-reboot script 2. new index.php = not working = multi-site-phone-reboot script 3. polycom-reboot.php = the script used by index.php taken from http://code.google.com/p/php-sip/ I need to switch old->new index.php for testing as this is running in production and the polycom-reboot.php script has references to index.php... My guess is that I'm parsing the [iP] wrong in the multi-site script (which should be called in the javascript part i guess), which is in php in my single-site script... I can't remember the exact error message (posting from home), will post this tomorrow... or maybe you are able to catch my error even before that...:-) Thanks in advance :-) ! ~maymann
  11. Hi Haku, I have a working single-site-phone-reboot script, and would like to move to a multi-site-phone-reboot script (both listed above [old and new index.php] and using polycom-reboot.php script). My multi-site-phone-reboot script doesn't work, and I'm trying to figure out what is causing this (my guess is: parsing the [ip] from index.php->polycom-reboot.php ?). So input to what could be wrong with my multi-site-phone-reboot script (index.php) are much welcome... and my question could then be "what is wrong with my multi-site-reboot script/how do i make it work like my single-site-reboot script" ? Thanks in advance :-) ! ~maymann
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.