I have a user control which has a linkbutton. On the link button click, I am redirecting to the default page. The default page uses this user control. I am trying to set the color of the linkbutton to purple, if visited. I think this is not working because of the page post back which is happening. Below is my code.
void LinkButton_Click(Object sender, EventArgs e)
{
Response.redirect("~/Default.aspx")
}
Css
.d:hover{
color:green;
}
.d:visited{
color:purple;
}
</style>
I don't think it is the css problem because when I hover, the color changes to green. The visited link color does not change. Is it because the page is being rendered again on the link button click? How would I fix this?