www.webdeveloper.com
Results 1 to 2 of 2

Thread: activex working locally until deployed

Hybrid View

  1. #1
    Join Date
    Mar 2013
    Posts
    1

    activex working locally until deployed

    I wrote some javascript to get my windows users name using activex. When I save this to my desktop it runs fine. The moment I deploy it to apache2 running on Ubuntu 12.10 it doesn't display anything.
    HTML Code:
    <html>
    <head>
        <script language="javascript">
            function GetUserName()
            {
                var wshell = new ActiveXObject("WScript.Shell");
                alert(wshell.ExpandEnvironmentStrings("%USERNAME%"));
            }
        </script>
    </head>
    <body OnLoad="GetUserName();">
    </body>
    </html>
    Am I doing something wrong or missing anything?

  2. #2
    Join Date
    Mar 2011
    Posts
    1,133
    There's probably a missing resource problem or a security issue. Open the Developer Tools in Internet Explorer with F12 and reload the page. You should find a helpful error message in the Scripts tab.
    Rick Trethewey
    Rainbo Design

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