Making Content


The Administration menu provides a Content item, which enables you to manage the content on your server. This section begins with a list of existing content items, although at first the list will, obviously, be empty. Next, the section contains two text boxes, which are used to add new content categories, as shown in Figure 12.1.

Figure 12.1. Adding a content category.


Note that these categories are unique to the Content module; they're different from categories you may have set up for news stories, FAQs, and so forth. Right below the Add a Category section is the Edit Category section, which includes a drop-down list of all the categories you've created. Finally, there's the Add a New Page section, the top part of which is shown in Figure 12.2.

Figure 12.2. Adding a new content page.


Adding a new page is easy. Start with the page's title, and then select its category. Note that the Category drop-down list box won't be displayed if you haven't yet defined any content categories. After selecting a category, you can provide a subtitle for the page. Keep it short; this will appear on the Content module's listing of available pages, and an especially long subtitle will make the listing difficult to read.

You then have three large text boxes for the page's actual content: Header Text, Page Text, and Footer Text. You can also include a short signature at the end. Here's how all of this fits together:

  • The title and subtitle will appear on each page of the content.

  • The header will appear on the first page of the content. You can format this text with HTML tags, if you like.

  • The footer will appear on the last page of the content. You can also format this text with HTML tags.

  • The signature will appear on the last page of the content and will be right-justified. HTML tags can be used to format this text also.

  • The page text can be split to appear on multiple pages. Just add the text <!--pagebreak--> where you want the text to be broken into pages. You can also add HTML formatting to the page text.

Figure 12.3 shows how you might enter a content page that you want broken into two pages; Figure 12.4 shows the final layout of the second (and last) page.

Figure 12.3. Creating a multipage layout.


Figure 12.4. Reading the finished multipage content.


Also note that you can use basic HTML tags in your content:

  • <br> creates a line break. Use two in a row to create a new paragraph, separated from the previous one by a blank line.

  • <b> boldfaces text. Just pick whatever you want to be boldface, and surround it with <b> and </b>.

  • <i> works similar to boldfacing, except that it italicizes. Whatever you want to be in <i>italics</i> should be surrounded by these tags.

  • <u> handles underlining; just surround text with the tags to make that text <u>underlined</u>.

  • You can surround paragraphs with the special <p>paragraph</p> tags. Doing so eliminates the need to use the <br> tags because paragraphs are automatically separated by some whitespace.

Probably the other main tag you'll want to use is one to create hyperlinks. First, select the text that you want to be the link. Try to make it descriptive; if you're linking to a Web page about a book, make the book's title the link rather than providing text that just says "Click here." Or, if you're linking to another Web site, make the site's name the link.

Once you've figured out which text will be the link, surround it with <a>anchor</a> tags (which, in this case, would make the word anchor the hyperlink). Now you just need to add some stuff to the opening <a> tag to make it a working link. If the site you're linking to is, for example, www.phpnuke.org, then you'd build a link <a href="http://www.phpnuke.org">to the PHP-Nuke Web site</a> like that. Be sure you always start the URL with http:// because if you don't, it won't work properly (unless you're linking to a page within your own sitethen you just need to provide the page name).

Note that this HTML formatting works in most places in PHP-Nuke where you're entering text into a large text box; however, the special <!--pagebreak--> tag works only within the Content module.

The last option you'll select for a new content page is whether to activate it. Please note that all content can be accessed at any time; deactivated content is simply not listed, meaning that you have to know the content's exact URL to see it.



    PHP-Nuke Garage
    PHP-Nuke Garage
    ISBN: 0131855166
    EAN: 2147483647
    Year: 2006
    Pages: 235
    Authors: Don Jones

    flylib.com © 2008-2017.
    If you may any questions please contact us: flylib@qtcs.net