Menu icon Foundation

Developer | Utrecht

My Posts

  • 4
    Replies
  • F5 codekit enqueue scripts php

    By Oloeg

    enqueue

    Hello, Is there a way to enqueue a couple of scripts just like people does in a Foundation wordpress theme. Only now it is for a basic php site without cms. So the document is cleaner. Regards, Hugo

    Last Reply by Oloeg over 4 years ago









My Comments

Oloeg commented on Oloeg's post over 4 years

@bob thanks!

Oloeg commented on Oloeg's post over 4 years

@Bob, true but do you know how to fix this?

Oloeg commented on Demetrius Ford's post almost 5 years
Oloeg commented on Oloeg's post about 5 years

Hello Already fixed it.

set the lightness to 100% as example and the link hover to a color.

$topbar-link-hover-lightness: 100%; // Darken by 10%
$topbar-link-bg-hover: green  ;

Oloeg commented on Oloeg's post about 5 years

Hello Preston McPeak,

But this are the styles for the side bar I think not for the top bar :)

Regards,
Hugo

Oloeg commented on Oloeg's post about 5 years

When I want the fastest load is it better then to take the css Essential? or is there no difference with a package stript for SASS?

Oloeg commented on Oloeg's post about 5 years

Hello Thanks for the options, does this reduce the loading time?
And is this just as fast as the Essential css download? or is that one faster with a smaller load?

regards,
Hugo

Oloeg commented on Oloeg's post over 5 years

@Ben Hutchings the sass background code fixed the full background. Thanks

html { 
    background: url(../img/bg.jpg) no-repeat center center fixed; 
    -webkit-background-size: cover;
    -moz-background-size: cover;
    -o-background-size: cover;
    background-size: cover;
}
$body-bg: transparent; 

Oloeg commented on Oloeg's post over 5 years

@James, Thanks now it loads fine! that I did'nt see that earlyer.

Many thanks now my theme is working and the js is loaded.

Regards,
Hugo

Oloeg commented on Oloeg's post over 5 years

@james, I have installed firebug and tried what you say.

•delete the dropdown js script so I enqueue the foundation.min.js.
•add the code in footer.

the following error is thrown by firebug:

TypeError: $(...).foundation is not a function
$(document).foundation();

  </footer>


    <?php wp_footer();?>

<script>
(function($) {
$(document).foundation();
})(jQuery);
</script>

  </body>
</html>
<?php

function register_my_scripts() {
  wp_deregister_script('jquery');  
  wp_register_script('jquery', "http://ajax.googleapis.com/ajax/libs/jquery/2.1.0/jquery.min.js", array(),'2.1.0',false);
  wp_register_script('modernizer', get_template_directory_uri()."/js/vendor/modernizr.js",array(),'2.7.1', false);
  wp_register_script('foundation', get_template_directory_uri()."/js/foundation.min.js", array('jquery'),'5.1.1',true);

  wp_enqueue_script(array('jquery','modernizer'));
}

function register_my_styles(){
  wp_register_style('reset', get_template_directory_uri()."/css/normalize.css",array(),'5.1.1','screen');
  wp_register_style('main', get_template_directory_uri()."/style.css",array(),'2.7','all');  
  wp_register_style('foundation', get_template_directory_uri()."/css/foundation.min.css",array('main'),'5.1.1','screen');

  wp_enqueue_style(array('reset','main','foundation'));
}

add_action('wp_print_scripts','register_my_scripts');
add_action('wp_print_styles', 'register_my_styles');

?>

Regards,

Posts Followed

  • 3
    Replies
  • Full Width Row

    By Alok Jethanandani

    Foundation 4Rows

    Hey guys, I’m just curious what you think the best practice is when I have a row that I need to be full width of the page. Because if I set a row to be the full width, then my interior subsequent row will be full width and not adopt the Foundation defa... (continued)

    Last Reply by AlexLasek over 5 years ago



  • 2
    Replies
  • Full screen grid

    By Roman

    gridfull screen

    Hi, I'm trying to make a full screen grid and have made the following change to _settings.scss: $row-width: 100%; But when i try to nest a row it gets the width set to auto: .row .row { width: auto; } I would like this to be 100% also. ... (continued)

    Last Reply by Jacky888 9 months ago








Following

    No Content

Followers

My Posts





My Comments

You commented on Oloeg's post over 4 years

@bob thanks!

You commented on Oloeg's post over 4 years

@Bob, true but do you know how to fix this?

You commented on Demetrius Ford's post almost 5 years
You commented on Oloeg's post about 5 years

Hello Already fixed it.

set the lightness to 100% as example and the link hover to a color.

$topbar-link-hover-lightness: 100%; // Darken by 10%
$topbar-link-bg-hover: green  ;

You commented on Oloeg's post about 5 years

Hello Preston McPeak,

But this are the styles for the side bar I think not for the top bar :)

Regards,
Hugo

You commented on Oloeg's post about 5 years

When I want the fastest load is it better then to take the css Essential? or is there no difference with a package stript for SASS?

You commented on Oloeg's post about 5 years

Hello Thanks for the options, does this reduce the loading time?
And is this just as fast as the Essential css download? or is that one faster with a smaller load?

regards,
Hugo

You commented on Oloeg's post over 5 years

@Ben Hutchings the sass background code fixed the full background. Thanks

html { 
    background: url(../img/bg.jpg) no-repeat center center fixed; 
    -webkit-background-size: cover;
    -moz-background-size: cover;
    -o-background-size: cover;
    background-size: cover;
}
$body-bg: transparent; 

You commented on Oloeg's post over 5 years

@James, Thanks now it loads fine! that I did'nt see that earlyer.

Many thanks now my theme is working and the js is loaded.

Regards,
Hugo

You commented on Oloeg's post over 5 years

@james, I have installed firebug and tried what you say.

•delete the dropdown js script so I enqueue the foundation.min.js.
•add the code in footer.

the following error is thrown by firebug:

TypeError: $(...).foundation is not a function
$(document).foundation();

  </footer>


    <?php wp_footer();?>

<script>
(function($) {
$(document).foundation();
})(jQuery);
</script>

  </body>
</html>
<?php

function register_my_scripts() {
  wp_deregister_script('jquery');  
  wp_register_script('jquery', "http://ajax.googleapis.com/ajax/libs/jquery/2.1.0/jquery.min.js", array(),'2.1.0',false);
  wp_register_script('modernizer', get_template_directory_uri()."/js/vendor/modernizr.js",array(),'2.7.1', false);
  wp_register_script('foundation', get_template_directory_uri()."/js/foundation.min.js", array('jquery'),'5.1.1',true);

  wp_enqueue_script(array('jquery','modernizer'));
}

function register_my_styles(){
  wp_register_style('reset', get_template_directory_uri()."/css/normalize.css",array(),'5.1.1','screen');
  wp_register_style('main', get_template_directory_uri()."/style.css",array(),'2.7','all');  
  wp_register_style('foundation', get_template_directory_uri()."/css/foundation.min.css",array('main'),'5.1.1','screen');

  wp_enqueue_style(array('reset','main','foundation'));
}

add_action('wp_print_scripts','register_my_scripts');
add_action('wp_print_styles', 'register_my_styles');

?>

Regards,

Posts Followed







Following

  • No Content

Followers

  • No Content