Search Knowledge Base by Keyword

Add Special Features

This page includes:

 


 

Introduction to Shortcodes

The Basic Content Editor is a tool in the Basic Content Module of the WordPress CMS where shortcodes can be added to create special forms and features on the page. 

A shortcode is a small piece of code, indicated by brackets like [this], that performs a dedicated function. It can be placed anywhere inside the Basic Content area.

All the shortcodes below can be used in the Basic Content Editor.

Note: When adding shortcode, use the Text tab inside the Basic Content module to avoid bringing in unwanted HTML formatting that may break the shortcode (the WYSIWYG converts some HTML characters when switching from text to visual tabs. For example, " and ' will be converted to “ and ‘).

 


 

Simple Tables

Tables should be used for presenting rows and columns of simple data. For tables containing more complex or large amounts of data (where sorting, search and pagination are desired), use a Data Table Module.

Create a table
screenshot of where to insert table in cms

Inside a Basic Content module form you can insert a table from the top menu.

Format table

screenshot of cms table formatting options

Adding Your Data - When building your table, try to include as few columns as possible (this will also display on mobile devices).

Adding/Deleting Rows or Columns - You may add or delete rows or columns by clicking in the desired area, selecting the table menu again and selecting the option needed.

Column Width - You can alter the width of columns by dragging the dividers.

Header - Create a header by selecting the first row, and finding the Table row properties in the menu and change the Row type to Header.

Table row properties module screenshot

In the Table row properties module select Header in the Row type.

 


 

Jump Links

Jump links provide users with more information about what is on the page as well as an easy way to 'jump' to that information. This page, for example, features a bulleted list of jump links at the top.

  • Use jump links as a bulleted list of links at the top of a page that contains many sections.
  • You may link from another page to a jumped link down a page by including the desired 'jumpto' id (for example: /kb/wysiwyg/#tips).

Important: Top of page must include a Basic Content Module

  • In the WYSIWYG field of the Basic Content moudle must include a bulleted list of links that include the jumplink shortcode.
  • Each jump link includes a unique name, all in lowercase, to refer to the link.

Two Ways to Link to Jump Links in Hunter's WordPress Theme

  1. Jump links within Basic Content Modules
  2. Jump links that use a module's Section ID

#1 Jump Links Within Basic Content Modules

  • Jump links must be created in the WYSIWYG field. The Basic Content module,  as well as others, include a WYSIWYG field.
  • The link you are jumping to may be in another Basic Content module in the page, as long as that module has an H2 inside a WYSIWYG field.

 

jump links cms screenshot

Important parts of the jump links code: You must be in the text tab, you must add links to the bulleted list and you must include the 'jumpto' code to each H2 that you wish to jump to.

How to Create Jump Links within Basic Content Modules

    1. In the first module with a WYSIWYG field, create a bulleted list of the items that will become jump links. The items should be initial caps and they should match the corresponding H2 heading.
    2. IMPORTANT: Switch to the Text tab (see example above). Text tab allows you to insert basic code into the page.
    3. Find the bulleted list of H2s you created.
    4. For each bullet:
      1. Add <a href="#uniquejumpname"> in between <li> and your title.
      2. Add </a> after your title and before </li>
      3. Replace uniquejumpname with a short jump title that refers to the title, no spaces. See underlined example above. This is how you tie the top link to the jump link, so they must be identical words (no spaces).
    5. For each H2:
      1. Find each H2 down the page and add <a id="uniquejumpname" class="jumpto"> after <h2> and before the title.
      2. Replace uniquejumpname with the the corresponding short jump title for each H2.
      3. Preview the page and test the jump links.

#2 Jump Links That Use a Module's Section ID

  • Follow instructions 1 - 4 above to create the links at the top of the page.
  • In order to link to the module, put the uniquejumpname in the Section ID of the module you wish to jump to. Most modules contain the Section ID at the top of the module container.
  • When you want to link to that jump link from another page. View your live page, click on your jump link and copy that url that will include #uniquejumpname at the end. Paste that in as your link.

 

 


 

Call to Action Links

For more prominent links with Basic Content Modules. Call to action links are fields available at the end of most modules to enable users to see more about the content for that module. This code enables the same style link to be used within Basic Content Modules. These should be used for more prominent links.

[calltoaction linktext='link text' linkurl='httP://url.com' linkstyle='text']

To apply the CTA link

  1. Copy the code below
  2. Paste it where you would like it to appear within a Basic Content Module
  3. Replace "text" with "button" to use a button style CTA. Button styles should be used only where you'd like to use a Big Button but need it more closely associated with the content. Do not add more than 1 Button style CTA per page.
  4. Replace "http://url.com" with the url of where the link should go. (Note the quotation marks must be included)

Learn More

 


 

Add Call-to-Action Arrow to a Link

To make a link in the Call-to-Action style (with the long arrow at the end).

Normal Links

[calltoaction linktext='link text' linkurl='http://url.com' linkstyle='']

  • Copy the entire line above. Using the Text tab within a Basic Content module, paste it where you want this to appear within your content.
  • Replace link text with the desired link copy.
  • Replace http://url.com with the desired url you are linking to.
  • Always test the link after adding it to make sure it is set up correctly.

Example:

Learn More

 

Course Catalog Links 

[catalog-program-link title="Jewish Studies - BA" linktext="Learn More About the Jewish Studies Major" linkstyle="cta" /]

  • Create your Course Catalog link using the instructions above.
  • Add linkstyle="cta" to the code, as shown above in the example code.

Example:

Learn More About the Jewish Studies Major

 


 

Course Catalog Links

Use the following shortcodes for linking to specific content in the latest version of the Course Catalog. These links will automatically point to the current version of the Course Catalog, as long as the name of the item being referenced remains the same in the new catalog.

 

Program of Study - Undergraduate

[catalog-program-link title="program title" linktext="link text" /]

  • Ensure you are looking in the Undergraduate Catalog.
  • Copy the entire line above. Using the Text tab within a Basic Content module, paste it where you want this to appear within your content.
  • Replace program title in the above shortcode with the full title of the program from the catalog.
  • Replace link text with the desired link copy.
  • Always test the link after adding it to make sure it is set up correctly.

Example: Learn More About the Jewish Studies Major
[catalog-program-link title="Jewish Studies - BA" linktext="Learn More About the Jewish Studies Major" /]

 

Program of Study - Graduate

[catalog-program-link title="program title" linktext="link text" graduate="1" /]

  • Ensure you are looking in the Graduate Catalog.
  • Copy the entire line above. Using the Text tab within a Basic Content module, paste it where you want this to appear within your content.
  • Replace program title in the above shortcode with the full title of the program from the catalog.
  • Replace link text with the desired link copy.
  • Always test the link after adding it to make sure it is set up correctly.

Example: Learn More About the Biochemistry MA
[catalog-program-link title="Biochemistry - MA" linktext="Learn More About the Biochemistry MA" graduate="1" /]

 

List of Courses by Department/Program - Undergraduate

[catalog-courselist-link department="department name" linktext="link text" /]

  • Ensure you are looking in the Undergraduate Catalog.
  • Copy the entire line above. Using the Text tab within a Basic Content module, paste it where you want this to appear within your content.
  • Replace department name in the above shortcode with name of the department or program from the catalog.
  • Replace link text with the desired link copy.
  • Always test the link after adding it to make sure it is set up correctly.

Examples: Jewish Studies Courses, Hebrew Courses
[catalog-courselist-link department="Jewish Studies" linktext="Jewish Studies Courses" /], [catalog-courselist-link department="Classical & Oriental Studies" linktext="Hebrew Courses" /]

 

List of Courses by Department/Program - Graduate

[catalog-courselist-link department="department name" linktext="link text" graduate="1" /]

  • Ensure you are looking in the Graduate Catalog.
  • Copy the entire line above. Using the Text tab within a Basic Content module, paste it where you want this to appear within your content.
  • Replace department name in the above shortcode with name of the department or program from the catalog.
  • Replace link text with the desired link copy.
  • Always test the link after adding it to make sure it is set up correctly.

Example: Anthropology MA Courses, Chemistry MA Courses
[catalog-courselist-link department="Anthropology" linktext="Anthropology MA Courses" graduate="1" /], [catalog-courselist-link department="Chemistry" linktext="Chemistry MA Courses" graduate="1" /]

 

Degree Maps by Department/Program

[catalog-degreemap-link program="degree map" linktext="link text" /]

  • Copy the entire line above. Using the Text tab within a Basic Content module, paste it where you want this to appear within your content.
  • Replace degree map in the above shortcode with name of the program that has the desired degree map from the catalog. Note, not all programs have Degree Maps. Search the catalog to see if your program has one.
  • Replace link text with the desired link copy.
  • Always test the link after adding it to make sure it is set up correctly.

Example: Plan Your Academic Path With the Jewish Studies Degree Map
[catalog-degreemap-link program="Jewish Studies" linktext="Plan Your Academic Path With the Jewish Studies Degree Map" /]

 

Hunter General Education Requirements

[catalog-page-link title="General Education - Effective Fall 2019" linktext="More About Hunter General Education Requirement" /]

  • Copy the entire line above. Using the Text tab within a Basic Content module, paste it where you want this to appear within your content.
  • This link will work as is, but if you want to change what the link says, update More About Hunter General Education Requirement with the desired copy.
  • Always test the link after adding it to make sure it is set up correctly.

Example: More About Hunter General Information Requirement
[catalog-page-link title="General Education - Effective Fall 2019" linktext="More About Hunter General Education Requirement" /]

 

Catalog Home Page - Undergraduate

[catalog-home-link linktext="Undergraduate Catalog" /]

  • Copy the entire line above. Using the Text tab within a Basic Content module, paste it where you want this to appear within your content.
  • This link will work as is, but if you want to change what the link says, update Undergraduate Catalog with the desired copy.
  • Always test the link after adding it to make sure it is set up correctly.

Example: Undergraduate Catalog
[catalog-home-link linktext="Undergraduate Catalog" /]

 

Catalog Home Page - Graduate

[catalog-home-link linktext="Graduate Catalog" graduate="1" /]

  • Copy the entire line above. Using the Text tab within a Basic Content module, paste it where you want this to appear within your content.
  • This link will work as is, but if you want to change what the link says, update Graduate Catalog with the desired copy.
  • Always test the link after adding it to make sure it is set up correctly.

Example: Graduate Catalog
[catalog-home-link linktext="Graduate Catalog" graduate="1" /]

 

School of Arts and Sciences in Catalog

[catalog-school-link title="School of Arts and Sciences" linktext="link text" graduate="1" /]

  • Copy the entire line above. Using the Text tab within a Basic Content module, paste it where you want this to appear within your content.
  • This link will work as is, but if you want to change what the link says, update the 'linktext' School of Arts and Sciences with the desired copy.
  • Always test the link after adding it to make sure it is set up correctly.

Example: School of Arts and Sciences
[catalog-school-link title="School of Arts and Sciences" linktext="School of Arts and Sciences" graduate="1" /]

 

Department in Catalog

[catalog-dept-link title="school name" linktext="link text" graduate="1" /]

  • Copy the entire line above. Using the Text tab within a Basic Content module, paste it where you want this to appear within your content.
  • Replace school title in the above shortcode with the full title of the school from the catalog.
  • Replace link text with the desired link copy.
  • Always test the link after adding it to make sure it is set up correctly.

Example: Department of Economics
[catalog-dept-link title="Economics" linktext="Department of Economics" graduate="1" /]

 

Individual Pages in the Catalog

This shortcode is to link to a generic page. All generic pages in the catalog have a URL (website address) with 'navoid' as a parameter in the query string (Example: http://catalog.hunter.cuny.edu/content.php?catoid=43&navoid=13777)

[catalog-page-link title="Grading Definition" linktext="More About Hunter's Grading Definition" /]

  • Copy the entire line above. Using the Text tab within a Basic Content module, paste it where you want this to appear within your content.
  • Replace Grading Definition in the above shortcode with name of the page from the catalog.
  • Replace More About Hunter's Grading Definition with the text you would like to display.
  • Always test the link after adding it to make sure it is set up correctly.

Example: More About Hunter's Grading Definition
[catalog-page-link title="Grading Definition" linktext="More About Hunter's Grading Definition" /]

 


 

Course Catalog Link Tips

 

Use the 'Text' Tab

Use the Text tab inside the Basic Content module to avoid bringing in unwanted HTML formatting that may break the shortcode.

 

Example Error Messages

If the shortcode has an incorrect or misspelled catalog name, you will see this error message:

No catalog entry found matching criteria or an error occurred.

If shortcode name  is misspelled (ie, cut the "k" out by mistake when editing) it will output it as inline text on the page:

[catalog-program-lin title="Jewish Studies" linktext="Non-existing program title" /]

 

 


 

Campus Maps Links

Select a location from the list below, copy the URL that appears below the select box, and paste it to the text you want to include as a link in your content.

Example of adding a link in your content to a specific location on the Campus Map:
68th Street Campus Visitor's Center

 

 


Giving Forms (Blackbaud)

Giving forms are used on Hunter giving pages using Blackbaud shortcode.

To insert a Blackbaud giving form into a page:

  • Obtain a Blackbaud code by sending a request to website_feedback@hunter.cuny.edu.
  • The shortcode will be the code below swapping out 'long ID number' with the code you receive.
  • Using the 'Text' tab within a Basic Content module, insert the entire line of code.
  • The form will appear wherever the code is placed. You may have content before/after the form.

[blackbaud id='long ID number']

 


 

Other Forms (MachForm)

Other types of long-standing forms may be inserted into a page using MachForm. These forms collect information and allow users to register for an opportunity or submit questions or documents for review. Each Hunter department has their own MachForm Admin Panel. Contact website_feedback@hunter.cuny.edu to get access.

To insert a MachForm into a page:

In MachForm

  • Sign In to your department MachForm Admin Panel.
  • Create your form and save with a unique name.
  • Go to Code. Make sure WordPress Shortcode is selected and copy the line of code.

In WordPress

  • Using the Text tab within a Basic Content module, paste the code.
  • The form will appear wherever the code is placed. You may have content before/after the form.

Example of a Machform Shortcode:
[machform dir='legal' id='10224' height='1155' title='OFFICE OF LEGAL AFFAIRS INTAKE FORM']