Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Integrating GS with a bootstrap html template
#1
Brick 
Hi,

I've bought an html boilerplate template called MyWay (on Themeforest) and now I'm trying to integrate it with GS. I've played before with theme creation, but from scratch Confused.

Now, I put all theme's files in a folder inside GS's themes folder, changed index.html by template.php, added get_header() and get_footer(), and adjust some minors changes (functions.php, etc.).

When I type the URL, the browser only shows the html output, without css nether js.

Undecided What I need to do? Is there any aspect which I'm not taking in mind?

Thanks,

BB

Ok, I'm starting to fix it.
It was an url problem, so I've used <?php get_theme_url(); ?> template's tag.
Perpetual learner trying to solve problems throught web design.
Reply
#2
is this useful?
http://get-simple.info/forums/showthread.php?tid=4246
Reply
#3
Another integration problem: as a one-page-theme I need to adjust the menu output to point to inpage anchors not to complet url. The site's going to be multilingual (using I18N plugin), so I can't write the menu by hard coding in template.php.

I'm looking for a way to produce an output like:

Code:
<li><a href="#page-slug">page_title</a></li>
<li><a href="#page-slug">page_title</a></li>
<li><a href="#page-slug">page_title</a></li>
<li><a href="#page-slug">page_title</a></li>
...

Using <?php get_navigation(return_page_slug()); ?> doesn't seem to be the solution as it's output is a complet url menu. Neither <?php menu_data('page-slug'); ?> works for me - actually hasn't produced any output.
Perpetual learner trying to solve problems throught web design.
Reply
#4
You can add your own functions.php and have a function to get pages from global $pagesArray
see wiki on page cache

To use native navigation functions you would have to do some kind of parsing or regex on it, I do not know how else you might do it.

Probably just copy the get nav function and remove the url or add a argument to it to only return slugs anchors.
NEW: SA Admin Toolbar Plugin | View All My Plugins
- Shawn A aka Tablatronix
Reply
#5
Hi Shawn A,

I'm not a developer, but I would like to find a solution Blush. So I ask you some of my doubts:

A. Adding functions to functions.php

Which kind of formula should I build?
  • One based on foreach() and echoPageField($page,$field).
  • One based on adding extra content to each array element.
How can I interact with $pagesArray? I check it out the wiki page but I need some more indications.

B. Parsing native navigation functions
  • Which files I'll need to edit? Those on /admin/ folder?
Perpetual learner trying to solve problems throught web design.
Reply
#6
Well your theme would need its own functions.php file
You can make your own copy of get_navigation, rename it of course, and change the one line that has the url in it to just the slug.

PHP Code:
function get_navigation_anchors($currentpage) {

    
$menu '';

    global 
$pagesArray;
    
    
$pagesSorted subval_sort($pagesArray,'menuOrder');
    if (
count($pagesSorted) != 0) { 
        foreach (
$pagesSorted as $page) {
            
$sel ''$classes '';
            
$url_nav $page['url'];
            
            if (
$page['menuStatus'] == 'Y') { 
                if (
"$currentpage== "$url_nav") { $classes "current active "$page['parent'] ." "$url_nav; } else { $classes trim($page['parent'] ." "$url_nav); }
                if (
$page['menu'] == '') { $page['menu'] = $page['title']; }
                if (
$page['title'] == '') { $page['title'] = $page['menu']; }
                
// $menu .= '<li class="'. $classes .'"><a href="'. find_url($page['url'],$page['parent']) . '" title="'. encode_quotes(cl($page['title'])) .'">'.strip_decode($page['menu']).'</a></li>'."\n";
                
$menu .= '<li class="'$classes .'"><a href="#'$page['parent']) . '" title="'encode_quotes(cl($page['title'])) .'">'.strip_decode($page['menu']).'</a></li>'."\n";
            }
        }
        
    }
    
    echo 
exec_filter('menuitems',$menu);


Something like that, i do not know if that change works or not.
NEW: SA Admin Toolbar Plugin | View All My Plugins
- Shawn A aka Tablatronix
Reply
#7
@biringanya

I think Carlos posted a method for a one page site with nav. I had intended to make a template theme out of it one day. You will need to search the forum, it may be what you need.
Reply
#8
Here it was:
http://get-simple.info/forums/showthread...4#pid23834
Also here: http://www.cyberiada.org/cnb/log/one-pag...getsimple/
Reply
#9
Oh, thanks Carlos, Timbow and Shawn A!

I'll mix all these code and share the results here!

Start working on it...
Perpetual learner trying to solve problems throught web design.
Reply




Users browsing this thread: 1 Guest(s)