Skip to content

Instantly share code, notes, and snippets.

protected function instantSendEmail($to, $subject,$data,$template='en_default-en_default',$email_debug=false){
$layout_view = explode('-', $template);
$layout=$layout_view[0];
$view=$layout_view[1];
# email preview - $email_debug=true #
if($email_debug){
$this->layout = 'Emails/html/'.$layout;
$this->set('content',$data);
$this->render('../Emails/html/'.$view);
Vue.component('vue-switch',{
template: '<label :class="classObject"><span class="vue-switcher__label" v-if="shouldShowLabel"><span v-if="label" v-text="label"></span><span v-if="!label && value" v-text="textEnabled"></span> <span v-if="!label && !value" v-text="textDisabled"></span> </span> <input type="checkbox" :disabled="disabled" @change="trigger" :checked="value"><div></div> </label>',
props: {
typeBold: {
default: false
},
value: {
default: false
},
function getYouTubeID($url){
/*
* type1: http://www.youtube.com/watch?v=H1ImndT0fC8
* type2: http://www.youtube.com/watch?v=4nrxbHyJp9k&feature=related
* type3: http://youtu.be/H1ImndT0fC8
*/
$vid_id = "";
$flag = false;
if(isset($url) && !empty($url)){
/*case1 and 2*/
function getDoc($id = null, $firm_id = null){
//PROVERA PRAVA PRISTUPA - user moze da cita samo svoj cv + provera da li odredjena komp koze da gleda cv
$getDocument = false;
$this->Attachment=classRegistry::init('Attachment');
$attach=$this->Attachment->find('first',array('conditions'=>array('Attachment.id'=>$id)));
//Ulogovan je MEMBER i MEMBER ID mora da bude jednak FOREIGIN KEY iz attachment tabele
if(isset($this->member_id) && !empty($this->member_id) && $id != null){
@Bane83
Bane83 / 0_reuse_code.js
Created June 19, 2017 11:06
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
http://crimson.conveo.net/en/logInUser
1) Pokusaj logovanja I
$_POST
accountType
token
U koliko ne postoji User sa prosledjenim instagram ID-em (cita se iz tokena koji se prosledjuje), vraca se response:
<?php
/**
* Places API V1
*/
class PlacesV1Controller extends ApiAppController {
var $name = 'PlacesV1';
var $uses = ['Place', 'Tag', 'Member', 'Attach', 'PlaceGroup', 'WorkingHour', 'Category', 'Rating','Repertoire','City','Country'];
var $components = ['Upload'];
array(
'id' => '1962',
'name00eng' => 'Test',
'description00eng' => '',
'promotions00eng' => '',
'name00srp' => '',
'description00srp' => '',
'promotions00srp' => '',
'email_to' => '',
'reservation_active' => false,
var map;
var i=0;
var modelData = {};
var PlaceEditView = Backbone.View.extend({
el: $('#content'),
imgs: [],
initialize: function () {
this.render();
newPlace.on('change', this.render, this); //change:profile_img
id
338685
337927
336978
327321
354494
287324
354473
354224