掲示板

Asset Link Behaviour

thumbnail
14年前 に kamalkant rajput によって更新されました。

Asset Link Behaviour

Expert 投稿: 266 参加年月日: 08/04/10 最新の投稿
Hi ,
In asset publisher portlet under display setting we are having
Asset Link Behaviour in which 2 options are there ?? what is this second option
view in specific portlet
??
How we can use this option??

Thanks
KamalKant
14年前 に karla jett によって更新されました。

RE: Asset Link Behaviour

Junior Member 投稿: 35 参加年月日: 09/09/07 最新の投稿
When you click the link, the content page will be displayed in a specific portlet of your choice..
thumbnail
14年前 に kamalkant rajput によって更新されました。

RE: Asset Link Behaviour

Expert 投稿: 266 参加年月日: 08/04/10 最新の投稿
Hi Karla,
can you please guide me on this ??
Thanks
thumbnail
14年前 に Maarten van Heiningen によって更新されました。

RE: Asset Link Behaviour

Regular Member 投稿: 174 参加年月日: 09/02/05 最新の投稿
Hi,

Did you get this one to work? I want to set the 'view in a specific portlet' to view a web content article to view in a specified part of my page.

many thanks,
Maarten
thumbnail
14年前 に kamalkant rajput によって更新されました。

RE: Asset Link Behaviour

Expert 投稿: 266 参加年月日: 08/04/10 最新の投稿
Hi Maarten,
I am not able make it work but I did a work around. If u can tell ur requirements may be I can help u.
Thanks
KamalKant
thumbnail
14年前 に Maarten van Heiningen によって更新されました。

RE: Asset Link Behaviour

Regular Member 投稿: 174 参加年月日: 09/02/05 最新の投稿
Hi Kamalkant,

I've created a work around as wel. It's not a very good one (when upgrading liferay this has to be done again) but it does the job.

in the /root/html/portlet/asset_publisher/display directory there is a file title_list.jsp

On the line 173 there is '<a href="<%= viewURL %>">'

change this to:

<a href="<%= viewURL.replaceAll("0Cbk","l8vB") %>">

Where the link presenter asset_publisher instance is changed by the displaying asset publisher
This works when both are on the same page and for only two instances off the portlet.
If you also want to point from one page to a specific page, lets say news. You also have to do something like this

<%
String NewveiwURL = viewURL;
NewveiwURL = NewveiwURL.replaceAll("/home?","/news?");
NewveiwURL = NewveiwURL.replaceAll("qfW5","l8vB"); // instance on the homepage
NewveiwURL = NewveiwURL.replaceAll("0Cbk","l8vB"); // instance on the news page linking to thirt instance display on the news page
%>
<a href="<%= NewveiwURL %>">

In the configuration set the link presenter asset_publisher to displaying 'Titles' and not 'Full content'

Fairly simple and effective.

This is temporary as I hope the next release 5.2.4 will fix this issue.

Is your fix something like this?

Regards,
Maarten
thumbnail
13年前 に Raj K によって更新されました。

RE: Asset Link Behaviour

Regular Member 投稿: 214 参加年月日: 09/06/19 最新の投稿
Hi Maarten,

I am using a asset publisher in an IFrame using Liferay.Widget({.....})

<%= viewURL.replaceAll("fWd1","7PzV") %> works fine with an independent asset publisher portlet.

But I have embedded my asset publisher in a IFrame. Therefore viewURL.replaceAll does not work in this condition and I get a liferay UI error message -- 'You do not have the roles required to access this portlet.'

Please suggest how to solve this IFrame related issue.
13年前 に Matthias Fenz によって更新されました。

RE: Asset Link Behaviour

Junior Member 投稿: 79 参加年月日: 09/03/24 最新の投稿
hi guys,

for me, the problem is a bit more complex... maybe somebody has an idea how to solve this (no problem with an workaround):

i have three different types of pages:

home, news and several "specialized" news pages

different persons should enter their news only on "their" specialized page

-> all news titles shall be displayed on the "news" page
-> the related news should be displayed in the depending portlet on "home"

(to describe more clearly... it's for a football club, so i have section "tem news", "club news", "youth", etc... coach enters news in the section "team news", news title shall appear on the news page as on "home" in the portlet configured to show titles of "team news").

so far, so good.

the problem is, i'd like to link the title to the specific news page, in this example, when you click on an entry for "team news" on the "home" page, the entry won't be shown in this portlet, instead you should be warped to the specific news page ("team news" in that case), where the full content is shown...

anybody an idea how to solve this?

thanks in advance for every hint... emoticon
thumbnail
13年前 に KK rajput によって更新されました。

RE: Asset Link Behaviour

Expert 投稿: 266 参加年月日: 08/04/10 最新の投稿
Hi ,
How many asset publisher portlets you are having on that page on which you are showing full content.If you are having only one portlet then you can easily do it by following simple steps.
1.Get the layoutId of that page as you are having predefined pages that will not be the issue.For specific method check LayoutLocalServiceImpl.java.
2.Create the portletUrl e.g.
PortletURL portletURL = new PortletURLImpl(request, [$your_portlet_name$], [$layoutId_from_step1$], PortletRequest.RENDER_PHASE);
regionURL.setPortletMode(PortletMode.VIEW);
3.Onclick invoke url you have got in step 2.

HTH
KamalKant
thumbnail
13年前 に Manish Kumar Jaiswal によって更新されました。

RE: Asset Link Behaviour

Regular Member 投稿: 153 参加年月日: 08/11/25 最新の投稿
Does this (Asset Link Behaviour) works in 6.0.4...??????????
thumbnail
13年前 に Daniel Breitner によって更新されました。

RE: Asset Link Behaviour

Regular Member 投稿: 105 参加年月日: 08/07/16 最新の投稿
Hi, don´t know if you are still interested in a (possible) solution to your problem, but this might help:

http://liferay-blogging.blogspot.com/2010/12/how-to-create-link-to-webcontent-in.html

The URL you create you can enter in the title_list.jsp page.

With kind regards


Daniel Breitner