The problem is that Cake interprets $f like a php variable.
I must use \$f to resolve the problem
On 7 Mag, 15:40, "Chris Hartjes" <[EMAIL PROTECTED]> wrote:
> On 5/7/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote:
>
>
>
>
>
> > Hi
> > I have this view:
>
> > <?php
> > echo $javascript->codeBlock("
> > function createNewArticle(id) {
> > var name = $F('sectionName');
> > alert(name);
> > }
> > ");
> > ?>
>
> > <input type="text" id="sectionName" size="25">
>
> > When I try this view with my browser I get this error:
>
> > Notice: Undefined variable: F in ......
>
> While this is not a CakePHP-related question, first thing you should
> do is make sure that Prototype is actually being loaded.
>
> --
> Chris Hartjes
>
> My motto for 2007: "Just build it, damnit!"
>
> @TheBallpark -http://www.littlehart.net/attheballpark
> @TheKeyboard -http://www.littlehart.net/atthekeyboard
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---