I'm passing a list of files along with their directories to my Razor view. I have successfully managed to list them all to facilitate downloading however I have now been asked to organise them in an accordion style.
I am trying to use JqueryUi's accordion however it is proving difficult to implement it whilst using a for each to populate the links.
this is what I have thus far:
#foreach (var fullPath in Model)
{
var fileName = Path.GetFileName(fullPath);
var parent = System.IO.Directory.GetParent(fullPath);
string parentString = parent.ToString();
var downloadPath = #Path.GetDirectoryName(fullPath) + "\\" + #fileName;
string yearOne = Server.MapPath("~/Pdfs/YearOne");
string yearTwo = Server.MapPath("~/Pdfs/YearTwo");
<div id="accordion">
#*<h3>Year One</h3>*#
#if (parentString == yearOne)
{
<div>
<p>
<ul>
<li>#Html.ActionLink(fileName, "Download", new { path = downloadPath }) </li>
</ul>
</p>
</div>
}
#*<h3>Year Two</h3>*#
#if (parentString == yearTwo)
{
<div>
<p>
<ul>
<li>#Html.ActionLink(fileName, "Download", new { path = downloadPath }) </li>
</ul>
</p>
</div>
}
</div>
}
What's happening is, its placing the first record in the appropriate accordion section, then the rest are just listed below. Can anyone suggest how I might achieve this requirement within a for each?
The logic of finding which path is for year one and which is for year two could be moved into the controller. The corresponding model could be:
public class AccordionModel
{
public List<string> YearOne { get; set; }
public List<string> YearTwo { get; set; }
}
The view could be changed to:
#model AccordionModel
#functions {
string GetFileName(string path)
{
var fileName = Path.GetFileName(path);
return fileName;
}
string GetDownloadPath(string path)
{
var fileName = Path.GetFileName(path);
var parent = System.IO.Directory.GetParent(path);
string parentString = parent.ToString();
var downloadPath = Path.GetDirectoryName(path) + "\\" + fileName;
return downloadPath;
}
}
<div id="accordion">
#*<h3>Year One</h3>*#
<div>
<p>
<ul>
#foreach(var path in Model.YearOne)
{
<li>#Html.ActionLink(GetFileName(path), "Download", new { path = GetDownloadPath(path) }) </li>
}
</ul>
</p>
</div>
#*<h3>Year Two</h3>*#
<div>
<p>
<ul>
#foreach(var path in Model.YearTwo)
{
<li>#Html.ActionLink(GetFileName(path), "Download", new { path = GetDownloadPath(path) }) </li>
}
</ul>
</p>
</div>
</div>
Related
I am dynamically building a list based on data that is coming from my database
I am trying to make every list item clickable such that when one list item is clicked I can redirect to my controller "requistion" and enter the action in that controller "Details"
The list builds and displays successfully the only issue is that the list item itself is not clickable so I am not able to redirect to my controller and proceed with the rest of the logic
here is my code below)Please not that the code below is inside the _Layout.cshtml page
<div id="notifications">
<h3 class="notify"><b>Notifications</b></h3>
<div style="height:300px;">
<ul id="notiContent">
#if (ViewData["MessageList"] != null)
{
var viewDataProd = ViewData["MessageList"] as List<Notification>;
#for (var i = 0; i < viewDataProd.Count; i++)
{
#*<li class="notiContentLi"> <a asp-controller="Requisition" asp-action="Details" asp-route-id="#viewDataProd[i].RequisitionId"></a> #viewDataProd[i].Action</li>*#
#*<li class="notiContentLi"> <a asp-controller="Requisition" asp-action="Details" asp-route-id="#viewDataProd[i].RequisitionId"></a> #viewDataProd[i].Action</li>*#
<li class="notiContentLi"><a href='#Url.ActionLink("Details","Requisition",new{#viewDataProd[i].RequisitionId})'>click me </a>#viewDataProd[i].Action</li>
}
}
#if (GlobalVariables.messageList != null)
{
var viewDataProd = GlobalVariables.messageList as List<Notification>;
#for (var i = 0; i < viewDataProd.Count; i++)
{
#*<li class="notiContentLi">#c.Action<br /> </li>*#
#*<li class="notiContentLi" asp action>#viewDataProd[i].Action</li>*#
<li class="notiContentLi"><a href='#Url.ActionLink("Details","Requisition",new{#viewDataProd[i].RequisitionId})'> click me </a>#viewDataProd[i].Action</li>
}
}
</ul>
</div>
<div class="seeAll">See All</div>
</div>
You can add the onclick event to the <li> tag:
#for (var i = 0; i < viewDataProd.Count; i++)
{
<li class="notiContentLi" onclick="location.href = '#(Url.Action("Details", "Requistion", new { id = viewDataProd[i].RequisitionId }))'" >#viewDataProd[i].Action</li>
}
And the Details action method declaration in the Requistion controller is:
public ActionResult Details(int id)
{
// Add your action code here...
}
Adding route values and html attributes does the trick
var viewDataProd = GlobalVariables.messageList as List<Notification>;
#for (var i = 0; i < viewDataProd.Count; i++)
{
<li class="notiContentLi">#Html.ActionLink(#viewDataProd[i].Action, "Details", "Requisition", routeValues: new { #viewDataProd[i].RequisitionId }, htmlAttributes: new { target = "_blank" })</li>
}
Index.cshtml
...
<div class="card-columns">
#foreach (var yourElement in Model.YourElements)
{
<div class="card">
<div class="card-body"
onclick="location.href =
'/AnotherElementsPage/ByID/?ID=#yourElement.AnotherElement.ID'" >
<h6 class="card-title">#yourElement.Name</h6>
<h7 class="card-text">#yourElement.Description</h7>
</div>
</div>
}
</div>
AnotherElementsPage.cshtml
#page "{handler?}"
AnotherElementsPage.cshtml.cs
public AnotherElementsService AnotherElementsService;
[BindProperty(SupportsGet = true)]
public IEnumerable<AnotherElement> AnotherElements { get; private set; }
public void OnGet()
{
AnotherElements = AnotherElementsService.GetAnotherElements().ToList();
}
public void OnGetByID(Guid ID)
{
AnotherElements = AnotherElementsService.GetAnotherElement(ID).ToList();
}
I have created PowerShell scripts to fetch the active directory groups, when the webpage loads the group names fill into the dropdown list. The next thing I am trying to do is using the search button click event, load the group details into the text area and members into the table by passing the PowerShell scripts. I am using the library System.Management.Automation to deal with the PowerShell scripts. As I am dealing directly with PowerShell I don't want my project to depend on any model class. So, I am carrying out interaction between my controller & view only.
Controller Code:
using System.Web.Mvc;
using System.Collections.Generic;
using System.Text;
using System.Management.Automation;
using System.Linq;
using System;
namespace MyProject.UI.MVC5.Controllers
{
public class GroupController : Controller
{
//
// GET: /Group/
public ActionResult Index()
{
return View();
}
public ActionResult GroupReview()
{
ViewBag.Message = "Group Review";
ViewBag.Domains = PowerShellExecutorLst(AppDomain.CurrentDomain.BaseDirectory + "Shell\\Get-ADDomain.ps1");
ViewBag.Groups = PowerShellExecutorLst(AppDomain.CurrentDomain.BaseDirectory + "Shell\\Get-ADStewardGroups.ps1");
return View();
}
[HttpPost]
public ActionResult FillDetails(string GroupName)
{
ViewBag.SDC = PowerShellExecutorStr(AppDomain.CurrentDomain.BaseDirectory + "Shell\\Get-SDC.ps1 '"+ GroupName +"'");
return View();
}
// Fetching DropDownItems from Powershell Script Output
public List<SelectListItem> PowerShellExecutorLst(string scriptPath)
{
string outString = "";
var shell = PowerShell.Create();
shell.Commands.AddCommand(scriptPath);
var results = shell.Invoke();
if (results.Count > 0)
{
var builder = new StringBuilder();
foreach (var psObj in results)
{
builder.Append(psObj.BaseObject.ToString() + "\r\n");
}
outString = Server.HtmlEncode(builder.ToString());
}
List<string> result = outString.Split(new char[] { '\n' }).ToList();
List<SelectListItem> listItems = result.Select(s => new SelectListItem { Value = s, Text=s }).ToList();
shell.Dispose();
return listItems;
}
//Fetching String Values from Powershell Script Output
private string PowerShellExecutorStr(string script)
{
string outString = "";
var shell = PowerShell.Create();
shell.Commands.AddCommand(script);
var results = shell.Invoke();
if (results.Count > 0)
{
var builder = new StringBuilder();
foreach (var psObj in results)
{
builder.Append(psObj.BaseObject.ToString() + "\r\n");
}
outString = Server.HtmlEncode(builder.ToString());
}
shell.Dispose();
return outString;
}
}
}
View Code:
<h2>#ViewBag.Message</h2>
<div>
<div class="row">
<div class="col-md-12">
#Html.DropDownList("ddlDirectory", (IEnumerable<SelectListItem>)#ViewBag.Domains, "Select Domain", new { #class = "form-control" })
</div>
</div>
<div class="row">
<div class="col-md-12" style="width:auto">
#Html.DropDownList("ddlGroup", (IEnumerable<SelectListItem>)#ViewBag.Groups, "Select Group", new { #class = "form-control" })
</div>
</div>
<div class="col-md-2">
<div class="focus-link theme-bg-medium-blue reopen-shim">
<a class="arrow-link theme-bg-color" id="btnSearch" data-form-method="get" type="submit" style="width:auto;"
tabindex="14" onclick="">search</a>
</div>
</div>
<div class="col-md-2">
<div class="focus-link theme-bg-medium-blue reopen-shim">
<a id="btnReset" class="arrow-link theme-bg-color" data-form-method="get" type="submit" style="width:auto;" tabindex="15">reset</a>
</div>
</div>
</div>
#* Group Details to be filled*#
<div class="row">
<div class="col-md-4">
<div class="row">
<div class="col-md-12 lnkLabel">
Stewardship Information
</div>
</div>
<div class="row">
<div class="col-md-12">
#Html.TextArea("txtSDC",null, new { #class = "form-control", #rows = "7", #disabled = "disabled" })
</div>
</div>
</div>
<div class="col-md-4">
<div class="row">
<div class="col-md-12 lnkLabel">
Business Purpose
</div>
</div>
<div class="row">
<div class="col-md-12">
#Html.TextArea("txtBusinessPurpose", "This is the text Area Created for the Business Purpose of the group.", new { #class = "form-control", #rows = "6", #disabled = "disabled" })
</div>
</div>
</div>
</div>
#* Result Grid with the list of members *#
<div>
Code to fill data in HTML Table or WebGrid
</div>
In the scripts I am just using normal commands like get-ADUser & get-ADGroup, I need to pass the text of dropdown as a parameter in the FillDetails() controller function but how to load the details in the text area when click event occurs?
I am invoking the PowerShellExecutorStr function to fetch values in the FillDetails() function , I just want to load the values in the dedicated areas if possible using Viewbag.
Calling this script onClick event of Button in
#section scripts{
<script>
function GetGroupDetails()
{
$.ajax({
type: "POST",
url: "/Group/FillDetails",
data: { GroupName: $("#ddlGroup option:selected").text().trim()} ,
success: function (response) {
$("#txtSDC").val(response.message);
}
});
}
</script>
}
However, controller method needs to return Json result
public JsonResult FillDetails(string GroupName)
{
var SDC = PowerShellExecutorStr(AppDomain.CurrentDomain.BaseDirectory + "Shell\\Get-SDC.ps1 '" + GroupName + "'");
return Json(new { message = SDC }, JsonRequestBehavior.AllowGet);
}
I have two model classes,
public class Claims //Goes into main view
{
public int Id { get; set; }
public string ClaimName { get; set; }
public List<ClaimDetails> ClaimList { get; set; }
}
public class ClaimDetails //Class I want in my partial view
{
public int ClaimNumber { get; set; }
public string Client { get; set; }
public int Amount { get; set; }
public string Type { get; set; }
}
My controller,
public class ClaimsController : Controller
{
public ActionResult Index()
{
Claims claims = new Claims();
claims.Id = 1;
claims.ClaimName = "Ashton";
return View(claims);
}
[HttpPost]
public ActionResult SearchList(string enterdNumber)//On click of button I come here using ajax call
{
ClaimDetails cD = new ClaimDetails();
Claims cms = new Claims();
cms.ClaimList = new List<ClaimDetails>();
cD.ClaimNumber = 10;
cD.Client = "Ashton";
cD.Amount = 2900;
cD.Type = "Vendor";
cms.ClaimList.Add(cD);
ClaimDetails cDD = new ClaimDetails();
cDD.ClaimNumber = 10;
cDD.Client = "Ashton";
cDD.Amount = 2900;
cDD.Type = "Vendor";
cms.ClaimList.Add(cDD);
return PartialView("SearchList",cms);
}
My main view in which I want my partial view to be rendered,
#using BusinessLayer
#model BusinessLayer.Claims
#{
ViewBag.Title = "Index";
}
<script src="~/Scripts/jquery-1.10.2.min.js" type="text/javascript"></script>
<script src="~/Scripts/bootstrap.min.js" type="text/javascript"></script>
<div class="row">
<div class="col-md-6">
#Html.LabelFor(m => m.Id):#Model.Id
</div>
<div class="col-md-6">
#Html.LabelFor(m => m.ClaimName):#Model.ClaimName
</div>
</div>
<div class="row">
<div class="col-md-6">
<input id="searchNumber" placeholder="Enter the number" type="text" />
</div>
<div class="row">
<button id="searchBtn" type="button">Search</button>
</div>
</div>
<div class="row">
<div class="col-md-12">
#Html.Partial("SearchList",Model.ClaimList)
</div>
</div>
<script type="text/javascript">
$(document).ready(function () {
$("#searchBtn").on("click", function () {
var enteredNum = $("#searchNumber").val();
$.ajax({
type: "POST",
url: "/Claims/SearchList",
data: { enterdNumber: enteredNum }
});
});
});
</script>
My partial view,
#model BusinessLayer.Claims
<p>
#Html.ActionLink("Create New", "Create")
</p>
<table class="table">
<tr>
<th>Claim Number</th>
<th>Client</th>
<th>Amount</th>
<th>Type</th>
</tr>
<tbody>
#if (Model.ClaimList != null)
{
foreach(var item in Model.ClaimList)
{
<tr>
<td>#item.ClaimNumber</td>
<td>#item.Client</td>
<td>#item.Amount</td>
<td>#item.Type</td>
</tr>
}
}
</tbody>
</table>
My control comes to my partial view page, which I confirmed using breakpoint, it also iterates through the foreach loop but still does not put rows into my table..Help to know where I am going wrong is appreciated, or may be my approach to partial view is itself wrong?
You're returning a partial view but you're not doing anything with it. You need to include the success callback in the ajax function and add the partial view to the DOM
$.ajax({
type: "POST",
url: '#Url.Action("SearchList", "Claims")', // use this
data: { enterdNumber: enteredNum },
dataType: 'html', // add this
success: function(response) {
$('#someElement').html(response); // add this (adjust id to suit)
}
});
and assuming you want to update the existing partial, add an id attribute to the existing container
<div class="row">
<div class="col-md-12" id="someElement"> // add id attribute
#Html.Partial("SearchList",Model.ClaimList)
</div>
</div>
Side notes:
You may want to consider including the <table> and <thead>
element in the main view and have the partial only return the
<tbody> elements to minimize the data transfered in each ajax
call.
Your method appears to be just getting data based on a filter, so
the method could be a GET rather than a POST
I have what I think is a easy problem but for the life of me I cant figure it out. I have a form which imports many emails from a multi-line text box. From that import, I generate a report that tells the user the status of the imported emails and any errors. I can generate the report data fine, but cant seem to display the "Errors" field properly in the view. The problem appears to be, the editor template for the "Errors" field, is not being used. My question is, how do I get the view to use and render the editor template for the "Errors" field. I have tried using UIHint, but it doesn't work. Any help would be appreciated.
ViewModels.cs
//**************************Report View Models***************************************
public class ShowErrors
{
public string EmailAddress { get; set; }
public string ErrorDescription { get; set; }
}
public class ReportViewModel
{
public int TotalEmails { get; set; }
public int SuccessEmails { get; set; }
public int DuplicateEmails { get; set; }
public int InvalidEmails { get; set; }
[UIHint("ShowErrors")]
public virtual ICollection<ShowErrors> Errors { get; set; }
}
public static class ViewModelHelpers
{
//*************************ReportViewModel Helpers**************************************
public static ShowErrors ShowErrors_ViewModel_To_Domain(this ShowErrors item)
{
var showErrors = new ShowErrors
{
EmailAddress = item.EmailAddress,
ErrorDescription = item.ErrorDescription
};
return (showErrors);
}
}
Controller for the Report:(Dont think the problem is here, I can generate the data for the report, just cant display it properly.
public ActionResult Import_Report(EmailEditViewModel emailEditViewModel)
{
string emailAddress = null;
string[] emailArray = Request.Form["ImportEmails"].Split (new string[] { System.Environment.NewLine }, StringSplitOptions.None);
var entityModified = new EmailContact();
var reportViewModel = new ReportViewModel();
Regex regex = new Regex(#"^([\w\.\-]+)#([\w\-]+)((\.(\w){2,3})+)$"); //Regular Expression that checks email address is valid
List<ShowErrors> errorList = new List<ShowErrors>();
foreach (string item in emailArray)
{
ShowErrors errorItem = new ShowErrors();
emailAddress = item.Trim();
reportViewModel.TotalEmails += 1;
Match match = regex.Match(emailAddress); //Check email is in valid format
if (emailAddress == null || emailAddress == "")
{
reportViewModel.TotalEmails -= 1;
}
else if (!match.Success)
{
//Log this email as duplicate
reportViewModel.InvalidEmails += 1;
errorItem.EmailAddress = emailAddress;
errorItem.ErrorDescription = "Invalid Email";
errorList.Add(errorItem);
}
else if (_globalClasses.IsDuplicateEmail(emailAddress) > 0)
{
//Log this email as duplicate
reportViewModel.DuplicateEmails += 1;
errorItem.EmailAddress = emailAddress;
errorItem.ErrorDescription = "Duplicate Email";
errorList.Add(errorItem);
}
else
{
entityModified.EmailAddress = emailAddress;
entityModified.ActiveCampaigns = entityModified.Campaigns.Count(); //Calculates how many campaigns a contact is a member
try
{
db.EmailContacts.Add(_crypto.EncryptAndSanitizeEmailContacts(entityModified));
db.SaveChanges();
reportViewModel.SuccessEmails += 1;
AddOrUpdateEmailContacts(entityModified, emailEditViewModel.Campaigns); //Saves campaigns selected to this contact
db.SaveChanges();
//return RedirectToAction("Contact_List");
}
catch { }
}
}
reportViewModel.Errors = errorList;
return View(reportViewModel);
}
Here is the View:
#model HoltsCA.ViewModels.ReportViewModel
#{
ViewBag.Title = "Import_Report";
Layout = "~/Views/Shared/_LayoutDashboard.cshtml";
}
<fieldset>
<legend></legend>
<div class="row col-md-6">
<div id="bootstrapTableHeader" class="row">
<div class="col-sm-12">
<h2 style="text-align:center; color:#fff; font-size:1.3em;">Import Contacts Report</h2>
</div>
</div>
<div id="bootstrapTableRow" class="row">
<div class="col-sm-7" style="text-align:right">Total Emails:</div>
<div class="col-sm-5" style="text-align:left">#Html.DisplayFor(model => model.TotalEmails)</div>
</div>
<div id="bootstrapTableRow" class="row">
<div class="col-sm-7" style="text-align:right">Success Imported Emails:</div>
<div class="col-sm-5" style="text-align:left">#Html.DisplayFor(model => model.SuccessEmails)</div>
</div>
<div id="bootstrapTableRow" class="row">
<div class="col-sm-7" style="text-align:right">Duplicate Emails:</div>
<div class="col-sm-5" style="text-align:left">#Html.DisplayFor(model => model.DuplicateEmails)</div>
</div>
<div id="bootstrapTableRow" class="row">
<div class="col-sm-7" style="text-align:right">Invalid Emails:</div>
<div class="col-sm-5" style="text-align:left">#Html.DisplayFor(model => model.InvalidEmails)</div>
</div>
<div class="row" style="height:50px"></div>
<div id="bootstrapTableHeader" class="row">
<div class="col-sm-12">
<h2 style="text-align:center; color:#fff; font-size:1.3em;">Error Report</h2>
</div>
</div>
<div id="bootstrapAccentRow" class="row">
<div class="col-sm-6" style="text-align:left">
<b>Email Address</b>
</div>
<div class="col-sm-6" style="text-align:left">
<b>Error Description</b>
</div>
</div>
<div id="bootstrapRow" class="row">
#Html.DisplayFor(model => model.Errors)
</div>
</div>
</fieldset>
<p>
#Html.ActionLink("Edit", "Edit", new { /* id=Model.PrimaryKey */ }) |
#Html.ActionLink("Back to List", "Index")
</p>
Finally Here is the Editor Template ShowErrors.cshtml
#model ShowErrors
#using HoltsCA.ViewModels
<fieldset>
<div class="col-md-6" style="text-align:left;">
#Html.DisplayFor(model => model.EmailAddress)
</div>
<div class="col-md-6" style="text-align:left;">
#Html.DisplayFor(model => model.ErrorDescription)
</div>
</fieldset>
I think you are trying to display errors by using editor template. Put your error template inside DisplayTemplates folder under Shared folder.
If you are using #Html.DisplayFor then your template should be in the DisplayTemplates folder and similar logic while displaying editing template. To specify which template to use you can also do
#Html.DisplayFor(model => model.Errors, "ShowErrors")
Another thing is your model.Errors is a List<ShowErrors> and inside your display template you have just #model ShowErrors instead you should display it like IEnumerable<ShowErrors> and iterate in the template to show all the errors.
#model IEnumerable<ShowErrors>
#using HoltsCA.ViewModels
#foreach(var error in Model)
{
<div class="col-md-6" style="text-align:left;">
#Html.DisplayFor(error => error.EmailAddress)
</div>
<div class="col-md-6" style="text-align:left;">
#Html.DisplayFor(error => error.ErrorDescription)
</div>
}
That's not an EditorTemplate, it's a DisplayTemplate.
You just need to create a folder named "DisplayTemplates" under Views/Shared, and put the ShowErrors.cshtml partial view in the folder.
Your model is a List<ShowErrors> not a ShowError object.
You could change your view to this:
#model List<ShowErrors>
#using HoltsCA.ViewModels
#foreach(var error in Model)
{
<fieldset>
<div class="col-md-6" style="text-align:left;">
#Html.DisplayFor(error => error .EmailAddress)
</div>
<div class="col-md-6" style="text-align:left;">
#Html.DisplayFor(error => error .ErrorDescription)
</div>
</fieldset>
I wrote something like this in the controller.
public ActionResult Giris()
{
ViewData["Tarif"] = (from t in _entities.Tarif
join k in _entities.Kullanici on t.KID equals k.KID
select new {KAdi = k.KAdi, TAdi = t.TAdi})
.Take(4);
return View();
}
I am using it as below in the view page.
<% foreach (var item in (IEnumerable<dynamic>)ViewData["Tarif"]) { %>
<div class="begenilen-video" style="float:left">
<img class="video-resmi" alt="reklam" src="../../Uygulama/Resimler/Reklam/1.jpg" />
<span class="benzer-yemek-tarifi-adi"></span><%=item.TAdi %><br />
<span class="benzer-yemek-tarifi-ekleyen">Ekleyen: </span><br />
<span class="benzer-yemek-tarifi-izlenme">İzlenme: </span>
</div>
<% } %>
However,I am receive the error in the select statement.How do I invoke the items in the view page?
Thanks in advance.
As a guess because you haven't posted the error:
The object being stored in ViewData["Tarif"] will be of the type IQueryable<T> where T is an anonymous object and in your view you are casting to IEnumerable<dynamic>. IQueryable is also lazily loaded so you will be trying to execute your query once the object has been disposed.
You should really create a strongly typed view model
public class ViewModelType {
public IEnumerable<TarifType> Tarif { get; set; }
}
Tarif type
public class TarifType {
public string KAdi { get; set; }
public string TAdi { get; set; }
}
controller
public ActionResult Giris() {
var viewModel = new ViewModelType();
viewModel.Tarif = (from t in _entities.Tarif
join k in _entities.Kullanici on t.KID equals k.KID
select new TraifType { KAdi = k.KAdi, TAdi = t.TAdi }
).Take(4)
.ToList();
return View(viewModel);
}
view
<% foreach (var item in viewModel.Tarif) { %>
<div class="begenilen-video" style="float:left">
<img class="video-resmi" alt="reklam" src="../../Uygulama/Resimler/Reklam/1.jpg" />
<span class="benzer-yemek-tarifi-adi"></span><%=item.TAdi %><br />
<span class="benzer-yemek-tarifi-ekleyen">Ekleyen: </span><br />
<span class="benzer-yemek-tarifi-izlenme">İzlenme: </span>
</div>
<% } %>