I take a look of the instruction from Adaptivetheme Gpanel doc and I was able to insert the given layout.

However, I want to insert a new Gpanel with my customize size such as : 25-75 or 70-30. Anyone has experience with version 3.x please help me? thanks.

Files: 
CommentFileSizeAuthor
#9 two_75_25.zip2.44 KBmariacha1
#3 two_25_75.zip3.6 KBcapellic

Comments

jenny.ciera’s picture

Priority:Critical» Major

anyone help me with this please?

capellic’s picture

Jeff -

Wondering if you're considering more layouts of the box. I thought I would ask before I dig into the code. I would love to see:

2. AT Two Column 25/75
3. AT Two Column 75/25

capellic’s picture

StatusFileSize
new3.6 KB

I went through the process of creating a plugin layout for my sub-theme. Here are the steps I followed along with the attachment of the end product. Would love some feedback on this.

--

In order to create the two_25_75 layout and the two_75_25 layout. These instructions are assuming the name of the sub-theme is called "base". In my case it's a AT Panels Everywhere sub-theme.

1. Copy the two_33_66 panel layout (themes/adaptivetheme/at_core/layouts/panels/two_33_66 to my theme in the layouts folder (themes/base/plugins/layouts/).

2. Rename layout folder name from two_33_66 to two_25_75.

3. Rename each of the files in the two_25_75 directory to follow the same naming scheme as the folder: two_25_75…

4. Open each of the files and do a find and replace "33-66" to "25-75" and "33_66" to "25_75". You will need to update some descriptive text in two_25_75.inc as well as the styles keys-- essentially where there is a 33 it needs to be a 25 and where there is a 66 it needs to be a 75. Be careful when doing this, I ended up with more than a view errors when attempting it.

5. There is some extra code at the bottom of the css file. I removed all but the first four lines -- not sure what this affects -- maybe Jeff can chime in here.

6. Modified the two_25_75.png file to look like 25/75.

7. After the renaming, I cleared the cache so that the layout is now selectable.

8. Then go to the Theme Appearance page (Layout & General Settings). Click on the Panels & Gpanels tab. The expand "Standard layout." Then expand "two." You will then see your new layout, "AT Two Column 25/75" I selected the first option and saved. I don't know what this bit really does -- maybe Jeff can chime in here.

9. I then assigned a panel variant to this new layout and reloaded the page that met the variant condition and viola-- it works!

Cebra’s picture

@capellic : It seems that you have forgotten something.

Or how does the theme know that there is a new custom gpanel? I used your files and put them into sites/all/themes/mytheme/plugins/layouts/... but Drupal doesn't recognize any new gpanel.

Thx

Cebra’s picture

There are some important information: How to include custom panels

gerontas’s picture

The final step is to uncomment the line in your theme.info file under
; Panels layout plugins

and be sure that it is pointing to the location where you have saved the new plugin.

derek smalls’s picture

This works great for 25/75, I was assuming i could reverse it to 75/25 but although i see the panel templates in panels and appearance i get

Notice: Undefined index: two_75_25_top in include() (line 29 of /var/www/html/sites/all/themes/mytheme/plugins/two-75-25.tpl.php).

derek smalls’s picture

Typo!!!

thanks for this...my two hours are now over!

mariacha1’s picture

StatusFileSize
new2.44 KB

Here's a modified version of #3 that puts the 75% on the left and the 25% on the right, in case it can save anyone else some time.

#3 worked great for me, once I followed the instructions in #6.

Diane Bryan’s picture

Thanks everyone! Bravo on creating this, mariacha1, derek, gerontas, capellic, etc.