Oh my... I totally forgot this built-in javascript function because I never use it! :-S
thanks a lot! julien On 16 jan, 00:05, "b logica" <[EMAIL PROTECTED]> wrote: > On Jan 15, 2008 9:56 PM, Julien <[EMAIL PROTECTED]> wrote: > > > > > > > Hi, I'm very new to cake. > > > I'm currently doing the blog tutorial (http://manual.cakephp.org/ > > appendix/blog_tutorial). And I've noticed that in the index view there > > is no <script> tag, but when you click on a link to delete a post > > there is an alert that pops up with a warning. But I was looking for > > the javascript behind this and I did not find anyscripttag inside > > the page's html. > > So my question is : How on earth is this possible? I mean, to include > > some Javascript without ascripttag (!!!). > > In the <a> tag there is an onclick event in which there is a > > function : > > return confirm('Are you sure ?') > > > And I know that there is something to do with HtmlHelper, but again, > > I'm very new to Cake so I would be very interrested to know the answer > > for this enigma. :-S > > Noscripttag is necessary. All of the javascript is inline in the > tag. confirm() is a built-in javascript function. If it were, instead: > > a onclick="yourFancyConfirmFunction('Are you sure?');" ... > > and was working without anyscriptloaded, THEN you'd have an enigma. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~----------~----~----~----~------~----~------~--~---
