Zsolt Balogh 14 Anos atrás Nice article, thanks!Your example is not set to be layout-cacheable, so it will really drop performance, if you are using it on every page. Or the layout.static.portlets.all included portlets are always layout cacheable? Por favor, autentique-se para votar. Responda como... Cancelar
Jonas Yuan 14 Anos atrás Nice article. Thank you, Samuel!. Por favor, autentique-se para votar. Responda como... Cancelar
Milen Dyankov 14 Anos atrás Samuel, thanks for sharing this really useful information. The technique you describe was used in "Custom Global Markup Portlet" which allows to add markups (javascript, css, html) to every page in given community by providing convenient management interface in Liferay’s control panel. Por favor, autentique-se para votar. Responda como... Cancelar
Blaine Boule 13 Anos atrás This is a great idea, but I have one question. I have implemented this in our environment, to enable WebTrends internally. It is nice to be able to configure this as a portlet and have it show on every page, but I dont want the user to actually see the portlet. Is it possible to attain this functionality without actually showing the portlet to the user? Essentially the portlet is empty except for the script block, so we would want the portlet to be invisible to the user.Blaine Por favor, autentique-se para votar. Responda como... Cancelar Samuel Kong Blaine Boule 13 Anos atrás Blaine, make sure you do step 6. Por favor, autentique-se para votar. Responda como... Cancelar Blaine Boule Samuel Kong 13 Anos atrás Thanks for the suggestion, but I did make sure I added that step. I was unaware of the "system" tag at first, but once I added that and made it true, all it did was remove it from the "Add Application" Menu. Meanwhile the portlet was added to every page, via the portal-ext.properties - not a hook, and is visible to users. Side note, this is being deployed to 5.2.3Blaine Por favor, autentique-se para votar. Responda como... Cancelar Samuel Kong Blaine Boule 13 Anos atrás You need to add <use-default-template>false</use-default-template> to liferay-portlet.xml. Sorry for the confusion.I've also updated the blog with the change. Por favor, autentique-se para votar. Responda como... Cancelar Blaine Boule Samuel Kong 13 Anos atrás Ahhh, thank you for the clarification!Blaine Por favor, autentique-se para votar. Responda como... Cancelar
Samuel Kong Blaine Boule 13 Anos atrás Blaine, make sure you do step 6. Por favor, autentique-se para votar. Responda como... Cancelar Blaine Boule Samuel Kong 13 Anos atrás Thanks for the suggestion, but I did make sure I added that step. I was unaware of the "system" tag at first, but once I added that and made it true, all it did was remove it from the "Add Application" Menu. Meanwhile the portlet was added to every page, via the portal-ext.properties - not a hook, and is visible to users. Side note, this is being deployed to 5.2.3Blaine Por favor, autentique-se para votar. Responda como... Cancelar Samuel Kong Blaine Boule 13 Anos atrás You need to add <use-default-template>false</use-default-template> to liferay-portlet.xml. Sorry for the confusion.I've also updated the blog with the change. Por favor, autentique-se para votar. Responda como... Cancelar Blaine Boule Samuel Kong 13 Anos atrás Ahhh, thank you for the clarification!Blaine Por favor, autentique-se para votar. Responda como... Cancelar
Blaine Boule Samuel Kong 13 Anos atrás Thanks for the suggestion, but I did make sure I added that step. I was unaware of the "system" tag at first, but once I added that and made it true, all it did was remove it from the "Add Application" Menu. Meanwhile the portlet was added to every page, via the portal-ext.properties - not a hook, and is visible to users. Side note, this is being deployed to 5.2.3Blaine Por favor, autentique-se para votar. Responda como... Cancelar Samuel Kong Blaine Boule 13 Anos atrás You need to add <use-default-template>false</use-default-template> to liferay-portlet.xml. Sorry for the confusion.I've also updated the blog with the change. Por favor, autentique-se para votar. Responda como... Cancelar Blaine Boule Samuel Kong 13 Anos atrás Ahhh, thank you for the clarification!Blaine Por favor, autentique-se para votar. Responda como... Cancelar
Samuel Kong Blaine Boule 13 Anos atrás You need to add <use-default-template>false</use-default-template> to liferay-portlet.xml. Sorry for the confusion.I've also updated the blog with the change. Por favor, autentique-se para votar. Responda como... Cancelar Blaine Boule Samuel Kong 13 Anos atrás Ahhh, thank you for the clarification!Blaine Por favor, autentique-se para votar. Responda como... Cancelar
Blaine Boule Samuel Kong 13 Anos atrás Ahhh, thank you for the clarification!Blaine Por favor, autentique-se para votar. Responda como... Cancelar
Stephen Theriault 13 Anos atrás is there a way to it have it run just on the main page or on one page instead of every page Por favor, autentique-se para votar. Responda como... Cancelar Blaine Boule Stephen Theriault 13 Anos atrás Stephen - when we needed to do that (on a single page) we went into Manage Pages, selecting the page you wanted. Under the Page tab, at the bottom you see a "JavaScript" area you can click on, select that and you will get 3 input areas where you can place JavaScript code. That will load every time for that page. I don't know if this is the best practice method, but it is what we have used for this situation.Blaine Por favor, autentique-se para votar. Responda como... Cancelar
Blaine Boule Stephen Theriault 13 Anos atrás Stephen - when we needed to do that (on a single page) we went into Manage Pages, selecting the page you wanted. Under the Page tab, at the bottom you see a "JavaScript" area you can click on, select that and you will get 3 input areas where you can place JavaScript code. That will load every time for that page. I don't know if this is the best practice method, but it is what we have used for this situation.Blaine Por favor, autentique-se para votar. Responda como... Cancelar
(Você) 11 Anos atrás [...] Hi, I'm using Liferay EE version 6.1.10. I've been searching for a way to add my own custom Javascript (also include for external JS files) to every page in the portal. I want to have a way to add JS... [...] Read More Por favor, autentique-se para votar. Responda como... Cancelar
Alexey Bykov 9 Anos atrás Thank you, Samuel Kong! This article helped me. Por favor, autentique-se para votar. Responda como... Cancelar