Ajax – How can I correct my function to display the result?

I'm doing project with XML file, xslt
I have a function that displays the result of the search, but if the result is not found, I want to say something like "nothing was found," but right now my function never goes into the other part of my code

Here is my code

  function Afficher(xml)
        var res = document.getElementById("result");
        res.innerHTML = "";
        if (xml != null) {

            var p = document.createElement("p");
            xsltProcessor = new XSLTProcessor();
            resultDocument = xsltProcessor.transformToFragment(xml, document);
            p = document.getElementById("result").innerHTML = "Voici les résultat de la recherche";
            document.getElementById("result").style.fontSize = "x-large";
        else {
            document.getElementById("result").innerHTML = "Aucun cours trouvé"; 

The mysql workbench debug query does not display any result rows

If I want to debug mysql workbench 6.3 on ubuntu 18 SQL, I'll click on the toolbar "Create new SQL tab to run queries"
and new tab editor opens. When I click "Run Selected Part …" in the toolbar, information about the executed SQL is displayed.
but not result lines, as I expected: https://imgur.com/a/wnRKTUO.
1] Is it a hidden area?

2] I do not want to use all my databases for this connection. How can I hide some databases without deleting them?

Thanks a lot!

php – I can not get a result from my function

One problem is that you need to pass the $ post_id to the function in order to work with it.

global $post;

check_gtin( $post->ID );

function check_gtin( $post_id ) { /* ... */ }

Another problem is that in PHP, single quotes are meant to be literal strings, and do not output the variables they contain. There are several ways to convert this to working code:

echo "gtin13:{$gtin}";
echo 'gtin13:' . $gtin;
printf( 'gtin13:%s', $gtin );

Depending on how you set the post-meta, it may also result in an "empty" but not an empty string '', Personally, I prefer to use empty() to check if something exists. This checks for empty arrays, empty strings, 0, false.

To bring it together, it might look like this:

 * Display GTIN
 * @param Integer $post_id
 * @return void
function check_gtin( $post_id ) {

    $gtin = get_post_meta( $post_id, 'gtin', true );

    if( ! empty( $gtin ) ) {
        echo "gtin13:{$gtin}";
    } else {
        echo 'identifier_exits:false';


seo – Rich Snippet's last breadcrumb does not appear in the search result

I struggle with rich snippets of breadcrumbs and how they appear in Google SERP

The code passes the Google Data Structure test. The Google search results page will display a rich snippet for my site if there is a breadcrumb on that particular page

I see these https://www.example.com> collections

I try to get that

but it would be https://www.example.com> collections> item3

I tried to add


Can I avoid the last breadcrumb being a link on the website?
Or is the only way to create a link with similar code as content = "1" and content = "2"
edit: I just tried to make a link from the last breadcrumb and updated the SERP with the search panel, but it still does not show item3

The solution sought should not be JSON-LD

Javascript – Doubts understanding the result of "Object.keys" within an if statement

These are two functions, one of which checks whether the parameter received in the function (isObject) is an object and the other that uses this function to validate the input to proceed to the next steps that provide property names should be countable (if that is the case)

A related question Reference / value of object "object.keys" within the function below.

Line 4: Why to return this "if → → (Object.keys) ← object.keys (obj)"? and how can it be wrong or true?

function _keys(obj) 
    if (!isObject(obj)) return ();
    if (Object.keys) return Object.keys(obj);
    var keys = ();
    for (var key in obj) if (_.has(obj, key)) keys.push(key);
    return keys;
function isObject(obj) 
    var type = typeof obj;
    return type === 'function' || type === 'object' && !!obj;
console.log(_keys({red: "#FF0000", green: "#00FF00", white: "#FFFFFF"}));

Drupal 8 website would not load for anonymous users. As a result, the allowable memory size of 629145600 bytes is exhausted

We have a Drupal 8.7.6 that works fine when logged in as an administrator. All pages, features work flawlessly and provide good performance.

When I tried to load the site as an anonymous user, it continued to spin and ended up with a broken 504 gateway. The logs show the following error:

2019/08/14 20:39:42 (error) 25423 # 25423: * 15460 FastCGI sent in stderr: "PHP message: Fatal PHP error: Allowed memory size of 629145600 bytes exhausted (trying to allocate 20480 bytes) in / core / lib / Drupal / Core / Entity / ContentEntityBase.php on line 191 "while the response header is read from the upstream

(Bug) 25423 # 25423: * 14852 FastCGI sent in stderr: "PHP message: Fatal PHP error: Maximum execution time of 30 seconds exceeded in /core/lib/Drupal/Core/Entity/Sql/SqlContentEntityStorage.php on line 606 "reading the response header from the upstream

All this worked fine until yesterday, before we started migrating users and content from our old Drupal 6 system.

We have a similar setup for our development environment that works perfectly well.

I tried setting the execution time in settings.php to 0 to increase the allowed memory, and so on, but this problem persists. There is a lot of data being migrated and I can not recover it from the new copy we have.

Please recommend possible solutions – Thank you in advance.

Maximum result

If you want to earn money quickly in this trading center, you must first acquire the most powerful analytics trading skills through learning. So it would be great if we choose the broker who always guarantees exclusive educational institutions.

sql – result + MySQL result grouping

Good Morning!

I have enormous doubts about the compilation of this query, which I attach. I have one table and cross it with another to know in which state most sales were made, where the result is grouped and displays the state's total value.

I would like to bring the overall result grouped by state among the top 5 cities.

Because I know that in my table data, order, state, city, value, etc. are.

The result that I currently have is this:

Enter image description here

I would like the result to be in this different format:

Enter image description here

Is there a way to do this? If someone has content to study, this is a great help.

Calculate in a multi-tape Turing machine [a binary substraction between 2 numbers and result on 3rd tape]?

I am trying to compute a multi-tape Turing machine (with 3 bands) that follows this statement.

A binary subtraction operation between the first and second bands prints the result on the third band.

I tried to do it in JFlap, but I've reached a point where I'm quite confused on the subject altogether.

Any help regarding this MTTM would be greatly appreciated.

How do I use multiple codes to get a result in a similar statement in MySQL?

I have a spreadsheet where the uploaded file information is stored as follows.

Enter image description here

I wrote query below to get the upload result.

set @v_stk_code = '50400'; -- 2753,8601
set @v_date = '0619';
set @sas = (Select Count(file_name) from ims_data.batchlog where file_name like concat('%',@v_stk_code ,'%',@v_date,'.txt','%') and file_name like 'SAS%' and upload_status = 'success');
set @product = (Select Count(file_name) from ims_data.batchlog where file_name like concat('%',@v_stk_code ,'%',@v_date,'.txt','%') and file_name like 'P%' and upload_status = 'success');
Select @v_stk_code,
        when @sas=0 and @product=0 then 'SAS and Product not Uploaded' 
        when @sas>0 and @product>0 then 'SAS and Product is Uploaded' 
        when @sas>0 and @product=0 then 'SAS uploaded but Product File Missing' 
        when @sas=0 and @product>0 then 'Product uploaded but SAS File Missing' 
    end as `Status`;

I get the result for an examined code. But I want several stockiest result that would be provided in parameter.