コード例 #1
0
ファイル: functions.php プロジェクト: phucanh92/vietlong
function bayfront_do_footer_bottom()
{
    // Open layout wrap
    wpsight_layout_wrap('footer-bottom-wrap');
    ?>

	<div id="footer-bottom" class="clearfix">
			
		<div id="bottom-menu">
		
			<?php 
    echo wpsight_menu('bottom');
    ?>
		
		</div><!-- #bottom-menu -->
		<?php 
    $credit = wpsight_get_option('credit');
    // Set default value if option has not been set
    if (wpsight_get_option('credit') === false) {
        $credit = wpsight_get_option('credit', true);
    }
    ?>
		<div id="footer-contact-info">
			<?php 
    // Open layout wrap
    wpsight_layout_wrap('credit-wrap');
    ?>
			<div id="credit" class="clearfix">			    
				<?php 
    echo do_shortcode($credit);
    ?>
			</div><!-- #credit --><?php 
    // Close layout wrap
    wpsight_layout_wrap('credit-wrap', 'close');
    ?>
		</div>
		
		<?php 
    // Loop through social icons
    $nr = apply_filters('wpsight_social_icons_nr', 5);
    $social_icons = array();
    for ($i = 1; $i <= $nr; $i++) {
        $social_icons[] = wpsight_get_social_icon(wpsight_get_option('icon_' . $i));
    }
    // Remove empty elements
    $social_icons = array_filter($social_icons);
    $output = '<div class="social-icons">';
    if (!empty($social_icons)) {
        $i = 1;
        foreach ($social_icons as $k => $v) {
            $social_link = wpsight_get_option('icon_' . $i . '_link');
            $output .= '<a href="' . $social_link . '" target="_blank" title="' . $v['title'] . '" class="social-icon social-icon-' . $v['id'] . '"><img src="' . $v['icon'] . '" alt="" /></a>' . "\n";
            $i++;
        }
    } else {
        $social_icon = wpsight_get_social_icon('rss');
        $output .= '<a href="' . get_bloginfo_rss('rss2_url') . '" target="_blank" title="' . $social_icon['title'] . '" class="social-icon social-icon-' . $social_icon['id'] . '"><img src="' . $social_icon['icon'] . '" alt="" /></a>' . "\n";
    }
    $output .= '</div><!-- .social-icons -->';
    echo apply_filters('wpsight_social_icons_top', $output);
    echo '<div class="subscribe-form">';
    if (function_exists('newsletter_form')) {
        newsletter_form(1);
    }
    echo '</div>';
    ?>
		
		</div><!-- #footer-bottom --><?php 
    // Close layout wrap
    wpsight_layout_wrap('footer-bottom-wrap', 'close');
}
コード例 #2
0
ファイル: newsletter.php プロジェクト: hzhou9/coupon_deal
<?php

echo '<div class="widget widget_newsletter' . (!$mobile_view ? ' mobile_view' : '') . '" id="widget_newsletter">';
if (!empty($title)) {
    echo '<h2>' . $title . '</h2>';
}
if (!empty($content)) {
    echo '<div class="text">' . $content . '</div>';
}
echo newsletter_form('_widget');
echo '</div>';
コード例 #3
0
         $form_add = "onsubmit=\"editor1.prepareSubmit()\" ";
     }
     if ($_GET[email_type] == "html" or $_GET[email_type] == "both") {
         echo "<script type=\"text/javascript\" src=\"../htmleditor/editor.js\"></script>";
     }
     echo "<h3 align=center>Send out a newsletter</h3><center>\n\t\t\t\t<table width=\"60%\" align=\"center\" style=\"font-size: 9pt; font-family: Verdana\">\n\t\t\t\t  <tr>\n\t\t\t\t\t<td><form " . $form_add . "method=\"POST\" action=\"" . $_SERVER[PHP_SELF] . "?action=add_news&email_type=" . $_GET[email_type] . "\">\n\t\t\t\t\t<input type=\"hidden\" name=\"email_type\" value=\"" . $_GET[email_type] . "\">";
     if ($_GET[email_type] == "html") {
         newsletter_form("html");
     } else {
         if ($_GET[email_type] == "text") {
             newsletter_form("text");
         } else {
             if ($_GET[email_type] == "both") {
                 newsletter_form("html");
                 echo "</td></tr><tr><td>&nbsp;</td></tr><tr><td>";
                 newsletter_form("text");
             }
         }
     }
     echo "</td></tr>\n\t\t\t\t\t<tr><td colspan=2 align=center><input type=submit name=submit value=submit></form></td>\n\t\t\t\t\t</tr></table>";
 } else {
     if (isset($_POST[submit])) {
         $continue = 1;
         if ($_GET[email_type] == "html") {
             if (empty($_POST[html_subject]) or empty($_POST[html_message])) {
                 $continue = 0;
             } else {
                 if (!empty($_POST[html_subject]) && !empty($_POST[html_message])) {
                     $continue = 1;
                 }
             }