Lars' Tech Tips

Small things that make your life easier

Skip to: Content | Sidebar | Footer



Category: PHP

Configuring FileField allowed extensions in Drupal

8 April, 2010 (13:52) | Drupal, PHP | By: Lars

Problem: you try to upload a file in Drupal and you get something like this: The selected file <file> cannot not be uploaded. Only files with the following extensions are allowed:… for an extension that is included in Administer->File Uploads. I found that I had the module CCK FileField installed and its allowed extensions are [...]

Change the date format in Symfony with Propel

2 March, 2010 (01:28) | PHP, Symfony / Propel | By: Lars

You’ll usually want to have the same date format all over your Symfony / Propel project. You only need to change one thing to do that: In config/propel.ini: propel.defaultTimeStampFormat = j M Y H:i propel.defaultTimeFormat      = H:i propel.defaultDateFormat      = j M Y You can set the above format using PHP date() formatting. After setting this [...]