Add custom code in WPCode
You need to first enter a title for your custom snippet. It can be anything that helps identify the code.
Afterwards, you can copy and paste the code list of real mobile phone numbers phone number snippet into the code preview box. Make sure you select the correct tag type from the drop-down menu on the right.
Add your first code snippet
In the screenshot above, we’ve added a custom code snippet to remove the WordPress version number from our test site.
1
2
3
4
function wpb_remove_version() {
return '';
}
add_filter('the_generator', 'wpb_remove_version');
Hosted by WPCode and
One-click use in WordPress
Insert options appear below the code pane. There are two main insertion options: automatic insertion and shortcodes.
Select insertion options for code snippets
If you choose the "Auto-insert" method, the code snippet will be automatically inserted and run on the website.
You can only automatically run this code snippet in your WordPress admin area, website frontend, or anywhere. You can also choose to insert the code snippet at a specific location on the page, such as before or after a post or within the post content.
If you're not sure, choose the default "Run snippet everywhere" option.
With the "shortcode" approach, code snippets are not inserted automatically. Once you save your snippet, you'll get a snippet-specific shortcode that you can use anywhere on your site.
By scrolling down further, you can limit snippet loading based on your device type. By default, snippets load on all device types, but you can set them to be desktop only or mobile only.
Automatically insert code snippets at specific locations on the page
-
- Posts: 63
- Joined: Mon Dec 23, 2024 2:26 pm