Change OG metatags from Liferay portlet

StaNov

I want to change OG metatags based on request params. I use Liferay 6.0.6 and Spring Portlet MVC 3.1.2.

If user comes to URL example.com?param=value1, I want to set:

<meta property="og:image" content="/image1.png">

If user comes to example.com?param=value2, I want to set:

<meta property="og:image" content="/image2.png">

Liferay can set title, subtitle, description and keywords through PortalUtil. Can I set these OG metatags somehow similar?

milos.zikmund

Try to have a look at <liferay-util:html-top>. It's discussed e.g. here http://www.liferay.com/web/samuel.kong/blog/-/blogs/adding-a-javascript-to-every-page

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

From Dev

Liferay portlet doView() after redirect

From Dev

Generate link to Liferay root site from Portlet's JSP

From Dev

Creating a Liferay portlet configuration page

From Dev

Inserting a JavaScript resource into a Liferay Portlet

From Dev

Liferay portlet with freemarker and spring

From Dev

Liferay: Call JSON service from portlet

From Dev

How to add time to Liferay portlet

From Dev

Customizing liferay Calendar portlet

From Dev

How to refresh a liferay portlet?

From Dev

passing parameters to a liferay portlet

From Dev

Ajax not triggered in my Liferay portlet

From Dev

Liferay - Call a controller of a remote portlet

From Dev

Embedding jpg within Liferay Portlet

From Dev

Liferay Portlet-Servlet communication

From Dev

Placing an iframe inside of a Liferay portlet

From Dev

Creating a Liferay portlet configuration page

From Dev

Setting and Getting Portlet ID in Liferay

From Dev

liferay use service/class from ext plugin in portlet

From Dev

Liferay portlet configuration

From Dev

Liferay login portlet display text change

From Dev

Overloading web content Portlet in Liferay

From Dev

Existing project as a portlet in Liferay

From Dev

Customizing liferay Calendar portlet

From Dev

How to delete a portlet in Liferay 6.1 programmatically from code

From Dev

Liferay - change portlet column programmatically

From Dev

passing parameters to a liferay portlet

From Dev

Liferay Search Portlet Customization

From Dev

How to send sensitive data to a Liferay portlet from outside the Liferay portal

From Dev

how to redirect from jsp of one portlet to jsp of another portlet inside liferay module project in liferay 7

Related Related

HotTag

Archive