Skip to content

Instantly share code, notes, and snippets.

View tonio's full-sized avatar
🏔️

Antoine Abt tonio

🏔️
View GitHub Profile
<?php
/**
* Returns PDF file whith appropriate headers
*
* @param string $content The file content
*
* @return sfView::NONE
*/
public function renderPDF($content)
<?php $menu = get_slot('menu') ?>
<?php slot('menu') ?>
<?php echo $menu ?>
<li><a href="#<?php echo sfInflector::Camelize($item) ?>"><?php echo $item ?></a></li>
<?php end_slot() ?>
config:
actions:
new: { credentials: [admin] }
list:
actions:
new: { credentials: [admin] }
<?php
class myForm extends sfFormDoctrine
{
public function processValues($values = null)
{
$values = parent::processValues($values);
// calculate the value of virtual field "foo"
$values['foo'] = $foo;
return $values;
# Js files to be included in the build should be marked as @requires
# in source files themselves, rather than include their path here.
[MapFish.js]
root =
../../MapFish/client/mfbase/openlayers/lib
../../MapFish/client/mfbase/geoext/lib
../../MapFish/client/mfbase/mapfish
#../src/main/webapp/js/proj4js/lib
../web/js
first =
default:
is_secure: on
credentials: admin
document.addEvent('domready', function() {
$$('a.blank').addEvent('click', function(link, e){
e.stop();
window.open(link.get('href'));
});
};
aabt@paradis:websig$ ./symfony test:coverage --detailed plugins/sfMapFishPlugin/test/unit/ plugins/sfMapFishPlugin/lib/GeoJSON/
>> coverage running /home/aabt/workspace/pn...in/test/unit/WKT_Test.php (1/2)
>> coverage running /home/aabt/workspace/pn...est/unit/GeoJSON_Test.php (2/2)
ns/sfMapFishPlugin/lib/GeoJSON/adapters/GeoJSON_Adapter_Doctrine.class 0%
plugins/sfMapFishPlugin/lib/GeoJSON/adapters/GeoJSON_Adapter.class 0%
plugins/sfMapFishPlugin/lib/GeoJSON/GeoJSON.class 52%
# missing: [34 - 35] [37 - 41] 43 57 62 80 [95 - 98] [100 - 102] 105 108 [121 - 127] 129 144 [152 - 154] [156 - 159] [164 - 166] [181 - 182] [210 - 212] [214 - 217] [220 - 222] [224 - 227] [239 - 241] [243 - 246] 261 [265 - 267] 281 291 314 322 326 332 [335 - 337] 354 [381 - 385]
plugins/sfMapFishPlugin/lib/GeoJSON/WKT/WKT.class 100%
plugins/sfMapFishPlugin/lib/GeoJSON/lib/Geometry/MultiPolygon.class 100%
plugins/sfMapFishPlugin/lib/GeoJSON/lib/Geometry/Polygon.class 100%
#!/bin/bash
# usage: ./svngrep http://svn.example.com/trunk/file foobar
#
# This example will look for the string foobar in all rev of file
#
# @todo better argv handling
# @todo add a --verbose option
# @todo automatic branches and tags detection (?)
<?php
require_once dirname(__FILE__).'/../lib/symfony/autoload/sfCoreAutoload.class.php';
sfCoreAutoload::register();
class ProjectConfiguration extends sfProjectConfiguration
{
public function setup()
{
$this->getEventDispatcher()->connect(