Using EZ class where a script will be placed in page and then run...

Author Message

Richard Francken

Wednesday 23 March 2005 1:59:30 am

Hi,

On this moment I have a website with static pages. In HTML page I'm using java script.

In the head there are some includes of scripts and some standard functions.

In the body there are some scripts. Those scripts get content from a partner. The follow line is the most important:

document.writeln('<sc'+'ript language=javascript src="http://www.mobilemoney.biz/wizard2.asp?mmpart0_1=content&mmchar0_1='+getparam("mmchar0_1")+'&mmstart0_1='+getparam("mmstart0_1")+'&mmsection0_1='+getparam("mmsection0_1")+'&mmphonetype0_1='+getparam("mmphonetype0_1")+'&mmmoreinfo0_1='+getparam("mmmoreinfo0_1")+'&cat=0&choice1=1&rows=10&cols=2&hidesex=&refname=wmemotion&language=nl&sections=0&phones=&mmcountry0_1=&mmdisplaytype="></sc'+'ript>');

This documentwriteline is for every type of content different. I want to use EZ as my new CMS so I can easy manage new content. I'm looking a way that I can create a class in EZ with a property so I can place in the specific code. The results need to be that, if I select a page the page will be build up with the specific script in it and with the content from my partner.

I don't get it work. Is there any one who has experience with this?

Thanks a lot,

Richard

Ɓukasz Serwatka

Wednesday 23 March 2005 2:51:30 pm

Hi Richard,

That`s great that you want to use eZ publish in your project!

You can add "text filed" data type to your class which can be use to display plain xhtml code or you can use match[node] for template override and paste your code in to tpl file.

Personal website -> http://serwatka.net
Blog (about eZ Publish) -> http://serwatka.net/blog

Richard Francken

Thursday 24 March 2005 2:27:18 am

Hi Lukazs,

I'll work this out. Thanks.

Richard

Jonathan Dillon-Hayes

Monday 28 March 2005 2:54:38 am

Howdy!

Basically, you would put that javascript directly into an override template for the site.

It's the same as embedding an ad server script (which I assume is probably what you're trying to do).

If you're trying to pass around ad server stuff, I would HIGHLY suggest against embedding it for any kind of display. The best way is to manage it as an attached text file from your partners in eZ.

Jonathan

---------
FireBright provides advanced eZ deployment with root access
http://www.FireBright.com/

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 18 2025 16:05:26
Script start
Timing: Jan 18 2025 16:05:26
Module start 'layout'
Timing: Jan 18 2025 16:05:26
Module start 'content'
Timing: Jan 18 2025 16:05:26
Module end 'content'
Timing: Jan 18 2025 16:05:26
Script end

Main resources:

Total runtime0.0162 sec
Peak memory usage4,096.0000 KB
Database Queries3

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0058 589.3203152.6563
Module start 'layout' 0.00580.0027 741.976639.4922
Module start 'content' 0.00850.0052 781.468893.3047
Module end 'content' 0.01370.0024 874.773434.3047
Script end 0.0161  909.0781 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.003622.1522140.0003
Check MTime0.001610.0055140.0001
Mysql Total
Database connection0.00063.683410.0006
Mysqli_queries0.002314.447430.0008
Looping result0.00000.073810.0000
Template Total0.002112.810.0021
Template load0.00148.386610.0014
Template processing0.00074.406510.0007
Override
Cache load0.00106.394310.0010
General
dbfile0.00031.829980.0000
String conversion0.00000.038440.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 1
 Number of unique templates used: 1

Time used to render debug report: 0.0001 secs