October 2009
Beginner
408 pages
7h 27m
English
Your first task is to create links that will allow you to edit and delete entries. You'll eventually want this to be available to administrators only (see Chapter 11 for more information on this topic), so you're going to build these links inside a function, rather than inline in index.php.
Name your function adminLinks() and have it accept two arguments: the current page ($page) and the URL of the entry you're working with ($url).
To start, open up functions.inc.php and declare your new function just below retrieveEntries():
function adminLinks($page, $url)
{
// Build admin links here
}
The first step in your function is to build the addresses for your links. For your editing link, this address simply appends ...
Read now
Unlock full access