Sitefinity / feather

mvc
Other
97 stars 68 forks source link

SfPlaceHolder inside a Partial #1846

Open elivnjak opened 9 years ago

elivnjak commented 9 years ago

Hi,

When I updated feather from v.1.2.140.2 to 1.2.220.1, the SfPlaceHolder's which were in my Partial file stopped rendering the widgets inside it. Its not being rendered in the pure MVC front end. The strange thing is when i go to edit the template or page the placeholder and widgets are showing.

Any idea what i could be doing wrong? This definitely worked fine in previous version i used (v.1.2.140.2).

Cheers, Edin

Boyko-Karadzhov commented 9 years ago

Hello elivnjak,

SfPlaceHolder can only be placed inside the actual layout file. The place holders are retrieved from the layout file by the page editor route handler without actually executing the Razor. Since 1.2.140.2 there was a big improvement on the way layouts are handled so that they can be truly dynamic when the actual rendering happens on the frontend.

Would you please give us more details on the scenario? How are the partials organized and used?

I will leave the issue in the backlog as a feature request. Any details will help with evaluating and specifying the task.

Thank you for the cooperation.

elivnjak commented 9 years ago

Hi Boyko,

Basically i'm using partials eg. @Html.Partial("~/ResourcePackages/ThemeFolder/MVC/Views/Layouts/Shared/_header.cshtml")

I do this so i can use that code across different layout templates therefore i'm not duplicating code.

Within the _header.cshtml file i had SfPlaceHolder that holds a menu widget.

Is there a different way i can achieve this without having to place the code literally within the sitefinity cms?

Cheers, Edin

ramo271285 commented 8 years ago

Hi,

There is any update on this issue??, becouse we have the same problem.

Regards,

Omar Amalfi

jhawver commented 8 years ago

I also am having this problem. How do you add content placeholders inside of partial views?

If this is not possible, then it would be very helpful if you could provide a tutorial on how to properly include a header/footer in your layout file.

selaromdotnet commented 8 years ago

can I get more information on this issue? Are you saying that prior to v1.2.220 it was possible to add placeholders to partials (such as a header) but after that it is no longer possible? is this still the case?

What specifically caused this behavior to break? Is there any workaround to enable placeholders in partials? If not is there any plan to restore this functionality?

thanks!

jmathur5 commented 7 years ago

I need help with this as well, I've been searching for a solution all day and still no help. Its November 30, 2016 and there is still no resolution for this ticket that was create over a year ago (May 27, 2015) :(

jhawver commented 7 years ago

I think this is a very, very useful and relevant request. How is it even possible using the MVC method to drag a menu widget into the shared site header that is used on literally every page? Currently, we have to hard code all of the menu links in HTML, which is basically unacceptable. A content manager should manage my content, plain and simple.

Please consider implementing this feature. And if you refuse, please explain potential alternatives and/or reason as to why. Thanks...

l3ender commented 7 years ago

I have recently started using Sitefinity and have also stumbled upon this shortcoming. An update or workaround would be greatly appreciated.

jmathur5 commented 7 years ago

@Boyko-Karadzhov as you can see this issue simply cannot be ignored anymore, and I highly recommended that you bring it up to management and prioritize it to top of the list for the next release. Our company is paying a ridiculous amount of money for this CMS and I agree with @jhawver, having the ability to create custom templates and use the CMS to modify content is THE MOST BASIC FEATURE that should come out the box, without any issues whatever. We know you're not responsible for pushing the code, but if you could please sympathize with us and get the right people to work on this, we would really appreciate it :)

svelik0v commented 7 years ago

Hi,

This problem have been moved to evaluation(checking possible fix paths) from the engineering team and is currently in status opened bug, here you can subscribe to the bug to receive notifications for changes in its status: https://feedback.telerik.com/Project/153/Feedback/Details/207089-sfplaceholder-inside-a-partialview-doesnt-render .

Once evaluated there will be more info on how this problem will be handled. If there are updates regarding this problem after evaluation I will followup with more info.

Regards, Stanislav Velikov Telerik by Progress.

ChristianMay21 commented 2 years ago

Pretty sad that this issue was brought up 7 years ago and still is not fixed.