3
Answers

what is the problem in this simple sample?

Photo of Bahar Jalali

Bahar Jalali

12y
2.3k
1
i have one page for example to show an error!

when i use some URL from some websites, it has forbidden error!

how can i fix it?

please view this link


thanks

Answers (3)

0
Photo of Dharmraj Thakur
NA 4.1k 61.7k 7y
You have to show me your model and what type is returning from controller. For now you can try it using foreach loop.
  1. @foreach(var item in Model)  
  2. {  
  3.     if(item.Selected == "1")  
  4.     {  
  5.         //stuff          
  6.     }  

0
Photo of Altaf Ansari
NA 1.4k 27.4k 7y
Where you are defining "m" in
 
@if(m => m[i].Selected=="1") //errorline
 
Please define it first before using it..