The role of the HtmlHelper in CakePHP is to make HTML-related
options easier, faster, and more resilient to change. Using this
helper will enable your application to be more light on its feet,
and more flexible on where it is placed in relation to the root of
a domain.
Inserting Well-Formatted Elements
The most important task the HtmlHelper accomplishes is creating
well formed markup. This section will cover some of the
methods of the HtmlHelper and how to use them.
Linking to CSS Files
-
Cake\View\Helper\HtmlHelper::
css
(mixed $path, array $options = [])
Creates a link(s) to a CSS style-sheet. If the block
option is set to
true
, the link tags are added to the css
block which you can print
inside the head tag of the document.
You can use the block
option to control which block the link element
will be appended to. By default it will append to the css
block.
If key ‘rel’ in $options
array is set to ‘import’ the stylesheet will be imported.
This method of CSS inclusion assumes that the CSS file specified
resides inside the webroot/css directory if path doesn’t start with a ‘/’.
echo $this->Html->css('forms');
Will output:
<link rel="stylesheet" href="/css/forms.css" />
The first parameter can be an array to include multiple files.
echo $this->Html->css(['forms', 'tables', 'menu']);
Will output:
<link rel="stylesheet" href="/css/forms.css" />
<link rel="stylesheet" href="/css/tables.css" />
<link rel="stylesheet" href="/css/menu.css" />
You can include CSS files from any loaded plugin using
plugin syntax. To include plugins/DebugKit/webroot/css/toolbar.css
you could use the following:
echo $this->Html->css('DebugKit.toolbar.css');
If you want to include a CSS file which shares a name with a loaded
plugin you can do the following. For example if you had a Blog
plugin,
and also wanted to include webroot/css/Blog.common.css, you would:
echo $this->Html->css('Blog.common.css', ['plugin' => false]);
Creating CSS Programatically
-
Cake\View\Helper\HtmlHelper::
style
(array $data, boolean $oneline = true)
Builds CSS style definitions based on the keys and values of the
array passed to the method. Especially handy if your CSS file is
dynamic.
echo $this->Html->style([
'background' => '#633',
'border-bottom' => '1px solid #000',
'padding' => '10px'
]);
Will output:
background:#633; border-bottom:1px solid #000; padding:10px;
Creating DOCTYPE
-
Cake\View\Helper\HtmlHelper::
docType
(string $type = 'html5')
Returns a (X)HTML DOCTYPE (document type declaration). Supply the document
type according to the following table:
| type |
translated value |
| html4-strict |
HTML 4.01 Strict |
| html4-trans |
HTML 4.01 Transitional |
| html4-frame |
HTML 4.01 Frameset |
| html5 (default) |
HTML5 |
| xhtml-strict |
XHTML 1.0 Strict |
| xhtml-trans |
XHTML 1.0 Transitional |
| xhtml-frame |
XHTML 1.0 Frameset |
| xhtml11 |
XHTML 1.1 |
echo $this->Html->docType();
// Outputs: <!DOCTYPE html>
echo $this->Html->docType('html4-trans');
// Outputs:
// <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
// "http://www.w3.org/TR/html4/loose.dtd">
Linking to Images
-
Cake\View\Helper\HtmlHelper::
image
(string $path, array $options = [])
Creates a formatted image tag. The path supplied should be relative
to webroot/img/.
echo $this->Html->image('cake_logo.png', ['alt' => 'CakePHP']);
Will output:

To create an image link specify the link destination using the
url
option in $attributes
.
echo $this->Html->image("recipes/6.jpg", [
"alt" => "Brownies",
'url' => ['controller' => 'Recipes', 'action' => 'view', 6]
]);
Will output:

If you are creating images in emails, or want absolute paths to images you
can use the fullBase
option:
echo $this->Html->image("logo.png", ['fullBase' => true]);
Will output:

You can include image files from any loaded plugin using
plugin syntax. To include plugins/DebugKit/webroot/img/icon.png
You could use the following:
echo $this->Html->image('DebugKit.icon.png');
If you want to include an image file which shares a name with a loaded
plugin you can do the following. For example if you had a Blog
plugin,
and also wanted to include webroot/img/Blog.icon.png, you would:
echo $this->Html->image('Blog.icon.png', ['plugin' => false]);
Creating Links
-
Cake\View\Helper\HtmlHelper::
link
(string $title, mixed $url = null, array $options = [])
General purpose method for creating HTML links. Use $options
to
specify attributes for the element and whether or not the
$title
should be escaped.
echo $this->Html->link(
'Enter',
'/pages/home',
['class' => 'button', 'target' => '_blank']
);
Will output:
Enter
Use '_full'=>true
option for absolute URLs:
echo $this->Html->link(
'Dashboard',
['controller' => 'Dashboards', 'action' => 'index', '_full' => true]
);
Will output:
Dashboard
Specify confirm
key in options to display a JavaScript confirm()
dialog:
echo $this->Html->link(
'Delete',
['controller' => 'Recipes', 'action' => 'delete', 6],
['confirm' => 'Are you sure you wish to delete this recipe?']
);
Will output:

Delete

Query strings can also be created with link()
.
echo $this->Html->link('View image', [
'controller' => 'Images',
'action' => 'view',
1,
'?' => ['height' => 400, 'width' => 500]
]);
Will output:
View image
HTML special characters in $title
will be converted to HTML
entities. To disable this conversion, set the escape option to
false
in the $options
array.
echo $this->Html->link(
$this->Html->image("recipes/6.jpg", ["alt" => "Brownies"]),
"recipes/view/6",
['escape' => false]
);
Will output:

Setting escape
to false
will also disable escaping of attributes of the
link. You can use the option escapeTitle
to disable just
escaping of title and not the attributes.
echo $this->Html->link(
$this->Html->image('recipes/6.jpg', ['alt' => 'Brownies']),
'recipes/view/6',
['escapeTitle' => false, 'title' => 'hi "howdy"']
);
Will output:

Also check Cake\View\Helper\UrlHelper::build()
method
for more examples of different types of URLs.
Linking to Videos and Audio Files
-
Cake\View\Helper\HtmlHelper::
media
(string|array $path, array $options)
Options:
type
Type of media element to generate, valid values are “audio”
or “video”. If type is not provided media type is guessed based on
file’s mime type.
text
Text to include inside the video tag
pathPrefix
Path prefix to use for relative URLs, defaults to
‘files/’
fullBase
If provided the src attribute will get a full address
including domain name
Returns a formatted audio/video tag:
<?= $this->Html->media('audio.mp3') ?>
// Output
<audio src="/files/audio.mp3"></audio>
<?= $this->Html->media('video.mp4', [
'fullBase' => true,
'text' => 'Fallback text'
]) ?>
// Output
<video src="http://www.somehost.com/files/video.mp4">Fallback text</video>
<?= $this->Html->media(
['video.mp4', ['src' => 'video.ogg', 'type' => "video/ogg; codecs='theora, vorbis'"]],
['autoplay']
) ?>
// Output
<video autoplay="autoplay">
<source src="/files/video.mp4" type="video/mp4"/>
<source src="/files/video.ogg" type="video/ogg;
codecs='theora, vorbis'"/>
</video>
Linking to Javascript Files
-
Cake\View\Helper\HtmlHelper::
script
(mixed $url, mixed $options)
Include a script file(s), contained either locally or as a remote URL.
By default, script tags are added to the document inline. If you override
this by setting $options['block']
to true
, the script tags will instead
be added to the script
block which you can print elsewhere in the document.
If you wish to override which block name is used, you can do so by setting
$options['block']
.
$options['once']
controls whether or
not you want to include this script once per request or more than
once. This defaults to true
.
You can use $options to set additional properties to the
generated script tag. If an array of script tags is used, the
attributes will be applied to all of the generated script tags.
This method of JavaScript file inclusion assumes that the
JavaScript file specified resides inside the webroot/js
directory:
echo $this->Html->script('scripts');
Will output:

You can link to files with absolute paths as well to link files
that are not in webroot/js:
echo $this->Html->script('/otherdir/script_file');
You can also link to a remote URL:
echo $this->Html->script('http://code.jquery.com/jquery.min.js');
Will output:

The first parameter can be an array to include multiple files.
echo $this->Html->script(['jquery', 'wysiwyg', 'scripts']);
Will output:

You can append the script tag to a specific block using the block
option:
echo $this->Html->script('wysiwyg', ['block' => 'scriptBottom']);
In your layout you can output all the script tags added to ‘scriptBottom’:
echo $this->fetch('scriptBottom');
You can include script files from any loaded plugin using
plugin syntax. To include plugins/DebugKit/webroot/js/toolbar.js
You could use the following:
echo $this->Html->script('DebugKit.toolbar.js');
If you want to include a script file which shares a name with a loaded
plugin you can do the following. For example if you had a Blog
plugin,
and also wanted to include webroot/js/Blog.plugins.js, you would:
echo $this->Html->script('Blog.plugins.js', ['plugin' => false]);
Creating Inline Javascript Blocks
-
Cake\View\Helper\HtmlHelper::
scriptBlock
($code, $options = [])
To generate Javascript blocks from PHP view code, you can use one of the script
block methods. Scripts can either be output in place, or buffered into a block:
// Define a script block all at once, with the defer attribute.
$this->Html->scriptBlock('alert("hi")', ['defer' => true]);
// Buffer a script block to be output later.
$this->Html->scriptBlock('alert("hi")', ['block' => true]);
-
Cake\View\Helper\HtmlHelper::
scriptStart
($options = [])
-
Cake\View\Helper\HtmlHelper::
scriptEnd
()
You can use the scriptStart()
method to create a capturing block that will
output into a


Lara Croft: Tomb Raider
Lara Croft: Tomb Raider is a movie starring Angelina Jolie, Jon Voight, and Iain Glen. Video game adventurer Lara Croft comes to life in a movie where she races against time and villains to recover powerful ancient artifacts.


# We are working with a suspended state so we need to combine *.vmss and *.vmem. If we were
dealing with a snapshot we would need to combine *.vmsn and *.vmem.
Avalon:Tools b33f$ ./vmss2core_mac64 -W
/Users/b33f/Documents/VMware/VMs/Win7-Testbed/Windows\ 7.vmwarevm/Windows\ 7-e7a44fca.vmss
/Users/b33f/Documents/VMware/VMs/Win7-Testbed/Windows\ 7.vmwarevm/Windows\ 7-e7a44fca.vmem
vmss2core version 3157536 Copyright (C) 1998-2013 VMware, Inc. All rights reserved.
Win32: found DDB at PA 0x2930c28
Win32: MmPfnDatabase=0x82970700
Win32: PsLoadedModuleList=0x82950850
Win32: PsActiveProcessHead=0x82948f18
Win32: KiBugcheckData=0x82968a40
Win32: KernBase=0x82806000
Win32: NtBuildLab=0x82850fa8
Win: ntBuildLab=7601.17514.x86fre.win7sp1_rtm.101119-1850 # Win7 SP1 x86
CoreDumpScanWin32: MinorVersion set to 7601
... 10 MBs written.
... 20 MBs written.
... 30 MBs written.
... 40 MBs written.
... 50 MBs written.
[...Snip...]
Finished writing core.


This is bold This is italic
This is both bold and italic you fix it!
Here is a link to google.ca
Here is an image
Now make a linked picture
Now make a table, with three names in the first row and eye colour in the second
Juan
Pablo
Jose
Blue
Green
Amber
Now an ordered list of favourite foods
Pizza
Bacon
Potatoes
Deer/Moose
Satanic Chicken
You add 5 ore items to the list
here are some input methods :
and a few fancy ones:


Word Game Summary
The jQuery Word Game project is a plugin that creates word grids for use in word games.
5x5 Grid
Please read the word game documentation for instructions on how to use the plugin.
Options
- classmodifier
- Used to apply class names to the elements created by the plugin. You only need to specify a class modifier if you have a name-clash.
- gridwidth
- The number of columns to display.
- gridheight
- The number of rows to display.
- allowable
- A comma separated list of allowable values.


SIEGESTONES
Copyright (c) 2003 Patrick Matthews, Live Oak Games
This game is played on the following board:
There are 20 stones for each player off board, and also 9 neutral stones (called towers).
- TURN - On each turn, each player must do one of the following actions:
- Drop a friendly stone on an empty cell.
- Each friendly stone has a threat rating (TR) equals to 6 minus the number of adjacent towers.
- Drop a tower on an empty cell.
- After the turn, the player places a friendly stone on every tower he controls (this is just to help figure out who owns what towers).
- A tower is controlled by the player with the greatest TR sum of his adjacent stones (provided that this sum is greater than four).
- GOAL - Wins the player that controls four towers.
- If the board is fully occupied before that happens, wins the player with more controlled towers. If both players control the same number of towers, wins the one with more stones on board. Otherwise, it is a draw.
The second criteria to decide a winner seems to give an advantage to the first player. Perhaps a better criteria is to win the player with greatest TR sum of all his pieces.
Control examples (in the diagram, towers are represented by red marks)
The tower at d6 is black, since the is a total TR of 15 for black and only 10 for white.
The tower at b3 is also black. There are 3 white stones and 3 black stones, but one white stone is adjacent to two towers, which reduces its TR by one, so Black wins the tower by 15-14.
The tower at b1 is not controlled by White, because his TR is only 4 (it must be at least 5 to control a tower).
The tower at e4 is also not controlled by anyone, since there is a tie of 5-5 between both players (each player only has one adjacent stone).
Check the official game website.


With a jury sworn in ready to hear evidence, James Anderson Weir (67) had been due to go on trial at Downpatrick Crown Court but instead, defence QC Niall Hunt asked trial Judge Geoffrey Miller QC for the charge to be put to Weir again.
It was then that Weir, from Manor Street, admitted trying to kill his father James Weir Snr on November 24 last year.
An earlier court heard how staff at the Newtownards care home contacted police after they saw Weir holding a pillow above his father’s face, believing he was trying to “suffocate” his dad.
Having taken the pillow off him Mr Weir Snr, who has since passed away, was examined by a doctor and taken to hospital while his intoxicated son was arrested.
In court yesterday, Judge Miller freed Weir on continuing bail, ordered a pre-sentence report and said he would pass sentence in the New Year.


Last update on 20 April 2017.
Parts needed
| Name | Quantity | Where to use |
|---|---|---|
| Platform sheet | 1 | Sheet on which everything is built |
| DC motors with planetary gears | 2 | Moving the platform |
| Motor gear | 2 | On motor |
| Tracks | 66 | |
| Cart wheel | 1 | back side |
| L profile 600x25x25mm, 3mm thick | 2 | Reinforcement for sheet |
| M12x150 hexa screw | 4 | Shaft for wheels |
| M12 long nut | 8 | Spacer for wheels |
| Radial bearing 6201rs | 8 | Shaft support |
| Radial bearing housing 6201 | 8 | Shaft support |
| M4x60 sunken screw | 16 | Fix the 6201 bearing housing |
| M12 autolock nut | 4 | Fix shaft after the 1st radial bearing |
| Washer 12x24 | 12 | Wheel shaft |
| M4x70 cylindric head | 16 | Wheel build |
| M4 autolock nut | 16 | Wheel build |
| Wood screw 40mm | 10 | Fixing reinforcement profile to sheet |
| M4x25 | 10 | Fixing reinforcement profile to sheet |
| M4x25 sunken | 8 | Fixing the motor housing to platform |
| M4 autolock nut | 8 | Fixing the motor housing to platform |
| 4x12 washer | 8 | Fixing the motor housing to platform |
| M4x10 sunken screw | 8 | Fixing the motor to housing |
| Rectangular tube 10x10mm, 2mm wall | 4 | Bridge between platform sheet and cart wheel |
| M4x30 hexa screw | 4 | Fixing the cart wheel to tubes |
| M4 autolock nut | 4 | Fixing the cart wheel to tubes |
| 4x12 washer | 8 | Fixing the cart wheel to tubes |
| M4x50 hexa screw | 4 | Fixing the bridge tubes to platform |
| M4 autolock nut | 4 | Fixing the bridge tubes to platform |
| 4x15 washer | many | Spacer between bridge tubes and sheet |
Platform sheet
BOTTOM SIDE
first shaft first bearing [10, 29]
first shaft first bearing [50, 29]
first shaft second bearing [10, 92]
first shaft second bearing [50, 92]
second shaft first bearing [240, 29]
second shaft first bearing [280, 29]
second shaft second bearing [240, 92]
second shaft second bearing [280, 92]
motor housing holes [66, 43]
motor housing holes [99, 43]
motor housing holes [66, 11]
motor housing holes [99, 11]
TOP SIDE
The same as the bottom side, but the measurements are made from the other side.
Final assembly


PokeMon Database
Add a PokeMon
Add a Pokemon
×
Pokemon Type
Default
Bug
Dragon
Electric
Fighting
Fire
Flying
Ghost
Grass
Ground
Ice
Normal
Poison
Psychic
Rock
Water
None
Bug
Dragon
Electric
Fighting
Fire
Flying
Ghost
Grass
Ground
Ice
Normal
Poison
Psychic
Rock
Water
Pokemon Weakness
Default
Bug
Dragon
Electric
Fighting
Fire
Flying
Ghost
Grass
Ground
Ice
Normal
Poison
Psychic
Rock
Water
None
Bug
Dragon
Electric
Fighting
Fire
Flying
Ghost
Grass
Ground
Ice
Normal
Poison
Psychic
Rock
Water
Does the Pokemon Evolve?
Yes
No
Pokemon Type
Default
Bug
Dragon
Electric
Fighting
Fire
Flying
Ghost
Grass
Ground
Ice
Normal
Poison
Psychic
Rock
Water
None
Bug
Dragon
Electric
Fighting
Fire
Flying
Ghost
Grass
Ground
Ice
Normal
Poison
Psychic
Rock
Water
Pokemon Weakness
Default
Bug
Dragon
Electric
Fighting
Fire
Flying
Ghost
Grass
Ground
Ice
Normal
Poison
Psychic
Rock
Water
None
Bug
Dragon
Electric
Fighting
Fire
Flying
Ghost
Grass
Ground
Ice
Normal
Poison
Psychic
Rock
Water
Does the Pokemon Evolve?
Yes
No
Save Changes
✖