-3
votes
0answers
39 views

Store content local for later use

I'm working in a development I'm wearing just get me with a challenge that had never before accomplished. I have an extremely complex form. Look at the attached image below: As shown in the ...
0
votes
0answers
23 views

Async add table rows

I want to include rows in a async fashion to speed up page loading and for better caching of the view fragments. Therefore I use hinclude.js to load the fragment asynchronously. The fragment just ...
1
vote
0answers
31 views

Symfony 2 : How to handle nested collections in forms

I am trying to create a form that contains nested collections. I don't know how to handle the JS part to display the children collection. Does anybody know how can I do that ? Here is the code of my ...
0
votes
0answers
26 views

twig escape('js') symfony2

got a problem... lets say i have article with content (content has html tags).. so: {{article.content|raw}} and it looks good.. problem is if user adds script tags.. so i try doing ...
0
votes
1answer
30 views

How to make the first radio button selected by default on a list of radios builded with a for in loop using twig

I'm using twig to make a list of radio buttons based on values from a Database. For that I'm using something like: {% for usermembershiptype in usermembershiptypes %} <div ...
0
votes
2answers
55 views

Symfony2 password encoder function in Javascript

I created a Symfony2 application using FOSUserBundle and FOSRestBundle. I'd like to connect other application with my Symfony application using rest api. I need to write the Symfony password encoder ...
0
votes
0answers
22 views

Symfony2 Collection fields with childs using Javascript

I'm trying to make a treeview collection with inputs inside a form. I can manage to create a "Add a Tag" button which creates a new input every time it's pressed, that's OK But what I need is create ...
0
votes
2answers
61 views
+50

Overriding a Method in Javascript

I have recently started using JsFormValidatorBundle to validate my forms on symfony. The only issue is that i need to send these forms with Ajax and unfortunately for some reason the ...
-1
votes
1answer
33 views

Cannot use Jquery with Symfony

I do not succeed in using Jquery with Symfony. For information I use Jquery link provided by google. in my twig file I have the following lines: <!DOCTYPE html> <html> <head> ...
-1
votes
1answer
55 views

How to access to a javascript variable inside another html.twig file in symfony2?

I would like to know how to access to a javascript variable inside another html.twig file in symfony2. Let's assume that we have two html\twig files: file1.html.twig and file2.html.twig, their codes ...
0
votes
2answers
33 views

Validate Symfony 2.5 form on client side (javascript - not only HTML5)

Does anyone know how to validate form on client-side using javascript. HTML5 validation it's not enough for me.
1
vote
1answer
24 views

Generate url with path twig function that doesn't meet the route requirements

I have fallowing Route defined: @Route("/photo/edit/{id}", name="gallery_photo_edit", requirements={"id" = "\d+"}) Since I have to make an Ajax request I need to generate it and put in JS code. For ...
0
votes
1answer
18 views

Where to put phantomjs script in symfony?

I want to run bash command phantomjs myAwesomeScript.js "www.example.com" from symfony service by using this line: $response = exec("phantomjs $scriptPath $arguments"); Where can I put my script ...
1
vote
2answers
30 views

symfony call controller action in javascript with id

Is it possible to call the controller action in javascript. I tried in the following way but it wont work $('#members').html({%render(controller('AmvMembersBundle:Pages:EditMembers'))%});
0
votes
1answer
75 views

javascript won't work when included

I have some weird problem with a javascript file. when I use it inside my html file, just by writing it within the script tags, it works just fine. but when I include it with this <script ...
0
votes
1answer
45 views

knp snappy bundle, generate pdf from a dinamically modified twig

I'm trying to generate a pdf from a twig that's modified in the client side. To do so I'm sending the html document to the server through AJAX but that's not possible since I'm receiving a binary ...
3
votes
0answers
56 views

Randomly very long cross domain ajax request with Symfony2

I have two subdomains client.domain.com and server.domain.com The client is just a index.html with a simple jquery ajax POST request. $.ajax({ url: 'http://server.domain.com/upload', type: ...
0
votes
2answers
39 views

How to access to a javascript function inside another html.twig file in symfony2?

I would like to know how to access to a javascript function inside another html.twig file in symfony2. Let's assume that we have two html.twig files: file1.html.twig and file2.html.twig . Let's also ...
0
votes
1answer
38 views

render template via service[Symfony 2]

I am working on custom bundle in symfony2. I am new in symfony2. My task is to load a javascript on all pages of website. I looked on tutorials and found out it can be done by creating a service. I ...
0
votes
0answers
33 views

Disqus with my own User Database

First of all, i want to ask if i can login to disqus with my own user db? I think we can do? I don't know what else can i do. I'm totally stuck now. I know i have to use SSO ...
0
votes
2answers
38 views

How to display alert or info messages in Symfony2 after a server response without reloading the page

I am building an admin application for opticians with Symfony2. When the admin adds a new customer to the database, my controller checks if the customer name is duplicate or not. I want to display a ...
0
votes
1answer
51 views

how to display to a html twig form field value through javascript using an alert message in Symfony2?

I would like to know how to display to a html twig form field value through javascript using an alert message in Symfony2. This is the form code: <html> <head> ...
0
votes
2answers
58 views

how to access to a html twig form field value through javascript in Symfony2?

I would like to know how to access to a html twig form field value through javascript in Symfony2. The explanation is as below: This is the screen shot of the form that I have: This is the form ...
0
votes
3answers
59 views

How to do something before form submission without using preventing default

my question is how can i do something before form submission witout doing e.preventDefault(); ? i have a situation where i got two form buttons and before form submission i want set hidden field ...
1
vote
1answer
39 views

symfony2 http 403 error (access denied) for CSS file localhost?

I've generated backup of a website has symfony2 CMS when i extracted it on my localhost its worked fine but (css/js/images) not working its like the bundles need to rebuild again right ? i am using ...
1
vote
2answers
35 views

How to give the datas from eventSources to the EventListener

I'm loading an EventListener used for FullCalendar for each calendar on my website. The problem is that sometimes I need to change the "method" of rendering events (depending on the URL). I would like ...
1
vote
1answer
25 views

Populate a Symfony form row with a table row index

I'm facing a stupid issue there but I'm sure it would be easy for you, master of javascript ! Here is my symfony form : $form = $this->createFormBuilder() ->add('accept', ...
0
votes
1answer
46 views

How can I autoloading Bower dependencies like with Composer?

With Composer I can simply autoload vendors, can I autoloading bower components in my HTML page like Symfony framework autoload with Composer? I need to autoload next dependencies from bower.json: ...
0
votes
2answers
32 views

Twig include Javascript

I want to include (yes include) some js file into a big js with Twig but from another directory. I explain. This is my organisation : AcmeBundle/ Script/ blabla1.js blabla2.js ...
1
vote
1answer
48 views

What are the options for managing controller-specific javascript in symfony2?

I understand the general concept of assetic, which makes sense for site-wide script resources, but what about the javascript that is specific to one page or controller? How do you structure those, ...
0
votes
1answer
59 views

Return confirm cancel button not working

I have this link in twig : <a href="{{ path('relation-delete', {'id': c.getCustomerId}) }}" onclick="return confirm('{% trans %}relation.delete{% endtrans %}');" class="tip" ...
0
votes
1answer
37 views

How to change Flash message in Alert message in Symfony2

I am stuck in a problem, that after execution of a action method in Symfony2 Controller , success message is come as in the form of flash message , but as per requirement i have to render these ...
0
votes
1answer
19 views

Twig javascript path with id

I normally use this peace of code. <a href="{{ path('person_edit', {'id': 0}) }}' + document.getElementById('person_search').value;"> Goto item </a> Which will generate correct url ...
1
vote
1answer
40 views

Symfony2: how to exclude 1 js asset file?

By default, all my scripts are loaded into the head section, and inside the folder js/. but, I want one of the script files not to be loaded with the others. How to exclude this file? Code ...
0
votes
0answers
59 views

Conflict jQuery with Bootstrap in symfony2

I have problem with jquery and bootstrap in my project which I am writing in Symfony 2. <script src="{{ asset('//ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js') ...
1
vote
0answers
70 views

Symfony2 and jquery checkbox

I want to use checkbox with symfony2. I want to update a field value in a table (0/1) dynamically using the checkbox value. Here is my wrong code : index.html.twig : <div class="slider demo" ...
0
votes
0answers
41 views

How can jTable work with Symfony 2?

I created a Datagrid with jTable, here is my JavaScript code in twig: <script type="text/javascript"> $(document).ready(function () { jQuery('#grid').jtable({ title: ...
0
votes
0answers
33 views

Fullcalendar passing options to listener

I'd like to add subviews of calendar in the fullcalendar. I explain : I'd like to let a user select with checkboxes some of his items ( that would be load in ajax ) and get events only from those ...
0
votes
2answers
20 views

How to generate a route without question mark on FOSJSRoutingBundle

Im confused, this is the documentation https://github.com/FriendsOfSymfony/FOSJsRoutingBundle/blob/master/Resources/doc/index.md documentation -> Routing.generate('my_route_to_expose', { id: ...
0
votes
1answer
40 views

Setting Value of Input OnSubmit using JQuery in Symfony

I am trying to set a onsubmit function that will use the google.maps.Geocoder to set the gps positions using the address entered by a user, my code is the following <form ...
0
votes
1answer
65 views

AngularJS, ngResource - Unexpected token Error

EDIT: I got the mistake but no solution. It seems that 'isEditable', 'isOnline' and 'isRecycled' are not sent as booleans but as strings. Therefore my Validaton did not pass and the Error-Response ...
0
votes
0answers
39 views

Symfony2: Form Collections, macro and jquery

I have this form <?php namespace ADS\LinkBundle\Form; use Symfony\Component\Form\AbstractType; use Symfony\Component\Form\FormBuilderInterface; use ...
0
votes
1answer
36 views

Symfony2 highcharts, change color

I'm using this bundle https://github.com/marcaube/ObHighchartsBundle for create some charts with Symfony2. I have created a pie chart but i don't know how can i change the color of a part ? you can ...
0
votes
1answer
52 views

How to stage data for Google Charts in Symfony?

I have been stuck on this for some time now: In my Symfony application I want to retrieve some data from the database and build a Google Chart with it. It seems to me, though, that I cannot produce ...
0
votes
0answers
52 views

How to access store from other controller in ExtJS 4.2.2

I'm developing an application which is build in ExtJS 4.2.2 with symfony2 backend. Now I have following problem : Lets say that I have 2 mvc's in my frontend - One for managing users and other for ...
0
votes
1answer
35 views

Can I create a Symfony form submission, entirely in the controller?

I have a Symfony FormType including some onPostSubmit actions in an Event Listener. The form is for uploading an image. I want to have additional functionality where instead of upload an image from ...
0
votes
2answers
32 views

symfony2 how to access twig path by javascript

In symfony2, this works fine in the html.twig file: <a class="btn brl-next brl-btn" href="{{ path('new_message') }}">Next</a> but currently, i need to access path('new_message') by ...
0
votes
2answers
75 views

How to switch an active link?

I'm using symfony2 (MVC framework) and Twitter Bootstrap v3.0.0. I'm trying to switch the class"active" everytime I click on a link. I tried many jquery solutions, the best one doesn't load the page. ...
0
votes
0answers
45 views

Firefox: very slow download of 9th request

In my example.localhost I have lots of requests for css and js files (during development). For some reason, if there are 9 of them, the last one crawls. Ie: first connection is to fetch html itself, ...
0
votes
1answer
26 views

Read excel file from clientside using symfony2 netbeans

Please help any one... I am trying to read excel file from client side and insert to mysql with out uploading excel file to server can any one help me?? Thanks in advance