neo yang

Copywriter, webmaster, product manager, architect, independent developer.

Time:2023/06/27

jQuery problem: juncaught typeerror: $ is not a function

js problems are all asynchronous problems.

WordPress also loads various js in a certain order. WordPress basically loads its own js first, and then loads its own defined js.

$(function(){})

In this way, if you encounter the following problems

uncaught typeerror: $ is not a function

You can change the way of writing

jQuery(function($){})

tags:

AIGC, Chat - What can GPT be used for?

Recently, I have discussed with many friends the topic of what "GPT" can be used for. Sort it out. 1. SEO and self-media creation in 2018 […]

Time:2023/06/25

The rise of artificial intelligence products

In the past two years, there has been an obvious trend.

More and more artificial intelligence software and hardware products are emerging.

Most of these products are used in various fields such as smart cities, AIOT, edge computing, smart agriculture, smart factories, robots, etc.

This general direction will only become more and more promising in the future.

Compared with the purely information-dimensional metaverse, this is a product direction that can directly intervene in the real world, profoundly affect the world, and ultimately lead to large-scale iterations in all directions of the entire society.

tags: ,
Time:2023/05/26

Regular expression to filter out links in articles

These two rules are both correct, but the first one succeeds and the second one fails. I don’t know why.

//This is successful. / ]*>/g //This failed. /<\/?a.*?>/g
tags:

Major changes in Internet user behavior

1. Changes of the Times and Business Opportunities 1. The Age of Carriages and the Age of Cars Before the emergence of automobiles, horse-drawn carriages were an important means of transportation. After the advent of automobiles, horse-drawn carriages […]

Time:2023/05/16

wordpress theme: How to get term data in archive——get_queried_object()

I've been iterating my own wordpress theme recently.

It is very common to obtain the term data of category and post-tag, two existing WordPress taxonomies, in the archive, and both have ready-made parameters and functions.

How to get the term data of custom taxonomy in archive?

get_queried_object()

This function can not only obtain the term data of custom taxonomy, but also the data of category and post-tag. Even if it is an archive of a custom post type, you can also get the current post type data.

    $term_data = get_queried_object();//In archive.php, use it directly.

URL on wordpress official website: https://developer.wordpress.org/reference/functions/get_queried_object/

You can also get the current post and user data. However, I haven't tried these two.

tags:
Time:2023/05/16

Documentation issue: wordpress Gutenberg editor blank page

Recently, for one of my websites, Baseon WordPress, the Gutenberg editor could not be used. When I opened it, the page was blank. I always thought it was caused by upgrading wordpress to v6.2 some time ago. I just figured it out today. It turns out that there is an extra "}" in a js file I wrote myself.

After removing this "}", the Gutenberg editor returns to normal.

tags:
Time:2022/09/09

Record a problem: $_SERVER['SERVER_NAME'] is the first domain name bound to the host

Record a question: $_SERVER['SERVER_NAME'] is the first domain name in the list of domain names bound to the host.

tags:

Flow carrier and bamboo basket to draw water

1. Drawing water from a bamboo basket Many years ago, during the personal website era, I made many websites, and several of them had relatively large traffic. I also made some money from this traffic. However, there is a question […]

E-commerce is all about traffic and conversion - a review and summary of the development of e-commerce

E-commerce is all about traffic and conversions. Logistics, supply chain, payment, etc. are all undergoing transformation. It is also the infrastructure of e-commerce. 1. Overseas e-commerce 1. Asia […]


copyright © www.lyustu.com all rights reserved.
Theme: TheMoon V3.0. Author:neo yang