Hi Sander, I'm not sure to understand your sample. You talk about directive but your sample is "a starter controller" ? So to be more clear here is a Plunker http://plnkr.co/edit/ys1vms7u3SLx5a3DhYhc
As you can see I have 2 times a Div with modalbox, and some info attribute. But they are created directly, repplacing the div content. What I need is that nothing happend from the directive until the user click on the element and it will create the template content at the end of the body (not inside himself). I'm not sure if it's what a Directive is for. Like a standart JQuery/Mootools/Javascript modal box. Le mercredi 11 février 2015 17:48:22 UTC+1, Sander Elias a écrit : > > Hi Aimery, > > Yes you should make this into a directive, which you can then include once > in your view. > Here is a small sample > <http://plnkr.co/edit/tpl:480DsyCUkgvMsKYk7pyg?p=preview>to get you > going. It just shows the mechanics you need. I think you need to add 2 > things. > > 1. The directive to put the stuff you need in the view. > 2. A service to controll the content and the show/hide of 1 > > Is this enough to get you going? > > Regards > Sander > > > -- You received this message because you are subscribed to the Google Groups "AngularJS" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/angular. For more options, visit https://groups.google.com/d/optout.
