Login and registration page path in ASP.NET MVC - asp.net-mvc

I am a newbie in C# programming and web development. Kindly let me know how I can find the code files for the login and register page in ASP.NET MVC.
I created this simple web app using this crash course; https://www.youtube.com/watch?v=BfEjDD8mWYg&t=909s.
This is the screenshot of the page I want to locate and alter. I want to change the text next to the login and registration forms.
Looking forward to getting a reply from anyone who can help.
Thanks in advance
I tried looking in all the files, like the css file and all the files in the views folder, but I could not find the file I want to change the text on the registration and login page.

I check the video you provided and find that he created a project with Individual User Accounts, So the project will generate Register and Login page Automatically, But you can't find these pages in your project.
If you wanna find these pages, You need to Scaffold Identity:
From Solution Explorer, right-click on the project > Add > New
Scaffolded Item
.
From the left pane of the Add New Scaffolded Item dialog, select
Identity. Select Identity in the center pane. Select the Add
button.
Select pages you want to create, Here you can choose Login and Register page, Then To use your existing data context, select at least one file to override. You must select at least one file to add your data context.
After you finish these steps and generate page successfully, You will find these pages in Area/Identity/Pages/Account/... ,Then you can edit them.
More information you can refer to this Docs.

Related

AspNetCore.Identity manage account header text change

Hi,
I created login on my app using Scaffolding Identity.
After the forder structure was added, I was able to modify all but the header of the page.
I opened up each cshtml file did not find the header text Change your account settings in any of them.
Can someone help me to locate the header?
Thank you.
https://learn.microsoft.com/en-us/answers/questions/503636/aspnetcoreidentity-manage-account-header-text-chan.html?childToView=504066#comment-504066
Refer to above, when I created Identity pages, I did not select all but only things that I wanted in the scaffoling options. As a result I did not have Account\Manage\Layout during scaffolding, did not have _Layout.cshtml file to override default view from AspNetCore.Identity.

Where is the default 'Login' view and corresponding controller in the template MVC Core application in VS2019

Odd one this, I must be missing something obvious but with a brand new MVC web application, with Authentication, it builds the DB migrations for the asp user tables and puts the _LoginPartial in _Layout etc. and login works fine, I can login and register etc but I can't find the view or code to alter it.
I navigate to localhost:blah/Identity/Account/Login and can login, but there's no view in the project that corresponds, there's an /Areas/Identity folder but it only has /Pages under it, no /Account and there's no Login.cshtml or anything called Account anywhere in the project.
Very odd, I keep thinking I'm just being dim and will look again tomorrow but have done that a few times. I've tried searching for it but only find false matches.
I've created a brand new application from the template a few times now thinking I somehow messed up the choices in the dialogues but it seems so basic - the view is obviously somewhere as it loads up and works fine, but where's MVC getting it view from, and where is the controller it's calling ??
Similarly, I search the project for some text on the page, eg. 'Use a local account to log in', both in VS and using grep on the entire source folder but it's not anywhere.
To fill out the answer to the question behind my question - i.e. how can I customise the login page. To generate the views and code in-project, right click on the Areas/Identity folder in the project, select 'Add' and 'New Scaffolded item...', select Identity and go from there.
Trying that generated an error for me, with a Core 2.2 project; but I retried in a virgin Core 2.1 solution and it worked OK, I then transferred the added folders and files to my 2.2 solution, changed the namespaces to match and I can now alter the login form and log in with it OK.
The account management function to change the phone number also works, so seems like it's all hooked up OK, I've not tried any of the other identify functionality as yet.
Thanks again to Nkosi for the answer.

How to add an external link under a page in Kentico?

We’re using Kentico 11.0.26 with MVC.
I need to add an external link under a page.
In content tree it should look something like this:
Page A
Page A1
Page A2
https://www.www.google.com/
The problem is that when I click the + button in Pages application, I only see page types, and there is no option to add a link.
Why not use value of page field to store the link and load the value inside of MVC app? Content tree alone does not have capability for this. All nodes have to be pages in one way or the other and plain old link to external domain can not be placed instead of page. To be honest I do not see benefit of having a link inside of content tree even for menu since you have to create menu using document path and not only its name anyway so accessing additional property should not be that much of a problem.
You could create a new content type to represent an external link and put that into your content tree. This would then also give you options to set additional properties of the link such as target and title rather than just a URL.

Make custom changes in admin generator

I develop a symfony 1.4 project,my issue with admin panel in backend,so I use the administration generator to do it.
I have a list of members generated automatically in backend,now Im hopping to add some custom action when a memeber edit her profile in backend,then I wish to add in edit page radio dial buttons give simple “Yes” or “No” Options. By default, the radial dial button is set to “No.” However, if the admin selects “Yes” then a popup window will come with the following text: “Are you sure you want to sell a new membership" and If the admin selects “Yes” and then saves the profile, a pop Window will need to display that reads: “New Membership sold"...
the problem is I can't change code because the form of edition page is generated using a plugin (sfguarduser) so It's deficult to make any changes?
Any Idea?
As the plugin documentation says, you can override the plugin module by creating a module with the same name in the application you want and by adding a require_once in the action.
As for your confirm and other javascript, you can override the generated partials by adding partials with the same name in your module, just as described here.

Sharepoint 2007 permissions needed to View webpart in page but not edit page?

I have the following scenario:
I have a list of custom items. Users with "Contribute" permission level can add and edit items on this list.
I created a blank webpart page, and added to the page a webpart to view the custom list.
The webpart page is stored on a "Pages" document library.
This works fine, except that I don't want contributors to mess with the webpart and modify the shared page. So in order to have "Modify shared webpart" link dissapear, I broke Inheritance on the Pages document library and set permissions of contributors to "Read only".
However, this does not work as expected and when users access the web part page, the whole webpart is not displayed.
I have troubleshooted the problem creating custom permission levels and the permission that is needed to the default "Read Only" level is the "edit items" permission on the Pages list.
However, this permission gives the user of editing the page and changing the webpart.
How can I achieve the correct permission set? I need to have the page as "read only" for most users, but still have them view the webpart (and add and edit items on the original custom list).
Thanks,
Manuel
Has the page with the web part been checked in, published, and approved?
It might not be a permissions issue, it could be that Read Only users are seeing the old, published version of the page (a version that does not contain the web part).

Resources