How do you get 2 different designs to talk to eachother?

Hi Guys,


I have a created a design for the Homepage which only needs to be for the website (lets call this design 1). I have also created a seperate design for the other standard pages (design 2).



Now i feel like im doubling on code in both designs, because design 2 contains the same code for the ‘banner’ as does design 1. Instead of doubling on the code, how do i get design 2 to use the ‘banner’ code from design 1? Also I want design 2 to use the same CSS file in design 1 instead of duplicating this.



Now on a static HTML page I would simply use a script that says

    


But as I asked that in another thread, mysource wouldn’t do this due to security reasons.



Cheers,

You could use a Nest Content design area in each design and store the banner code in a standard page asset. Then nest that into each design. Also, remember you can link CSS files anywhere – so the same file can be used in both designs.

Ok,


So the steps i would take is:


  1. Create Standard page asset
  2. Insert Banner code in standard page
  3. Insert nested content in design area that calls the standard page asset



    Am I on the right path?

Yes, exactly. Also, switch the standard page bodycopy to Raw Presentation and Raw HTML mode, so that the WYSIWYG doesn't try to "fix" your banner HTML.

how do i go about switching the standard page body copy to Raw Presentation?


In the Div Properties dialog box. You can see this by clicking the orange icon above the WYSIWYG editor. This dialog will allow you to switch to Raw presentation and Raw HTML mode.

thanks heaps!

Ok im having trouble calling the standard page:

    
    
    


what is: value="page file"?

Also in the Design Manual v3.8.0, there must be something missing it says 'An example nested content is given below:' and then theres nothing after it, just goes to another section.

In that example "page file" means that the nested content area can only nest assets based on Page or File types. You can safely remove that entire <MySource_SET> line though. Once you've created the design area, you'll need to target the Standard Page area you want to nest via a cusomisation.

I have another question regarding this matter.


When you create the Standard page for your RAW HTML code, are you supposed to create it under the 'Web Site' asset?

Because when I do, it adds the page title to the dynamic menu.


You don't have to -- I usually create a folder called "Nested Content" under the Designs folder for this stuff. Though, on the linking screen of the standard page, you can change the link type to TYPE_2 to make it disappear from the menu.

I've created the 'Nested Content' folder under the designs folder. But I can only add the customisation to a Design, not to the Standard Page. How would I target the Standard Page area I want to nest, with customisation?


Once you've created the customisation, you customise the nest content design area. On the details screen of this customised design area, you will be able to pick the standard page you want to nest into the customisation. You then apply the customisation to the site, as the System Defined Frontend Design.S

hmmmm still not working. I'll just explain to you what i've done, hopefully you can fill me in if i missed anything:

1. Created a 'Standard Page Design' asset in the design folder;

2. Edited the above parse file and added code of my template design. Also added the following for the nested content:
    
    


3. Created a folder under the Design Folder called 'Nested Content';

4. Created standard page in 'Nested Content' and titled it nest_content;

5. Changed the 'nest_content' page so it read as RAW HTML and added the following code:

    
This is a test


6. Created 'Standard Page Design Customisation' by right clicking on 'Standard Page Design' and clicking Customisation. Allowed customisation for Type: nest_content [b]Design Area:[/b] dme_banner via the settings.

7. Used the Settings on the standard page that i created earlier (step 4) 'nest_content' and added the 'Standard Page Design Customisation' as its front end design.

8. Chose the page that I wanted the design and nest content to be in (AboutMe) and applied the Standard Page Design to it as front end design.

9. Reloaded page AboutMe.

End result was no change, images are not there.

Two problems:

[quote]

    

This is a test

[/quote]



Standard Pages can’t render the mysource_files/ virtual location. You’ll have to change those urls to ./?a=XXX where XXX is the asset ID of the image. Matrix will automatically replace that with the most appropriate URL when it renders the page.


[quote]8. Chose the page that I wanted the design and nest content to be in (AboutMe) and applied the Standard Page Design to it as front end design.[/quote]



You need to apply 'Standard Page Design Customisation' as the frontend design. Then Matrix will paint the page using the configuration of the customisation.

I've done the above, and it didn't change anything. :frowning:


I'll try and fiddle around abit more. Is there anywhere in the manual i can read about this: ./?a=XXX


Not that I know of -- but the documentation authors probably know more. ;) It may be worthwhile for you to attend Matrix training (if possible), particularly the 201 System Administration and 330 Design courses.

Im so close!


I must of missed a step, this is what i did:



On the Details screen of the Standard Page Design Customisation screen, i clicked on the 'dme_banner' and it came to the Details screen of 'dme_banner'



Now at the bottom it has Link Nested Asset, so i linked it to the Nest_Content and it came up on the page with the red X in the box, meaning the path must be wrong. So its something to do with ./?=XXX



I would love to go to training, but its too expensive.


Look at the HTML source of the page and see what URLs Matrix is printing for those images. If there is no URL, you may need to check that the images you're linking to actually have URLs on their web paths screen. They need to be children of an asset that has a URL. If they're under the Media folder, make sure the folder has a URL on its URL screen.

From the HTML Source of the page it has:

    


So according to you it is hasn't got the URL.

The image '367' it has the following on the web paths screen:

[quote]Paths dme-left.jpg

Current URLs
http://lasun198.dnr.qld.gov.au/_designs/design_363/dme-left.jpg
http://lasun198.dnr.qld.gov.au/_designs/design_363/dme-left.jpg[/quote]

When you say Media Folder, I've got nothing there, all the images are in the Design Folder as child assets of 'Test Design'

Should my images be in Media Folder?