Review readme.md for commit log at this stage.

This commit is contained in:
Jay Wood
2014-11-09 13:18:03 -05:00
parent 1fd0624928
commit dff22f705e
8 changed files with 193 additions and 169 deletions

View File

@ -25,62 +25,67 @@ function cwv3_get_css(){
$bg_color_css = ! empty( $color ) ? 'background-color: ' . $color['color'] . ';' : '';
ob_start();
?><style type="text/css"><?php
?>
<!-- CWV3 CSS -->
<style type="text/css">
#cboxOverlay{<?php echo $bg_image_css . $bg_color_css; ?>}
<?php
if ( ! empty( $custom_css ) ){
echo apply_filters( 'cwv3_custom_css', $custom_css );
}
?>#cboxOverlay{
echo $bg_image_css . $bg_color_css;
}<?php
do_action( 'cwv3_after_css' );
?></style><?php
?>
</style>
<!-- END CWV3-CSS -->
<?php
return apply_filters( 'cwv3_css', ob_get_clean() );
}
function cwv3_js_dialog(){
echo cwv3_get_js_dialog();
}
function cwv3_get_js_dialog(){
$exit_text = get_option( 'cwv3_exit_txt', __( 'Exit', 'cwv3' ) );
$enter_text = get_option( 'cwv3_enter_txt', __( 'Enter', 'cwv3' ) );
$exit_text = get_option( 'cwv3_exit_txt', __( 'Exit', 'cwv3' ) );
$enter_text = get_option( 'cwv3_enter_txt', __( 'Enter', 'cwv3' ) );
$cwv3_denial_title = get_option( 'cwv3_den_title', __( 'Access Denied', 'cwv3' ) );
$cwv3_denial_title = get_option( 'cwv3_den_title', __( 'Access Denied', 'cwv3' ) );
$cwv3_denial_message = get_option( 'cwv3_den_msg', __( 'You have been denied access to this content. If you feel this is in error, please contact a site administrator.', 'cwv3' ) );
$cwv3_title = get_option( 'cwv3_den_title', __( 'Access Denied', 'cwv3' ) );
$cwv3_message = get_option( 'cwv3_den_msg', __( 'You have been denied access to this content. If you feel this is in error, please contact a site administrator.', 'cwv3' ) );
$cwv3_title = get_option( 'cwv3_den_title', __( 'Access Denied', 'cwv3' ) );
$cwv3_message = get_option( 'cwv3_den_msg', __( 'The content you are about to view may be considered offensive and/or inappropriate. Furthermore, this content may be considered adult content, if you are not of legal age or are easily offended, you are required to click the exit button.', 'cwv3' ) );
$exit_url = get_option( 'cwv3_exit_link', '#' );
$enter_url = get_option( 'cwv3_enter_link', '#' );
$exit_url = get_option( 'cwv3_exit_link', '#' );
$enter_url = get_option( 'cwv3_enter_link', '#' );
ob_start();
?>
<div id="cwv3_dialog" class="cwv3_dialog js">
<div class="cwv3 auth">
<div class="cwv3_title"><?php echo esc_attr( $cwv3_den_title ); ?></div>
<div class="cwv3_content"><?php echo wp_kses_post( $cwv3_den_msg ); ?></div>
<div class="cwv3_title"><?php echo esc_attr( $cwv3_title ); ?></div>
<div class="cwv3_content"><?php echo wp_kses_post( $cwv3_message ); ?></div>
<div class="cwv3_btns">
<div class="cwv3_enter">
<a href="<?php echo esc_url( $enter_url ); ?>"><?php echo esc_attr( $enter_text ); ) ?></a>
<a href="<?php echo esc_url( $enter_url ); ?>"><?php echo esc_attr( $enter_text ); ?></a>
</div>
<div class="cwv3_exit">
<a href="<?php echo esc_url( $exit_url ); ?>"><?php echo esc_attr( $exit_url ); ) ?></a>
<a href="<?php echo esc_url( $exit_url ); ?>"><?php echo esc_attr( $exit_url ); ?></a>
</div>
</div>
</div>
<div class="cwv3 denied">
<div class="cwv3_title"><?php echo esc_attr( $cwv3_title ); ?></div>
<div class="cwv3_content"><?php echo wp_kses_post( $cwv3_message ); ?></div>
<div class="cwv3_title"><?php echo esc_attr( $cwv3_denial_title ); ?></div>
<div class="cwv3_content"><?php echo wp_kses_post( $cwv3_denial_message ); ?></div>
<div class="cwv3_btns">
<div class="cwv3_exit">
<a href="<?php echo esc_url( $exit_url ); ?>"><?php echo esc_attr( $exit_url ); ) ?></a>
<a href="<?php echo esc_url( $exit_url ); ?>"><?php echo esc_attr( $exit_url ); ?></a>
</div>
</div>
</div>
</div>
<?php
$dialog_output = ob_get_clean();
return apply_filters( 'cwv3_js_dialog_output', $dialog_output );
}