www.webdeveloper.com
Results 1 to 5 of 5

Thread: Remove a button and/or run the buttons function

  1. #1
    Join Date
    Oct 2009
    Posts
    4

    Question Remove a button and/or run the buttons function

    I have a button on my page that looks like this...

    Code:
    <input type="button" class="button" id="createButton" 
     value="Run" onclick="handleCreateButton()">
    What I want to do is remove the button and just have the page continue on. I figured the easiest way would be to use a timer so I replaced the button script with this script...

    Code:
    <Script language="Jscript">
    		var oInterval;
      		function RemindMsg(msg) {
      		oInterval=window.setInterval("handleCreateButton()", 0010);
    }</Script>

    But it does absolutely nothing. I obviously don't know java, but I thought this was simple enough. I'm open to any solution. Thanks everybody

  2. #2
    Join Date
    Apr 2006
    Location
    Houston
    Posts
    1,374
    You want to hide the button when it is clicked ? If so then do this:
    Code:
    <input type="button" class="button" id="createButton" 
     value="Run" onclick="handleCreateButton();this.style.display='none';">

  3. #3
    Join Date
    Oct 2009
    Posts
    4
    I have a plugin in Sketchup that loads a html window so that you can choose options. The thing is I never change any options so basically I'd like it to automatically click the button

  4. #4
    Join Date
    Apr 2006
    Location
    Houston
    Posts
    1,374
    Then find the <BODY> tag of the web page and change it to look like this:

    <BODY onload="handleCreateButton();">

    The second the web pages loads it will then execute handleCreateButton()

  5. #5
    Join Date
    Oct 2009
    Posts
    4
    That is so simple. no wonder I couldn't think of it. Thank you so much

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles