Quantcast
Channel: ActiveTopics
Viewing all articles
Browse latest Browse all 72689

Getting the ActionChild examples to work - help needed

$
0
0

Hi,

I'm new to Umbraco. Just started learning MVC and Razor, I want to add own "things" to the Umbraco CMS.

I've downloaded latest the latest source - 4.11.1. The projects will be edited with VS2012.

I had a closer look to the Documentation (the section Documentation on Our Umbraco), especially to Developer API Reference -> MVC -> ChildActions.

If I had understood that right, I can use ChildAction to render my own parts of code? Par examples I want to use my own MVC project, let's say, a simple form, where te user can input some text?

My questions are:

# What I have to do, so that i can use e.g. my own form in Umbraco? Which .dll i have to use for the controller class? This class has to inherit from SurfaceController, right?

I guess I have to write something like the following code into Umbraco -> Developer -> Scripting Files -> xyz.cshtml (Example-Code from the documentation site):

@Html.Action("SearchResults", "MySearch", 
    new { query = new QueryParameters(Request.QueryString["search"]) })

Does I have to write some @inherit or @using here? If so, which? And what does "MySearch" in the example code mean?

Further, if I take the example code from this site, where do i store it? In an umbraco folder or somewhere else?

If someone knows a link to a step-by-step example, i would be happy... At the moment the example-code is a mammut problem for me, because I don't know exactly what to do. Perhaps somebody might help me?

Hope my explainations and my englisch (not native) are understandable.

Thanks in advance for your help, Kai

 


Viewing all articles
Browse latest Browse all 72689

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>