Creating a centered fixed header or footer menu on Unbounce
Follow the full instructions here: https://getsatisfaction.com/unbounce/topics/creating_a_fixed_header_menu
<script>
//Fixed Menu (Header or footer) v1.3.1
<?php | |
/** | |
* Automatically login a single WordPress user upon arrival to a specific page. | |
* | |
* Redirect to home page once logged in and prevent viewing of the login page. | |
* Compatible with WordPress 3.9.1+ | |
* Updated 2014-07-18 to resolve WP_DEBUG notice: "get_userdatabylogin is deprecated since version 3.3! Use get_user_by('login') instead." | |
* Updated 2019-07-09 to reformat code, pass 2nd parameter to `do_action()`, and hook into priority 1. | |
* |
{ | |
"meta": { | |
"theme": "elegant" | |
}, | |
"basics": { | |
"name": "Thomas Davis", | |
"label": "Web Developer", | |
"image": "https://avatars0.githubusercontent.com/u/416209?s=460&u=38f220a2c9c658141804f881c334c594eb1642ac&v=4", | |
"summary": "I’m a full stack web developer who can build apps from the ground up. I've worked mostly at startups so I am use to wearing many hats. I am a very product focussed developer who priotizes user feedback first and foremost. I'm generally very flexible when investigating new roles. ", | |
"website": "https://lordajax.com", |
<?php // only copy this line if needed | |
/** | |
* Renders a notice and prevents checkout if the cart | |
* only contains products in a specific category | |
*/ | |
function sv_wc_prevent_checkout_for_category() { | |
// set the slug of the category for which we disallow checkout | |
$category = 'clothing'; |
// This gist is now maintained on github at https://github.com/luetkemj/wp-query-ref | |
<?php | |
/** | |
* WordPress Query Comprehensive Reference | |
* Compiled by luetkemj - luetkemj.github.io | |
* | |
* CODEX: http://codex.wordpress.org/Class_Reference/WP_Query#Parameters | |
* Source: https://core.trac.wordpress.org/browser/tags/4.9.4/src/wp-includes/query.php | |
*/ |
<?php | |
/** | |
* Plugin Name: Custom API | |
* Plugin URI: http://chrushingit.com | |
* Description: Crushing it! | |
* Version: 1.0 | |
* Author: Art Vandelay | |
* Author URI: http://watch-learn.com | |
*/ |
{ | |
"AN":"Andaman and Nicobar Islands", | |
"AP":"Andhra Pradesh", | |
"AR":"Arunachal Pradesh", | |
"AS":"Assam", | |
"BR":"Bihar", | |
"CG":"Chandigarh", | |
"CH":"Chhattisgarh", | |
"DN":"Dadra and Nagar Haveli", | |
"DD":"Daman and Diu", |
<?php | |
/* | |
Plugin Name: R Debug | |
Description: Set of dump helpers for debug. | |
Author: Andrey "Rarst" Savchenko | |
Author URI: https://www.rarst.net/ | |
License: MIT | |
*/ |
#Code à mettre:
(function(e){function t(){var t=window.module.lp.form.data;var n=t.validationMessages;var r=t.validationRules;this.changeTitle=function(n){e(function(){e("#"+t.errorContainerId).find("div.error").text(n)})};this.changeField=function(e,t,i){if(!n[e])return;n[e].required=t;if(i&&r[e].email)n[e].email=i;if(i&&r[e].phone)n[e].phone=i}}window.errors=new t(lp.jQuery)})(lp.jQuery)
$(function() {
setTimeout(function(){
lp.jQuery.validator.addMethod("phone", function(phone_number, element)
{
phone_number = phone_number.replace(/\s+/g, "");
<script> | |
//Scroll and Stick Fixed header v1.0 | |
//Replace ID below with your box ID | |
var boxToFix = '#lp-pom-box-587'; | |
function showOrHideHeader(){var o=$(window).scrollTop();o>topPositionOfBox?($(boxToFix).css({position:"fixed",top:"0px"}),$(boxClone).css({position:"fixed",top:"0px"})):($(boxToFix).css({position:"absolute",top:topPositionOfBox}),$(boxClone).css({position:"absolute",top:boxTop}))}var boxParent=$(boxToFix).parent(),boxClone=$(boxToFix).clone().attr("id",boxToFix+"-bg"),topPositionOfBox=$(boxToFix).position().top,boxHeight=$(boxToFix).css("height"),boxTop=$(boxToFix).css("top"),boxBorderWidthTop=$(boxToFix).css("border-top-width"),boxBorderWidthBottom=$(boxToFix).css("border-bottom-width"),boxBorderWidthLeft=$(boxToFix).css("border-left-width"),boxBorderWidthRight=$(boxToFix).css("border-right-width"),boxBorderStyleTop=$(boxToFix).css("border-top-style"),boxBorderStyleBottom=$(boxToFix).css("border-bottom-style"),boxBorderStyleLeft=$(boxToFix).css("border-left-style"),boxBorderStyl |