Forums

Home » Liferay Portal » English » 3. Development

Combination View Flat View Tree View
Threads [ Previous | Next ]
Showing 1 - 20 of 22 results.
of 2
Sasha Firsov
what to modify in New blank theme which brakes layout
April 7, 2011 1:17 PM
Answer

Sasha Firsov

Rank: New Member

Posts: 6

Join Date: April 7, 2011

Recent Posts

Using fresh installation of tomcat bundle, Plugin SDK and Eclipse.
The new theme war file compiled and deployed, theme is listed.
Bugs:
- No preview image.
- Broken layout(CSS?) once theme is chosen.

The theme has nothing customized and once applied, shall be identical to default one.
For magic reason it did not happen. The styling is broken apart and blocks lost their width making one long list of items instead of rectangular blocks.

Q. What shall be done on freshly created theme project to make it identical to default?
By the book, nothing emoticon

Thanks,
Sasha
Mika Koivisto
RE: what to modify in New blank theme which brakes layout
April 7, 2011 3:57 PM
Answer

Mika Koivisto

LIFERAY STAFF

Rank: Liferay Legend

Posts: 1499

Join Date: August 7, 2006

Recent Posts

The default theme that comes from plugins sdk is based on _styled not classic. If you want to base your theme on classic (this is not recommended) you can change the base theme by editing build.xml of the theme plugin and set theme.parent property to classic like this:
1<property name="theme.parent" value="classic" />
Sasha Firsov
RE: what to modify in New blank theme which brakes layout
April 7, 2011 4:12 PM
Answer

Sasha Firsov

Rank: New Member

Posts: 6

Join Date: April 7, 2011

Recent Posts

Nor "classic" not "_styled" do not fix the issue. Layout still broken.

I would expect the freshly created theme to work immediately without any changes.
Obviously if no changes done, nothing should be changed after applying the theme.
Am I wrong in that expectation?

Definitely, the goal is modifying of this and that. But from working state and step by step. Issue is that there is no working start point.

May be I could take the source for one of existing themes and use it instead of SDK generated one? But than what is the point in generating of non-working project?

Could you recommend some theme which is closest to LifeRay default and could be used for incremental changes?

Thanks,
Sasha
Mika Koivisto
RE: what to modify in New blank theme which brakes layout
April 11, 2011 7:06 PM
Answer

Mika Koivisto

LIFERAY STAFF

Rank: Liferay Legend

Posts: 1499

Join Date: August 7, 2006

Recent Posts

It works for me in trunk and has worked in past with various EE and CE versions. Which LR version are you using? Does your plugins sdk match your portal version?
Sasha Firsov
RE: what to modify in New blank theme which brakes layout
April 12, 2011 2:12 PM
Answer

Sasha Firsov

Rank: New Member

Posts: 6

Join Date: April 7, 2011

Recent Posts

To make sure on clean PC I installed latest available SDK(liferay-plugins-sdk-6.0.5) and Tomcat bundles(liferay-portal-tomcat-6.0.6-20110225.zip )

The minor version mismatch is not a cause of problem. Same version has same issues with lost header layout.

liferay-plugins-sdk-6.0.6-20110225.zip
is not listed on LifeRay download page, need to get it from sourcefourge directly
Daniel Lipski
RE: what to modify in New blank theme which brakes layout
April 13, 2011 5:14 AM
Answer

Daniel Lipski

Rank: New Member

Posts: 3

Join Date: April 13, 2011

Recent Posts

I have the samee issue.
New liferay installation (liferay-portal-tomcat-6.0.6-20110225.zip)
New sdk installation (liferay-plugins-sdk-6.0.6-20110225.zip)

No matter if I develop & deploy new theme with Liferay IDE (Eclipe) or directly with Liferay SDK. Problem is the same.

Screenchots in attachments.

Regards
Daniel Lipski
Attachment

Attachment

Attachments: default_theme.PNG (50.3k), new_theme.PNG (47.6k)
Mika Koivisto
RE: what to modify in New blank theme which brakes layout
April 13, 2011 11:06 AM
Answer

Mika Koivisto

LIFERAY STAFF

Rank: Liferay Legend

Posts: 1499

Join Date: August 7, 2006

Recent Posts

The new theme looks like _styled. What value do you have in your build.xml for theme.parent? By default it is _styled and not classic.
Sasha Firsov
RE: what to modify in New blank theme which brakes layout
April 13, 2011 11:39 AM
Answer

Sasha Firsov

Rank: New Member

Posts: 6

Join Date: April 7, 2011

Recent Posts

As has been mentioned, NO changes have been done after theme generation. Hence _styled is in place. The screenshots above are identical to mine.

I have tried to play and use "classic" along with copy of classic theme from tomcat folder. Does not help significantly. Only workaround was to alter velocity files directly in tomcat.
But it breaks the theme as deployable module idea emoticon

Is there a working theme project which could be used as base instead of generated one?
7Cogs does not look like one.
Mika Koivisto
RE: what to modify in New blank theme which brakes layout
April 13, 2011 12:45 PM
Answer

Mika Koivisto

LIFERAY STAFF

Rank: Liferay Legend

Posts: 1499

Join Date: August 7, 2006

Recent Posts

Then in works just the way it is supposed to. _styled provides the minimal styling needed to get started with building your theme without you having to reset bunch of Liferay defined styles. Some theme designers even use _unstyled as their base because they want full control of how their theme looks like.

Now if you are like me not so good at styling you might want to start with an existing theme and just modify it slightly. You can do this by copying the custom.css of that theme and any extra images you need.
Sasha Firsov
RE: what to modify in New blank theme which brakes layout
April 13, 2011 1:02 PM
Answer

Sasha Firsov

Rank: New Member

Posts: 6

Join Date: April 7, 2011

Recent Posts

NO, it is not suppose to break layout.

WHAT exactly I need to place in this custom.css and what images shall be in place? Just to make it work and do not break layout. Tried to dig over docs. Nothing in this regard.

Plain empty custom.css does not help.
Mika Koivisto
RE: what to modify in New blank theme which brakes layout
April 13, 2011 1:53 PM
Answer

Mika Koivisto

LIFERAY STAFF

Rank: Liferay Legend

Posts: 1499

Join Date: August 7, 2006

Recent Posts

Try reading the theme development documentation here http://www.liferay.com/documentation/liferay-portal/6.0/development/-/ai/creating-liferay-themes-2. That should help you understand how to develop themes.
Ivano Carrara
RE: what to modify in New blank theme which brakes layout
August 15, 2011 11:21 AM
Answer

Ivano Carrara

Rank: Regular Member

Posts: 231

Join Date: July 2, 2005

Recent Posts

Hi all!

To start from the Classic Theme and then apply some changes to it, proceed as follow:

- execute create newtheme "New Theme" from the themes subfolder of theLiferay's SDK.
- in the _diff folder, copy the entire structure from <TOMCAT_HOME>\webapps\ROOT\html\themes\classic LESS the _diff folder

Then you do an "ant all" command to deploy the newtheme-theme that it is identical to the Classic theme, or import the new Theme in the Liferay's Eclipse plugin and start with your changes ...

I hope helps...

Ivano C.
Anonymous
RE: what to modify in New blank theme which brakes layout
August 16, 2011 2:18 PM
Answer

Anonymous

Instead of Editing the Classic Theme Directly you can edit the build.xml
SDK
----- clients
----- dist
----- ext
----- layouttpl
----- lib
----- misc
----- portlets
----- themes
----- docroot
----- build.xml
----- tools
----- webs

in the build.xml file change

<property name="theme.parent" value="_styled" />

to

<property name="theme.parent" value="classic" />

then ant deploy to your bundle. this will get all of the dependent files.

Hope that is what you wanted.
Anonymous
RE: what to modify in New blank theme which brakes layout
August 16, 2011 2:46 PM
Answer

Anonymous

Here is some css to get an "unstyled" Liferay Theme up and running
 1/* -------- Global -------- */
 2
 3#skip-to-content,
 4#heading .community-title,
 5#heading .page-title,
 6#navigation h1,
 7#navigation .child-menu,
 8#breadcrumbs {
 9    clip: rect(0 0 0 0);
10    height: 0;
11    margin: 0;
12    padding: 0;
13    position: absolute;
14}
15
16body {
17    background: #CCC;
18    font-family: Arial, Helvetica, sans-serif;
19    font-size: 12px/1;
20}
21
22#wrapper {
23    background: #FFF;
24    margin: 0 auto;
25    padding: 5px;
26    width: 960px;
27}
28
29/* -------- Sign-in / Navigation -------- */
30
31#sign-in {
32    position: absolute;
33    right: 0;
34    top: 0;
35}
36
37#navigation ul {
38    display: inline-block;
39    margin: 0;
40}
41
42#navigation li {
43    background: #DDD;
44    display: block;
45    float: left;
46    padding: 5px;
47}
48
49#navigation li a {
50    text-decoration: none;
51}
52
53/* -------- Web Content -------- */



https://gist.github.com/1150260#file_custom.css
Nagaraja Chokkavarapu
RE: what to modify in New blank theme which brakes layout
January 31, 2012 11:51 AM
Answer

Nagaraja Chokkavarapu

Rank: New Member

Posts: 5

Join Date: November 18, 2011

Recent Posts

I have the exact same issue. Added the attached custom.css. No use.

Any luck?

Thanks,
Nagaraja
archana thakur
RE: what to modify in New blank theme which brakes layout
May 18, 2012 2:49 AM
Answer

archana thakur

Rank: New Member

Posts: 18

Join Date: March 12, 2012

Recent Posts

I know about the actionUrl and renderUrl
But I want to know Where I can use exactly ?
when we go through actionURL and renderURL?
Ajeykumar HB
RE: what to modify in New blank theme which brakes layout
May 18, 2012 4:12 AM
Answer

Ajeykumar HB

Rank: Junior Member

Posts: 72

Join Date: March 12, 2012

Recent Posts

archana thakur:
I know about the actionUrl and renderUrl
But I want to know Where I can use exactly ?
when we go through actionURL and renderURL?


Hi Archana!..

There are three different types of portlet URLs:
1.Render URL —Used to ask a portlet instance to generate markup (like HTML,XML, WML) based on its current state. For example This URL you can use when if you want to go to next jsp page from current jsp page with out executing action class (linking hyper link etc). and also one more example if you want execute render method of action class you can use Render URL.

2.Action URL —Used for action processing, which results in a state change on the server. The request sent to the portlet by an action URL is referred to as an
action request. For example if you want to submit some form to action class or if you want process your request, you go for action URL. After completing the execution of action method, render method will execute once again.

3.Resource URL —Used to render content or retrieve resources (like image files).Depending upon the application requirement, a resource URL may be used for
updating application state. The request sent to the portlet by a resource URL is referred to as a resource request. For example if you want some resource from server like(Document or some download things) can go for Resource URL.

I hope so this may clear your doubt.
Hitoshi Ozawa
RE: what to modify in New blank theme which brakes layout
May 18, 2012 4:22 AM
Answer

Hitoshi Ozawa

Rank: Liferay Legend

Posts: 7990

Join Date: March 23, 2010

Recent Posts

SDK(liferay-plugins-sdk-6.0.5) and Tomcat bundles(liferay-portal-tomcat-6.0.6-20110225.zip )


First, you should be using the same version of sdk as liferay. You seem to be using liferay 6.0.6, so you need to use sdk-6.0.6.
Hitoshi Ozawa
RE: what to modify in New blank theme which brakes layout
May 18, 2012 4:26 AM
Answer

Hitoshi Ozawa

Rank: Liferay Legend

Posts: 7990

Join Date: March 23, 2010

Recent Posts

archana, if you have a new question, please create a new thread. You're making this difficult to follow by your new question which is unrelated to the original question.
Pradip A Bhatt
Not Overriding custom.css in _diff folder in theme
January 30, 2013 1:13 AM
Answer

Pradip A Bhatt

Rank: Junior Member

Posts: 51

Join Date: January 29, 2013

Recent Posts

I have tried so much but I am failed.

I am using Liferay 6.1.1 latest version and I am creating new theme.... But whatever code written in _diff/css/custom.css is not affecting...

What I have to do??
Showing 1 - 20 of 22 results.
of 2