Questions tagged as 'mvc'

1
answer

Display ajax data returned by controller in view

Hello, I'm having difficulty displaying the data returned by the controller via ajax call My js is this: var requestList = $.ajax({ type:'GET', data:null, url:"index.php/Pages/loadComentarios" }); requestList.done(function(e)...
asked by 10.04.2018 / 05:43
1
answer

Write the user's Session / Cookie when signing in

In WEB applications, usually in the Login screen you have the Remind me option, this application will save the user data once it has checked the option. So when the user re-enters the site, instead of going to the Login screen, he will go...
asked by 31.01.2018 / 11:54
1
answer

Error while validating homepage after login / password

I have an access validation (Login / Password) that if true, should return to homepage, however I return the following error:    InvalidOperationException: RenderBody invocation in '/Views/Shared/_Layout.cshtml' is invalid. RenderBody can onl...
asked by 19.01.2018 / 20:34
1
answer

Return List in a View

Hello, I'm a beginner in C # and MVC and am having difficulty returning a list of data. I have the code below and I do not know how to return the data loaded from the list. Can anyone suggest me how to do this? Thanks public class EstoqueAca...
asked by 30.12.2017 / 02:05
1
answer

How to correctly split php code in mvc

I'm making a site for a college course and I have to split the code following the MVC standard. But I do not know very well PHP, I'm learning during the course so I wanted to know how to properly divide the code. I wanted to create a class ju...
asked by 16.12.2017 / 17:18
1
answer

end process

I have a dilemma here in my code a few days ago, I'm developing a routine that reads data from a spreadsheet and populates the data in the cshtml of the page, I'm programming in MVC5 with Razor. The code I created is: public ActionResult Index...
asked by 02.08.2017 / 17:16
1
answer

Register on more than one table with Laravel

So I have 3 tables (doctors, addresses and phones), first I insert into the table doctors using the store method that gets in its own controller, and I get the id created for it and insert into the other tables along with the other information. F...
asked by 02.07.2017 / 01:38
3
answers

How to anchor a redirect in APS.NET MVC

How can I send the user to a certain page block by passing the id in the url. For example: link , how to pass this type in ASP.NET MVC using return RedirectToAction . The line of my code looks like this: return RedirectToAction("Ind...
asked by 21.06.2017 / 22:09
1
answer

htaccess switch "_" to "-"

I have this code that I'm using in my MVC that I did for studies: class Como_Funciona extends Controller { public function __construct() { parent::__construct(); } public function index() { $data = [...
asked by 20.08.2017 / 17:23
1
answer

MVC 5 Ajax.ActionLink returns result, but does not render in DOM

Gentlemen, I'm having trouble displaying a list of results in my view. The idea is, when I click on a value from a dropdown, I make an asynchronous query to populate the next dropdown. I would refer to the controller by the Ajax.ActionLink me...
asked by 07.01.2017 / 18:56