#Vue.js component for Select2
A select2 component for vue.js. Quickly create select2 components, load data via ajax and retrieve selected values and newly created tags.
#Usage
Download and register the component:
Vue.component(
$input_lines = '<a href="index.php" target="_blank" class="link testing" >Test Link</a><a href="index.php" class="link testing" target="_blank" >Test Link</a><a href="index.php" target="_blank" class="link testing" >Test Link</a>'; | |
$replace_text = preg_replace('/(\<a.*?target=\"_blank\".*?>)(.*?)(\<\/a\>)/', '$1$2<span>screen reader</span>$3', $input_lines); | |
echo $replace_text; | |
// Output... | |
<a href="index.php" target="_blank" class="link testing" >Test Link<span>screen reader</span></a> | |
<a href="index.php" class="link testing" target="_blank" >Test Link<span>screen reader</span></a> |
➜ vvv-local git:(stable) vagrant reload --provision | |
__ __ __ __ | |
\ V\ V\ V / v3.8.1 Path:"/Users/sabbir/vvv-local" | |
\_/\_/\_/ git::stable(8252690) | |
Platform: darwin19 shell:/bin/zsh vagrant-goodhosts shared_db_folder_disabled | |
Vagrant: v2.2.19, virtualbox: v6.1.32 | |
Docs: https://varyingvagrantvagrants.org/ | |
Contribute: https://github.com/varying-vagrant-vagrants/vvv |
<template> | |
<div class="wpvue-modal-dialog"> | |
<div class="wpvue-modal"> | |
<div class="wpvue-modal-content" :style="{ width: width }"> | |
<section :class="['wpvue-modal-main', { 'has-footer': footer }]"> | |
<header class="modal-header" v-if="header"> | |
<slot name="header"> | |
<h1>{{ title }}</h1> | |
</slot> | |
</header> |
/* Woocommerce Styles */ | |
/* | |
A couple things to note... | |
1. This code was written very specifically for my base child theme so it might not work out of the box with every theme. | |
I have it here mostly to share with anyone who might be looking to do the same thing I was. | |
2. I generally add my WooCommerce CSS overrides to a custom-woo.css file then use wp_enqueue_style() to call it | |
so that it enqueues after the default WooCommerce Stylesheets |
#Vue.js component for Select2
A select2 component for vue.js. Quickly create select2 components, load data via ajax and retrieve selected values and newly created tags.
#Usage
Download and register the component:
Vue.component(
// JS File -- index.js | |
Vue.component( 'test-com', { | |
template: 'tmpl-test-com', | |
data: function() { | |
return { | |
localizeData: [] | |
} |
#!/bin/bash | |
clear | |
# Remove/Uninstall process | |
echo "Start WordPress installation" | |
if [[ $1 == "remove" ]]; then | |
| |
# Grab the project name | |
if [[ -z $2 ]]; then | |
echo "WP Project to remove: " |
<?php | |
function wp1982_handle_file_upload( $filename, $file_url ) { | |
add_filter( 'upload_dir', 'wp1982_customize_upload_dir', 10 ); | |
$upload_file = wp_upload_bits( $filename, null, file_get_contents( $file_url ) ); | |
remove_filter( 'upload_dir', 'wp1982_customize_upload_dir' , 10 ); | |
if ( !$upload_file['error'] ) { | |
$wp_filetype = wp_check_filetype( $filename, null ); | |
$attachment = array( |
Locate the section for your github remote in the .git/config
file. It looks like this:
[remote "origin"]
fetch = +refs/heads/*:refs/remotes/origin/*
url = [email protected]:joyent/node.git
Now add the line fetch = +refs/pull/*/head:refs/remotes/origin/pr/*
to this section. Obviously, change the github url to match your project's URL. It ends up looking like this: