Shortcode called twice – WordPress Development Stack Exchange

I'm working on my product information with a shortcode that can automatically generate a spreadsheet with information. But it looks like the shortcode is called twice. I'm not a great backend developer, but I'm trying to learn some basics so I can build some basic PHP functions. I would be very happy about help. Thank you in advance.

My code looks like this:

function displayTable()
{
    echo '';
    echo '';
    $fields = get_field_objects();
    foreach($fields as $field)
    {
      echo '';
      echo '';
      echo '';
    }
    echo '';
    echo '
'; echo ''. $field('label') .''. $field('value') .'
'; } add_shortcode('popnagel-tabel', 'displayTable')

Algorithms – Compiler shows: Abort Called

When does a C ++ compiler issue the following message: "terminate is called after an instance of & # 39; std :: out_of_range & # 39; was triggered"? I tried this problem of a website. I wrote an algorithm, but the code can not be compiled.

Enter image description here

The algorithm I wrote was this:

int stringSimilarity(string s) {
int size=s.size(), sum=0;

for(int i=0; i

Can someone please tell me where I am wrong?

Enter image description here

json rpc – rpc API can not be called from another computer on the same local network

rpc api can not be called from another machine on the same local network

There is a test node on my local network that I can call rpc api Only from the node's machine, not from my local machine.

I know rpcallowip is changed in the current version https://bitcoin.org/en/release/v0.18.0#configuration-option-changes

http clinet httpie

IP of my local machine: 192.168.1.155

IP of the BTC node: 192.168.1.132

the harbor 8332 it is open.

$ bitcoind -version                 
# Bitcoin Core Daemon version v0.18.0.0-g2472733a24a9364e4c6233ccd04166a26a68cc65

I start testing and my IP is 192.168.1.155

bitcoind -regtest -deprecatedrpc=generate -printtoconsole -rpcuser=user -rpcpassword=password -rpcallowip=0.0.0.0/24 -rpcbind=127.0.0.1  -server -rpcport=8332

customer request

# request from btc node's machine
http POST http://user:password@127.0.0.1:8332 jsonrpc="2.0" method="getblockchaininfo" id=1
# successed

# request from my local machine 192.168.1.155
http POST http://user:password@192.168.1.132:8332 jsonrpc="2.0" method="getblockchaininfo" id=1
# http: error: ConnectionError: HTTPConnectionPool(host='192.168.1.132', port=8332): Max retries exceeded with url: / (Caused by NewConnectionError(': Failed to establish a new connection: (Errno 111) Connection refused',)) while doing POST request to URL: http://user:password@192.168.1.132:8332/

Functions – Why is it called a functional component?

A quick Google search shows that the question I asked was not directly asked. That's why I'm putting her here. For what it pays, I learn to react and come from a C ++ background, in my knowledge, "functional components" are not a thing.

Taken from a tutorial, this seems to be a barebone example of a functional component

import React from 'react';
function App() 
{
        const greeting = 'Hello Function Component!';
        return 

{greeting}

; } export default App;

It just looks like a function to me, and yet it's called a functional component in the response.

  • Why is the term "feature component" used?
  • Why not "Component Function"?
  • If I just called that a function, would the reacting developers be confused?

Thank you very much.

SOAP APIs: How a response updates a database and where it is called from

I believe I have a void in understanding the process that a request and response go through to create, read, update, and delete using a SOAP API. I have the WSDL. I have created, read, updated and deleted the APIs in SoapUI with XML.

But is not the main purpose of an API to connect two applications together to communicate with each other? Well, I have SoapUI, but I need my database to connect (with SOAP) to an Excel workbook, assessment software, and other applications. Obviously, none of my users will know how to write XML and send the request to the database using SoapUI. How are the records created if they do not know XML? Where are the API calls on GitHub? Somewhere on another website? How do I access this location and tell it to retrieve this information from rating software and paste it into these tables and columns in my database?

I'm having trouble understanding how to set up an API so that when a record is added to a rating software, it automatically updates my database with the review information in the rating software. Or like when a workbook is saved to Excel, my database is automatically updated with the information in the workbook. Do these other applications need to have an API for the APIs / endpoints of my database to interact with? If so, do the other applications also need SOAP? If so, is it possible to convert REST to SOAP?

The database my company uses is hosted in the cloud and has a VB front-end. I have access to the backend tables and stored procedures, but only from a snapshot of the database created a few months ago. Also, nothing is possible which requires saving in the directory of the database.

I know that I have a few questions in this post, but I hope you get an understanding of where I am wrong and what the gap is in my understanding of APIs. Please help me to understand. Thank you in advance!!!!

python – selenium does not work (no module called selenium)

running windows 10 and pycharm pro,

Install Selenium from the command prompt with Pip on Python 3.7

Selenium installed via the project interpreter on my IDE

but when I run from selenium import webdriver
I get

ModuleNotFoundError: No module named 'selenium'

Can I check something else? or steps of the installation process that I missed?

  • I tried to invalidate / restart the cache

node.js – npm ERR! cb () never called! when trying to create a new Angular app

I tried to create a new Angular app for my web project at school, but I can not seem to be able to do so because of an unknown bug – cb () never called! I have a log of the console, but I can not find anything useful that I can use to fix the error. That's why I decided that I would post in forums and try to get posts from other users. Already posted in the npmcommunity forum, but I have no answers there yet.

After going through the normal process of creating a new app, I come to the last command "ng new angle-tour-of-heroes". After some time it goes with it

npm ERR! cb () never called!

npm ERR! This is a mistake at npm. Please report this error:
npm ERR! https://npm.community

npm ERR! A complete log of this run can be found in:
npm ERR! C: Users lache AppData Roaming npm-cache_logs 2019-09-11T16_05_41_529Z-debug.log
Package installation failed, see above.

The log is 866,000 characters long, so I can not paste it here and I'm not sure how to link it.

I'm running Node 10.16.3 and Npm 6.9.0.

If this is an inappropriate place to post, please tell me where it would be more appropriate.

8 – hook_theme () is not called

I have a module called picnic, Here is hook_theme():

notice($message);

    return (
        'picnic_list' => (
            'template' => 'picnic_list',
            'path' => $path . '/templates',
            'variables' => (
                'picnic_name' => 'Default Picnic',
                'picnic_items' => ('Bacon')
            )
        )
    );
}

Here is my controller, PicnicController:

     'picnic_list',
            '#picnic_name' => 'Super Picnic',
            '#picnic_items' => $items,
        );
      }
    }

Here is my template file, which is located on /modules/picnic/templates/picnic-list.html.twig:

Here is a test!

When I go to the route, I have defined the usage PicnicController::description Only the title and not the contents of the template file are output. When I go to the last log messages, there is a message saying Theme hook picnic_list not found. I emptied caches and also uninstalled the module and then activated it again.

Why is not hook_theme () called? The Picnic Theme Hook called Message is never logged.