Categories
CMS Mastering Development Wordpress

Rich text (gutenberg) block not updating meta field

I want to save some HTML to my meta data using the rich text component. If the key does not exist, the rich text will create and save the key and value no issues. It will save edits as required; no issues as long as the page has not been re-loaded. When the page is […]

Categories
Mastering Development

How to fix Next.js Vercel deployment module not found error

My next.js app works on my machine and was working when deployed on Vercel but now it fails when building on Vercel with the following error: I’ve tried deleting node_modules and running npm install a few times but with no joy. Any help would be hugely appreciated. Thank you! Analyzing source code… 21:30:52.642 Installing build […]

Categories
Mastering Development

Using Node.js to generate dynamic word document using Database value

I am trying to dynamically populate the WORD Document using npm docx. I am trying to read the data from the SQLite database but due to async node js property the values are not getting into the variable and it shows undefined. If I make the function synchronous the npm docx throws error and doesn’t […]

Categories
Mastering Development

Handpose tfjs Error – No backend found in registry

When trying to run a demo project for Handpose tfjs, I get the below error. My package.json file has below dependencies: { “name”: “tensorflowJs”, “version”: “1.0.0”, “description”: “”, “main”: “index.js”, “scripts”: { “watch”: “cross-env NODE_ENV=development parcel index.html –no-hmr “, “build”: “cross-env NODE_ENV=production parcel build index.html –public-url ./” }, “browser”: { “crypto”: false }, “keywords”: [], […]

Categories
CMS Mastering Development Wordpress

JSX in WordPress Plugin Development

plugin.php <?php /** * Plugin Name: Test * Version: 1.0.0 */ defined( ‘ABSPATH’ ) || exit; function test__register_block() { if ( ! function_exists( ‘register_block_type’ ) ) { // Gutenberg is not active. return; } wp_register_script( ‘test’, plugins_url( ‘block.js’, __FILE__ ), array( ‘wp-blocks’, ‘wp-i18n’, ‘wp-element’, ‘wp-editor’ ), filemtime( plugin_dir_path( __FILE__ ) . ‘block.js’ ) ); register_block_type( […]

Categories
Mastering Development

Use Application Insights with on-premises Node.js application

I am currently trying to set up Application Insights for an on-premises node.js backend. According to the documentation it should be possible. Application Insights can gather telemetry data from any internet-connected application, whether or not it’s running on-premises or in the cloud. Use the following steps to start viewing this data. I found a couple […]

Categories
Database Development

SQL Server Full-Text Search Order by another Column Performance

I have two tables, Entity and EntityDetails. Entity table has columns EntityId, Col1, Col2, Col3, LastUpdated (smalldatetime). EntityDetails table has columns EntityId, Details1, Details2. Where Col3 in Entity table and Details1 and Details2 in EntiryDetails table are full text indexed. I also have a NONCLUSTERED INDEX on Entity table. CREATE NONCLUSTERED INDEX [IX_LastUpdated] ON [dbo].[Entity] […]

Categories
Mastering Development

Branch.io initSession returns empty BranchUniversalObject JSON and BranchLinkProperties JSON

I’m trying to add a sharing feature to my existing app using Unity Branch SDK. I created the short URL using the following code. BranchUniversalObject universalObject = new BranchUniversalObject(); BranchLinkProperties linkProperties = new BranchLinkProperties(); string deviceUniqueIdentifier = SystemInfo.deviceUniqueIdentifier; universalObject.canonicalIdentifier = $”xLeague/{deviceUniqueIdentifier}”; universalObject.canonicalUrl = “http://xleague.games/”; universalObject.title = MetaDataManager.Title; universalObject.contentDescription = MetaDataManager.Description; universalObject.imageUrl = MetaDataManager.Image; linkProperties.controlParams.Add(“$desktop_url”, “http://xleague.games/xleague-solitaire-share/”); […]

Categories
Mastering Development

Not returning URL in discord

at the end of my rope. I’m pretty new when it comes to code I’ve been trying desperately to get this to post the url to a tweet to my discord. so far it only posts the tweet body text but if I could get it to post a link to the tweet then I […]

Categories
Mastering Development

How to extract the Abstract from PDF using PHP?

I am using pdfparser.org for parsing the pdf. I need to extract the pdf. I need the below details from PDF. Title, Author, Keywords, Abstract, Reference(Optional) In pdfparser.org we can extract the metadata only. Otherwise Full text. But how to get the Abstract. I attached the sample PDF link below. (http://www.hindex.org/2013/1V1I115.pdf) Also, please suggest the […]