WordPress.org

Ready to get started?Download WordPress

Forums

[Plugin: NextGEN Gallery] How to add nextgen code to a custom page (13 posts)

  1. dekmar
    Member
    Posted 6 years ago #

    Hi,
    I want to add a gallery to a custom home page from a theme I bought. My problem is that I can't see that page as I see the others, so I have to work directly modifying the code. I installed the gallery on a testing page and it works fine, but I want it on my home page. My problem is how to recognize the code that I have to add to the home page in order for it to show there. [gallery=1] doesn't work there... Can anybody help?

  2. bee dudler
    Member
    Posted 6 years ago #

    Hi,
    may i ask if thats a custom template within the theme especially for the homepage or something else e.g. static html which could be as you can't edit in wordpress?

    best regards
    bee

  3. dekmar
    Member
    Posted 6 years ago #

    It's a custom template within the theme (tpl_home.php). I can see the code through the theme editor, and it comes ready for flickr rss, but I really want a nextgen gallery which I already tested in another of the regular pages. I'm a newbie with php, so I don't know what I need to write there.
    This is what I have now, although flickr rss is not active:

    <h2>GalerĂ­a de fotos</h2>
    <div class="nextgen"><div class="flickr">
    <script type="text/javascript" src="http://www.flickr.com/badge_code_v2.gne?count=10&display=latest&size=s&source=user&user=<?php echo $pt_flickr_id; ?>"></script>
    </div>

    How do I tell this page that I want my nextgen gallery there?

  4. bee dudler
    Member
    Posted 6 years ago #

    Hi,
    sorry but i have to play the q and a game over again. Normally a custom template is connected to one or more page(s), you just select the template that you wish to use from the write page or mangage page in the editing window - look for page template below the text field and select it.

    Then you define this page as start page wordpress settings for reading (orso mine is not english)

    Generally a template is not for adding content but to be associated with a page just for the look sidebar or not and the like in the settings for that page and you can edit normally and of course add a gallery.

    Do you use it this way?

    best regards
    bee

  5. dekmar
    Member
    Posted 6 years ago #

    Hi,
    First, I want you to know that I'm very grateful for your help.
    I think I did as you explained.
    I'll tell you what I did:
    on Write -> Write Page I entered the page title "Inicio" (my site is in Spanish). In the page template box I selected "Home", which is the custom home page template.
    In Settings -> Reading I selected Static Page -> Front Page -> Inicio.
    But when I add [gallery=1] to my Inicio page, nothing happens. When I add [gallery=1] to my testing page, it shows perfectly.

  6. bee dudler
    Member
    Posted 6 years ago #

    Hi,
    thank you for sorting that out - the next thing you could try to analayze the code both pages are delivering to your browser when visiting (there view source of page orso its a right click menue in my firefox) have to be differencies especially in the header section.

    You can also try to compare the working template with the non working one especially for example is there perhaps also a different header included by the custom template, and then is there <?php wp_head();?> called (must be called between <HEAD> and </HEAD>) ..sorry but i'm guessing too.

    best regards
    bee

  7. dekmar
    Member
    Posted 6 years ago #

    Everything looks the same between <HEAD> and </HEAD> in both Inicio and Testing pages...

  8. bee dudler
    Member
    Posted 6 years ago #

    Hello again,
    last try for today and back to q and a (sorry again for that),
    in the template file in question is there
    <?php get_header();?> to find or is the header included os does it look any other, is there a another header file in the theme than standard headerfile and is anywhere the function call <?php wp_head();?>

    the next thing i know is to let me have the code for that template.

    best regards
    bee

  9. dekmar
    Member
    Posted 6 years ago #

    Hi, bee

    Now I REALLY messed up my page. I was looking at header.php, and was going to copy the code to send it to you... As far as I'm concerned, I hadn't done anything yet, but now my sidebar is misplaced, and, since I don't know what I did wrong, now I have two problems instead of one. I think I'll have to change the theme and start all over again. Just in case you want to look at my domain, it's

    Thanks for all the time you've given me. If I find how to fix this last problem, I'll let you have all the code you want if that will help. Right now I'm kind of frustrated. This is what I get for starting a big project when I should be studying WordPress for Dummies instead. Thanks again for all your help.

  10. dekmar
    Member
    Posted 6 years ago #

    Sorry, the URL didn't come out.. it's
    hend-latinoamerica.org
    Bye!

  11. bee dudler
    Member
    Posted 6 years ago #

    Hi dekmar,
    i'm very sorry that this has happened, i think the first thing would be to replace the themefiles with the originial ones you have bought and that are hopefully stored somewhere on your harddisk.

    Nonetheless i'm seeing something that should not be there anyways - both effects are inserted lightbox2 (a plugin if i guess right?) and thickbox which is integrated into ngg are called thats not good. If im right deactivate the lightbox2 plugin for now.

    And hey simply contact me via e-mail this one will be valid 3 days and then you will have a reply with my real email ok?
    dudler(at)winterslow.org

    best regards
    bee

  12. dekmar
    Member
    Posted 6 years ago #

    Thanks for the advice. Lightbox 2 has been deactivated. I'll replace my themefiles. Thanks a lot for giving me the chance to communicate by e-mail. I was concerned about how safe it was for me to put my page codes for all to see.

  13. bee dudler
    Member
    Posted 6 years ago #

    Hi,
    You're welcome. awaiting your email.

    best regards
    bee

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.