掲示板

Link to Private Page

11年前 に Kushal Shah によって更新されました。

Link to Private Page

New Member 投稿: 3 参加年月日: 13/03/14 最新の投稿
I have created 1 site in liferay and also there is one page in it, When any user sign in and clicks on that page I want to show private page of that particular user.. Can any one help me?? Thanks in advance..
thumbnail
11年前 に Jitendra Rajput によって更新されました。

RE: Link to Private Page

Liferay Master 投稿: 875 参加年月日: 11/01/07 最新の投稿
Some thing like this ?

<a class="myhome" href="/user/$user.getScreenName()/home">My Home</a>
11年前 に Kushal Shah によって更新されました。

RE: Link to Private Page

New Member 投稿: 3 参加年月日: 13/03/14 最新の投稿
Hey, Jitendra thanks for replying emoticon Actually I am new in liferay, So can you tell me where to put this code?

I want to show all the portlets and settings which user did in his/her private page in to the welcome page of my site.
thumbnail
11年前 に Anil Sunkari によって更新されました。

RE: Link to Private Page

Expert 投稿: 427 参加年月日: 09/08/12 最新の投稿
Hi Kushal,

Actually the page which you created will be generated from navigation.vm. For reference you can cross check the current applied theme(classic) under the following location irrespective of server.


\...\ROOT.war\html\themes\classic\templates

and Code will somehow looks like the below and you have to restrict the line

<a href="$nav_item.getURL()" $nav_item.getTarget()><span>$nav_item.icon() $nav_item.getName()</span></a> with your rescpective page name/friendly url to perform whatever jitendra says.

<nav class="$nav_css_class" id="navigation">
<h1>
<span>#language("navigation")</span>
</h1>

<ul>
#foreach ($nav_item in $nav_items)
#if ($nav_item.isSelected())
<li class="selected">
#else
<li>
#end
<a href="$nav_item.getURL()" $nav_item.getTarget()><span>$nav_item.icon() $nav_item.getName()</span></a>

#if ($nav_item.hasChildren())
<ul class="child-menu">
#foreach ($nav_child in $nav_item.getChildren())
#if ($nav_child.isSelected())
<li class="selected">
#else
<li>
#end
<a href="$nav_child.getURL()" $nav_child.getTarget()>$nav_child.getName()</a>
</li>
#end
</ul>
#end
</li>
#end
</ul>
</nav>



Hope it surely helps you!!!

Regards,
Anil Sunkari
11年前 に Kushal Shah によって更新されました。

RE: Link to Private Page

New Member 投稿: 3 参加年月日: 13/03/14 最新の投稿
Hey thank you Anil it works, But I want only content of User's private page to be displayed on my site's welcome page. Can you tell me how to do that??
thumbnail
11年前 に Anil Sunkari によって更新されました。

RE: Link to Private Page

Expert 投稿: 427 参加年月日: 09/08/12 最新の投稿
HI Kushal,


For this you have to refer layout_ table for reference which stores portlets/layouts information.So that if will fetch while page renders.For you it will be having in user respective page records in layout_ entry....

Regards,
Anil Sunkari