Shared Flashcard Set

Details

Controllers
Knowledge Check for Using JS Controllers
6
Software
Intermediate
07/30/2017

Additional Software Flashcards

 


 

Cards

Term

Which of the Following Functions can be accomplished with a Guard?

  1. Require a Secure connection
  2. Require a WebDav connection
  3. Require that the customer is logged in
  4. require or forbid a specific http method
Definition
1, 3, 4
Term

Which have higher priority, JavaScript controllers or Pipelines? 

 

1. JavaScript controllers

2. Pipelines

3. Whichever comes first in the cartridge path

4. They have equal priority

Definition
1
Term

What does the guard script module ensure? 

(all that apply)

 

1. That the function is invoked from a job

2. That the customer is not registered 

3. That the customer is Logged in

4. That the function is public or private

Definition
3, 4
Term

If you were editing an address.isml template, what JavaScript code would you use to pass the string value "State" to the "x" variable?

1. ISML.renderTemplate('address', {'State':x} );

2. ISML.renderTemplate('address', {x:'State'} );

3. renderISML(x, 'State', 'address.isml');

4. pdict.load("address",x,"State");

Definition
2
Term

When you render a JSON object without using an ISML template, can you cache the response?

 

1. Yes, by setting the expiration time at the response.

2. Yes, by putting the <iscache> tag in the script

3. No, JSON objects cannot be cached

4. No, caching is only possible in ISML

Definition
1
Term

product.js contains response.setExpires(20)

product.isml contains <iscache type="relative" minute="30">

If the product.js file calls the product.isml template, what is the resulting cache time? 

 

1. 50 mins

2. 20 mins

3. 30 mins

4. 0 mins

5. Unknown. An error is returned

Definition
2
Supporting users have an ad free experience!