popup – Magento 1.9 – How to declare two id or class name for single input field?

Magento 1 courier selection,

path : app/design/frontend/base/default/template/checkout/onepage/shipping_method/available.phtml

<span class="no-display"><input name="shipping_method" type="radio" value="<?php echo $_rate->getCode() ?>" id="s_method_<?php echo $_rate->getCode() ?>" checked="checked" /></span>
<?php else: ?>

<input name="shipping_method" type="radio" value="<?php echo $_rate->getCode() ?>" id="s_method_<?php echo $_rate->getCode() ?> "<?php if($_rate->getCode()===$this->getAddressShippingMethod()) echo ' checked="checked"' ?> class="radio"/>

The input field i need to declare another name for my popup message purpose i just declare script for same file location,

app/design/frontend/base/default/template/checkout/onepage/shipping_method/available.phtml

<script>
document.addEventListener('click', function (event) {
  if (event.target.name === 'obtrusive-radio') {
    alert(event.target.value)
  }
})
</script>

I want to assign the name obtrusive-radio but input field already have a name like “shipping_method”

certification – The correct way to declare the disposition?

I'm doing some Magento 2 certification test questions. There is one question I don't understand.

The question is like the screenshot. My answer is re, but the correct answer for the test is B

enter description of image here

I have worked a lot with XML layout, and I am pretty confident re is the correct way to declare a custom layout. But if B is the correct answer, can someone explain why?

Google Search Console – Your sitemap or sitemap index file does not correctly declare the namespace!

Here is my site map, it starts like this:








    
        https://autocostos.info/AR
        weekly
        

            
            
            
            
            
            
            
            
            

But the Google search console insists that

Your sitemap or sitemap index file does not correctly declare the namespace

They just give an example on line 16:
Line 16
Parent tag: url
Tag: link

Line 16 corresponds to

What am i doing wrong?

[ Politics ] Open question: Sources say Trump will declare a national emergency tonight and demand emergency powers. Is this the end of our democracy?

[Politic] Open question: Sources say Trump will declare a state of national emergency tonight and demand the granting of emergency powers. Is this the end of our democracy?

SQL server – Must declare the scalar variable "@utd_replace_project"

I am trying to insert missing records from the data table via the user defined table into the SQL table. upon insertion, i get error code 137 saying "Must declare the scalar variable UDT"

@ut_replace_project utd_replace_project READONLY
AS
BEGIN
 INSERT INTO dbo.tbl_replace_project ((Project_no), (project_name), (project_location), (project_startDate), (project_endDate))
 SELECT  
         urp.(Project_no)
        ,urp.(project_name)
        ,urp.(project_location)
        ,urp.(project_startDate) 
        ,urp.(project_endDate)
         FROM @ut_replace_project urp
         WHERE urp.(Project_no) NOT IN 
                   (
                     SELECT rp.Project_no
                     FROM dbo.tbl_replace_project rp WHERE rp.Project_no = urp.Project_no
                   )

END

html – How can I declare heights in CSS (without JS) if I only have widths defined in percentages?

I have attached an image with a practical exercise where you can only work with HTML and CSS3 (without JS)

The idea is to create 3 views:

Focusing only on the 1200px desktop view: it should contain, in the center of the screen, a white container where there are 3 red squares inside with 3 geometric figures of 50px x 50px placed from the same way. If you look closely, we only have the width values ​​in% (including the margins). The 3 red squares are understood to be 28% wide and 28% high.

The question is: how do I declare the height of the red squares in% if I only have the width in percentages?

Another point: the design must be reactive, that is to say that by reducing the screen size from 1200px to 400px, the red squares must keep their proportionality.

thank you so much

PS: The letters that are inside the cubes should not be written!

enter description of image here

c ++ – Clean code VS performance – how to declare a large number of variables

I have read in many threads, that from a performance standpoint, it is good to declare basic variables like int, float, bool etc. as close as possible. It is therefore preferable to declare a large number of variables in the context of MyClass::method(), that in the MyClass body. Is it the truth?

But what if I need a lot of variables and have to use them in two separate functions.
For example:

void MyClass::firstMethod()
{
    // here I use a lot of variables
    secondMethod(); // and here I need all those variables
}

It is therefore preferable (always thinking about performance) to declare all these variables in the body of MyClass? Or is it better to do something like this:

void MyClass::firstMethod()
{
    float var001, var002 ... var100;
    // here I make some calculations with all variables

    secondMethod(var001, var002 ... var100);
}

void MyClass::secondMethod(float &v001, float &v002 ... float &v100)
{
    // do some calculations
}

Of course, this sounds silly when the method gets 100 input parameters. In the book "Clean Code" by Robert C. Martin, I read that the methods should not take more than 3 or 4 input parameters. But I wonder if it has good performance in such not typical algorithms?

I'm working on an audio processor and in the audio process block I have to calculate a lot of things like calculating MID / SIDE samples, multiplying by input gain, output gain, filtering, dynamic analysis , multiply by the gain reduction coefficient and send some of these variables to the graphical wires to display them on certain audio monitors, and many other things. And I have to do this independently for each sample, and there are tens of thousands of samples per second. So is it a good practice to declare as much as possible in the scope, or better in the class body?

Please note that many of my variables must also be std::atomic, so these are not just basic variables like I said at the start. I don't know how to declare all of this to provide the best performance.

I also have more than one processor block for different audio processes that I can choose in real time in the graphical interface of my application. So is it better to make a big processor block with lots of if (or swich) instructions for choosing the processor? Or better to declare a labmda for which I can assign various processes and then call only this lambda in the main process block? And the problem is that I also have varius algorithms in each of my different processors. So I find myself calling lambdas inside other lambdas.

I am wondering how to handle all these problems to provide the best performance, but also to provide clean code as much as possible.

For any help, thank you in advance.

Best regards

Fatal error: unable to declare class WP_User_Request, because the name is already used?

Suddenly I get the following error on my website, I don't know why,
these are the following errors displayed on my website:

1) Fatal error: impossible to declare class WP_User_Request, because the name is already used in /home/hnukt37ls4nt/public_html/wp-includes/user.php on line 3657

2) Fatal error: error not caught: call to undefined function wp_kses_normalize_entities () in /home/hnukt37ls4nt/public_html/wp-includes/formatting.php:4316 Stack trace: # 0 / home / hnukt37ls4nt / public_html / wp- includes / class- wp-fatal-error-handler.php (190): esc_url (& # 39; https: // wordpre … & # 39;) # 1 / home / hnukt37ls4nt / public_html / wp-includes / class -wp-fatal-error-handler.php (147): WP_Fatal_Error_Handler-> display_default_error_template (Array, false) # 2 /home/hnukt37ls4nt/public_html/wp-includes/class-wp-fatal-error-handler.php(52) : WP_Fatal_Error_Handler-) # 3 (internal function): WP_Fatal_Error_Handler-> handle () # 4 {main} thrown in /home/hnukt37ls4nt/public_html/wp-includes/formatting.php on line 4316

Help me resolve this error,

Thanks in advance.
Cheers!!

php – Should I declare all the classes in your files?

My question is if the way i plan to do is right, does creating a class with all my other instantiated classes work?

p

Class instances {

public $ Instances;
public $ CRUD;
public objectives;

public service ArrowClasses () {

$this->Instancias = new Instancias;
$this->CRUD = new CRUD;
$this->Metas = new Metas;

}

public service SetouClasses () {

return $this->SetaClasses();

}
}

I'm sorry for the errors I have on the phone and calling each class would use automatic loading in the index, so just define the methods in their appropriate classes, can you give an example if possible?

[ Politics ] Open question: should Democrats reverse the impeachment and simply declare Trump supreme leader and allow him to continue using the office for political gain?

[Politics] Open question: should the Democrats reverse the impeachment and simply declare Trump supreme leader and allow him to continue using the office for political gain?