Contexts: browser, server
- Takes the image id provided by the storage and creates an URL like /carousel/06a55f5c-fb24-4a81-8ab8-abb0f630ce81.jpeg
- Passes it as a source to the lazy image.
<?php | |
public function markActiveNode($navigation, $currentUrl) | |
{ | |
if(!empty($navigation['nodes']) && is_array($navigation['nodes']) { | |
foreach ($navigation['nodes'] as $node) { | |
$node['isActive'] = false; | |
if(!empty($node['url'])) { | |
if($node['isVisible']) { | |
$node['isActive'] = ($node['url'] === $currentUrl); |
<?php | |
public function markActiveNode($navigation, $currentUrl) | |
{ | |
if(empty($navigation['nodes']) or !is_array($navigation['nodes']) { | |
return $navigation; | |
} | |
foreach ($navigation['nodes'] as $node) { | |
$node['isActive'] = false; |
<?php | |
foreach ($navigation['nodes'] as $node) { | |
$node['isActive'] = false; | |
if(empty($node['url'])) { | |
continue; | |
} | |
if($node['isVisible']) { |
<?php | |
foreach ($navigation['nodes'] as $node) { | |
$node['isActive'] = false; | |
if(empty($node['url'])) { | |
continue; | |
} | |
if(!$node['isVisible']) { |
<?php | |
public function markActiveNode($navigation, $currentUrl) | |
{ | |
if(empty($navigation['nodes']) or !is_array($navigation['nodes']) { | |
return $navigation; | |
} | |
foreach ($navigation['nodes'] as $node) { | |
$node['isActive'] = false; |
# | |
# Table structure for table 'tx_realurl_pathcache' | |
# | |
CREATE TABLE tx_realurl_pathcache ( | |
cache_id int(11) NOT NULL auto_increment, | |
page_id int(11) DEFAULT '0' NOT NULL, | |
language_id int(11) DEFAULT '0' NOT NULL, | |
rootpage_id int(11) DEFAULT '0' NOT NULL, | |
mpvar tinytext NOT NULL, | |
pagepath text NOT NULL, |
var dust = require('dustjs-linkedin'), | |
express = require('express'), | |
cons = require('consolidate'); | |
app.engine('dust', cons.dust); | |
app.set('view engine', 'dust'); | |
app.set('views', __dirname + '/theme/dust'); | |
app.use(express.static(__dirname + '/theme')); |
// the test fails but there is no description about what happened | |
request.post('/endpoint').expect(200).end(function(err, res) { | |
if (err) return done(err); | |
res.body.email.should.be.a('string'); | |
res.body.email.should.equal('mail@example.org'); | |
done(); | |
}); |