0

There are no examples of use anywhere, or even an explanation on how to use it.

3 Answers 3

3

Here's the source, make with it what you will. (Doesn't appear overly useful IMO).

566 /**
567  * Adds a dynamic javascript to the response object.
568  *
569  * The first argument is an internal URI.
570  * The helper automatically adds the sf_format to the internal URI, so you don't have to.
571  *
572  * @see sfResponse->addJavascript()
573  */
574 function use_dynamic_javascript($js, $position = '', $options = array())
575 {
576   $options['raw_name'] = true;
577 
578   return use_javascript(_dynamic_path($js, 'js'), $position, $options);
579 }
Sign up to request clarification or add additional context in comments.

1 Comment

Thanks Ian! I was just curious if it was enough to significantly help with the process of building dynamic JavaScript.
2

I know the question has its age, but I consider the problem is still there for many of us :)

After banging my head against the wall several hours, I want to share some info with you :P

How to use use_dynamic_javascript() helper in symfony here.

Comments

0

Obviously, this helper adds non-static (generated by you) JS to response. First parameter is an url as if it was passed url_for().

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.