I have silverlight project and this project are deploying in IIS. But in solution I created two another SL projects with .Web projects. The problem that I cannot deploy these projects in web site (IIS). How I can do this? How I can do this xaps and dlls are visible for project?
In these two projects i have wcf services too.
if you have multiple web pages and each has their own silverlight xap, you can just set in IIS the default web page to be viewed then put a navigation of some sort in the webpage (links or redirects) so you view the other web pages.
Related
How to publish ASP.NET 6 Web API with React Project to IIS
I followed this MS tutorial for creating an ASP.NET Core project with a React front-end - https://learn.microsoft.com/en-us/visualstudio/javascript/tutorial-asp-net-core-with-react?view=vs-2022. I choose the option to create my client app in a separate project outside of the ASP.NET core project.
I am trying to publish my project to a local IIS server but I’m running into a few snags.
I’ve followed the instructions in the Publish the project section of the same guide. When I follow those steps, my web api project and dependencies are deployed to the root of my IIS project folder, and the react web files are placed in a wwwroot directory within my IIS project folder. If I navigate to the site, I get a can’t reach this page.
I was under the impression that my single asp.net app could host both the react web files as well as my web API. If I should be deploying the react app and the web API to separate sites within IIS, what is the most effective way to update all my API paths in react once deployed? Right now all my web api calls are relative links “/api/resourcesA”. Finding this all a bit confusing as someone coming from Razor Pages and MVC.
From what I gather I will also need to update the “homepage” property in package.json to my site’s URL, and I will also need to install and configure a URL rewriter as I am using react-router. However, I feel like I am getting stuck before getting to these steps. Any advice/direction appreciated.
I refer to the document(https://learn.microsoft.com/en-us/visualstudio/javascript/tutorial-asp-net-core-with-react?view=vs-2022) on my side and I am able to reproduce the said issue.
It might create confusion as its combines the React project and .Net Core API in the single folder while publishing it.
You could refer to the steps below may help to fix the issue.
I assume that your project is running successfully from the VisualStudio and showing the data.
Go to Program.cs file and add these 2 lines.
app.MapFallbackToFile("index.html");
app.UseStaticFiles();
It should look like below.
For simplicity, try to publish it to Folder.
While creating the site in the IIS, set physical path like below.
While setting physical path, Select the site folder(don't select the wwwroot folder in it).
Visit the site in the browser.
As title.
I am developing ASP.Net core project with react.js, and deployed the project to a physical folder in my computer. Assume that my IP is a.b.c.d, I want to deploy it as application under default web site, and set a virtual path point to the physical folder where I deploy my project. That is, I want to show my project result when I open a browser and key in http://a.b.c.d/MyvirtualPath inside my address bar.
I've tried a way that to set PUBLIC_URL but I didn't see anything on my browser, and what I found about deploying onto IIS is to publish as a website, and that is not what I want.
Could someone guide me to achieve this?
If you want to deploy a React application under the default website, you should not use a virtual directory but add an application under the default website:
Another point to note is that if IIS wants to host asp.net core applications, you need to install .NET Core Hosting Bundle. For more information about it, you can refer to this link.
I need to share session between two web applications on different servers. My main web application is developed on ReactJS and some eCommerce stuff is developed on WIX. So, how can I use same session for both domains. I read lot of blogs and stackoverflow questions but not get any authentic and secure way to do that. Both web applications are hosted on different servers and using main domain i.e "example.com" and sub-domain i.e "store.example.com".
If HTML iframe is used in WIX site then session will automatically share between main domain and sub-domain. What I did for this
Created a separate component for header in ReactJs application.
Use the URL of that component in WIX site as iframe.
Sessions automatically share between for domain and sub-domain by
browser.
I want to create a web application. Before knowing about pwa, i wanna to create my wep app with rwd(responsive web design) that implements by react.
I don't want to have two seperated url and site for pwa and desktop. What could i do? Can i use serviceworker and manifest in root of my rwd design ? When users go to url in mobile, they see pwa and in desktop they see rwd. Just with one url. Thanks.
Yes service workers and manifest will help you accomplish this. The pwa will be from the Responsive Web Design, meaning you Progressive Web App is linked to the rwd.
See explanation: https://www.optasy.com/blog/3-essential-steps-convert-your-website-progressive-web-app
Following the walkthrough at http://msdn.microsoft.com/en-us/library/ee707351(v=VS.91).aspx I have a working Silverlight solution that employs a WCF RIA Services Class Library. I am now stuck on how to deploy this to a production server.
In a previous project (not using RIA services) that used a standard WCF Class Library I had to create a seperate web application to host the services. When it came to deployment it was obvious that I needed to deploy both the front-end (Silverlight hosting) web app and the server (WCF hosting) web app and everything worked well.
With the WCF RIA Services Class library solution there is only one web app in the solution. I am presuming that since the solution works in VS, the service is somehow being hosted in the same web app that was created for the Silverlight front-end but this is not visibly clear. Anyhow, I deployed the application using Web Deploy (as I have done other apps before) but it does not work. I didn't really expect it to!
Can anyone point me in the right direction?
When you link the .web RIA class library projects to your main web project, the services are accessed behind the scenes by URLs like:
http://localhost:2911/ClientBin/RiaServices-Documents-Web-DocumentDomainService.svc/binary/GetDocuments?$take=20&$includeTotalCount=True
The client RIA class library projects just assume a relative URL (relative to the hosting project), so they will work in any Silverlight application.
The only requirement is that you link the RIA service ".Web" project to the website hosting your Silverlight app. That will place the required service relative to the clientbin folder, ready to be consumed.
I had not installed RIA on the IIS Server because I received a message that led me to believe that you couldn't do it. However there is a command prompt command to do a special Server install see here msdn.microsoft.com/en-us/library/ff426913(v=VS.91).aspx. It now works by simply deploying the Web project.