VSource Web Solutions About Us  |  News  |  Contact Info  |  Network  |  Policies  |  Login  |  Support  |  Forum  |  (866) 346-9327


Online Demo



   
 
Search Documentation Search Documentation
 
   

The Wizard Manager

   
 
Table Of Contents - Collapse

NEXT: Wizard Manager Parameters
 
   

Introduction:
The Wizard Manager can be called in 2 different ways. The first is if you have a Wizardmanager type module. If this is the case, then the only thing that the module does is output a wizard to the user. Usually, this type of module is used for updating properties or to perform an action that has nothing to do with datamanager managed data. The second way that the Wizard Manager is called is if you create a datamanager action that is formatted as a wizardmanager action file. These types of files are used to manage datamanager managed data. (See here for more information on datamanager actions.) Either way, everything pretty much works the same whether you use it as a module or as a datamanager action except for the part where you have to output your results to the browser after the wizardmanager() function returns. (Don't worry, there are code files that you can download that contain the code that is needed below.) OK, that being said, let's explain more about what the Wizard Manager does.

What does the Wizard Manager do?
The Wizard Manager allows you to output a step by step wizard to the user that collects input from them and then returns that input to your php script. The input that is returned to you is fully validated according to the validation parameters that you set. You then take that input and do something with it. Usually, you would update a record in your database or maybe create a file based on the users input. You can even define step conditions that check the input from previous steps to determine whether or not to execute the next step. This allows you to give the user a fully customized wizard experience. The user can actually go backward and forward in the wizard and the wizard manager remembers their input and / or changes the steps that are shown for when they navigate back and forth through the wizard interface. The Wizard Manager actually consists of 3 things. A data structure, the wizardmanager() function, and the return where you actually do something with the input.

How does the Wizard Manager work?
You simply create a data structure and hand that data structure off to the wizardmanager() function. When the function returns, you get an array of all the input values from the user. You should then take those values and do something with them like update your database, create a file, send an email, etc.... Whatever you do with the input data from the user is up to you. However, it is good practice to let the user know what you are going to do with the data that they are entering. OK, so let's take a look at the skeleton files. The files listed below are the default files that you should use to build your wizard manager modules and action files from. The files are heavily commented so you should just be able to copy the code, then modify the file to meet your needs. Also, if you have the VConsole Developers Toolkit for Dreamweaver® installed, then you don't have to copy the code in the files below. All you need to do is select "New Wizardmanager Module" or "New Wizardmanager Action File" from the VConsole drop down menu and the files are created for you.

OK, so let's take a look at the components of the Wizard Manager from a user's perspective. Here is an illustration of all the different components.
Wizard Manager Components

  1. This is the title of the wizard. This is shown in every step.
  2. This is the image that is displayed in the wizard. Remember, it is a visual world. Icons like this give the user an idea of what they are doing. This is also shown at every step.
  3. This is also the title of the wizard. It is duplicated for clarification to the user. This is also shown at every step. (You can get rid of this by modifying the wizardmanager.html template file. (See Customizing Look and Feel for more info)
  4. This is the wizard information text and should describe what the user is doing. This is also shown at every step.
  5. This is the step instructions. This changes from step to step and should describe what to do in this step.
  6. This area contains all the input fields. You can create a variety of feature rich fields that can do everything from collecting plain text to uploading files. (See below)
  7. This area contains the next, back, finish, and cancel buttons. These buttons are pretty self explanatory as they control the navigation through the wizard.

So how do you create all these components? You don't, the wizardmanager() function handles all this for you. You simply create a data structure (which is a multi-dimensional array) and hand it off to the wizardmanager() function. The rest is taken care of for you including GUI output to the user and field validation. Let's start with the skeleton files. Use these files to build your Wizard Manager module files or action files.



See the next section for a full reference of all the parameters that the wizardmanager takes.


NEXT: Wizard Manager Parameters


COMMENTS
 

There are no comments at this time.

Post Your Comment
 
Your Name*
Your Email Address* (Not Shown)
Your Comment (HTML OK)*
Enter the characters that you see here
Get New Image
*required fields