Results 1 to 20 of 20

Thread: [RESOLVED] Localhost - problems with exentions

  1. #1

    Thread Starter
    WiggleWiggle dclamp's Avatar
    Join Date
    Aug 2006
    Posts
    3,527

    Resolved [RESOLVED] Localhost - problems with exentions

    i made a simple asp page, default.aspx. I saved it to localhost and ran it, i got the error "Server Application Unavailable"

    I changed the extention to .asp, and it ran, but the script didnt work.

    here is the script:

    asp Code:
    1. <head>
    2.     <title>Test Page</title>
    3. </head>
    4. <body>
    5.     <form id="form1" method='post'>
    6.     <div>
    7.         <input type="text" name="myname" />
    8.         <input type="submit" name="submit" value="Submit" />
    9.     </div>
    10.     </form>
    11.     <%
    12.         Dim myname
    13.         myname = Request.Form("myname")
    14.         Response.Write("Hello " & myname)
    15.      %>
    16. </body>
    17. </html>
    My usual boring signature: Something

  2. #2
    Ex-Super Mod RobDog888's Avatar
    Join Date
    Apr 2001
    Location
    LA, Calif. Raiders #1 AKA:Gangsta Yoda™
    Posts
    60,709

    Re: Localhost - problems with exentions

    Moved

    Where is your runat="server" in your form?
    VB/Office Guru™ (AKA: Gangsta Yoda®)
    I dont answer coding questions via PM. Please post a thread in the appropriate forum.

    Microsoft MVP 2006-2011
    Office Development FAQ (C#, VB.NET, VB 6, VBA)
    Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
    If a post has helped you then Please Rate it!
    Reps & Rating PostsVS.NET on Vista Multiple .NET Framework Versions Office Primary Interop AssembliesVB/Office Guru™ Word SpellChecker™.NETVB/Office Guru™ Word SpellChecker™ VB6VB.NET Attributes Ex.Outlook Global Address ListAPI Viewer utility.NET API Viewer Utility
    System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6

  3. #3
    Frenzied Member StrangerInBeijing's Avatar
    Join Date
    Mar 2005
    Location
    Not in Beijing
    Posts
    1,666

    Re: Localhost - problems with exentions

    saved it to localhost
    ....
    You just saved it, or created a virtual directory?
    Sounds like you tried to create a page in text editor not using VS? Good idea, just make sure all is in place (.net, virtual directory, folder permission, etc)
    Install and Configure Eclipse For both Java and PHP development
    Accessible Ajax/jQuery Forms Degrade gracefully with JavaScript Disabled

  4. #4

    Thread Starter
    WiggleWiggle dclamp's Avatar
    Join Date
    Aug 2006
    Posts
    3,527

    Re: Localhost - problems with exentions

    rob helped me a little, he got me a vitural dir, i am just getting the error:
    "Failed to access IIS metabase."
    My usual boring signature: Something

  5. #5
    Ex-Super Mod RobDog888's Avatar
    Join Date
    Apr 2001
    Location
    LA, Calif. Raiders #1 AKA:Gangsta Yoda™
    Posts
    60,709

    Re: Localhost - problems with exentions

    Make sure your web.config looks something like this...

    vb Code:
    1. <?xml version="1.0" encoding="UTF-8"?>
    2. <!--
    3.     Note: As an alternative to hand editing this file you can use the
    4.     web admin tool to configure settings for your application. Use
    5.     the Website->Asp.Net Configuration option in Visual Studio.
    6.     A full list of settings and comments can be found in
    7.     machine.config.comments usually located in
    8.     \Windows\Microsoft.Net\Framework\v2.x\Config
    9. -->
    10. <configuration>
    11.     <appSettings />
    12.     <connectionStrings />
    13.     <system.web>
    14.         <!--
    15.             Set compilation debug="true" to insert debugging
    16.             symbols into the compiled page. Because this
    17.             affects performance, set this value to true only
    18.             during development.
    19.         -->
    20.         <compilation debug="false" />
    21.         <!--
    22.             The <authentication> section enables configuration
    23.             of the security authentication mode used by
    24.             ASP.NET to identify an incoming user.
    25.         -->
    26.         <authentication mode="Windows" />
    27.         <!--
    28.             The <customErrors> section enables configuration
    29.             of what to do if/when an unhandled error occurs
    30.             during the execution of a request. Specifically,
    31.             it enables developers to configure html error pages
    32.             to be displayed in place of a error stack trace.
    33.  
    34.         <customErrors mode="RemoteOnly" defaultRedirect="GenericErrorPage.htm">
    35.             <error statusCode="403" redirect="NoAccess.htm" />
    36.             <error statusCode="404" redirect="FileNotFound.htm" />
    37.         </customErrors>
    38.         -->
    39.     </system.web>
    40.     <system.webServer>
    41.         <defaultDocument>
    42.             <files>
    43.                 <clear />
    44.                 <add value="default.aspx" />
    45.             </files>
    46.         </defaultDocument>
    47.     </system.webServer>
    48. </configuration>
    VB/Office Guru™ (AKA: Gangsta Yoda®)
    I dont answer coding questions via PM. Please post a thread in the appropriate forum.

    Microsoft MVP 2006-2011
    Office Development FAQ (C#, VB.NET, VB 6, VBA)
    Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
    If a post has helped you then Please Rate it!
    Reps & Rating PostsVS.NET on Vista Multiple .NET Framework Versions Office Primary Interop AssembliesVB/Office Guru™ Word SpellChecker™.NETVB/Office Guru™ Word SpellChecker™ VB6VB.NET Attributes Ex.Outlook Global Address ListAPI Viewer utility.NET API Viewer Utility
    System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6

  6. #6

    Thread Starter
    WiggleWiggle dclamp's Avatar
    Join Date
    Aug 2006
    Posts
    3,527

    Re: Localhost - problems with exentions

    yeah it does




    (off topic: one more post cout for me )
    My usual boring signature: Something

  7. #7
    Ex-Super Mod RobDog888's Avatar
    Join Date
    Apr 2001
    Location
    LA, Calif. Raiders #1 AKA:Gangsta Yoda™
    Posts
    60,709

    Re: Localhost - problems with exentions

    Also, noticed you are missing some stuff on your page...
    vb Code:
    1. <%@ Page Language="VB" AutoEventWireup="false" CodeFile="default.aspx.vb" Inherits="_default" %>
    2. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    3. <html xmlns="http://www.w3.org/1999/xhtml" >
    4. <head runat="server">
    5. '...
    VB/Office Guru™ (AKA: Gangsta Yoda®)
    I dont answer coding questions via PM. Please post a thread in the appropriate forum.

    Microsoft MVP 2006-2011
    Office Development FAQ (C#, VB.NET, VB 6, VBA)
    Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
    If a post has helped you then Please Rate it!
    Reps & Rating PostsVS.NET on Vista Multiple .NET Framework Versions Office Primary Interop AssembliesVB/Office Guru™ Word SpellChecker™.NETVB/Office Guru™ Word SpellChecker™ VB6VB.NET Attributes Ex.Outlook Global Address ListAPI Viewer utility.NET API Viewer Utility
    System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6

  8. #8
    Frenzied Member StrangerInBeijing's Avatar
    Join Date
    Mar 2005
    Location
    Not in Beijing
    Posts
    1,666

    Re: Localhost - problems with exentions

    register .net in iis? (aspnet_regiis -i)
    Make sure that Windows Authentication is enabled for the Virtual Directory in IIS. You will get this error if it is unchecked. To see if it's enabled, click on the Directory Security tab, click Edit under Access control, and place a check in the Intergrated Windows Security box. You MUST restart IIS for the changes to take effect!
    Right-click on the virtual directory (or Default Web Site), go to properties and click on the Configuration button. Under the Mappings Tab, make sure .aspx and other .NET related extentions are listed. If not, I believe you'll have to run the aspnet_regiis.exe utility.

    This shouldn't affect your problem, but it might. Under the Documents Tab, it seems you have to manually add index.aspx or default.aspx. Again, this probably isn't causing your problem UNLESS you are not supplying the page name in the address bar when navigating.

    If you're using Windows 2003, make sure you've enabled ASP.NET in IIS Manager.

    Lastly, make sure the ASPNET account has proper rights for the directory and it's subs.
    Install and Configure Eclipse For both Java and PHP development
    Accessible Ajax/jQuery Forms Degrade gracefully with JavaScript Disabled

  9. #9

    Thread Starter
    WiggleWiggle dclamp's Avatar
    Join Date
    Aug 2006
    Posts
    3,527

    Re: Localhost - problems with exentions

    Quote Originally Posted by StrangerInBeijing
    register .net in iis? (aspnet_regiis -i)
    Make sure that Windows Authentication is enabled for the Virtual Directory in IIS. You will get this error if it is unchecked. To see if it's enabled, click on the Directory Security tab, click Edit under Access control, and place a check in the Intergrated Windows Security box. You MUST restart IIS for the changes to take effect!
    Right-click on the virtual directory (or Default Web Site), go to properties and click on the Configuration button. Under the Mappings Tab, make sure .aspx and other .NET related extentions are listed. If not, I believe you'll have to run the aspnet_regiis.exe utility.

    This shouldn't affect your problem, but it might. Under the Documents Tab, it seems you have to manually add index.aspx or default.aspx. Again, this probably isn't causing your problem UNLESS you are not supplying the page name in the address bar when navigating.

    If you're using Windows 2003, make sure you've enabled ASP.NET in IIS Manager.

    Lastly, make sure the ASPNET account has proper rights for the directory and it's subs.
    i have windows (server) 2003, and the scripts work just fine.I have tried just about everything you said.. and nothing...
    My usual boring signature: Something

  10. #10
    Frenzied Member StrangerInBeijing's Avatar
    Join Date
    Mar 2005
    Location
    Not in Beijing
    Posts
    1,666

    Re: Localhost - problems with exentions

    Seems like a pretty common problem: Google is your friend too
    Install and Configure Eclipse For both Java and PHP development
    Accessible Ajax/jQuery Forms Degrade gracefully with JavaScript Disabled

  11. #11
    Ex-Super Mod RobDog888's Avatar
    Join Date
    Apr 2001
    Location
    LA, Calif. Raiders #1 AKA:Gangsta Yoda™
    Posts
    60,709

    Re: Localhost - problems with exentions

    So then you had it correct

    aspnet_regiis -i

    Ps, He said Google is not his friend so he had to post the thread.
    VB/Office Guru™ (AKA: Gangsta Yoda®)
    I dont answer coding questions via PM. Please post a thread in the appropriate forum.

    Microsoft MVP 2006-2011
    Office Development FAQ (C#, VB.NET, VB 6, VBA)
    Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
    If a post has helped you then Please Rate it!
    Reps & Rating PostsVS.NET on Vista Multiple .NET Framework Versions Office Primary Interop AssembliesVB/Office Guru™ Word SpellChecker™.NETVB/Office Guru™ Word SpellChecker™ VB6VB.NET Attributes Ex.Outlook Global Address ListAPI Viewer utility.NET API Viewer Utility
    System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6

  12. #12
    I'm about to be a PowerPoster! mendhak's Avatar
    Join Date
    Feb 2002
    Location
    Ulaan Baator GooGoo: Frog
    Posts
    38,170

    Re: Localhost - problems with exentions

    Are you even using Visual Studio? How did you 'publish' in the first place?

  13. #13
    Ex-Super Mod RobDog888's Avatar
    Join Date
    Apr 2001
    Location
    LA, Calif. Raiders #1 AKA:Gangsta Yoda™
    Posts
    60,709

    Re: Localhost - problems with exentions

    He is using notepad I believe, hence the missing asp code on the page.
    VB/Office Guru™ (AKA: Gangsta Yoda®)
    I dont answer coding questions via PM. Please post a thread in the appropriate forum.

    Microsoft MVP 2006-2011
    Office Development FAQ (C#, VB.NET, VB 6, VBA)
    Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
    If a post has helped you then Please Rate it!
    Reps & Rating PostsVS.NET on Vista Multiple .NET Framework Versions Office Primary Interop AssembliesVB/Office Guru™ Word SpellChecker™.NETVB/Office Guru™ Word SpellChecker™ VB6VB.NET Attributes Ex.Outlook Global Address ListAPI Viewer utility.NET API Viewer Utility
    System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6

  14. #14

    Thread Starter
    WiggleWiggle dclamp's Avatar
    Join Date
    Aug 2006
    Posts
    3,527

    Re: Localhost - problems with exentions

    so do i put "aspnet_regiis -i" in the ISAPI filter tab of my website?
    My usual boring signature: Something

  15. #15
    Ex-Super Mod RobDog888's Avatar
    Join Date
    Apr 2001
    Location
    LA, Calif. Raiders #1 AKA:Gangsta Yoda™
    Posts
    60,709

    Re: Localhost - problems with exentions

    No you need to run it from the commandline. The full path may be required though.
    VB/Office Guru™ (AKA: Gangsta Yoda®)
    I dont answer coding questions via PM. Please post a thread in the appropriate forum.

    Microsoft MVP 2006-2011
    Office Development FAQ (C#, VB.NET, VB 6, VBA)
    Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
    If a post has helped you then Please Rate it!
    Reps & Rating PostsVS.NET on Vista Multiple .NET Framework Versions Office Primary Interop AssembliesVB/Office Guru™ Word SpellChecker™.NETVB/Office Guru™ Word SpellChecker™ VB6VB.NET Attributes Ex.Outlook Global Address ListAPI Viewer utility.NET API Viewer Utility
    System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6

  16. #16

    Thread Starter
    WiggleWiggle dclamp's Avatar
    Join Date
    Aug 2006
    Posts
    3,527

    Re: Localhost - problems with exentions

    what would be the full path?
    My usual boring signature: Something

  17. #17
    Ex-Super Mod RobDog888's Avatar
    Join Date
    Apr 2001
    Location
    LA, Calif. Raiders #1 AKA:Gangsta Yoda™
    Posts
    60,709

    Re: Localhost - problems with exentions

    The fool path would be everything including the root drive


    XP Framework 1.1:
    C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322

    XP/Vista 2.0:
    C:\Windows\Microsoft.NET\Framework\v2.0.50727
    VB/Office Guru™ (AKA: Gangsta Yoda®)
    I dont answer coding questions via PM. Please post a thread in the appropriate forum.

    Microsoft MVP 2006-2011
    Office Development FAQ (C#, VB.NET, VB 6, VBA)
    Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
    If a post has helped you then Please Rate it!
    Reps & Rating PostsVS.NET on Vista Multiple .NET Framework Versions Office Primary Interop AssembliesVB/Office Guru™ Word SpellChecker™.NETVB/Office Guru™ Word SpellChecker™ VB6VB.NET Attributes Ex.Outlook Global Address ListAPI Viewer utility.NET API Viewer Utility
    System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6

  18. #18

    Thread Starter
    WiggleWiggle dclamp's Avatar
    Join Date
    Aug 2006
    Posts
    3,527

    Re: Localhost - problems with exentions

    so what do i enter into command line? do i need to change the directory to get there? then enter the line?
    My usual boring signature: Something

  19. #19
    Ex-Super Mod RobDog888's Avatar
    Join Date
    Apr 2001
    Location
    LA, Calif. Raiders #1 AKA:Gangsta Yoda™
    Posts
    60,709

    Re: Localhost - problems with exentions

    C:\Windows\Microsoft.NET\Framework\v2.0.50727\aspnet_regiis -i

    from the run box and press enter. A dos window will popup showing the reregistering of iis.
    VB/Office Guru™ (AKA: Gangsta Yoda®)
    I dont answer coding questions via PM. Please post a thread in the appropriate forum.

    Microsoft MVP 2006-2011
    Office Development FAQ (C#, VB.NET, VB 6, VBA)
    Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
    If a post has helped you then Please Rate it!
    Reps & Rating PostsVS.NET on Vista Multiple .NET Framework Versions Office Primary Interop AssembliesVB/Office Guru™ Word SpellChecker™.NETVB/Office Guru™ Word SpellChecker™ VB6VB.NET Attributes Ex.Outlook Global Address ListAPI Viewer utility.NET API Viewer Utility
    System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6

  20. #20

    Thread Starter
    WiggleWiggle dclamp's Avatar
    Join Date
    Aug 2006
    Posts
    3,527

    Re: Localhost - problems with exentions

    great! it works!
    My usual boring signature: Something

Posting Permissions

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



Click Here to Expand Forum to Full Width