-
Search Results
-
Topic: Messed up the footer
Hello, while trying to add an image to my footer through the footer.php file in my editor I’ve messed up the code so it wouldn’t load the website now. Could you please help me figure out what is the problem.
Here is the current text I have in the footer.php
<?php
do_action( ‘ava_before_footer’ );
global $avia_config;
$blank = isset($avia_config[‘template’]) ? $avia_config[‘template’] : “”;//reset wordpress query in case we modified it
wp_reset_query();//get footer display settings
$the_id = avia_get_the_id(); //use avia get the id instead of default get id. prevents notice on 404 pages
$footer = get_post_meta($the_id, ‘footer’, true);
$footer_widget_setting = !empty($footer) ? $footer : avia_get_option(‘display_widgets_socket’);//check if we should display a footer
if(!$blank && $footer_widget_setting != ‘nofooterarea’ )
{
if( $footer_widget_setting != ‘nofooterwidgets’ )
{
//get columns
$columns = avia_get_option(‘footer_columns’);
?>
<div class=’container_wrap footer_color’ id=’footer’><div class=’container’>
<?php
do_action(‘avia_before_footer_columns’);//create the footer columns by iterating
switch($columns)
{
case 1: $class = ”; break;
case 2: $class = ‘av_one_half’; break;
case 3: $class = ‘av_one_third’; break;
case 4: $class = ‘av_one_fourth’; break;
case 5: $class = ‘av_one_fifth’; break;
case 6: $class = ‘av_one_sixth’; break;
}$firstCol = “first el_before_{$class}”;
//display the footer widget that was defined at appearenace->widgets in the wordpress backend
//if no widget is defined display a dummy widget, located at the bottom of includes/register-widget-area.php
for ($i = 1; $i <= $columns; $i++)
{
$class2 = “”; // initialized to avoid php notices
if($i != 1) $class2 = ” el_after_{$class} el_before_{$class}”;
echo “<div class=’flex_column {$class} {$class2} {$firstCol}’>”;
if (function_exists(‘dynamic_sidebar’) && dynamic_sidebar(‘Footer – column’.$i) ) : else : avia_dummy_widget($i); endif;
echo “</div>”;
$firstCol = “”;
}do_action(‘avia_after_footer_columns’);
?>
</div><?php
<!– ####### END FOOTER CONTAINER ####### –>
</div><?php } //endif nofooterwidgets ?>
//copyright
$copyright = do_shortcode( avia_get_option(‘copyright’, “© “.__(‘Copyright’,’avia_framework’).” – “.get_bloginfo(‘name’).”“) );// you can filter and remove the backlink with an add_filter function
// from your themes (or child themes) functions.php file if you dont want to edit this file
// you can also just keep that link. I really do appreciate it ;)
$kriesi_at_backlink = kriesi_backlink(get_option(THEMENAMECLEAN.”_initial_version”));//you can also remove the kriesi.at backlink by adding [nolink] to your custom copyright field in the admin area
if($copyright && strpos($copyright, ‘[nolink]’) !== false)
{
$kriesi_at_backlink = “”;
$copyright = str_replace(“[nolink]”,””,$copyright);
}if( $footer_widget_setting != ‘nosocket’ )
{?>
<footer class=’container_wrap socket_color’ id=’socket’ <?php avia_markup_helper(array(‘context’ => ‘footer’)); ?>>
<div class=’container’><span class=’copyright’><?php echo $copyright . $kriesi_at_backlink; ?></span>
<?php
if(avia_get_option(‘footer_social’, ‘disabled’) != “disabled”)
{
$social_args = array(‘outside’=>’ul’, ‘inside’=>’li’, ‘append’ => ”);
echo avia_social_media_icons($social_args, false);
}$avia_theme_location = ‘avia3’;
$avia_menu_class = $avia_theme_location . ‘-menu’;$args = array(
‘theme_location’=>$avia_theme_location,
‘menu_id’ =>$avia_menu_class,
‘container_class’ =>$avia_menu_class,
‘fallback_cb’ => ”,
‘depth’=>1,
‘echo’ => false,
‘walker’ => new avia_responsive_mega_menu(array(‘megamenu’=>’disabled’))
);$menu = wp_nav_menu($args);
if($menu){
echo “<nav class=’sub_menu_socket’ “.avia_markup_helper(array(‘context’ => ‘nav’, ‘echo’ => false)).”>”;
echo $menu;
echo “</nav>”;
}
?></div>
<!– ####### END SOCKET CONTAINER ####### –>
</footer><?php
} //end nosocket check} //end blank & nofooterarea check
?>
<!– end main –>
</div><?php
//display link to previeous and next portfolio entry
echo avia_post_nav();echo “<!– end wrap_all –></div>”;
if(isset($avia_config[‘fullscreen_image’]))
{ ?>
<!–[if lte IE 8]>
<style type=”text/css”>
.bg_container {
-ms-filter:”progid:DXImageTransform.Microsoft.AlphaImageLoader(src='<?php echo $avia_config[‘fullscreen_image’]; ?>’, sizingMethod=’scale’)”;
filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(src='<?php echo $avia_config[‘fullscreen_image’]; ?>’, sizingMethod=’scale’);
}
</style>
<![endif]–>
<?php
echo “<div class=’bg_container’ style=’background-image:url(“.$avia_config[‘fullscreen_image’].”);’></div>”;
}
?><?php
/* Always have wp_footer() just before the closing </body>
* tag of your theme, or you will break many plugins, which
* generally use this hook to reference JavaScript files.
*/wp_footer();
<div id=”fb-root”></div>
</body>
</html>You feedback will be greatly appreciated.
Best regards,
SimeonTopic: Link do not work :-/
Hi,
I have make an image in the top of the right side of the header – with a link. I have put this code:
echo “<div class=’header-custom-text’></div>”;
…in the helper-main-menu.php, right after the line, $output .= avia_logo(AVIA_BASE_URL.’images/layout/logo.png’, $addition, ‘strong’, true);:
Also – In the QUICK CSS style i have put this in:
.header-custom-text {
position: absolute;
right: 0px;
top: 0px;
}
.. but the link dont work correctly anymore, after the last enfold update. i want the hole images to be clic able. Please can you help me, they started a campaign today, and this link is very importent?Also – if it is possible, can i make the images to be in front, i dont want the border from the header to go across the images?
Thanks in advance!
TinaI was wondering if it is possible to add a custom div id field to all avia-layout elements (ex. text-block, image, notification, tabs, etc). I know it is possible to add div classes via the functions.php file with this
add_theme_support('avia_template_builder_custom_css');but I was hoping to use div ID on elements for anchor link purposes. My anchor links don’t always drop down to the appropriate view.
Thanks,
BradI am trying to remove borders around specific images only. I followed instructions to enable custom css class and added css rules to try and accomplish this but, to no eval.
Added cw-noborder to custom class
css: .avia-image-container-inner .avia-image-container-inner.cw-noborder {
border:none !important;
}I have two sites that are almost identical and was able to get the english site to show the post title but wasn’t able to get the post title to show up on my spanish site. I have shown my functions.php file below.
Do you have any tips on how I can get this to work for both sites?
<?php // Opening PHP tag - nothing should be before this, not even whitespace // Custom Function to Include function favicon_link() { echo '<link rel="shortcut icon" type="image/x-icon" href="/favicon.ico" />' . "\n"; } add_action( 'wp_head', 'favicon_link' ); add_filter('avf_which_archive_output','avf_change_which_archive', 10, 3); function avf_change_which_archive($output) { if(is_category()) { $output = __('','avia_framework').' '.single_cat_title('',false); } return $output; } add_filter( 'wp_nav_menu_items', 'avia_append_search_nav', 10, 2 ); function avia_append_search_nav ( $items, $args ) { if(avia_get_option('header_searchicon','header_searchicon') != "header_searchicon") return $items; if ((is_object($args) && $args->theme_location == 'avia') || (is_string($args) && $args = "fallback_menu")) { global $avia_config; ob_start(); $getform = get_search_form(false); $items .= '<li id="menu-item-search" class="noMobile menu-item menu-item-search-dropdown">'.$getform.'</li>'; } return $items; } add_filter('avf_title_args', 'fix_single_post_title', 10, 2); function fix_single_post_title($args,$id) { if ( $args['title'] == 'Blog - Latest News' ) { $args['title'] = get_the_title($id); $args['link'] = get_permalink($id); $args['heading'] = 'h1'; } return $args; } add_action('wp_head' , 'remove_post_list_title_links'); function remove_post_list_title_links() { ?> <script id="remove-links-in-title" type="text/javascript"> jQuery(document).ready(function($) { $('.entry-title').each(function() { var $title_link = $('a[rel="bookmark"]' , $(this)), $title_text = $title_link.text(); $title_link.remove(); $(this).prepend($title_text); }); }); </script> <?php }I can see that the title on my site is hidden with CSS but the title shows up below the featured image and is supposed to be shown in the top title bar.
I have tried my best to read through the form and documentation but haven’t been able to solve this.
Hey,
Thanks in advance for any help on this.
I found a thread on this with code for functions.php already but would like to change the following…
1) The image being 100% width (responsive) and centered.
2) No parallax effect.Thanks!
____________________________add_action('ava_after_main_container', 'add_banner_before_breadcrumb'); function add_banner_before_breadcrumb() { if ( is_product() ) { echo '<div id="av_product_description" class="avia-section main_color avia-section-default avia-no-shadow avia-full-stretch av-parallax-section avia-bg-style-parallax av-minimum-height av-minimum-height-75 container_wrap fullsize" style="color:#ffffff;" data-section-bg-repeat="stretch"> <div class="av-parallax avia-full-stretch"></div> </div>'; } } add_action('wp_footer', 'ava_custom_script_parallax'); function ava_custom_script_parallax(){ ?> <script> (function($){ $('#av_product_description .av-parallax').css('background-image', 'url(' + 'https://paultmurphy.files.wordpress.com/2010/08/cropped-boston-skyline-banner-1000.jpg' + ')'); $('#av_product_description').css('height', '180px'); })(jQuery); </script> <?php }

