This question is locked. New answers and comments are not allowed.
I'm new to Razor syntax and telerik MVC, but I am trying to get telerik controls to register the required javascript for a menu control using the following:
The out put is in the wrong location, it is is comming out before the HTML node and so the menu which looks great, does not actually work
<!DOCTYPE html>
<
html
>
<
head
>
<
meta
charset
=
"utf-8"
/>
<
title
>@ViewBag.Title</
title
>
<
link
href
=
"@Url.Content("
~/Content/Site.css")"
rel
=
"stylesheet"
type
=
"text/css"
/>
@(Html.Telerik().StyleSheetRegistrar().DefaultGroup(group => group.Add("telerik.common.min.css").Add("telerik.vista.min.css")))
<
script
src
=
"@Url.Content("
~/Scripts/jquery-1.5.1.min.js")"
type
=
"text/javascript"
></
script
>
<
script
src
=
"@Url.Content("
~/Scripts/modernizr-1.7.min.js")"
type
=
"text/javascript"
></
script
>
</
head
>
<
body
>
@RenderBody()
<!-- NOTE: Should render required JavaScript for view page -->
@{Html.Telerik().ScriptRegistrar().Render();}
</
body
>
</
html
>
The out put is in the wrong location, it is is comming out before the HTML node and so the menu which looks great, does not actually work
<
script
type
=
"text/javascript"
src
=
"/Scripts/2011.1.315/jquery-1.5.1.min.js"
></
script
>
<
script
type
=
"text/javascript"
src
=
"/Scripts/2011.1.315/telerik.common.min.js"
></
script
>
<
script
type
=
"text/javascript"
src
=
"/Scripts/2011.1.315/telerik.menu.min.js"
></
script
>
<
script
type
=
"text/javascript"
>
//
<![CDATA[
jQuery(document).ready(function(){
jQuery('#Menu').tMenu();});
//]]>
</
script
><!DOCTYPE html>
<!-- NOTE: The script has written before the HTML tag -->
<
html
>
<
head
>
<
meta
charset
=
"utf-8"
/>
<
title
>Administrator Home</
title
>
<
link
href
=
"/Content/Site.css"
rel
=
"stylesheet"
type
=
"text/css"
/>
<
link
type
=
"text/css"
href
=
"/Content/2011.1.315/telerik.common.min.css"
rel
=
"stylesheet"
/>
<
link
type
=
"text/css"
href
=
"/Content/2011.1.315/telerik.vista.min.css"
rel
=
"stylesheet"
/>
<
script
src
=
"/Scripts/jquery-1.5.1.min.js"
type
=
"text/javascript"
></
script
>
<
script
src
=
"/Scripts/modernizr-1.7.min.js"
type
=
"text/javascript"
></
script
>
</
head
>
<
body
>
<
ul
class
=
"t-widget t-reset t-header t-menu"
id
=
"Menu"
><
li
class
=
"t-item t-state-default"
><
span
class
=
"t-link"
><
img
alt
=
"image"
class
=
"t-image"
src
=
"/Content/Common/Icons/Suites/mvc.png"
/>ASP.NET MVC<
span
class
=
"t-icon t-arrow-down"
></
span
></
span
><
ul
class
=
"t-group"
><
li
class
=
"t-item t-state-default"
><
span
class
=
"t-link"
><
img
alt
=
"image"
class
=
"t-image"
src
=
"/Content/Common/Icons/Mvc/Grid.png"
/>Grid</
span
></
li
><
li
class
=
"t-item t-state-default"
><
span
class
=
"t-link"
><
img
alt
=
"image"
class
=
"t-image"
src
=
"/Content/Common/Icons/Mvc/Menu.png"
/>Menu</
span
></
li
><
li
class
=
"t-item t-state-default"
><
span
class
=
"t-link"
><
img
alt
=
"image"
class
=
"t-image"
src
=
"/Content/Common/Icons/Mvc/PanelBar.png"
/>PanelBar</
span
></
li
><
li
class
=
"t-item t-state-default"
><
span
class
=
"t-link"
><
img
alt
=
"image"
class
=
"t-image"
src
=
"/Content/Common/Icons/Mvc/TabStrip.png"
/>TabStrip</
span
></
li
></
ul
></
li
><
li
class
=
"t-item t-state-default"
><
span
class
=
"t-link"
><
img
alt
=
"image"
class
=
"t-image"
src
=
"/Content/Common/Icons/Suites/sl.png"
/>Silverlight<
span
class
=
"t-icon t-arrow-down"
></
span
></
span
><
ul
class
=
"t-group"
><
li
class
=
"t-item t-state-default"
><
span
class
=
"t-link"
><
img
alt
=
"image"
class
=
"t-image"
src
=
"/Content/Common/Icons/Sl/GridView.gif"
/>GridView</
span
></
li
><
li
class
=
"t-item t-state-default"
><
span
class
=
"t-link"
><
img
alt
=
"image"
class
=
"t-image"
src
=
"/Content/Common/Icons/Sl/Scheduler.gif"
/>Scheduler</
span
></
li
><
li
class
=
"t-item t-state-default"
><
span
class
=
"t-link"
><
img
alt
=
"image"
class
=
"t-image"
src
=
"/Content/Common/Icons/Sl/Docking.gif"
/>Docking</
span
></
li
><
li
class
=
"t-item t-state-default"
><
span
class
=
"t-link"
><
img
alt
=
"image"
class
=
"t-image"
src
=
"/Content/Common/Icons/Sl/Chart.gif"
/>Chart</
span
></
li
><
li
class
=
"t-item t-state-default"
><
a
class
=
"t-link"
href
=
"http://www.telerik.com/products/silverlight.aspx"
>... and 28 more!</
a
></
li
></
ul
></
li
><
li
class
=
"t-item t-state-default"
><
span
class
=
"t-link"
><
img
alt
=
"image"
class
=
"t-image"
src
=
"/Content/Common/Icons/Suites/ajax.png"
/>ASP.NET AJAX<
span
class
=
"t-icon t-arrow-down"
></
span
></
span
><
ul
class
=
"t-group"
><
li
class
=
"t-item t-state-default"
><
span
class
=
"t-link"
><
img
alt
=
"image"
class
=
"t-image"
src
=
"/Content/Common/Icons/Ajax/Grid.png"
/>Grid</
span
></
li
><
li
class
=
"t-item t-state-default"
><
span
class
=
"t-link"
><
img
alt
=
"image"
class
=
"t-image"
src
=
"/Content/Common/Icons/Ajax/Editor.png"
/>Editor</
span
></
li
><
li
class
=
"t-item t-state-default"
><
span
class
=
"t-link"
><
img
alt
=
"image"
class
=
"t-image"
src
=
"/Content/Common/Icons/Ajax/Scheduler.png"
/>Scheduler</
span
></
li
><
li
class
=
"t-item t-state-default"
><
a
class
=
"t-link"
href
=
"http://www.telerik.com/products/aspnet-ajax.aspx"
>... and 28 more!</
a
></
li
></
ul
></
li
><
li
class
=
"t-item t-state-default"
><
a
class
=
"t-link"
href
=
"#Menu-4"
><
img
alt
=
"image"
class
=
"t-image"
src
=
"/Content/Common/Icons/Suites/orm.png"
/>OpenAccess ORM<
span
class
=
"t-icon t-arrow-down"
></
span
></
a
><
ul
class
=
"t-group"
><
li
class
=
"t-item"
><
div
class
=
"t-content"
id
=
"Menu-4"
>
<
img
src
=
"/Content/Common/orm-comparison.png "
alt
=
"Telerik OpenAccess"
/>
<
a
id
=
"buy"
href
=
"http://www.telerik.com/purchase/individual/orm.aspx"
>
Telerik OpenAccess ORM
</
a
>
<
a
id
=
"express"
href
=
"http://www.telerik.com/community/license-agreement.aspx?pId=639"
>
Telerik OpenAccess ORM Express
</
a
>
</
div
></
li
></
ul
></
li
><
li
class
=
"t-item t-state-default"
><
span
class
=
"t-link"
><
img
alt
=
"image"
class
=
"t-image"
src
=
"/Content/Common/Icons/Suites/rep.png"
/>Reporting</
span
></
li
><
li
class
=
"t-item t-state-default"
><
span
class
=
"t-link"
><
img
alt
=
"image"
class
=
"t-image"
src
=
"/Content/Common/Icons/Suites/sitefinity.png"
/>Sitefinity ASP.NET CMS</
span
></
li
><
li
class
=
"t-item t-state-default"
style
=
"border-right: 0;"
><
span
class
=
"t-link"
>Other products<
span
class
=
"t-icon t-arrow-down"
></
span
></
span
><
ul
class
=
"t-group"
><
li
class
=
"t-item t-state-default"
><
span
class
=
"t-link"
><
img
alt
=
"image"
class
=
"t-image"
src
=
"/Content/Common/Icons/Suites/test.png"
/>Web Testing Tools</
span
></
li
><
li
class
=
"t-item t-state-default"
><
span
class
=
"t-link"
><
img
alt
=
"image"
class
=
"t-image"
src
=
"/Content/Common/Icons/Suites/win.png"
/>WinForms UI Controls</
span
></
li
><
li
class
=
"t-item t-state-default"
><
span
class
=
"t-link"
><
img
alt
=
"image"
class
=
"t-image"
src
=
"/Content/Common/Icons/Suites/wpf.png"
/>WPF UI Controls</
span
></
li
></
ul
></
li
></
ul
>
</
body
>
</
html
>