Język polskiEnglish language
Products Company Partnership Contact News Online store Download

Embedding CubeWalk on a web page

CubeWalk is very easy to embed on your web page. The instruction below will guide you through the whole process.

CubeWalk is composed of a set of files, the files include jpeg pictures and a CubeWalk description file called 'cubeWalk'.

First make sure that your document is HTML5. You need to specify a document type like this:

<!DOCTYPE html>

Then you must:
  • Include CubeWalk.js file.
  • Call CubeWalk_Init (divId, cubeWalkPath) JavaScript function to initialize CubeWalk on a particular div. The first parameter is a Id of a CubeWalk container div. The second parameter is a relative location of a cubeWalk file along with its name.
  • Add a CubeWalk container div to your document.

The full HTML5 code looks like this:

<!DOCTYPE html>
        <script src="http://pixelplan.pl/cube-walk/cubeWalk.min.js"></script>
    <body onLoad="CubeWalk_Init ('CubeWalk', '../cube-walk/examples/apartment/cubeWalk');">
        <div id="CubeWalk" style="width: 800px; height: 600px;">

And this is it. Have a good time playing around with CubeWalk!

Copyright © 2008 - 2018 Pixelplan S.C., All rights reserved.