当前位置: 首页>>代码示例>>PHP>>正文


PHP html::add_parameter方法代码示例

本文整理汇总了PHP中html::add_parameter方法的典型用法代码示例。如果您正苦于以下问题:PHP html::add_parameter方法的具体用法?PHP html::add_parameter怎么用?PHP html::add_parameter使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在html的用法示例。


在下文中一共展示了html::add_parameter方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: mail

' . $url . '

For the password reminder go here:

' . _HOMEPAGE . '/password-reminder.php';
        $msg .= "\n\n";
        $msg .= _SEPARATOR . "\n";
        $msg .= _EMAIL_ADVERT_TEXT . "\n";
        $msg .= _SEPARATOR . "\n";
        $msg .= _SLOGAN . "\n";
        $msg .= _HOMEPAGE . "\n";
        $msg .= 'Email: ' . _ADMIN_EMAIL . "\n";
        mail($email, $mailsubject, $msg, $mailheaders);
        $base_instance->query("UPDATE {$base_instance->entity['USER']['MAIN']} SET last_reminded='{$today}' WHERE ID={$ID}");
    }
    if ($sizeof > 0) {
        echo '<head><meta http-equiv="refresh" content="10;URL=send-warning.php?months=' . $months . '&save=1"></head><p><strong>Continue to send more reminder emails in a few seconds (' . $fnd_rows . ' left) ..</strong>';
    } else {
        echo 'finished';
    }
    exit;
}
$html_instance->add_parameter(array('ACTION' => 'show_form', 'HEADER' => 'Send Reminder', 'TEXT_CENTER' => 'Send a reminder email to user who have not logged in for a long time.<p>', 'FORM_ACTION' => $_SERVER['PHP_SELF'], 'BUTTON_TEXT' => 'Send', 'INNER_TABLE_WIDTH' => '220'));
$html_instance->add_form_field(array('TYPE' => 'label', 'TEXT' => '<strong>Send Email to users who have .. </strong>'));
$html_instance->add_form_field(array('TYPE' => 'label', 'TEXT' => '<select name="months">
<option value=3>Not logged in for 3 months
<option selected value=6>Not logged in for 6 months
<option value=12>Not logged in for 1 year
<option value=24>Not logged in for 2 years
</select>'));
$html_instance->process();
开发者ID:vijo,项目名称:Blue-Smiley-Organizer,代码行数:31,代码来源:send-warning.php

示例2: header

    for ($index = 1; $index <= sizeof($data); $index++) {
        $checkbox_field_id = $data[$index]->ID;
        $base_instance->query("DELETE FROM {$base_instance->entity['DATABASE']['CHECKBOX_ITEMS']} WHERE user='{$userid}' AND checkbox_field_id='{$checkbox_field_id}'");
    }
    $base_instance->query("DELETE FROM {$base_instance->entity['DATABASE']['CHECKBOX_FIELDS']} WHERE user='{$userid}' AND category_id='{$category_id}'");
    # delete select records
    $base_instance->query("DELETE FROM {$base_instance->entity['DATABASE']['SELECT_VALUES']} WHERE user='{$userid}' AND category_id='{$category_id}'");
    $data = $base_instance->get_data("SELECT * FROM {$base_instance->entity['DATABASE']['SELECT_FIELDS']} WHERE user='{$userid}' AND category_id='{$category_id}'");
    for ($index = 1; $index <= sizeof($data); $index++) {
        $select_field_id = $data[$index]->ID;
        $base_instance->query("DELETE FROM {$base_instance->entity['DATABASE']['SELECT_ITEMS']} WHERE user='{$userid}' AND select_field_id='{$select_field_id}'");
    }
    $base_instance->query("DELETE FROM {$base_instance->entity['DATABASE']['SELECT_FIELDS']} WHERE user='{$userid}' AND category_id='{$category_id}'");
    # delete number records
    $base_instance->query("DELETE FROM {$base_instance->entity['DATABASE']['NUMBER_FIELDS']} WHERE user='{$userid}' AND category_id='{$category_id}'");
    $base_instance->query("DELETE FROM {$base_instance->entity['DATABASE']['NUMBER_VALUES']} WHERE user='{$userid}' AND category_id='{$category_id}'");
    header('Location: close-me.php');
    exit;
} else {
    $data = $base_instance->get_data("SELECT * FROM {$base_instance->entity['DATABASE']['CATEGORY']} WHERE user='{$userid}' AND ID='{$category_id}'");
    if (!$data) {
        $base_instance->show_message('Database Category not found');
        exit;
    }
    $title = $data[1]->title;
}
$html_instance->add_parameter(array('ACTION' => 'show_form', 'HEADER' => '<font color="#ff0000">Delete this category?</font>', 'FORM_ACTION' => $_SERVER['PHP_SELF'], 'BUTTON_TEXT' => 'Delete Category'));
$html_instance->add_form_field(array('TYPE' => 'hidden', 'NAME' => 'category_id', 'VALUE' => "{$category_id}"));
$html_instance->add_form_field(array('TYPE' => 'hidden', 'NAME' => 'delete_it', 'VALUE' => 1));
$html_instance->add_form_field(array('TYPE' => 'label', 'TEXT' => "Are you sure you want to delete the <b>'{$title}'</b> category AND the items of this category?"));
$html_instance->process();
开发者ID:vijo,项目名称:Blue-Smiley-Organizer,代码行数:31,代码来源:delete-database-category.php

示例3:

    $datetime = $data[1]->datetime;
    $firstname = $data[1]->firstname;
    $lastname = $data[1]->lastname;
    $telephone = $data[1]->telephone;
    $fax = $data[1]->fax;
    $mobile = $data[1]->mobile;
    $email = $data[1]->email;
    $address = $data[1]->address;
    $notes = $data[1]->notes;
    $company = $data[1]->company;
    $url = $data[1]->url;
    $category_id = $data[1]->category;
    $public = $data[1]->public;
    $datetime_converted = $base_instance->convert_date($datetime);
}
$html_instance->add_parameter(array('ACTION' => 'show_form', 'HEADER' => 'Edit Contact', 'FORM_ACTION' => $_SERVER['PHP_SELF'], 'BUTTON_TEXT' => 'Save Contact'));
# build category select box
$select_box = '&nbsp;<select name="category_id">';
$data = $base_instance->get_data("SELECT * FROM {$base_instance->entity['CONTACT']['CATEGORY']} WHERE user='{$userid}' ORDER BY title");
for ($index = 1; $index <= sizeof($data); $index++) {
    $category_title = $data[$index]->title;
    $ID = $data[$index]->ID;
    if ($ID == $category_id) {
        $select_box .= "<option selected value={$ID}>{$category_title}";
    } else {
        $select_box .= "<option value={$ID}>{$category_title}";
    }
}
$select_box .= '</select> or <b>New Category:</b> <input type="text" name="new_category" value="">';
#
$html_instance->add_form_field(array('TYPE' => 'hidden', 'NAME' => 'contact_id', 'VALUE' => $contact_id));
开发者ID:vijo,项目名称:Blue-Smiley-Organizer,代码行数:31,代码来源:edit-contact.php

示例4:

        $weekday_reminder_id = (int) $_GET['weekday_reminder_id'];
        $data = $base_instance->get_data("SELECT * FROM {$base_instance->entity['REMINDER']['WEEKDAY']} WHERE ID={$weekday_reminder_id} AND user={$userid}");
        $title = $data[1]->title;
        $text = $data[1]->text;
        $text = convert_square_bracket($text);
        $text = nl2br($text);
        $all_text = "<strong>{$title}</strong><p>{$text}";
    } else {
        if (!empty($_GET['hours_reminder_id'])) {
            $hours_reminder_id = (int) $_GET['hours_reminder_id'];
            $data = $base_instance->get_data("SELECT * FROM {$base_instance->entity['REMINDER']['HOURS']} WHERE ID={$hours_reminder_id} AND user={$userid}");
            $title = $data[1]->title;
            $text = $data[1]->text;
            $text = convert_square_bracket($text);
            $text = nl2br($text);
            $all_text = "<strong>{$title}</strong><p>{$text}";
        } else {
            if (!empty($_GET['date_reminder_id'])) {
                $date_reminder_id = (int) $_GET['date_reminder_id'];
                $data = $base_instance->get_data("SELECT * FROM {$base_instance->entity['REMINDER']['DATE']} WHERE ID={$date_reminder_id} AND user={$userid}");
                $title = $data[1]->title;
                $text = $data[1]->text;
                $text = convert_square_bracket($text);
                $text = nl2br($text);
                $all_text = "<strong>{$title}</strong><p>{$text}";
            }
        }
    }
}
$html_instance->add_parameter(array('TEXT' => $all_text));
$html_instance->process();
开发者ID:vijo,项目名称:Blue-Smiley-Organizer,代码行数:31,代码来源:show-notes-text.php

示例5: back

}
if (empty($_GET['order_col'])) {
    $order_col = 'ID';
} else {
    $order_col = sql_safe($_GET['order_col']);
}
if (empty($_GET['show_all'])) {
    $where = "WHERE DATE_ADD(last_reminded, INTERVAL frequency DAY)<'{$datetime}' AND user='{$userid}'";
    $header = 'Reminders To Do &nbsp;&nbsp; <a href="' . $_SERVER['PHP_SELF'] . '?show_all=1">[Show all Reminders]</a>';
    $show_all = 0;
} else {
    $where = "WHERE user='{$userid}'";
    $header = 'All Reminders &nbsp;&nbsp; <a href="' . $_SERVER['PHP_SELF'] . '?show_all=0">[Show Reminders To Do]</a>';
    $show_all = 1;
}
$html_instance->add_parameter(array('ACTION' => 'show_content', 'ENTITY' => 'REMINDER', 'SUBENTITY' => 'DAYS', 'MAXHITS' => 50, 'WHERE' => "{$where} AND homepage=1", 'ORDER_COL' => "{$order_col}", 'ORDER_TYPE' => "{$order_type}", 'HEADER' => "{$header}", 'SORTBAR' => 6, 'SORTBAR_FIELD1' => 'title', 'SORTBAR_NAME1' => 'Title', 'SORTBAR_FIELD2' => 'bluebox', 'SORTBAR_NAME2' => 'Days due', 'SORTBAR_FIELD3' => 'last_reminded', 'SORTBAR_NAME3' => 'Last Time Done', 'SORTBAR_FIELD4' => 'done', 'SORTBAR_NAME4' => 'Done', 'SORTBAR_FIELD5' => 'frequency', 'SORTBAR_NAME5' => 'Do every', 'SORTBAR_FIELD6' => 'datetime', 'SORTBAR_NAME6' => 'Date added', 'INNER_TABLE_WIDTH' => '95%', 'URL_PARAMETER' => "show_all={$show_all}"));
if ($order_col == 'bluebox') {
    $html_instance->para['ORDER_COL'] = '(UNIX_TIMESTAMP("' . $datetime . '")-UNIX_TIMESTAMP(last_reminded)-(frequency*86400))';
}
# translate bluebox ORDER_COL
$data = $html_instance->get_items();
if ($order_col == 'bluebox') {
    $html_instance->para['ORDER_COL'] = 'bluebox';
}
# translate back (workaround to show red arrow down and up)
$all_text = '<table width="100%" border=1 cellspacing=0 cellpadding=2 class="pastel"><tr><td align="center"><a href="' . $_SERVER['PHP_SELF'] . '?order_col=' . $order_col . '&order_type=' . $order_type . '&show_all=' . $show_all . '">[Refresh]</a></td>';
if ($order_col == 'bluebox') {
    $all_text .= '<td align="center"><u><b>Days due</b></u></td>';
} else {
    $all_text .= '<td align="center"><b>Days due</b></td>';
}
开发者ID:vijo,项目名称:Blue-Smiley-Organizer,代码行数:31,代码来源:show-reminder-days-overview.php

示例6: sizeof

    } else {
        $data = $base_instance->get_data("SELECT * FROM {$base_instance->entity['DATABASE']['CHECKBOX_FIELDS']} WHERE user='{$userid}' AND ID='{$checkbox_field_id}'");
        if (!$data) {
            $base_instance->show_message('Database field not found');
            exit;
        }
        $title_field = $data[1]->title;
        $data = $base_instance->get_data("SELECT * FROM {$base_instance->entity['DATABASE']['CHECKBOX_ITEMS']} WHERE user='{$userid}' AND checkbox_field_id='{$checkbox_field_id}' ORDER BY ID ASC");
        $number_of_fields = sizeof($data) + 3;
        for ($index = 1; $index <= sizeof($data); $index++) {
            $item_id[$index] = $data[$index]->ID;
            $item_name[$index] = $data[$index]->title;
        }
    }
}
$html_instance->add_parameter(array('ACTION' => 'show_form', 'HEADER' => 'Edit Checkbox Field', 'FORM_ACTION' => $_SERVER['PHP_SELF'], 'TEXT_CENTER' => 'You can rename field names here, do not change the position of field items.<p>', 'BUTTON_TEXT' => 'Update Field'));
$html_instance->add_form_field(array('TYPE' => 'hidden', 'NAME' => 'number_of_fields', 'VALUE' => "{$number_of_fields}"));
$html_instance->add_form_field(array('TYPE' => 'hidden', 'NAME' => 'checkbox_field_id', 'VALUE' => "{$checkbox_field_id}"));
$html_instance->add_form_field(array('TYPE' => 'text', 'NAME' => 'title_field', 'VALUE' => "{$title_field}", 'SIZE' => 30, 'TEXT' => 'Name of Field'));
for ($index = 1; $index <= $number_of_fields; $index++) {
    if (empty($item_id[$index])) {
        $item_id[$index] = '';
    }
    if (empty($item_name[$index])) {
        $item_name[$index] = '';
    }
    $html_instance->add_form_field(array('TYPE' => 'text', 'NAME' => 'name_checkbox_field_item_' . $index, 'VALUE' => $item_name[$index], 'SIZE' => 30, 'TEXT' => 'Name Item ' . $index));
    $html_instance->add_form_field(array('TYPE' => 'hidden', 'NAME' => 'id_checkbox_field_item_' . $index, 'VALUE' => $item_id[$index]));
}
$html_instance->add_form_field(array('TYPE' => 'label', 'TEXT' => '<input type="submit" name="add_fields" value="More Item Fields">'));
$html_instance->process();
开发者ID:vijo,项目名称:Blue-Smiley-Organizer,代码行数:31,代码来源:edit-database-checkbox-field.php

示例7:

<td><a href="javascript:void(window.open(\'delete-database-select-field.php?select_field_id=' . $ID . '\',\'\',\'width=450,height=200,top=100,left=100\'))">[Delete Field]</a></td><td><a href="delete-database-select-field-items.php?select_field_id=' . $ID . '">[Delete Field Items]</a></td></tr>';
}
$all_text .= '</table></td></tr></table><p>';
# get number fields
$all_text .= '<table border=1 cellspacing=0 cellpadding=10 bgcolor="#ffffff" class="pastel"><tr><td>';
$all_text .= '<strong>Number Fields</strong> <a href="add-database-number-field.php?category_id=' . $category_id . '">[Add New]</a><br><br>';
$data = $base_instance->get_data("SELECT * FROM {$base_instance->entity['DATABASE']['NUMBER_FIELDS']} WHERE category_id='{$category_id}' AND user='{$userid}'");
$all_text .= '<table border=1 cellspacing=0 cellpadding=2 bgcolor="#ffffff" class="pastel">';
for ($index = 1; $index <= sizeof($data); $index++) {
    $ID = $data[$index]->ID;
    $title = $data[$index]->title;
    $all_text .= '<tr><td bgcolor="#dedede"><b>' . $title . '</b></td>
<td><a href="edit-database-number-field.php?number_field_id=' . $ID . '">[Edit]</a></td>
<td><a href="javascript:void(window.open(\'delete-database-number-field.php?number_field_id=' . $ID . '\',\'\',\'width=450,height=200,top=100,left=100\'))">[Delete]</a></td></tr>';
}
$all_text .= '</table></td></tr></table><p>';
# get text fields
$all_text .= '<table border=1 cellspacing=0 cellpadding=10 bgcolor="#ffffff" class="pastel"><tr><td>';
$all_text .= '<strong>Text Fields</strong> <a href="add-database-text-field.php?category_id=' . $category_id . '">[Add New]</a><br><br>';
$data = $base_instance->get_data("SELECT * FROM {$base_instance->entity['DATABASE']['TEXT_FIELDS']} WHERE category_id='{$category_id}' AND user='{$userid}'");
$all_text .= '<table border=1 cellspacing=0 cellpadding=2 bgcolor="#ffffff" class="pastel">';
for ($index = 1; $index <= sizeof($data); $index++) {
    $ID = $data[$index]->ID;
    $title = $data[$index]->title;
    $all_text .= '<tr><td bgcolor="#dedede"><b>' . $title . '</b></td>
<td><a href="edit-database-text-field.php?text_field_id=' . $ID . '">[Edit]</a></td>
<td><a href="javascript:void(window.open(\'delete-database-text-field.php?text_field_id=' . $ID . '\',\'\',\'width=450,height=200,top=100,left=100\'))">[Delete]</a></td></tr>';
}
$all_text .= '</table></td></tr></table><p>';
$html_instance->add_parameter(array('HEADER' => 'Edit Fields', 'TEXT_CENTER' => "{$all_text}", 'BACK' => 1));
$html_instance->process();
开发者ID:vijo,项目名称:Blue-Smiley-Organizer,代码行数:31,代码来源:show-database-fields.php

示例8: base

<?php

require 'class.base.php';
require 'class.html.php';
$base_instance = new base();
$html_instance = new html();
$userid = $base_instance->get_userid();
$id = isset($_GET['id']) ? (int) $_GET['id'] : exit;
$del_message = isset($_GET['del_message']) ? (int) $_GET['del_message'] : '';
if ($userid == _ADMIN_USERID && $del_message) {
    $base_instance->query("DELETE FROM {$base_instance->entity['FORUM']['MAIN']} WHERE ID={$del_message}");
}
$html_instance->add_parameter(array('ACTION' => 'show_content', 'ENTITY' => 'FORUM', 'WHERE' => "WHERE ID={$id} OR followup={$id}", 'ORDER_COL' => 'followup,datetime', 'ORDER_TYPE' => 'DESC', 'MAXHITS' => 40, 'TEXT_CENTER' => '<center><a href="javascript:history.go(-1)">[Go Back]</a></center>', 'INNER_TABLE_WIDTH' => '90%', 'HEADER' => 'Thread', 'URL_PARAMETER' => "id={$id}"));
$data = $html_instance->get_items();
$all_text = '';
for ($index = 1; $index <= sizeof($data); $index++) {
    $ID = $data[$index]->ID;
    $text = $data[$index]->text;
    $title = $data[$index]->title;
    $text = convert_square_bracket($text);
    $title = convert_square_bracket($title);
    if ($title) {
        $html_instance->para['HEADER'] = $title;
    }
    $userid_message = $data[$index]->user;
    $followup = $data[$index]->followup;
    $datetime = $data[$index]->datetime;
    $datetime_converted = $base_instance->convert_date($datetime);
    if ($followup == 0) {
        $color = '#dedfdf';
    } else {
开发者ID:vijo,项目名称:Blue-Smiley-Organizer,代码行数:31,代码来源:show-forum-thread.php

示例9: trim

if (isset($_POST['save'])) {
    $error = '';
    $about_me = $_POST['about_me'];
    $firstname = $_POST['firstname'];
    $lastname = $_POST['lastname'];
    $country = (int) $_POST['country'];
    if (!empty($about_me)) {
        $about_me = trim($about_me);
        if (strlen($about_me) > 65535) {
            $error .= '<li> Text is too long (Max. 65535 Characters)';
        }
    }
    if (!$error) {
        $base_instance->query('UPDATE ' . $base_instance->entity['USER']['MAIN'] . ' SET about_me="' . sql_safe($about_me) . '",firstname="' . sql_safe($firstname) . '",lastname="' . sql_safe($lastname) . '",country=' . $country . ' WHERE ID=' . $userid);
        $base_instance->show_message('About Me page updated', '<a href="show-user.php?userid=' . $userid . '">[View Profile Page]</a>');
    } else {
        $html_instance->error_message = $error;
    }
} else {
    $data = $base_instance->get_data("SELECT about_me,firstname,lastname,country FROM {$base_instance->entity['USER']['MAIN']} WHERE ID='{$userid}'");
    $about_me = $data[1]->about_me;
    $firstname = $data[1]->firstname;
    $lastname = $data[1]->lastname;
    $country = $data[1]->country;
}
$html_instance->add_parameter(array('ACTION' => 'show_form', 'HEADER' => 'About Me', 'TEXT_CENTER' => 'The About Me text is a public text which appears in your profile.<br>Firstname and lastname is not public, it will only be used for sending emails within the Organizer.<p>', 'FORM_ACTION' => $_SERVER['PHP_SELF'], 'BODY' => 'onLoad="javascript:document.form1.about_me.focus()"', 'BUTTON_TEXT' => 'Update'));
$html_instance->add_form_field(array('TYPE' => 'textarea', 'NAME' => 'about_me', 'VALUE' => "{$about_me}", 'TEXT' => 'About me', 'COLS' => 80, 'ROWS' => 4));
$html_instance->add_form_field(array('TYPE' => 'text', 'NAME' => 'firstname', 'VALUE' => "{$firstname}", 'SIZE' => 35, 'TEXT' => 'Firstname'));
$html_instance->add_form_field(array('TYPE' => 'text', 'NAME' => 'lastname', 'VALUE' => "{$lastname}", 'SIZE' => 35, 'TEXT' => 'Lastname'));
$html_instance->add_form_field(array('TYPE' => 'select', 'NAME' => 'country', 'VALUE' => "{$country}", 'OPTION' => 'country_array', 'TEXT' => 'Country'));
$html_instance->process();
开发者ID:vijo,项目名称:Blue-Smiley-Organizer,代码行数:31,代码来源:edit-about-me.php

示例10: date

if ($test == 1) {
    $query = 'WHERE ID=' . _ADMIN_USERID . ' AND newsletter_opt_in=1';
} else {
    if ($subscribed == 1) {
        $query = "WHERE newsletter<>{$newsletter_id} AND newsletter_opt_in=1";
    } else {
        if ($all == 1) {
            $query = "WHERE newsletter<>{$newsletter_id}";
        } else {
            echo 'Error';
            exit;
        }
    }
}
$period_11 = date('Y-m-d H:i:s', mktime(0, 0, 0, date('m') - 11, date('d'), date('Y')));
$html_instance->add_parameter(array('ENTITY' => 'USER', 'WHERE' => $query, 'ORDER_COL' => 'ID', 'ORDER_TYPE' => 'DESC', 'MAXHITS' => '199'));
$data = $html_instance->get_items();
if (empty($data)) {
    echo 'All done!';
    exit;
} elseif ($test == 1) {
    echo '<a href="edit-newsletter.php?newsletter_id=' . $newsletter_id . '">Edit Newsletter</a><br><br>';
} else {
    echo '<head><meta http-equiv="refresh" content="3;URL=' . $_SERVER['PHP_SELF'] . '?all=' . $all . '&newsletter_id=' . $newsletter_id . '&subscribed=' . $subscribed . '"></head>';
}
for ($index = 1; $index <= sizeof($data); $index++) {
    unset($msg);
    $ID = $data[$index]->ID;
    $username = $data[$index]->username;
    $email = $data[$index]->email;
    $lastlogin = $data[$index]->lastlogin;
开发者ID:vijo,项目名称:Blue-Smiley-Organizer,代码行数:31,代码来源:send-newsletter.php

示例11: date

        $ID = $data[1]->ID;
        $diary_text = $data[1]->text;
        $title = $data[1]->title;
    } else {
        $ID = '';
        $diary_text = '';
        $title = '';
    }
}
if (empty($ID)) {
    $ID_text = '';
} else {
    $ID_text = '<strong>ID:</strong> ' . $ID;
}
$current_month = $diary_instance->get_month_view($month, $year);
$weekday = date('l', mktime(0, 0, 0, $month, $day, $year));
$date_converted = $base_instance->convert_date($year . '-' . $month . '-' . $day . ' 00:00:00');
$all_text .= '<form action="' . $_SERVER['PHP_SELF'] . '" method="post" name="form1">
<input type="Hidden" name="day" value="' . $day . '">
<input type="Hidden" name="month" value="' . $month . '">
<input type="Hidden" name="year" value="' . $year . '">

<div align="center"><br>

<table><tr><td><table cellpadding=4 cellspacing=0 border=0 bgcolor="#ffffff" width=40% class="pastel2"><tr><td align="right"><b>Date:</b></td><td>' . $date_converted . ' - ' . $weekday . ' &nbsp;&nbsp; ' . $ID_text . '</td></tr><tr><td align="right"><b>Title:</b></td><td align="left">&nbsp;
<input type="text" name="title" size="65" value="' . $title . '"></td></tr><tr><td colspan=2 align=center><textarea rows=15 cols=100 name="diary_text" wrap>' . $diary_text . '</textarea></td></tr><tr><td colspan=2 align=center><input type="SUBMIT" value="Save Diary" name="save"></td></tr></form></td></tr></table>
</td><td valign="top">' . $current_month . '</td></tr></table>

</div>';
$html_instance->add_parameter(array('TEXT_CENTER' => "{$all_text}", 'BODY' => 'onLoad="javascript:document.form1.title.focus()"'));
$html_instance->process();
开发者ID:vijo,项目名称:Blue-Smiley-Organizer,代码行数:31,代码来源:add-diary.php

示例12: base

<?php

require 'class.base.php';
require 'class.html.php';
$base_instance = new base();
$html_instance = new html();
$userid = $base_instance->get_userid();
$data = $base_instance->get_data("SELECT left(datetime,7) as odate,COUNT(*) AS number FROM {$base_instance->entity['KNOWLEDGE']['MAIN']} WHERE user='{$userid}' GROUP BY odate ORDER BY odate DESC");
if (!$data) {
    $base_instance->show_message('No knowledge added yet', '');
}
$all_text = '<div align="center"><table border=1 cellspacing=0 cellpadding=5 bgcolor="#ffffff" class="pastel"><tr bgcolor="#dedede"><td><b>Month</b></td><td><strong>Entries</strong></td></tr>';
for ($index = 1; $index <= sizeof($data); $index++) {
    $number = $data[$index]->number;
    $odate = $data[$index]->odate;
    $all_text .= '<tr><td><b>' . $odate . '</b></td><td align="center">' . $number . '</td></tr>';
}
$all_text .= '</table></div>';
$html_instance->add_parameter(array('HEADER' => 'Added Knowledge by Month', 'TEXT' => "{$all_text}", 'BACK' => 1));
$html_instance->process();
开发者ID:vijo,项目名称:Blue-Smiley-Organizer,代码行数:20,代码来源:show-added-knowledge-monthly.php

示例13: setcookie

}
#
if (isset($_GET['view_mode'])) {
    $view_mode = $_GET['view_mode'];
    setcookie('vm_todo', $view_mode, time() + 2592000);
} else {
    $view_mode = isset($_COOKIE['vm_todo']) ? $_COOKIE['vm_todo'] : '';
}
#
if ($view_mode == 1) {
    $link = '<a href="' . $_SERVER['PHP_SELF'] . '?' . $param . 'view_mode=0">[Complete View]</a>';
} else {
    $link = '<a href="' . $_SERVER['PHP_SELF'] . '?' . $param . 'view_mode=1">[List View]</a>';
}
#
$html_instance->add_parameter(array('ACTION' => 'show_content', 'ENTITY' => 'TO_DO', 'ORDER_COL' => $order_col, 'ORDER_TYPE' => $order_type, 'MAXHITS' => 40, 'WHERE' => "WHERE user='{$userid}' {$query}", 'SORTBAR' => 2, 'SORTBAR_FIELD1' => 'datetime', 'SORTBAR_NAME1' => 'Date added', 'SORTBAR_FIELD2' => 'priority', 'SORTBAR_NAME2' => 'Priority', 'HEADER' => 'To-Do ' . $category_name . ' &nbsp;&nbsp; ' . $link . ' &nbsp;&nbsp; <a href="show-to-do-print.php?' . $param . '" target="_blank">[Print]</a>  &nbsp;&nbsp; <a href="generate-rss-feed-to-do.php">[RSS Feed]</a> ', 'INNER_TABLE_WIDTH' => '80%', 'URL_PARAMETER' => $param, 'HEAD' => '<script language="JavaScript" type="text/javascript">function createRequestObject(){try {var requester=new XMLHttpRequest();}catch (error) {try{var requester=new ActiveXObject("Microsoft.XMLHTTP");}catch(error){return false;}}return requester;}var http=createRequestObject();function DelToDo(item){if(confirm("Delete To-Do?")){http.open(\'get\',\'delete-to-do.php?item=\'+item);http.onreadystatechange=handleResponse;http.send(null);}}function handleResponse(){if(http.readyState==4){var response=http.responseText;var update=new Array();if(response.indexOf(\'|\'!=-1)){res=response.split(\'|\');document.getElementById(res[0]).innerHTML=res[1];}}}</script>'));
$data = $html_instance->get_items();
if (!$data) {
    if ($text_search) {
        if ($text_search) {
            $base_instance->show_message('Search Result', 'Nothing found for the entered search terms.<p><a href="javascript:history.go(-1)">[Go Back]</a>');
        }
    } else {
        $base_instance->show_message('No to-do added yet', '<a href="add-to-do.php">[Add To-do]</a>');
    }
} else {
    $all_text = '';
    for ($index = 1; $index <= sizeof($data); $index++) {
        $ID = $data[$index]->ID;
        $title = $data[$index]->title;
        $priority = $data[$index]->priority;
开发者ID:vijo,项目名称:Blue-Smiley-Organizer,代码行数:31,代码来源:show-to-do.php

示例14: AND

    $param = "category_id={$category_id}";
    $data = $base_instance->get_data("SELECT title FROM {$base_instance->entity['FILE']['CATEGORY']} WHERE ID={$category_id}");
    $title = $data[1]->title;
    $category_name = '(Category ' . $title . ')';
} else {
    $category_name = '';
}
#
if (!empty($_GET['public'])) {
    $query .= " AND (public=2) ";
    $param = "public=1";
    $link = '<a href="show-files.php">[Show all]</a>';
} else {
    $link = '<a href="show-files.php?public=1">[Only Public]</a>';
}
$html_instance->add_parameter(array('ACTION' => 'show_content', 'ENTITY' => 'FILE', 'MAXHITS' => 40, 'WHERE' => "WHERE user='{$userid}' {$query}", 'SORTBAR' => 2, 'SORTBAR_FIELD1' => 'datetime', 'SORTBAR_NAME1' => 'Date added', 'SORTBAR_FIELD2' => 'title', 'SORTBAR_NAME2' => 'Title', 'HEADER' => 'Uploaded Files ' . $category_name . ' &nbsp;&nbsp; ' . $link, 'INNER_TABLE_WIDTH' => '80%', 'URL_PARAMETER' => $param, 'HEAD' => '<script language="JavaScript" type="text/javascript">function createRequestObject(){try {var requester=new XMLHttpRequest();}catch (error) {try{var requester=new ActiveXObject("Microsoft.XMLHTTP");}catch(error){return false;}}return requester;}var http=createRequestObject();function DelFile(item){if(confirm("Delete File?")){http.open(\'get\',\'delete-file.php?item=\'+item);http.onreadystatechange=handleResponse;http.send(null);}}function handleResponse(){if(http.readyState==4){var response=http.responseText;var update=new Array();if(response.indexOf(\'|\'!=-1)){res=response.split(\'|\');document.getElementById(res[0]).innerHTML=res[1];}}}</script>'));
$data = $html_instance->get_items();
if (!$data) {
    if ($text_search) {
        $html_instance->add_parameter(array('HEADER' => 'Nothing found (Files)', 'TEXT' => '<form action="show-files.php" method="post"><center><table cellpadding=10 cellspacing=0 border=0 bgcolor="#ffffff" class="pastel2"><tr><td align="right"><b>Text:</b> &nbsp;<input type="text" name="text_search" size="30" value="' . $text_search . '"></td></tr><tr><td align="center"><input type="SUBMIT" value="Search Files" name="save"></td></tr></table></center></form>'));
        $html_instance->process();
    } else {
        $base_instance->show_message('No files uploaded yet', '<a href="add-file.php">[Upload File]</a>');
    }
} else {
    $all_text = '<table width="100%" border cellspacing=0 cellpadding=5 class="pastel">';
    for ($index = 1; $index <= sizeof($data); $index++) {
        $ID = $data[$index]->ID;
        $datetime = $data[$index]->datetime;
        $text = $data[$index]->text;
        $title = $data[$index]->title;
开发者ID:vijo,项目名称:Blue-Smiley-Organizer,代码行数:31,代码来源:show-files.php

示例15: base

<?php

require 'class.base.php';
require 'class.html.php';
require 'class.diary.php';
$base_instance = new base();
$html_instance = new html();
$diary_instance = new diary();
if (isset($_GET['year'])) {
    $year = (int) $_GET['year'];
} else {
    exit;
}
$year_overview = $diary_instance->get_year_view($year);
$html_instance->add_parameter(array('TEXT_CENTER' => '<p>' . $year_overview));
$html_instance->process();
开发者ID:vijo,项目名称:Blue-Smiley-Organizer,代码行数:16,代码来源:show-diary-year.php


注:本文中的html::add_parameter方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。