Intro page

Author Message

Michael Kress

Saturday 22 September 2007 2:31:42 pm

Hi,I'd like to create a flash based intro page which just tells the visitor "Hi, welcome, wait 30 sec and see some pics or click on [skip intro]".
Is there any method that you'd recommend me for this?

I would do it like this:
www.siteinquestion.com --> This is the intro page and forwards to
siteinquestion.com --> which is the ez publish installation.
This is not very elegant, but it should work.

Any ideas to make it more elegant?

Thanks
Michael

Felix Laate

Sunday 23 September 2007 6:44:01 am

Hi Michael,

I'm sure there are many ways to do this. I have done it 2 or 3 ways myself :-)

Why not try this approach:

1) create a class which you e.g. call intro. You need an name attribute, but nothing else.

2) somewhere in the content-structure create an object of this class

3) under override/site.ini.append.php do

# Which page to show when the root index is accessed
IndexPage=/content/view/sitemap/_NODE_ID_OF_OBJECT_YOU_CREATED_/

4) make sure the redirect links in your flash point to the main page

That's it!

Felix

Publlic Relations Manager
Greater Stavanger
www.greaterstavanger.com

Michael Kress

Monday 24 September 2007 1:05:05 pm

Hi, I created _NODE_ID_OF_OBJECT_I_CREATED_ of class (I called it) flashintro and I can see it, but what I don't understand: where do I upload the swf file and how do I embed it? With the method you described I just am able to fill in a name into the name field and that's it, no possibility to include my flash html code.
Greetings Michael

Felix Laate

Monday 24 September 2007 1:44:40 pm

Hi Michael,

sorry that my post was somewhat ncomplete. Two ways to do this:

1) use some logic in your pagelayout-template. e.g.

{if eq($module_result.node_id,_THE_NODE_ID_OF_YOUR_INTRO_)}
<object width="550" height="400">
<param name="movie" value="/path/to/your/introflash.swf">
<embed src="somefilename.swf" width="550" height="400">
</embed>
</object>
{else}

_YOUR_NORMAL_PAGELAYOUT_STUFF_

{/if}

2) make a new section with its own pagelayout-template which basicaly only shows your flash

Felix

Publlic Relations Manager
Greater Stavanger
www.greaterstavanger.com

Michael Kress

Tuesday 02 October 2007 2:39:35 pm

Hi Felix, thank you very much for your suggestions. I think I found quite an easy way, your {if} in pagelayout.tpl lead me to my solution which is as you said: certainly just one out of many.

{if eq($module_result.node_id,2)}{include uri='design:flashintro.tpl'}{else}<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
....
  pagelayout.tpl stuff
...
</body>
</html>{/if}

flashintro.tpl is just an ordinary HTML page which just contains the swf, nothing else.
So with this solution I don't use my old front page anymore. I created an item on main menu level called "home" and my flash forwards to the URL "home" (after 30 secs or with skip button), which will then be the main page for the rest of the visit.

Greetings
Michael

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.