Can jQuery or JavaScript code be used in partial views?
I have a grid in my partial view, and I'm trying to hide a single grid element using jQuery in this partial view. I can not do it. But the same code works if I use it without a partial presentation.
Can anybody help me?
Here is my code
<%@ Page Title="" Language="C#" Inherits="System.Web.Mvc.ViewPage<NascoBenefitBuilder.ViewModels.Obn.ProductTemplate.ObnProductTemplateMainData>" %> <script type = "text/javascript" language="javascript"> $(document).ready(function(){ alert("success"); }); </script>
This code is in my partil view, but when this page loads, I cannot pop up a warning in this window.
thanks
user300485
source share