WordPress.org

Ready to get started?Download WordPress

Forums

IPNation plugin set up? (30 posts)

  1. mostdates
    Member
    Posted 9 years ago #

    http://frenchfragfactory.net/ozh/archives/2004/08/27/ip-to-nation-plugin/

    I have done sql into worpress database etc

    But where, in what page, and where in the page code, do I put this code?:
    <?
    echo "You are probably from ". wp_ozh_getCountryName() ."
    ";
    echo "If so, your country flag is <img alt=\"your flag\"
    src=\"http://frenchfragfactory.net/images/flag_"
    . wp_ozh_getCountryCode() . ".gif\">
    ";
    ?>

  2. Mark (podz)
    Support Maven
    Posted 9 years ago #

    I would imagine that you put that into index.php, and inside the menu div.

  3. mostdates
    Member
    Posted 9 years ago #

    Any others got an iea please?

  4. Mark (podz)
    Support Maven
    Posted 9 years ago #

    So what I said did not work then ??

  5. mostdates
    Member
    Posted 9 years ago #

    Sorry for being a bit slow on this -but I tried with the 2 index.php - one on the main root and one in the wp-admin directory.
    No luck.
    Please where is the 'menu div.' and in which index.php?
    thanks.
    Brian

  6. You want index.php in the main root and place the code somewhere below <div id="menu">. Below <div id="menu">, you will notice things like your archives, calendar, links, etc. This is the order in which they will display on your site. So, place the ip-to-nation code under <div id="menu"> in the order you want.

  7. mostdates
    Member
    Posted 9 years ago #

    Oh and I am running WP version 1.5.

  8. mostdates
    Member
    Posted 9 years ago #

    My index.php in the main root edits as :
    <?php
    /* Don't remove this line. */
    require('./wp-blog-header.php');
    ?>

  9. Mark (podz)
    Support Maven
    Posted 9 years ago #

    Look in the theme directory for whichever you are using, and stick it in sidebar.php

  10. mostdates
    Member
    Posted 9 years ago #

    I went to /themes/classic/sidebar.php
    I put it under <div id="menu"> as seen below
    I don't seem to be getting posts working.
    Brian

    <!-- begin sidebar -->
    <div id="menu">
    <?
    echo "You are probably from ". wp_ozh_getCountryName() ."
    ";
    echo "If so, your country flag is <img alt=\"your flag\"
    src=\"http://frenchfragfactory.net/images/flag_"
    . wp_ozh_getCountryCode() . ".gif\">
    ";
    ?>

      <?php wp_list_pages(); ?>
      <?php get_links_list(); ?>
      <li id="categories"><?php _e('Categories:'); ?>

        <?php wp_list_cats(); ?>
      etc etc etc

  11. Mark (podz)
    Support Maven
    Posted 9 years ago #

    You are definitely using that sidebar.php file ?

    To test that write "This is a test" just under the menu div, save, and then do a refresh in the browser.

    `<!-- begin sidebar -->
    <div id="menu">
    This is a test

    (and leave the other stuff)

  12. Mark (podz)
    Support Maven
    Posted 9 years ago #

    mostdates - if this does not work, can we have a url to your site please ? It will help us to help you.

  13. mostdates
    Member
    Posted 9 years ago #

    http://www.freepgs.com/mostdates/wordpress15

    I have put it in both sidebars - classic and default, no result.
    Brian

  14. Ozh
    Member
    Posted 9 years ago #

    1st : please download the flags pack and upload it to your server, instead of using flags from my server. This is bandwidth stealing, and the day I'll be bandwidth monitor, I'll start caring about all the people linking my flags instead of downloading the pack :)

    2nd : you *sure* you activated the plugin ? .......

    3rd : try replacing <? with <?php

  15. Mark (podz)
    Support Maven
    Posted 9 years ago #

    Have you definitely activated the plugin ?

  16. mostdates
    Member
    Posted 9 years ago #

    Yes IP2Nation set at 'deactivate' now

  17. Mark (podz)
    Support Maven
    Posted 9 years ago #

    Please paste your sidebar.php here:
    http://paste.uni.cc/

  18. mostdates
    Member
    Posted 9 years ago #

    Yes I already downloaded the flags pack and will point to it today.

  19. Mark (podz)
    Support Maven
    Posted 9 years ago #

  20. mostdates
    Member
    Posted 9 years ago #

    OK I uploaded Potz' code - but no luck, as you see
    Maybe I should email my password
    Potz:
    <!-- begin sidebar -->
    <div id="menu">
    This is a test
    <?php echo "You are probably from ". wp_ozh_getCountryName() ." "; echo
    "If
    so, your country flag is <img alt=\"your flag\"
    src=\"http://frenchfragfactory.net/images/flag_" . wp_ozh_getCountryCode() .

    .gif"> "; ?>

    </div>
    <!-- end sidebar -->

  21. Mark (podz)
    Support Maven
    Posted 9 years ago #

    Do you use #IRC ? If so, freenode.net and #wordpress

    If you don't, you can certainly email me so I can login and try to find out what's going wrong... tamba2 at gmail dot com

  22. mostdates
    Member
    Posted 9 years ago #

    NO IRC
    email on the way tamba2.
    Thanks
    mostdates

  23. Mark (podz)
    Support Maven
    Posted 9 years ago #

    Fixed :)

    I'll email you.
    -------Email bounced, mailbox somewhere is full.

  24. mostdates
    Member
    Posted 9 years ago #

    All is AOK!
    Potz and all for President!
    Thank you very much.
    mostdates

  25. Ozh
    Member
    Posted 9 years ago #

    Except that you still miss something, since according to your site I'm from New Zealand, which is about 20.000 miles wrong :-)

  26. mostdates
    Member
    Posted 9 years ago #

    Ouch!
    20.000 miles wrong
    Disorientation is making our whales beach themselves also?
    Oh well I cleaned out my email so messages don't bounce from the secondary email address at softhome.net

    Also there is a problem with wp-plugin-mgr.php:
    One-Click install gives:

    Warning: exec() has been disabled for security reasons in /drive2/fpgshttpd/mostdates/wordpress15/wp-plugin-mgr.php on line 459

  27. Mark (podz)
    Support Maven
    Posted 9 years ago #

    The exec() error - contact your host.

  28. mostdates
    Member
    Posted 9 years ago #

    http://www.freepgs.com/mostdates/wordpress15/
    makes all punters into kiwis.

    Could be worse...

    I am contacting http://system.freepgs.com/forum
    and Support at freepgs.com about the other exec() error.

  29. mostdates
    Member
    Posted 9 years ago #

    The exec() function has been disabled for security reasons and will not be enabled. Sorry.
    Thus spake freepgs.com

  30. sdollen
    Member
    Posted 9 years ago #

    This post was last posted in almost 3 months ago... I was looking for a solution to my IP2nation problem... I noticed that mostdates still is still linking to the flags on the author's page. Duh!

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.