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.

eZ debug

Timing: Jan 31 2025 06:00:10
Script start
Timing: Jan 31 2025 06:00:10
Module start 'layout'
Timing: Jan 31 2025 06:00:10
Module start 'content'
Timing: Jan 31 2025 06:00:11
Module end 'content'
Timing: Jan 31 2025 06:00:11
Script end

Main resources:

Total runtime1.4730 sec
Peak memory usage4,096.0000 KB
Database Queries63

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0058 588.0078151.1953
Module start 'layout' 0.00580.0025 739.203136.6016
Module start 'content' 0.00831.4639 775.8047958.7813
Module end 'content' 1.47210.0008 1,734.585915.8906
Script end 1.4729  1,750.4766 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00310.2099160.0002
Check MTime0.00120.0834160.0001
Mysql Total
Database connection0.00080.053210.0008
Mysqli_queries1.406395.4713630.0223
Looping result0.00070.0461610.0000
Template Total1.419096.320.7095
Template load0.00200.133220.0010
Template processing1.417196.204120.7085
Template load and register function0.00120.080010.0012
states
state_id_array0.00400.273210.0040
state_identifier_array0.00310.213520.0016
Override
Cache load0.00170.1140420.0000
Sytem overhead
Fetch class attribute can translate value0.00050.030820.0002
Fetch class attribute name0.00200.133760.0003
XML
Image XML parsing0.00240.163120.0012
class_abstraction
Instantiating content class attribute0.00000.001170.0000
General
dbfile0.00450.3087160.0003
String conversion0.00000.000540.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
5content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
6content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
11content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
2content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
3content/datatype/view/ezxmltags/literal.tpl<No override>extension/community/design/standard/templates/content/datatype/view/ezxmltags/literal.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 29
 Number of unique templates used: 7

Time used to render debug report: 0.0001 secs