When using Symfony frontend application it is sometimes necessary to access other application’s routing to create an internal url that points to that application.
In order for that to be posssible, a method for getting the desired application’s routing is required.
Tag: symfony
Creating new relations by using jQuery Autocompleter widget in Symfony
Posted on Categories:PHP, MySQL, SymfonyThis post describes how to create new relation by usin jQuery Autocompleter widget in Symfony project.
Recently, I’ve had a situation where I had to create a form for entering a product details, with a dropdown or autocomplete input for selecting product’s brand. If a user entered a non-existing brand, it had to be automatically created and assigned to product that the user was editing.
Embedding relations in Symfony
Posted on Category:SymfonyThis quick post describes a necessary step in embedding a relation in a Symfony 1.4 form.
If you have followed Symfony’s official documentation and forums regarding embedding relations in a form, you may have already seen an example of product and productPhoto forms in a single form.
Creating Autocomplete input field for Symfony based web form
Posted on Category:SymfonyThis post describes steps required to create jQuery/AJAX input text field with autocomplete feature using Symfony php framework. It is assumed that you know how to create a web form, and install Symfony plugins, so that part won’t be explained here.
A Symfony plugin sfFormExtraPlugin is required, and, of course, jQuery (I’m using sfJqueryReloadedPlugin).
Generating url using routing from anywhere in Symfony
Posted on Category:SymfonyThis post describes how to generate URL from anywhere in Symfony application. For example, I needed to create URL for forgotten password within an error message for invalid e-mail address. Needless to say, this should be done in user registration form class.
Troubleshooting /sf directory with mod-rewrite on Symfony projects
Posted on Category:SymfonyThis post shows example for setting up /sf directory required for default css and javascript files on Symfony projects. Symfony documentation describes how to create Alias for /sf directory, and on most configurations it works perfectly. Directory and all assets are visible, and usable by your web application.
Setting up new VirtualHost for Symfony 1.4 project
Posted on Category:SymfonyThis post shows an example how to setup apache2 virtual host for symfony 1.4 based project. Although there’s already an documented VirtualHost example on official Symfony website, I think that this virtualHost setup is more practical for development purposes.
Enabling logging in production enviroment for Symfony project
Posted on Category:PHP, MySQLThis post describes steps required to enable logging in Symfony project in production enviroment.
By default logging is disabled in prod enviroment, and if you want to enable it, you need to edit settings.yml and factories.yml files in your app directory.