Initial commit with Symfony 2.1+Vendors

Signed-off-by: Gergely POLONKAI (W00d5t0ck) <polesz@w00d5t0ck.info>
This commit is contained in:
Polonkai Gergely
2012-07-01 09:52:20 +02:00
commit 082a0130c2
5381 changed files with 416709 additions and 0 deletions

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html>
<head>
<title><?php $view['slots']->output('title') ?></title>
<?php $view['slots']->output('stylesheets') ?>
</head>
<body>
<?php $view['slots']->output('_content') ?>
<?php $view['slots']->output('javascripts') ?>
</body>
</html>

View File

@@ -0,0 +1,11 @@
<!DOCTYPE html>
<html>
<head>
<title>{% block title '' %}</title>
{% block stylesheets '' %}
</head>
<body>
{% block content '' %}
{% block javascripts '' %}
</body>
</html>

View File

@@ -0,0 +1,17 @@
<?php $view->extend('::base.html.php') ?>
<?php $view['slots']->start('stylesheets') ?>
<?php foreach($view['assetic']->stylesheets('stylesheet1.css, stylesheet2.css, @TestBundle/Resources/css/bundle.css') as $url): ?>
<link href="<?php echo $view->escape($url) ?>" type="text/css" rel="stylesheet" />
<?php endforeach; ?>
<?php $view['slots']->stop() ?>
<?php $view['slots']->start('javascripts') ?>
<?php foreach($view['assetic']->javascripts('javascript1.js, javascript2.js') as $url): ?>
<script src="<?php echo $view->escape($url) ?>"></script>
<?php endforeach; ?>
<?php $view['slots']->stop() ?>
<?php foreach ($view['assetic']->image('logo.png') as $url): ?>
<img src="<?php echo $view->escape($url) ?>">
<?php endforeach; ?>

View File

@@ -0,0 +1,19 @@
{% extends '::base.html.twig' %}
{% block stylesheets %}
{% stylesheets 'stylesheet1.css' 'stylesheet2.css' '@TestBundle/Resources/css/bundle.css' %}
<link href="{{ asset_url }}" type="text/css" rel="stylesheet" />
{% endstylesheets %}
{% endblock %}
{% block javascripts %}
{% javascripts 'javascript1.js' 'javascript2.js' %}
<script src="{{ asset_url }}"></script>
{% endjavascripts %}
{% endblock %}
{% block content %}
{% image 'logo.png' %}
<img src="{{ asset_url }}">
{% endimage %}
{% endblock %}

View File

@@ -0,0 +1,40 @@
framework:
charset: UTF-8
secret: xxxxxxxxxx
csrf_protection:
enabled: true
router: { resource: "%kernel.root_dir%/config/routing.yml" }
validation: { enabled: true, enable_annotations: true }
templating: { engines: ['twig', 'php'] }
session:
lifetime: 3600
auto_start: false
twig:
debug: %kernel.debug%
strict_variables: %kernel.debug%
assetic:
use_controller: true
read_from: "%kernel.root_dir%/web"
bundles: [ TestBundle ]
assets:
jquery: js/jquery.js
app_css:
inputs:
- css/main.css
- css/more.css
- @widget_css
filters: [ ?yui_css ]
output: css/packed/app.css
widget_css:
inputs: css/widget.sass
filters: sass
filters:
sass:
apply_to: "\.sass$"
yui_css:
jar: %kernel.root_dir/java/yui-compressor-2.4.6.jar
twig:
functions:
yui_css: { output: css/*.css }

View File

@@ -0,0 +1,3 @@
_assetic:
resource: .
type: assetic

View File

@@ -0,0 +1 @@
// javascript1.js

View File

@@ -0,0 +1 @@
// javascript2.js

View File

@@ -0,0 +1 @@
/* stylesheet1.css */

View File

@@ -0,0 +1 @@
/* stylesheet2.css */