×
Clear all filters including search bar
Valeri Tandilashvili's Personal Professional Blog
$
followed by curly brackets ${expression}
let name = 'George'
let age = 25
document.write(`My name is ${name} and I am ${age} years old!`)
$new = htmlspecialchars("<a href='test'>Test</a>", ENT_QUOTES);
echo $new; // <a href='test'>Test</a>
Without quotes:$new = htmlspecialchars("<a href='test'>Test</a>");
echo $new; // <a href='test'>Test</a>
The second parameter possible values:
ENT_COMPAT
- Will convert double-quotes and leave single-quotes alone.
ENT_QUOTES
- Will convert both double and single quotes.
ENT_NOQUOTES
- Will leave both double and single quotes unconverted.
The default is ENT_COMPATPost
php artisan make:model Post
With the following basic content<?php
namespace App;
use Illuminate\Database\Eloquent\Model;
class Post extends Model
{
//
}
Creates Post
model and also migrations to create table for the modelphp artisan make:model Post -m
The migration file location isdatabase/migrations/2020_09_02_041219_create_posts_table.php
public function contact() {
return 'Under Construction';
}
Returns HTMLpublic function about() {
return '<h1>About the site</h1>details...';
}
Returns view located at resources/views/pages/services.blade.php
public function services() {
return view('pages/services');
}
git config --global credential.helper 'cache --timeout=3600'
sdt_prices
tableSELECT *
FROM (
SELECT @row := @row +1 AS rownum, sdt_prices.*
FROM (
SELECT @row :=0) r, sdt_prices where token_id = 1 order by id desc
) ranked
WHERE rownum %5 = 1
ISC
)npm config delete init-license
Deletes manually set default author name (default author will become empty string)npm config delete init-author-name
file_put_contents($filePath, $content, FILE_APPEND);
Note: if FILE_APPEND
parameter is not passed, the function overwrites the content.name
- name of the app (default is the name of the current folder)
version
- version of the app (default is 1.0.0 - major.manor.patch)
description
- short description for the project
main
- entry point - main JS file
keywords
- keywords that the app is related to
author
- project author
license
- default is ISC (Internet Systems Consortium).class1 .class2 h2{
color: red;
}
Selects all <h2>
elements within .class2
that is a descendant of .class1
element