Layout of Portfolio to another ContentType

brave's picture
brave
Mon, 04/18/2016 - 05:32
#1
Layout of Portfolio to another ContentType

I want to take over the portfolio template to another content type. Has everything worked except the Full Slider "Full white Slider" and "Full Hight Slider" are not displayed.

I have all the code now by and not find the clue where the mistake because the can not display are.

About Portfolio Type it works beautifully. Only I can not migrate all existing content on the portfolio, so I need the layout of portfolio to another ContentType

Can you help me?

phuonght's picture
phuonght
Sat, 04/23/2016 - 00:06

Hi,

Please

- create a new file which has name type as page--node--tyle--"name new content type".tpl.php in templates/page (similar to file page--node--tyle--portfolio.tpl.php). Note: code of your 2 sliders is from line 135 to line 170 file page--node--tyle--portfolio.tpl.php.


- go to file page.preprocess.inc lines from 254 to 256: print slider by added media in content type


copy these 3 lines, paste and customize base on your own content type.


- in templates/fields, field--field-multimedia--portfolio.tpl.php: structure of media content type

create a new similar file, name type: field--"name field media new content type".tpl.php (in new content type, machine name of field media)

phuonght's picture
phuonght
Tue, 04/26/2016 - 23:44

Please do not copy whole old file then paste to new one and you need to named file following content type to advoid conflicting with old portfolio (example: newcontent is beitrag so you need to rename $display_portfolio to $display_beitrag ). Also in file page.preprocess.inc, please replace line 206

 if ($node->type == 'portfolio') {

with

 if ($node->type == 'beitrag') {
phuonght's picture
phuonght
Thu, 04/28/2016 - 23:11

So please send us your site url and admin account by private comment. We would like to have a check in your site. 

brave's picture
brave
Tue, 05/03/2016 - 04:26

I would respectfully ask again if they have already found a fault?

cindy's picture
cindy
Tue, 05/03/2016 - 22:30

Hi Brave,

Sorry for the late respond,

We have just resumed our service from a 4-day holiday

Just working on your issue and feedback you at the soonest time

Thank you for your understanding and your patience

cindy's picture
cindy
Wed, 05/04/2016 - 06:13

Hi,

We need your FTP account also

Please send us

phuonght's picture
phuonght
Tue, 05/10/2016 - 00:00

Sorry,

We can not access FTP. Could you check?

Also, please:

Use F12, select header top place mobile in mobile version, you can see it is empty. It means page header second have not been rendered yet. You need to check file tpl of new content type and other page tpl files if code line "<?php print render($page['header_second']); ?>" exits in tag 
<div class="header_index">
</div>

phuonght's picture
phuonght
Thu, 05/12/2016 - 06:08

Never mind. We fixed problem for you. Check your site please. 

brave's picture
brave
Sat, 05/14/2016 - 02:48

Thanks it worked, I can grab the code in a js file? Many thanks for your help!

brave's picture
brave
Fri, 11/18/2016 - 07:29

I could also solve the problem in their demo. How can I solve the problem

Image title

Website http://demo.megadrupal.com/d7/md-make/portfolio-single-full-width

Log in or register to post comments
Have More Idea?

We are here to build your website!

No Universal solution fits all special business requirements. Our experienced team is ready with ideas and state-of-the-art technical solutions to consult the best solution within your budget.