dynamic images as a banner

Author Message

Claudia Neu

Tuesday 10 January 2006 8:46:39 am

Hello,

is there a possibility changing images in a template depending on any action? I mean, if the user clicks at a buttom the banner image should change.

Must i code this dynamically or is it just a possible feature of ez Publish? It will be good having a destined image for every action.

Thank you in advance for your soon help.

Greetings

Tore Skobba

Wednesday 11 January 2006 1:21:51 am

Hi

If I understand you right then it is possible to with eZ with a small bit of template code, you can check out my own page if this is what you were thinking about:

http://www.skobba.com/about/about_me/(node_id)/155

Click the photos in the black banner beneath the large photo.

Cheers

Claudia Neu

Wednesday 11 January 2006 1:44:49 am

Hi Tore,

first thank you for a near solution.

I tried with
------------------------------------------------------------------------
{literal}
<script language="JavaScript">
var i= 1
function bilderTauschen1()
{
document.images[0].src="mal" + i +".jpg";
i++;
if(i==2)i=1
}
</script>{/literal}
-------------------------------------------------------------------------

but I guess thereĀ“s something wrong. Maybe the reason is Xhtml?

It should looks like the different images which change by click at the black menue buttons "Beratung" | "Veranstaltungen" | and so on at www.jdk.de

Thank you very much for your help.

Greetings

Claudia

Tore Skobba

Wednesday 11 January 2006 2:34:01 am

hmm but at www.jdk.de each information page probably has its own banner. If I was you then I would make an new customized class which had an banner image. Then with template code show the banner and the content. I do not know enough of Javascript technology in order to help you with image displaying with javascript

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 19 2025 00:31:48
Script start
Timing: Jan 19 2025 00:31:48
Module start 'layout'
Timing: Jan 19 2025 00:31:48
Module start 'content'
Timing: Jan 19 2025 00:31:50
Module end 'content'
Timing: Jan 19 2025 00:31:50
Script end

Main resources:

Total runtime1.9817 sec
Peak memory usage4,096.0000 KB
Database Queries60

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0069 587.9141152.6250
Module start 'layout' 0.00690.0040 740.539139.4453
Module start 'content' 0.01091.9693 779.9844477.9766
Module end 'content' 1.98010.0015 1,257.960912.1641
Script end 1.9817  1,270.1250 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00350.1777160.0002
Check MTime0.00140.0716160.0001
Mysql Total
Database connection0.00100.050810.0010
Mysqli_queries1.920696.9146600.0320
Looping result0.00080.0386580.0000
Template Total1.932897.520.9664
Template load0.00210.105920.0010
Template processing1.930697.423320.9653
Template load and register function0.00020.011210.0002
states
state_id_array0.00160.079910.0016
state_identifier_array0.00380.193520.0019
Override
Cache load0.00180.0883370.0000
Sytem overhead
Fetch class attribute can translate value0.00490.245920.0024
Fetch class attribute name0.00290.144040.0007
XML
Image XML parsing0.00020.012520.0001
class_abstraction
Instantiating content class attribute0.00000.000640.0000
General
dbfile0.00160.0803100.0002
String conversion0.00000.000640.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
4content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
5content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
1content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 12
 Number of unique templates used: 5

Time used to render debug report: 0.0001 secs