Jump to content

Rakeshhit

New Members
  • Posts

    2
  • Joined

  • Last visited

Everything posted by Rakeshhit

  1. I tried something like this : <?php $html = file_get_contents("http://geoportaal.maaamet.ee/url/xgis-ky.php?ky=79401:006:0812"); preg_match_all('(<li.*?>.*?</li>)', $html, $matches); $one=$matches[0][0]; ?> <script type="text/javascript"> function Assign() { document.getElementById("OutputField").value = "<?=$one?>"; } </script> <input id="inputfield" type="text" style="width:200px"/> <input id="OutputField" type="text" style="width:200px"/> <input type="button" value="Assign Value" onclick="Assign()"/> Code is working, but i need to add the Inputfield value at the end of webaddress (After ky=) that part i am not sure.
  2. I have researched all over forums from past day. Not getting correct solution. I have 2 textboxes and a button. First box is to enter value and i will click button, i need to get the value. Here is the code, that works without input box 1 In this code i want to modify my web address, at the end after ky= i want add my first textbox value, then click event and output in second textbox, let me know where i messed. <script type="text/javascript"> function Assign() { <?php $html = file_get_contents("http://geoportaal.maaamet.ee/url/xgis-ky.php?ky=79401:006:0812" ); preg_match_all('(<li.*?>.*?</li>)', $html, $matches); $one=$matches[0][0]; ?> document.getElementById("OutputField").value = "<?=$one?>"; } </script> <input id="InputField" type="text" style="width:200px"/> <input type="submit" value="Assign Value" onclick="Assign()"/> <input id="OutputField" type="text" style="width:200px"/>
×
×
  • 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.