Skip to content

Second-cup-of-coffee

Web Development

Category: Javascript

Passing PHP Variables to JavaScript in WordPress

One thing that I found difficult to understand when starting out with WordPress development was how to use PHP variables in my JavaScript. I’m not sure why I found it so confusing. There are a lot of good examples out there but I thought I would break down how use PHP variables in your JavaScript… Continue reading Passing PHP Variables to JavaScript in WordPress

Published April 28, 2021
Categorized as Javascript, PHP, Web Development, WordPress

Inserting JavaScript with a Shortcode

Have you ever needed to insert a piece of JavaScript into a single post or page? Maybe there is an external contact form from a vendor that you’ve been given a snippet of JavaScript to include? There are a number of ways to do this. You could put a conditional in your template file and… Continue reading Inserting JavaScript with a Shortcode

Published March 30, 2020
Categorized as Javascript, PHP, WordPress

Passing PHP variables to JavaScript

I was recently working on a project in CodeIgniter and I was setting numeric variables with constants for things like locations (1 = Maine, 2 = New Hampshire, etc.). This all worked fine but when it came to doing some JavaScript AJAX work I didn’t have access to these constants. One of the advantages to… Continue reading Passing PHP variables to JavaScript

Published July 25, 2013
Categorized as Javascript, PHP, Web Development

Debugging Google Analytics

I was recently working with Google Analytics and discovered the Google Analytics Tracking Code Debugger. In the past, one of the biggest frustrations I had was that I would make a change and then have to wait until the next day to see if the changes worked. I guess that the time to see results… Continue reading Debugging Google Analytics

Published May 9, 2012
Categorized as Javascript, Web Development

Recent Posts

  • Using Flexbox and Pseudo Elements for Text Between Lines
  • Programmatically Adding a Menu Item to a WordPress Menu
  • Hiding empty paragraphs
  • Importing a MySQL Dump with Bad Dates
  • Adding the Page Order to the Page List in the WordPress Admin

Recent Comments

  • John on Creating Unique IDs for ACF Repeaters
  • Mark on Creating Unique IDs for ACF Repeaters
  • David on Using an SVG Icon for a WordPress Custom Post Type
  • David on WordPress Plugin for the BotMan Web Widget
  • Ian on Creating Unique IDs for ACF Repeaters

Archives

  • January 2023
  • April 2022
  • February 2022
  • December 2021
  • November 2021
  • May 2021
  • April 2021
  • February 2021
  • January 2021
  • December 2020
  • July 2020
  • May 2020
  • April 2020
  • March 2020
  • February 2020
  • March 2019
  • January 2018
  • October 2017
  • September 2017
  • August 2017
  • June 2017
  • May 2017
  • October 2016
  • March 2016
  • November 2015
  • July 2015
  • June 2015
  • February 2014
  • January 2014
  • July 2013
  • June 2013
  • May 2013
  • March 2013
  • January 2013
  • December 2012
  • September 2012
  • August 2012
  • July 2012
  • June 2012
  • May 2012

Categories

  • CodeIgniter
  • CSS
  • Javascript
  • Macintosh
  • Movies
  • MySQL
  • PHP
  • Quick Tip
  • TextMate
  • Uncategorized
  • Unix
  • Web Development
  • WordPress
Second-cup-of-coffee
Privacy Policy
Proudly powered by WordPress.