OpenLampTech issue #70
'Tainted' PHP code | SQL NULL | 10 useful PHP functions | WordPress CF7 block workaround | Don't let Imposter Syndrome get in the way. Thank you for reading OpenLampTech!
I’m so grateful you are here reading OpenLampTech! 👍
Thank you!!!
If someone fantastic shared this newsletter with you and you are not yet subscribed, please use the Subscribe button below and join:
OpenLampTech has sponsorship opportunities in the weekly newsletter for your brand, product, or service. As a starter publication, collaboration is very budget-friendly. Inquire by email at openlamptech@substack.com for more information.
Recently Published on the Digital Owl’s Prose Developer Blog
Whether you are using WooCommerce, Shopify, or another e-Commerce platform, you may have a product that you want to capture some additional information from the customer. Perhaps it is a name for a hat, jacket, or t-shirt. I see this type of question asked a good bit in the WooCommerce groups I frequent on Facebook. Oftentimes, shop owners are looking for a plugin to accomplish this. However, I don’t think you need a full plugin for this type of enhancement. A few lines of PHP in the child theme will do it. I made it a point to research a solution and learn how to add this functionality with PHP. Learn with me in this article.
Below is the content I am sharing I enjoyed this week:
Tainted PHP code? JetBrains Qodana has a new detection feature
#php
My thoughts: I'm dang sure hung up on Sublime Text because I just haven't found another IDE/text editor that has VIM keybindings that are even close. All that said, I think this is one example of where using a dedicated IDE has better benefits. What is a taint in programming? Here's how JetBrains defines it:
A “taint”, the company said, is “any value that can pose a security risk when modified by an external user.”
Hmm. That covers a lot of things on any interactive site.
Learn more about the Qodana PHP linter in this article.
Shouldn’t Let Imposter Syndrome Keep You from Trying: John Jameson | DrupalCamp NJ
#php #drupal #cms
My thoughts: I personally need to take a dose of this medicine as I tend to let Imposter Syndrome get in my way a lot (most) of the time. I can definitely relate to one portion in the context of this interview where 'doing a little bit of everything' is concerned. The best thing going for me is I'm involved in a lot of LAMP-stack-related things so it's not necessarily shiny object syndrome 🤣. This is a great interview with a side tangent on some core concepts around accessibility in the Drupal space.
Contact Form 7 Block Editor Issue
#wordpress #cms
My thoughts: The original Contact Form 7 (CF7) was my first WordPress contact form. I was so impressed with shortcodes (still am) and how you could build out the input fields using them. In this article, we see a workaround - using a shortcode - in the event, your contact form is not available in the Gutenberg dropdown selector. Even in a 'block editing' setting, shortcodes still have their place and can be used with a shortcode block.
What Are Package Dependencies on Linux? Explained
#linux
My thoughts: Chances are if you are a developer of any sort, you know what dependencies are. However, a Linux user who isn't necessarily a developer may be aware of dependencies but not really know what they are. If you're updating your Linux applications with the command line, you've seen them fly by on the screen as updates are pulled down from the repositories. Dependencies are modular building blocks and many programs and applications depend on and use multiple(s) of them. Most packages and programs today use and depend on, multiple dependencies.
Drupal Doesn't Always Have to Do Everything: Melissa Bent and April Sides | FLDC
#drupal #cms
My thoughts: Here is a very interesting text-based interview with a couple of Red Hat Software Engineers. Both interview participants shed light on how they ultimately got started with Drupal on the back-end. A common theme amongst both participants, in my opinion, is how in-person Drupal camps/cons affected their individual careers. I personally haven't ever attended any in-person events but know I should someday. If I ever get any significant amount of time off from work, I'm gone bass fishing so there is that.
📰 Get your brand, product, or service the attention it deserves with affordable classified ad placement in the OpenLampTech newsletter.
10 PHP Array Functions And How To Use Them
#php
My thoughts: We work with array data so much in PHP. Fortunately, the language provides a plethora of array functions for us. So many that in fact, you could spend forever and a day on the php.net functions documentation page. This is an excellent write-up covering 10 array functions that you are likely using all the time. I can never remember how many or the order of an array functions' parameters just FYI. Do you have any tricks or tips that you use to help you remember a favorite PHP array functions' arguments?
Working with NULL Values in SQL
#sql #database
My thoughts: That tricky SQL NULL
is (likely) in the database table somewhere. When dealing with NULL
in SQL - particularly in the WHERE
clause of a SELECT
statement - which potentially has target filter columns that contain NULL
, standard equality (=
) and inequality (<>
) tests don't work. You must check for what I like to think of as a NULL
state in verbal tense: IS
or IS NOT NULL
. Remember, NULL
isn't equal to anything, not even another NULL
. Don't let NULL
wreck your query results.
Interesting Tech News and Articles 📰
New GoBruteforcer malware targets phpMyAdmin, MySQL, FTP, Postgres (03-10-2023)
The 30 Best Website Color Schemes to Make Your Website More Compelling
WooCommerce Update(s)
WooCommerce Blocks 9.8.0 Release Notes (March 14th, 2023)
WooCommerce 7.5 Released (March 14th, 2023)
🤝 OpenLampTech earns a small commission (or payment in some form) from many of these links. Your support helps keep the weekly OpenLampTech newsletter free for readers.
We make incorporating a company as easy as possible so that you can focus on the essential things. Visit IncFile today.
Never miss the essential e-commerce industry news. Free delivery to your Inbox every Monday. Subscribe to the Shopifreaks E-Commerce Newsletter.
Go beyond the 9 to 5 with the Gig Newsletter.
Thank you for reading. I hope you have a great rest of your week.
Take care.
Joshua Otwell
When you are ready, here are more ways I can help...
WordPress Services - Initial website setup, blog management, small WooCommerce customizations
Content creation - Writing, editing, blog management
Email - Newsletters, marketing, copywriting
Interested? Great!
Just hit Reply and ask for more information about any of these services.
OpenLampTech is a reader-supported publication. You can support the publication with a virtual coffee for as little as $3 (USD).