visual studio's folder publish is not compatible for SFTP webhotel

venus-messiah manzar-nejad 0 Reputation points
2025-05-23T17:36:02.75+00:00

hello. i have published my C# asp.net webforms project by folder in visual studio 22. it have four different masterpages. i have uploaded all files in file manager's webhotel, through FileZilla. but when i press a button in my page, it appears codes of the page, not the designed page. please check your-event.se and choose any button, then you will se what i mean.

their technical support tells that their system supports .html or .php files. my project hve qlready only one index.html file. but i suppose that their system cannot recognize which html file it should start, does it? besides converting to html files, looses masterpage dependencies, doesnt it?

if i convert to php file it lose its masterpage depenencies, doesnt it?

how should i solve my problem? if you know a webhotel supporting FTP server, please let me know.

i appreciate your quick responds. very kind regards

Developer technologies | C#
0 comments No comments
{count} votes

3 answers

Sort by: Most helpful
  1. Michael Taylor 60,326 Reputation points
    2025-05-23T18:22:42.5733333+00:00

    If your webhost provider doesn't support hosting ASP.NET apps then there is nothing you can do to make this work. Your app would require that the host you're running on have the ASP.NET v4 runtime installed. If it isn't installed then your app cannot run. You should get concrete information from them about what web frameworks they support. If they only support static sites (html) and PHP then you are limited to those options.

    Master pages are an ASP.NET Web Forms thing. If you aren't able to use webforms then master pages won't work.


  2. Bruce (SqlWork.com) 77,926 Reputation points Volunteer Moderator
    2025-05-23T19:56:30.4133333+00:00

    to support a webform project, your web host has to have windows, IIS and asp.net 4.* support. as your host supports php, its probably a Wordpress host, which does not support asp.net webforms.

    you will probably need to need to pick a hosting provider, or convert your site to php. if you need to use sqlserver, that needs to one of their options. most php hosts support MySql

    https://www.w3schools.com/php/

    as this is a ms site, the only hosting provider we can recommend is azure:

    https://azure.microsoft.com/en-us/

    0 comments No comments

  3. BD9000 0 Reputation points
    2025-05-27T03:21:32.2233333+00:00

    There's a ton of web hosting companies that support ASP.Net and for dirt cheap too!
    I'm using Interserver www.interserver.net for my small to medium websites, for corporate sites use Azure or anything that requires more redundancy.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.