Announcement

Collapse
No announcement yet.

dynamically updating HTML w/ ip address

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    dynamically updating HTML w/ ip address

    Goal:
    take an <a href="http://127.0.0.1:81" > and replace the 127.0.0.1 portion and detect the "actual" IP address and replace it with that. Basically, dynamically update the HTML page.

    thanks

    #2
    ...but where the tricky bit comes in is, where do you want to put it?

    Nucleus Home Automation
    News, support, and updates for Rover, Network Monitor, TimeIcons, and more

    Comment


      #3
      I'll tell ya where to put it. [img]/infopop/emoticons/icon_wink.gif[/img]

      --David

      Comment


        #4
        I want to update a web page (locally in a dir). This web page is built to redirect users from a static web page on the internet to my "home" web server which has a dynamic IP.

        Comment


          #5
          There are VBScript file commands that let your scripts open and write to text files. That's how you'd need to proceed for that. You'd use hs.GetIPAddress to get the IP address (though if you ever might have multiple NICs, be careful about getting the right address).

          Though depending on what you're going to do with that file, you might be better of just using an ASP and not creating an actual file.

          Nucleus Home Automation
          News, support, and updates for Rover, Network Monitor, TimeIcons, and more

          Comment


            #6
            Do a search on Linksys or router reset (I'm at work, so don't have the name in front of me). Someone wrote a script to get an IP from the router, then update a Web page and FTP it. It has all the code to do what you wish to do (at least the page update.

            Barry T

            Comment


              #7
              Do a search for Hunters Slideshow.vbs. The Template file will give you the info for updating a page with Replace function. I have included a small script that I use to call this function.
              Then I use a batch file calling WSFTP, in batch mode, in same event as script, to push updated page to isp provided website. Please change it to fit your needs..........................JG
              I'm online for awhile today
              http://www.crpud.net/~jjgrau/
              click on "Garage is ON Line"
              3.0.0.548: HS3PRO - 3.0.5.10: AIAlert - 2.1.1.0: APIWeather - 2.0.64.0: BLBackup - 2.0.45.0: BLLAN - 2.0.37.0: BLRoombaWifi - 1.0.0.3: DevLog - 1.2.5.15: KeyPad - 3.0.2.25: NetCAM - 0.0.0.52: Pushover 3P - 3.0.0.5: SendVFD - 1.0.0.3: Tiles - 3.0.11.0: Z-Wave

              Comment

              Working...
              X