This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.gps_ring { | |
border: 3px solid #999; | |
-webkit-border-radius: 30px; | |
height: 32px; | |
width: 32px; | |
display: inline-block; | |
-webkit-animation: pulsate 1s ease-out; | |
-webkit-animation-iteration-count: infinite; | |
opacity: 0.0 | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Force SSL | |
RewriteCond %{HTTPS} !=on | |
RewriteRule ^/?(.*) https://%{SERVER_NAME}/$1 [R,L] | |
Setting a rewrite rule in .htaccess: use cases | |
---------------------------------------------- | |
NOTE: The directives specified below work under their own syntax. Changing any symbol or character can lead to improper function or failure of the rewrite rule. To keep things clear, we have highlighted those parts, which can be modified, with red color (mostly where a certain domain name should be placed). | |
Let’s take an overview of the most common situations in which a redirection from HTTP to HTTPS can be configured. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.presentation-title { | |
font-size: 8em; | |
font-weight: 700; | |
margin: 0; | |
color: #FFFFFF; | |
background: #fbf8ec; | |
background: -moz-linear-gradient(top, #FFFFFF 35%, #4e6773 100%); | |
background: -webkit-linear-gradient(top, #FFFFFF 35%, #4e6773 100%); | |
background: linear-gradient(to bottom, #FFFFFF 35%, #4e6773 100%); | |
background-clip: border-box; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script type="text/javascript"> | |
/* First CSS File */ | |
var giftofspeed = document.createElement('link'); | |
giftofspeed.rel = 'stylesheet'; | |
giftofspeed.href = '../css/yourcssfile.css'; | |
giftofspeed.type = 'text/css'; | |
var godefer = document.getElementsByTagName('link')[0]; | |
godefer.parentNode.insertBefore(giftofspeed, godefer); | |
/* Second CSS File */ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{{ $var }} - Echo content | |
{{ $var or 'default' }} - Echo content with a default value | |
{{{ $var }}} - Echo escaped content | |
{{-- Comment --}} - A Blade comment | |
@extends('layout') - Extends a template with a layout | |
@if(condition) - Starts an if block | |
@else - Starts an else block |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for (double i = 1; i >= 0; i -= 0.01) { | |
i = Math.round(i * 100) / 100.0d; | |
int alpha = (int) Math.round(i * 255); | |
String hex = Integer.toHexString(alpha).toUpperCase(); | |
if (hex.length() == 1) | |
hex = "0" + hex; | |
int percent = (int) (i * 100); | |
System.out.println(String.format("%d%% — %s", percent, hex)); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function starsLineIcons($count = 1, $title = FALSE) { | |
echo '<span class="ratings ratings-golden"'; | |
if (empty($title)) { | |
echo " title='{$title}'"; | |
} | |
echo '>'; | |
for ($i=0; $i < $count; $i++) { | |
echo '<span class="fa fa-star"></span>'; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Replaces double line-breaks with paragraph elements. | |
* | |
* A group of regex replaces used to identify text formatted with newlines and | |
* replace double line-breaks with HTML paragraph tags. The remaining | |
* line-breaks after conversion become <<br />> tags, unless $br is set to '0' | |
* or 'false'. | |
* | |
* @param string $para The text which has to be formatted. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<select name="country" id="country"> | |
<option value="0" label="Select a country … " selected="selected">Select a country</option> | |
<optgroup id="country-optgroup-Africa" label="Africa"> | |
<option value="DZ" label="Algeria">Algeria</option> | |
<option value="AO" label="Angola">Angola</option> | |
<option value="BJ" label="Benin">Benin</option> | |
<option value="BW" label="Botswana">Botswana</option> | |
<option value="BF" label="Burkina Faso">Burkina Faso</option> | |
<option value="BI" label="Burundi">Burundi</option> | |
<option value="CM" label="Cameroon">Cameroon</option> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<select name="countries"> | |
<option value="United States">United States</option> | |
<option value="United Kingdom">United Kingdom</option> | |
<option value="Afghanistan">Afghanistan</option> | |
<option value="Albania">Albania</option> | |
<option value="Algeria">Algeria</option> | |
<option value="American Samoa">American Samoa</option> | |
<option value="Andorra">Andorra</option> | |
<option value="Angola">Angola</option> | |
<option value="Anguilla">Anguilla</option> |