So I am new to ASP.NET and have run through some tutorials. The next step for me was to find a really cool bootstrap template to employ. I downloaded this solution http://bootstraptaste.com/bocor-bootstrap-template-nice-animation/ and tried to change the .css file as I did originally following the Visual Studio tutorial http://www.asp.net/visual-studio/overview/2013/creating-web-projects-in-visual-studio#bootstrap .
Nothing happened. Also, a ton of files came with the template I downloaded, including an index.html file which actually loads the project into Internet Explorer.
I'd like to load this solution in Visual Studio so I can play around with it and modify it. Is this possible? I am definitely not advanced enough yet to get the same results on my own. Any advice and help is appreciated!
I'm not sure if Visual Studio is the best tool for creating your websites. To get your template running, execute the file index.html in a web browser. It is however, a better practice to run your templates from a server like xampp, wamp or IIS (in case of Windows OS).
In case of xampp, copy the folder to xampp/htdocs/. Then start the xampp server and based upon the port your xampp server is running on, run it on a web browser by typing localhost:port/folder_name in the address bar.
The procedure is similar for wamp with the only difference being in the path. The path for wamp will be wamp/sites/
Related
I'm sure there's something simple I'm missing.
I'm attempting to help a buddy move his ASP site from one host to another to avoid some questionable billing practices. I usually work with PHP-based sites (Wordpress etc.) and, unfortunately, have no experience with VS or ASP.
He's temporarily moving to Godaddy on their Plesk offering temporarily until he can work out something else. He provided me with all of the files contained within his ftp (containing his site's default.asp file, header, footer etc.) as well as an archive.xml, parameters.xml, and a systemsinfo.xml file. No .snl file or anything like that.
The files did not come with a web.config file. The error I keep getting, after uploading the FTP files is "HTTP Error 502.5 - Process Failure". From my understanding, it's often related to the web.config file. And from what I understand, you can have one generated by deploying the site through VS. Problem is, I'm at a loss as to what the proper actions to deploy this project.
Plesk provides a .publish settings file, I'm just at a loss as to how to properly open this file in VS to then have it create a "web.config" file and proceed to have it publish to the hosting. Part of this is I'm unsure how to properly open a project like this in Visual Composer to then proceed with the process of setting a web.config file and going forward with the deploying.
Not knowing exactly how to open this project without an .snl file or anything, I tried creating a new project and dropping in the other files to try and set up the process that way with no luck. Considering that Plesk provides a deploy file with that information, I'm assuming if I can properly open the project, working locally, I can then go through the deploy process. I'm just at a loss as to how I can properly setup a new project with someone else project files without an .snl file or otherwise.
Any guidance that you provide would be awesome.
Thank you.
Well, if you missing basic files required to operate the site such as web.config, then you don't have the site or files required, right?
Either FTP down the existing site, or you go to the source code and VS project, and re-compile the code, and re-publish. In fact, I suggest publishing to a local simple file folder.
Even publishing to a local file folder is a good start. Now, just copy that local folder that you published from the source code project, and that published folder should work on the new site. But, really, missing files like web.config? Rather fundamental that you have ALL files of that existing published site, or you have to go back to source code project in VS and re-publish.
since that site has vb.net or c# code? Then it also not clear if the original site was a
asp.net web site
or
asp.net web site application.
Rather critical you determine the above. The reason is that for a asp.net web site application, then at publish time, all code is complied at publish time, source code is stripped out, and then you have a working site.
If this is a web site (not web site application), then all source code is in fact published to the web site, and IIS is now responsible for compiling the .net code.
but, gooly, without a web config file, you simple don't have the files for that site to work - NOT even close!!!
but, as noted, if you have the original source code and VS project, then I would of course use the source code project for the publish. As noted, you can publish via FTP, and several other ways - but I in most cases use folder/file publish to a local folder, and then that is FTP up to the site.
You also don't mention if a database is involved. But, the connection strings to the database will FOR SURE change on the new site - and that boatload of required information will of course be in the web config file.
So, what road will much depend on if you going to download the exiting site, or your going back to the original source code and Visual Studio project.
So, first step - which will take about 10 seconds of your time is to determine if this is a asp.net web site, or a asp.net web site application.
If the existing published site has the c# (or vb.net) source code, then this was/is a web site.
If the existing published site does NOT have the source code, then of course this was a asp.net web site application - and Visual Studio is responsible for compiling the code BEFORE publish.
I guess this really comes down to if you have the source code and the original project used to build the site in VS or not?
I mean, if you have the source code (not compiled) of that site and have the full project in VS, then that's your best starting point. And if that site was published asp.net web site (application), then FTP and downloading the site WILL NOT get you a working asp.net project in VS.
This is much like saying you have a some .exe program, but don't have the source code and project used to build that .exe.
Same goes for asp.net. but, as I stated, often the web site as opposed to web site application model is used, and in that case, then you would get and have the source code files by a simple FTP download. But, you don't even have the web.config file - and that makes no sense at all, since that going to exist in the current site if you download, and it would exist in the original VS project used to create that site in the first place. During a publish, we often have an additional config file that has the local database connections, and during publish, they are transformed into the correct database connections for the published site. But then again, you not even noted or mentioned if a database is involved here.
I mean, if I was handed a LAMP project (Linux, Apache, MySQL, PHP), and had to publish that site? gooly, I not worked with LAMP, but I'm sure it would be a week, or more for me to figure that out, since I'm not familiar with LAMP, and how such sites are laid out, let alone how the configuration of such a site works. Big job if the whole system, programming language and framework is something you never used before.
I know that Godaddy use Plesk control panel too. But you need to make sure that Godaddy has support .NET Core. You may refer to this post https://dotnetblog.asphostportal.com/how-to-fix-error-502-5-process-failure-asp-net-core/. I believe it will solve your issue.
I am trying to create a web server with XAMPP to host an ASP.NET website. However, I am unable to do so. As I understand it, ASP.NET apps cannot be served out-of-the-box with XAMPP. I have found that in order to get Apache to work through XAMPP that mod_aspdotnet needs to be installed and configured. I am following the instructions for mod_aspdotnet by Shehroz Kaleem at https://xehroz.tumblr.com/post/43884721903/how-to-run-aspnet-on-xampp, but I am running into issues. First off, the current version of mod_aspdotnet (https://sourceforge.net/projects/mod-aspdotnet/files/latest/download) is in a zip file that does not include an installer inside of it (or at least, I can't find one). This makes installing it a problem. So, in order to fix that issue, I have resorted to attempting to use the previous version (2.2.0.2006) that is not a zip file, but a directly installable .msi. The problem with this installer, however, is that it does not recognize C:\xampp\apache as a "valid path to an installed instance of Apache." This install location from XAMPP is suggested in the aforementioned instructions by Shehroz Kaleem. Does anyone have any experience setting up a web server for ASP.NET using XAMPP? Is there something that I am doing wrong?
I have a website which was created using Microsoft Visual Studio 2010.
I want to copy the website onto a CD so that my professor can run it on his computer.
However, since Visual Studio creates the solution of the website in My Documents/Visual Studio 2010/Projects, I cannot simply copy the website folder only.
What is the best way to transfer a copy of this website please? Thank you and all the best for the new year.
Of course you can copy the folder. It will make the website in a folder within projects and you will be able to copy this folder onto a CD. When you run the website you can see where it is stored, if you look into the address bar of your web browser it will say something like c:\Users\You\Documents\Visual Studio 2010\Projects\MyWebsite\index.html. In this case the folder you need to copy is c:\Users\You\Documents\Visual Studio 2010\Projects\MyWebsite\ - instruct your professor to open the folder and select index.html.
The question is, have you used something other than just HTML and CSS to do this? Its probably a stupid question as if you have used ASP or similar to create the website you would probably also have the knowledge to copy said website. In the off chance that you HAVE used ASP or similar you will need to put this website onto a server that runs ASP.
However, if you've just used Visual Studio to lay out the website and put in some content and such, then its most likely all the files are images, HTML and CSS which will happily run off a CD.
If your professor needs only to run it on his environment, you can use "Publish" feature of Visual Studio 2010 and choose the file system as the target.
Then burn the published folder.
He then will be able to copy it from the CD to his Microsoft.NET enabled application server and run it.
You have to search My Documents/Visual Studio 2010/WebSites/
And obviosly, u should find there the website of your solution. It is needed to copy the website folder and solution folder of your site from VS2010/Projects and /Websites folders to your professors' computer.
This way is right if your professor has VS 2010 installed.
Upload it to a cheap or free hosting provider and send the URL to your professor. If necessary, you can password-protect the site to prevent access by unauthorized third parties.
Hello i just deployed my web site to the remote server. I noticed that the menu (navigation) bar is doesn't display as on my local server. I am using visual studio 2010.
The stylesheet was also deployed to my remote server. I am using the new asp.net 4 already designed navigation. It works find on my local machine but not on the remote machine. Can someone help me?
Use firebug (a firefox) extension to make sure that you are using the correct CSS classes for the menu, as it is in the development version. Check the CSS files exist on the server. I guess it may be a path problem (wrong path to the CSS file). Use the "Net" tab in firebug to see whether the files are present on the server or not.
Are you getting the same problem in some particular browser ?
Make sure correct version of all files are uploaded.
Next, check the .NET version set for the application on the server.
I have an ASP.NET application which I'd like to try running on Mono, just as an experiment. When I bring the application as it is to Mac, start xsp2 on the directory, it runs as I would imagine it should. That is, it crashes on because of the file system path differences (\ vs / in directories).
This is where I would like to open it in MonoDevelop and fix the problems. But since it was website, it doesn't have .csproj file. And it seems that there's no .sln file either, since Visual Studio stores those to some random directory by default. In Visual Studio you could open the project with Open -> Web site... -> Local IIS etc., but I see no such thing in Mono.
Is there a way to open a directory as a web site or somehow generate the .csproj file? I would prefer an answer which won't need Visual Studio or even Windows to help me with that.
Create new project in MonoDevelop in the same directory as your files.
Right click the project in the solution window
Choose Display Options -> Show All Files
Right click a file and choose Include to Project
You can select multiple files at a time (shift or ctrl click) and include them all at once, or include full directories.
Unfortunately you can't open WebSites in MonoDevelop. WebApplications are supported in MD, but WebSites aren't. Michael promised yesterday that he will explain why, you can ping him to touch this topic quicker.
Some more information is available:
http://mjhutchinson.com/journal/2008/08/15/web_application_projects_md_and_vwd
http://mjhutchinson.com/journal/2007/06/04/rethinking_asp_net_project_models
http://mjhutchinson.com/journal/2006/06/10/asp_net_project_models
Probably, in the long run, the best solution for you will be to migrate from WebSite to WebApp.
One option to avoid changing your application settings is to use Mono's built-in path remapping feature, basically do this:
$ MONO_IOMAP=all
$ xsp2
For more details you can read:
http://www.mono-project.com/IOMap
Create a new project in MonoDevelop and import the files into it.