|
< link href = "/css/jquery.autocomplete.css" rel = "stylesheet" type = "text/css" />
< script src = "/Scripts/jquery-1.4.1.min.js" type = "text/javascript" ></ script >
< script src = "/Scripts/jquery.autocomplete.js" type = "text/javascript" ></ script >
|
no it is not comming
i think it is not geting path of that jquery and css
here is the my url http://localhost:51912/Default.aspx
this page is comming fine
but this http://localhost:51912/products/97-a-dance-with-dragons.aspx is not comming
http://localhost:51912/category/53-arts-photography-and-design.aspx.
one more think can i call jquery in codebehind page using class file
like this
BindJQuery();
string superFishMenu = CommonHelper.GetStoreLocation() + "Scripts/jquery.superfishmenu.js";
Page.ClientScript.RegisterClientScriptInclude(superFishMenu, superFishMenu);
Page.ClientScript.RegisterClientScriptBlock(GetType(), String.Format("{0}_sfmenu", ClientID), String.Format("$(document).ready(function(){{$('#{0}').superfish({{autoArrows:false,speed:'fast',delay:200}});}});", ClientID), true);
///////////////////////////////
protected virtual void BindJQuery()
{
CommonHelper.BindJQuery(this.Page);
}
public static void BindJQuery(Page page)
{
BindJQuery(page, false);
}
public static void BindJQuery(Page page, bool useHosted)
{
if (page == null)
throw new ArgumentNullException("page");
//update version if required (e.g. 1.4)
string jQueryUrl = string.Empty;
if (useHosted)
{
jQueryUrl = "http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js";
if (CommonHelper.IsCurrentConnectionSecured())
{
jQueryUrl = jQueryUrl.Replace("http://", "https://");
}
}
else
{
jQueryUrl = CommonHelper.GetStoreLocation() + "Scripts/jquery-1.4.min.js";
}
jQueryUrl = string.Format("<script type=\"text/javascript\" src=\"{0}\" ></script>", jQueryUrl);
if (page.Header != null)
{
//we have a header
if (HttpContext.Current.Items["JQueryRegistered"] == null ||
!Convert.ToBoolean(HttpContext.Current.Items["JQueryRegistered"]))
{
Literal script = new Literal() { Text = jQueryUrl };
Control control = page.Header.FindControl("SCRIPTS");
if (control != null)
control.Controls.AddAt(0, script);
else
page.Header.Controls.AddAt(0, script);
}
HttpContext.Current.Items["JQueryRegistered"] = true;
}
else
{
//no header found
page.ClientScript.RegisterClientScriptInclude(jQueryUrl, jQueryUrl);
}
}
pls give some solution......
waiting any response...........plssssss...