Hi Zou,

>  Is the Right code for body Tag ?

No, I don't think this will work as it stands.

>  But I am not clear about what is the 'window' and 'load'.

The Window object is the highest level js object which corresponds
to the web browser window.  The 'load' is the argument that you are
passing into
the 'event' function,  corresponding to the type of event you are
attaching to.  If you want an
onclick event, you pass in 'click', for onblur->'blur' etc.  The
function
prepends it with 'on' depending on the type of browser that you have.

>  Is the part of onload event or what ? I can't find any refrence.

Hmm.  If you want to do it this way (there are a few ways to do this)
then the
body tag could just stay like this:

<body>

In your <head> (maybe) you should have a script tag or a call to a .js
with the following:


<script type="text/javascript">

// attach the event to the body tag and attach the doAjaxCall() to the
event
$javascript->event('window','load', 'doAjaxCall()', false);

function doAjaxCall () {
        
$ajax->remoteFunction(array("url"=>"/posts/load/","update"=>"posts_view","type"=>"asynchronous"));
}

</script>

I haven't tested this, so you'll probably need to play with it to get
it to work.
Hope this helps...

Cheers


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/cake-php
-~----------~----~----~----~------~----~------~--~---

Reply via email to