Liferay 7.2 Edit Blog Entry Html - liferay

I have Lifeary 7.2
I found the way to edit the template of List of Blogs Entries but i don't find the way to edit the html or template of a single entry.
How can i do that?

You can't edit the single entity post html, because the template rules this for all posts.
Instead you can edit the specific blog content post, as html.

Related

How to make advanced CMS-like blog system from scratch?

When you create a news or blog tab with CMS it's really easy to make a feed of posts with content preview. Also when you follow a link to a particular post you can notice that it consists of a different html tags and css styling and not just plain text. It just uses rich text editor. So just getting text from db is not enough.
My question is how to achieve the same result when making a website from scratch. It doesn't matter what language is used for back-end. I'm just interested in the idea how to do it. But if you could provide a code examples (with any language) it would be greatly appreciated
Ok I've figured it out. Posting the answer for somebody who will have the similar question in the future.
The idea is that you need to put a text with html tags into your database and then to retrieve it you need to put it in your desired div in unescaped state. The thing is that almost all view (template) engines escape html tags by default. To do that you have to use some built in functions specific to that view engine.
To put the article with html tags in db you can just write raw html into input field or you can somehow add richtext editor to input field. Richtext editor will generate html for you.
I've researched it and found out that that's exactly how cms work.
So there you have it. If you want to add something feel free to do it

How to customize the HTML code of Content Query Web Part

I want to custom the output HTML code of CQWP and I do not want to see <table class="s4-wpTopTable">...</table>. But even I try to edit ContentQueryMain.xsl file by the help of this article:Customizing the HTML code of a Content Query Web Part, the table is still there.I can't even find any code generated the table which class is "s4-wpTopTable".
So ,I need some talent guy to tell me how to stop the CQWP to generate TABLE.
I have tried to set the Content Query Webpart's SuppressWebPartChrome to "True",but the table is still there, such a big problem.
I faced problems like you had and I decided to develop a web part that makes it easy to customize the look & feel of a portal. You can find detailed information about it here: Item Lister Web Part
If you want to customize the output HTML of CQWP,you should:
Insure your CQWP is NOT in the webpartzone, because the webpartzone will make the the SuppressWebPartChrome does not work for your webpart.
Insert your webpart to the page with the help of SPD,and then in the code view,you can change the SuppressWebPartChrome of CQWP to True(Defualt is False).
Look at the source code of your page,the <table class="s4-wpTopTable">...</table> is not there now, cool!
Anyother addtionnal code generated by sharepoint of the CQWP,you can custom it in your ContentQueryMain.xsl file, so you should learn the language--XSTL .Don't be afraid of it,it is so easy for you to learn in one hour.

What is the difference between include tags and embed tags in expressionengine?

The discussion forum module for expression engine uses {include:file} tags in its templates like in forum_themes/developer/forum_index/main_forum_list.html:
{include:table_heading}
{include:table_rows}
{include:table_footer}
I've searched for the include tag documentation but I can't find it anywhere? What is the include tag and when/where should it be used? Is it specific to the discussion forum module?
I cannot speak to the scope of the {include:file} tag but for most purposes the {embed} tag is what you will be using in ExpressionEngine to include/embed other bits of code.
Other alternatives, depending on the information you would like to include in your page, are the Snippets, Global Variables, or for more complex information LowVariables
Forums are quite difficult to customize and there is very little documentation but the include for forums essentially acts as an embed.
For customizing your forums I would recommend looking at using at the Scaffold Theme on Devot:ee
It should also be noted that {include:file} only work in the forum template code and most standard EE tags (such as the {embed} tag) don't work in the forum templates. Why? I don't know, but dems da rules. :)
There is no documentation on the {include:XXX} tag as it is only used in the Forum templates.
You will never use this tag in normal EE templates. In EE templates you will use an {embed="group/template"} tag or a Snippet depending on your needs.
In addition to embedding templates within each other, you can also create shared layouts for your templates. A layout can be thought of as a wrapping template or a reverse embed. To use a template you use the {layout=""} tag at the top of your template:
{layout="template_group/template"}

Manipulating BlogPost MetaData

After having followed the instructions to "unabridge" blog posts in Orchard, I'd now like to separate the blog post date and comment-count, so that the date appears ahead of the blog post, and the comment-count appears after. How would that be done?
Even better, I'd additionally like to have the comment-count be a hyper link to the blog post detail. How would that be done?
To do this and many other similar things, you should enable shape tracing (it comes as part of the designer tools module). This will show you what template is rendering what, and also where they are positioned. It will also tell you what templates you can create in your theme to override behavior. The Model tab in particular will show you the whole model object graph and will give you the expression to put in your template to include any property into your markup.

Working with Drupal views and theming views

I am new to drupal views. I know how to basically use views from from end i.e creating some views.
I wanted to know if i can create a view from my module and how do i theme a view that i have created.
Is there any clear ebook or something regarding this. I tried 1 book, But i felt it was not good explanation in it.
This is a fairly large subject. There are a lot of tutorials for Views & Panels out there.
Here's a link to the blog of the Views module author Angry Donuts, you'll find a link to the book he has written.
Have you checked drupal.org? You should find links to video tutorials and a lot of info about Views.
Is the question about theme views or programmatically create it? you can theme view by adding your own custom template for view, view field, view list, etc etc etc.
Now, create view or go edit some, at Basic settings, press Theme:information, and you'll see active template for each element of the view. So, you can copy required views template from views/theme folder to your_active_theme/templates, give it proper name (as written in Information pane), and press rescan in Theme: information.
After this, you should see your template highlighted.
That's actually it.
As for programmatic way of working with views, I suggest to create view via interface, and then call in in your module, and theme as you wish.
Please see this post for details.

Resources