Thursday, August 18, 2022

Running WordPress on SQL Server

 August 18, 2022

Here is the link. 

It seems to be a well kept secret that WordPress runs on a SQL Server or SQL Azure database. At least it was well kept from me until recently. (Perhaps that says something about my ability to follow current news, but that’s a topic for another day.) In any case, the cat is out of the bag with this new blog: WordPress on Microsoft. Now, you might ask why the BLEEP is Microsoft doing this? But that is answered here: Why the BLEEP is Microsoft doing this? You might also ask how is Microsoft doing this? The answer to that question is here: WordPress on SQL Server: Architecture and Design. Finally, you might ask how do I do this? Again, the answer is here: Installing WordPress on SQL Server. (These guys seem to have all their bases covered.) However, that set of instructions for installing WordPress on SQL Server assumes you are starting from scratch and it guides you through set up using the Web Platform Installer (WPI). I thought is would be relevant to look at how to get things set up assuming you already have PHP and SQL Server 2008 Express installed. I ran into a few “gotchas” in doing this – I’m hoping this post will help you avoid these. If you do install this WordPress patch, keep in mind that it is a beta release and that we'd appreciate feedback.

How do I configure WordPress to talk to a Microsoft SQL Server database?

Here is the link. 

We have are building a WordPress site on our intranet site and wish to connect it to a Microsoft SQL Server.

I have downloaded and configured PHP and PHP Manager on IIS.

I have also downloaded SQL Server DLL from the list of answered questions that popped on as I was typing the title of this thread.

I downloaded those DLLs inside the PHP folder as instructed.

When I fired up the server address to install WordPress, I was prompted to provide SQL DB name, username, password and DB hostname.

I have also downloaded wp-db-Abstraction plugin, put the wp-db-abstraction.php file into the folder where the WordPress files are saved, put the wp-db-abstraction folder into wp_content as instructed by the online article I was reading. Inside this folder, there is a db.php file. I also copied this db.php file into foldername where the rest of the downloaded WordPress files reside.

Settings API vs Options API

 A quick tip for our readers today. I've received a question asking me to explain the difference between the Settings API and Options API when developing WordPress plugins.


A quick tip for our readers today. I’ve received a question asking me to explain the difference between the Settings API and Options API when developing WordPress plugins.

The Options API precedes the Settings API in WordPress history. The Settings API was only introduced in WP 2.7 in order to facilitate the building of options pages for themes and plugins, thus building on the existing Options API.

Basically the Options API is the simplest form of saving options to your database, but does not provide any methods for building the settings interface, and neither does it do any validation checks, leaving both these cumbersome tasks to the developer. That is not even mentioning the security hassles whereby which developers (especially new contributors) could easily create security holes if not following best practices. This of course would be bad for the community in general who downloaded that plugin.

Creating settings interfaces, security checks and data validation are very repetitive tasks for developers. The can also lead to custom implementations (especially in terms of UI) which conflict with the overall interface of WordPress. So the good folks at WordPress decided to create the Settings API to help us out.

Nowadays, with the Settings API all the security checks are handled automatically by WordPress itself. Creating the settings form is also taken care of automatically. Basically, all you have to do is to register your options with the Settings API and specify the input fields you wish to add to the options page, and you’re ready to go.


Wordpress: Home / Core Handbook / Best Practices / Core APIs

Here is the link. 

Core APIs

The WordPress Core Application Programming Interface (API) is comprised of several individual APIs, each one covering the functions involved in, and use of, a given set of functionality. Together, these form the project interface which allows plugins and themes to interact with, alter, and extend WordPress core functionality.

   Why You Should Use The Core APIs

Using the core APIs when developing for WordPress is strongly encouraged because:

  • Core APIs make building things for WordPress easier by providing hooks, actions, filters, helper functions.
  • WordPress does the “heavy lifting” for you (database calls, input validation, security, form building) so you don’t have to.
  • Using core APIs ensures your code will be both backward-compatible and future-proof.
  • The APIs allow seamless integration into wp-admin for plugin/theme options pages, inline help documentation, etc.


Wednesday, August 17, 2022

Wordpress plugin handbook

Here is the link. 

Introduction to Plugin Development

Welcome to the Plugin Developer Handbook. Whether you’re writing your first plugin or your fiftieth, we hope this resource helps you write the best plugin possible.

The Plugin Developer Handbook covers a variety of topics — everything from what should be in the plugin header, to security best practices, to tools you can use to build your plugin. It’s also a work in progress — if you find something missing or incomplete, please notify the documentation team in slack and we’ll make it better together.

Why We Make Plugins

If there’s one cardinal rule in WordPress development, it’s this: Don’t touch WordPress core. This means that you don’t edit core WordPress files to add functionality to your site. This is because WordPress overwrites core files with each update. Any functionality you want to add or modify should be done using plugins.

WordPress plugins can be as simple or as complicated as you need them to be, depending on what you want to do. The simplest plugin is a single PHP file. The Hello Dolly plugin is an example of such a plugin. The plugin PHP file just needs a Plugin Header, a couple of PHP functions, and some hooks to attach your functions to.

Plugins allow you to greatly extend the functionality of WordPress without touching WordPress core itself.

Wordpress -> Home / Plugin Handbook / Hooks

 Hooks are a way for one piece of code to interact/modify another piece of code at specific, pre-defined spots. They make up the foundation for how plugins and themes interact with WordPress Core, but they’re also used extensively by Core itself.

There are two types of hooks: Actions and Filters. To use either, you need to write a custom function known as a Callback, and then register it with a WordPress hook for a specific action or filter.

Actions allow you to add data or change how WordPress operates. Actions will run at a specific point in the execution of WordPress Core, plugins, and themes. Callback functions for Actions can perform some kind of a task, like echoing output to the user or inserting something into the database. Callback functions for an Action do not return anything back to the calling Action hook.

Filters give you the ability to change data during the execution of WordPress Core, plugins, and themes. Callback functions for Filters will accept a variable, modify it, and return it. They are meant to work in an isolated manner, and should never have side effects such as affecting global variables and output. Filters expect to have something returned back to them.

WordPress provides many hooks that you can use, but you can also create your own so that other developers can extend and modify your plugin or theme.

Actions vs. Filters

The main difference between an action and a filter can be summed up like this:

  • an action takes the info it receives, does something with it, and returns nothing. In other words: it acts on something and then exits, returning nothing back to the calling hook.
  • a filter takes the info it receives, modifies it somehow, and returns it. In other words: it filters something and passes it back to the hook for further use.

Said another way:

  • an action interrupts the code flow to do something, and then returns back to the normal flow without modifying anything;
  • a filter is used to modify something in a specific way so that the modification is then used by code later on.

The something referred to is the parameter list sent via the hook definition. More on this in later sections.

How to Create a WordPress Plugin (Beginner’s Guide)

Here is the link. 




How To Access And Edit Your WordPress Directory Files [2022]

 Here is the link. 

It’s not uncommon to come across solutions where you are asked to modify the core WordPress files. It can be very tough to find the correct location, especially for a beginner. So, if you are one of these users who are stuck in this sort of situation, you don’t have to worry anymore. In this article, we are going to give you a brief on how you can access and edit your WordPress Directory files with ease.

Why You Might Need to Access Your WordPress Directory Files

Well, locating the WordPress directory files can be very troublesome for normal users. You might find it a lot of hassle at first as well. Even though it is not recommended to make any changes to your files without prior coding knowledge, at some stage, you might actually have no other options.

For instance, if your site goes out of order for unexpectedly and you do not have your developer around, the instant solution would be a way to go. Most of these quick fixes tell you to modify a simple bit of code of a core WordPress file. So, if you are aware of where to find these files, you can solve the problem all by yourself in a few minutes.

Usually, when you run into an issue on your site, you would be asked to enable the debug mode. As a result, you can let the respective plugin or theme support team know about the error you are getting. So, if you know how to modify the wp-config.php file, you can do it in no time. Thus, you will be able to save your time and get a quick solution at the same time.


SanDisk® Memory Zone™ app

 SanDisk® Memory Zone™ is a file management app for SanDisk Dual Drives, SanDisk Solid State Drives, microSD™ cards*, and certain cloud providers**. The app lets you organize your files, clean up your memory, and back up your files. The app comes with a user-friendly interface and is a simple and convenient tool to help manage your files and content.


FREE UP SPACE
Easily offload or back up content to your compatible SanDisk Dual Drive, SanDisk Solid State Drive, or microSD card*.

ADD EXTERNAL STORAGE SOURCE(S)
Add and manage external storage locations such as a compatible SanDisk Dual Drive, SanDisk Solid State Drive, or microSD card*. The app also supports popular cloud services**.

VIEW AND ACCESS FILES
Easily view and access the content stored on your SanDisk Dual Drive, SanDisk Solid State Drive, or microSD card* from the home page of the SanDisk Memory Zone app.

STORAGE MANAGER
Quickly organize and manage your content with the delete, rename, share, copy, or move operations.

EASILY FIND PHOTOS
Save time looking for files with the intuitive user interface. Search for photos by keyword or utilizing geotagging or timeline searches.

CLEAN APP CLUTTER
Clean your unwanted content in one-click with the “Delete Junk Files” tool. SanDisk Memory Zone can also clean up certain chat apps** to free up more storage instantly. Additionally, erase and uninstall your unused apps with the “Manage Apps” tool.

EASILY MOVE CONTENT
SanDisk Memory Zone allows you to easily move content between your different external and internal storage locations*.

AUTOMATICALLY BACK UP
Use SanDisk Memory Zone app to automatically back up your photos, videos, and/or contacts.

*SanDisk Dual Drive, Solid State Drives, and microSD cards not included with SanDisk Memory Zone. See SanDisk Memory Zone Product Compatibility for a list of compatible SanDisk drives and microSD cards.
**Cloud services provider compatibility subject to change.

SanDisk, the SanDisk logo, Memory Zone, and the Squirrel logo are registered trademarks or trademarks of Western Digital Corporation or its affiliates in the US and/or other countries. The microSD mark is a trademark of SD-3C, LLC. All other marks are the property of their respective users.

Product specifications subject to change without notice. Pictures shown may vary from actual products.

©2021 Western Digital Corporation or its affiliates. All rights reserved.

Western Digital Technologies, Inc. is the seller of record and licensee in the Americas of SanDisk® products.
Updated on
Feb 1, 2022

Data safety

Safety starts with understanding how developers collect and share your data. Data privacy and security practices may vary based on your use, region and age The developer provided this information and may update it over time.

Google phone: Move videos to sandisk

 Steps to follow:

  1. Go to Google Files app
  2. Categories -> Videos ->Click one video -> three dots -> Move to -> 
There are so many problems on this app. I decided to install Sandisk app called SanDisk Memory Zone app to transfer files instead. 


Tuesday, August 16, 2022

Vancouver open tennis

 


WordPress Plugin Development - Part 14 - Modular Administration Page

August 16, 2022

Here is the link. 


94.5K subscribers
SUBSCRIBED

:: Become a Patreon :: https://www.patreon.com/alecaddd :: Join the Forum :: https://forum.alecaddd.com/ :: Support Me :: http://www.alecaddd.com/support-me/ http://amzn.to/2pKvVWO GitHub Repo: http://bit.ly/2gvDHAJ :: Tutorial Series :: WordPress 101 - Create a theme from scratch: http://bit.ly/1RVHRLj WordPress Premium Theme Development: http://bit.ly/1UM80mR WordPress Mega Menu: http://bit.ly/2ucxSO4 Learn SASS from Scratch: http://bit.ly/220yzmZ Design Factory: http://bit.ly/1X7Csaz Affinity Designer: http://bit.ly/1X7CrDA :: My Website :: http://www.alecaddd.com/ :: Follow me on :: Twitter: https://twitter.com/alecaddd Google+: http://bit.ly/1Y7sunz Facebook: https://www.facebook.com/alecadddpage

Analyzing NBA Championships with Graph Theory

 Here is the link. 


327 subscribers
SUBSCRIBED

Last month 2020 NBA season ended with the LA Lakers winning their 17th franchise championship, at the same time, my Graph Theory course has been teaching the PageRank Algorithm. Today I'm going to see if I can apply what I've learned to analyze some of the more recent NBA Championship runs. I had to sacrifice my GPA to make this video, please consider subscribing. Also, 3 likes and I'll increase the font size on my next video. Source code: https://github.com/H-Richard/NBA-page... Data source: https://www.basketball-reference.com For the music, check out: https://www.youtube.com/channel/UCaCV...