示例#1
0
$nc->init();
?>
        <?php 
$nc->hidden('id');
?>
        <?php 
$nc->hidden('status');
?>

        <table class="form-table">

            <tr valign="top">
                <th>Theme</th>
                <td>
                    <?php 
$nc->select_grouped('theme', array(array_merge(array('' => 'Custom themes'), newsletter_get_themes()), $themes, $themes_panel));
?>
                    <?php 
$nc->button('compose', 'Change');
?>
 (email content below will be regenerated)
                    <div class="hints">
                        Theme changing does not save this email, remember to press save if you are satisfied of the result. A theme can have a style file
                        (style.css in theme folder): that style will be added to your emails, so when you change the theme you MUST press "change" to have
                        in the editor the right content for the current theme style. No easy to explain. No all email readers respect the theme graphics!
                    </div>
                </td>
            </tr>

            <tr valign="top">
                <th>Subject</th>
示例#2
0
                            <option <?php 
echo 'messages' == $options['theme'] ? 'selected' : '';
?>
 value="messages">For messages</option>
                        </optgroup>
                        <optgroup label="Extras themes">
                            <?php 
$themes = newsletter_get_extras_themes();
foreach ($themes as $theme) {
    echo '<option ' . ('$' . $theme == $options['theme'] ? 'selected' : '') . ' value="$' . $theme . '">' . $theme . '</option>';
}
?>
                        </optgroup>
                        <optgroup label="Custom themes">
                            <?php 
$themes = newsletter_get_themes();
foreach ($themes as $theme) {
    echo '<option ' . ('*' . $theme == $options['theme'] ? 'selected' : '') . ' value="*' . $theme . '">' . $theme . '</option>';
}
?>
                        </optgroup>
                    </select>
                    <br />
                    <?php 
_e('Selected theme has to be one with {message} tag inside, tag that will be replaced with messages. Use the blank theme to send messages as you see them in the editor.', 'newsletter');
?>
                </td>
            </tr>
        </table>
        <p class="submit">
            <?php