Skip to content

Instantly share code, notes, and snippets.

View jerronimo's full-sized avatar

Eugene Kashkarov jerronimo

  • Kharkiv
View GitHub Profile
jerry@work:~$ sudo /var/www/photoluxe.com/start_vm.sh
Usage: docker rm [OPTIONS] CONTAINER [CONTAINER...]
Remove one or more containers
-f, --force=false Force the removal of a running container (uses SIGKILL)
-l, --link=false Remove the specified link and not the underlying container
-v, --volumes=false Remove the volumes associated with the container
Unable to find image '192.168.51.99:5000/registry:ul.pl.dev' locally
dev@docker:~$ sudo docker images -a
REPOSITORY TAG IMAGE ID CREATED VIRTUAL SIZE
192.168.51.99:5000/registry pgdb.pl.dev d3cecf497198 7 days ago 2.167 GB
192.168.51.99:5000/registry ul.pl.dev 6a0fe5458441 7 days ago 782.6 MB
<none> <none> 2b7a7330a2e3 8 days ago 756.2 MB
192.168.51.99:5000/registry front.pl.dev 73d22c6582ac 8 days ago 556.4 MB
192.168.51.99:5000/registry dl.pl.dev 40b1f88fe180 8 days ago 752.1 MB
<none> <none> 8eddd9a824db 8 days ago 756 MB
192.168.51.99:5000/registry ws.pl.dev b0d198a97bf7 8 days ago 805.6 MB
<none> <none> a0cfba3b8cb1 8 days ago 805.3 MB
<?php
/**
* @Route("/personal/stories/stories_add", name="stories_add")
* @Template("FtWsContestStoriesBundle:Stories:stories_add.html.twig")
*/
public function storiesAddAction(Request $request)
{
$currentUserId = $this->getUser()->getId();
<form method="POST" action="{{ path('stories_add') }}" class="form-stories-test" role="form">
<p class="form-group">
<label for="name">Name</label>
<input type="text" name="name" id="name" class="form-control" />
</p>
<p class="form-group">
<label for="title">Title</label>
<input type="text" name="title" id="title" class="form-control" />
</p>
<p>
<?php
/**
* @Route("/personal/personal_stories/stories_add", name="stories_add")
* @Template("FtWsContestStoriesBundle:Stories:stories_add.html.twig")
*/
public function storiesAddAction(Request $request)
{
$photoGroup = new PhotoGroup();
$form = $this->createForm(new PhotoGroupType($photoGroup));
$(function () {
$('#attachment-field').change(function () {
var file = this.files[0];
if (file.type.match(/^image\//)) {
var url = $('#form-xyz').attr('action');
var request = new XMLHttpRequest();
request.open('POST', url);
request.send(new FormData(document.getElementById('form-xyz')));
}
var path = [];
<?php
public function storiesAddAction(Request $request)
{
$photoGroup = new PhotoGroup();
$form = $this->createForm(new PhotoGroupType($photoGroup));
$form->handleRequest($request);
if ($form->isValid()) {
$photoGroup = $form->getData();
$photoPath = $form->get('pathToFile')->getData();
$arr = explode(",", $photoPath);
<?php
{{ form_start(form) }}
{{ form_row(form.name) }}
{{ form_row(form.title) }}
{{ form_row(form.theme) }}
{{ form_row(form.category) }}
{{ form_row(form.textFoto) }}
{{ form_row(form.unTitled) }}
{{ form_start(form) }}
<?php
/**
* @Route("/personal/personal_stories/edit_stories", name="edit_stories")
* @Template("FtWsContestStoriesBundle:Stories:edit_stories.html.twig")
* @param Request $request
* @return array
*/
public function editStories2Action(Request $request)
{
$('#edit_stories_filter_name').change(function () {
var storiesName = $('#edit_stories_filter_name option:selected').text();
$('.story-item').fadeOut();
$('.story-item').each(function(){
if($(this).hasClass(storiesName)){
$(this).fadeIn();
}
console.log(storiesName);
});
})