PDA

View Full Version : missed something with calljs/loadjs


OLBoris
10-31-2007, 06:29 AM
I am developing a Laszlo application that integrates into our existing CMS. The CMS includes a javascript based add deployment system. My HTML wrapper includes the javascript with the OAS_AD function. When I run the following code The ad appears but in the upper left hand corner "over" the other views. I need the ad to show up "in" the 'ad300' view.

<canvas width="740" height="300" >
<simplelayout axis="x" spacing="10" />
<view name="leftcol">
<simplelayout axis="y" spacing="10" />
<view width="430" height="250" bgcolor="#F8E496">
<text> Left Side here </text>
</view>
</view>
<view name="rightcol">
<view name="ad300" width="300" height="250" bgcolor="#EEEEEE">
<handler name="oninit">
var command = 'OAS_AD("300x250_1")';
LzBrowser.callJS(command);
</handler>
</view>
</view>
</canvas>

I have also tried several variations of LzBrowser.loadjs with no success. I'm sure I just need a syntax lesson here.

notzippy
11-01-2007, 11:48 AM
Im assuming your deploying to DHTML ?
What may be the problem is the way laszlo is building the component, you should be able to use the <html> component (inside the ad view) to point to the page with the javascript for the add..

OLBoris
11-05-2007, 04:59 AM
Thanks for your response. I tried using the HTML tag as well. The canvas is "inside" an HTML wrapper that includes other ad positions. All the ad positions are generated by the same javascript function. When I use the HTML tag it has no awareness of the Javascript function in the wrapper. I'm not having a problem getting the ad to display. The problem is in getting it positioned inside the view I set up for it.