Announcement

Collapse
No announcement yet.

Control a device without recalling web page

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

  • donstephens
    replied
    No. Still ended up with the page refreshing. Just saw Rupp's example, and will try that.

    EDIT:

    That works.

    Thanks Greg.
    Last edited by donstephens; October 18, 2015, 10:56 PM.

    Leave a comment:


  • Rupp
    replied
    Just saw this. You should be able to use something like this.
    PHP Code:
    <html>
    <
    body>
     <
    iframe id="mainFrame" name="mainFrame" width="200"  height="200" src="" style="visibility:visible;"></iframe>
            <
    input type="button" value="Click" onclick="mainFrame.location.href = 'http://yourIpAddress:81/JSON?request=runevent&group=Speaking&name=SpeakTheTime'" /> 
    </
    body>
    </
    html
    Once this works set the visibility to hidden on the iFrame.

    Leave a comment:


  • unbwogable
    replied
    Ever find out anything about this? I'm trying to do something similar and having no luck whatsoever

    Leave a comment:


  • donstephens
    replied
    Can you give me an example Greg? Or perhaps point me to one...

    Thanks to both of you for suggestions.

    Leave a comment:


  • Rupp
    replied
    You could put an iFrame on the page (hide it after testing) that you target with an asp:LinkButton that runs the JSON command and the results are shown in the hidden iFrame.

    Leave a comment:


  • mrhappy
    replied
    My gut instinct wonders if you could use some sort of AJAX function with the postback via the JSON interface which would then not need the page to be refreshed. I'll have a play around see whether I can do it...

    Leave a comment:


  • donstephens
    replied
    User Input. I have a video stream embedded in the page and the reload plays havoc with it.

    I'm not sure how to use JSON w/a button.

    Originally posted by mrhappy View Post
    Are you trying to control the devices on the back of some sort of user input (button or such) or do you just want the device controlled on page load?

    Leave a comment:


  • Rupp
    replied
    Have you looked at the JSON interface. You can call these from many different ways.

    Leave a comment:


  • mrhappy
    replied
    Are you trying to control the devices on the back of some sort of user input (button or such) or do you just want the device controlled on page load?

    Leave a comment:


  • donstephens
    started a topic Control a device without recalling web page

    Control a device without recalling web page

    Probably a stupid question... I'm using forms to call functions on an ASP page. Is there a way to control a device without using forms?
Working...
X