TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Priyank Khare
NA
256
76k
menu item display according to condition
Oct 19 2012 1:53 AM
hello,
i've a menu list with some menu items... i wants to display only few items according to login ids..
for example:-
if anyone logins, then menu list have following menu items:-
home | news |love |action |wellness |family |business travel |fanclub | update credit | logout
but if someone dont want to login and go inside pages then menu list have following options:-
home | news |love |action |wellness |family |business travel |fanclub
i am doing following code but it gives error (
Expected ; or = (cannot specify constructor arguments in declaration)
) in following highlighted blue line :-
<body>
<div id="lr_bg">
<div class="top_menu">
<div class="ttop">
<div class="td_r"></div>
<div class="clear"></div>
<div class="loginposition">
<div class="fildbg">
<%-- <%
If Session("Login") = "log" Then
%>
<div class="login">
<a style="cursor:pointer;" id="dialog_LogOut" href="logout.aspx" ><font color="#18AAD2"><b>Log Out</b></font></a>
</div>
<%End If %>
--%>
</div>
</div>
</div>
<div class="logo"><a href="index.htm"><img src="maldievs/images/top/just-maldives-logo.png" alt="" /></a></div>
<div class="top_right">
<div class="pad_10">
<div class="td_l">
</div>
<div class="td_r"></div>
<%--
<div class="weather">
<div class="whead"> Maldives Weather</div>
<div class="wimage"></div>
<div class="wdesc">
<div class="pad_5">30 °C | 86 °F / Scattered Clouds<br />Humidity 70%</div>
</div>
<div class="clear"></div>
</div>
--%>
<div class="top_right1">
<!--<span style="padding-right:90px"><font color="#18AAD2"><i> Supported By</i></font> </span> </center> -->
<%--<span style="padding-right:60px"><font color="#18AAD2"><i> Supported By</i></font> </span> --%>
<span style="padding-right:60px; color:#18AAD2; font-style:italic; font-family:Verdana, Arial; font-size:11px; font-weight:normal"> Supported By</span>
</div>
<div class="top_right1">
<div style="vertical-align:text-bottom; float:left">
<!--<span><font color="#18AAD2"><i> Supported By</i></font> </span>-->
<br/><br/> <%--<a href="http://www.maldivian.aero" target="_blank"> --%><img src="images/screenshot.38.jpg" height="40px" width="220px" alt="" /><%-- </a>--%>
</div>
<div>
<a href="http://www.visitmaldives.com" target="_blank"> <img src="images/VisitMALDIVESlogo.jpg" alt="" height="100px" width="100px" /> </a>
</div>
</div>
<div class="clear"></div>
</div>
<div class="clear"></div>
</div>
<div class="clear"></div>
</div>
<div id="header">
<div id="menu">
<ul class="menu">
<li><a href="index.htm" class="parent"><span style="font-size:11px; font-family:Arial; font-weight:bold">Home</span></a></li>
<li><a href="CommingSoon.aspx" class="parent"><span style="font-size:11px; font-family:Arial; font-weight:bold">News</span></a>
<%-- <ul>
<li><a href="#" class="parent"><span>Travel</span></a></li>
<li><a href="#" class="parent"><span>Lifestyle</span></a></li>
<li><a href="#" class="parent"><span>Local</span></a></li>
<li><a href="#" class="parent"><span>International</span></a></li>
</ul>
--%>
</li>
<li><a href="CommingSoon.aspx" class="parent"><span style="font-size:11px; font-family:Arial; font-weight:bold">Love</span></a>
<%--<ul>
<li><a href="#" class="parent"><span>Travel</span></a></li>
<li><a href="#" class="parent"><span>Lifestyle</span></a></li>
<li><a href="#" class="parent"><span>Local</span></a></li>
<li><a href="#" class="parent"><span>International</span></a></li>
</ul>--%>
</li>
<li><a href="CommingSoon.aspx"><span style="font-size:11px; font-family:Arial; font-weight:bold">Action</span></a>
<%--<ul>
<li><a href="#" class="parent"><span>Travel</span></a></li>
<li><a href="#" class="parent"><span>Lifestyle</span></a></li>
<li><a href="#" class="parent"><span>Local</span></a></li>
<li><a href="#" class="parent"><span>International</span></a></li>
</ul>--%>
</li>
<li><a href="CommingSoon.aspx" class="parent"><span style="font-size:11px; font-family:Arial; font-weight:bold">Wellness</span></a>
<%--<ul>
<li><a href="#" class="parent"><span>Travel</span></a></li>
<li><a href="#" class="parent"><span>Lifestyle</span></a></li>
<li><a href="#" class="parent"><span>Local</span></a></li>
<li><a href="#" class="parent"><span>International</span></a></li>
</ul>--%>
</li>
<li><a href="CommingSoon.aspx" class="parent"><span style="font-size:11px; font-family:Arial; font-weight:bold">Family</span></a>
<%-- <ul>
<li><a href="#" class="parent"><span>Travel</span></a></li>
<li><a href="#" class="parent"><span>Lifestyle</span></a></li>
<li><a href="#" class="parent"><span>Local</span></a></li>
<li><a href="#" class="parent"><span>International</span></a></li>
</ul>--%>
</li>
<li><a href="CommingSoon.aspx" class="parent"><span style="font-size:11px; font-family:Arial; font-weight:bold">Business Travel</span></a>
<%-- <ul>
<li><a href="#" class="parent"><span>Travel</span></a></li>
<li><a href="#" class="parent"><span>Lifestyle</span></a></li>
<li><a href="#" class="parent"><span>Local</span></a></li>
<li><a href="#" class="parent"><span>International</span></a></li>
</ul>--%>
</li>
<%--<li><a href="#"><span>Wine & Dine</span></a>
<ul>
<li><a href="#" class="parent"><span>Travel</span></a></li>
<li><a href="#" class="parent"><span>Lifestyle</span></a></li>
<li><a href="#" class="parent"><span>Local</span></a></li>
<li><a href="#" class="parent"><span>International</span></a></li>
</ul>
</li>
<li><a href="#"><span>Lifestyle</span></a>
<ul>
<li><a href="#" class="parent"><span>Travel</span></a></li>
<li><a href="#" class="parent"><span>Lifestyle</span></a></li>
<li><a href="#" class="parent"><span>Local</span></a></li>
<li><a href="#" class="parent"><span>International</span></a></li>
</ul>
</li>
<li><a href="#"><span>Island Goers</span></a>
<ul>
<li><a href="#" class="parent"><span>Travel</span></a></li>
<li><a href="#" class="parent"><span>Lifestyle</span></a></li>
<li><a href="#" class="parent"><span>Local</span></a></li>
<li><a href="#" class="parent"><span>International</span></a></li>
</ul>
</li>
<li><a href="#"><span>Insiders</span></a>
<ul>
<li><a href="#" class="parent"><span>Travel</span></a></li>
<li><a href="#" class="parent"><span>Lifestyle</span></a></li>
<li><a href="#" class="parent"><span>Local</span></a></li>
<li><a href="#" class="parent"><span>International</span></a></li>
</ul>
</li>--%>
<li class="parent"><a href="CommingSoon.aspx"><span style="font-size:11px; font-family:Arial; font-weight:bold">Fan Club</span></a>
<%--<ul>
<li><a href="#" class="parent"><span>Travel</span></a></li>
<li><a href="#" class="parent"><span>Lifestyle</span></a></li>
<li><a href="#" class="parent"><span>Local</span></a></li>
<li><a href="#" class="parent"><span>International</span></a></li>
</ul>--%>
</li>
<%--<li id="idLogout" class="last" runat="server" >--%>
<%
If Session("Bookuserid") <> "" Then
If Session("UserType") = "OO" Then
Response.Write("<li id='idcredit' class='parent'>")
Response.Write("<a href='DefineCreditmain.aspx'><span style='font-size:11px; font-family:Arial; font-weight:bold'>Update Credit</span></a>")
Response.Write("</li>")
End If
Response.Write("<li id='idLogout' class='last'>")
Response.Write("<a href='Logoutvb.aspx'><span style='font-size:11px; font-family:Arial; font-weight:bold'>LogOut</span></a>")
Response.Write("</li>")
End If
%>
<%--<li id="idLogout" class="last" >
<a href="Logout1.aspx">
<span style="font-size:11px; font-family:Arial; font-weight:bold">LogOut</span>
</a>
</li>--%>
</ul>
</div>
<div class="clear"></div>
<div class="clear"></div>
</div>
</div>
</body>
please help me..
thank you.
Reply
Answers (
1
)
How to create dynamic menu by using entity framework using c#
livelock