SitePoint Sponsor

User Tag List

Results 1 to 1 of 1

Threaded View

  1. #1
    SitePoint Member
    Join Date
    Jul 2013
    Posts
    1
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Can't display TWO ezinearticles authors widgets

    Hello

    I write for eZineArticles under my own & Pen name. They provide widgets useful to display your articles on your sites.

    In Wordpress, I wanted to include BOTH widgets, one below the other. But the problem is, ONLY ONE appears.

    The code looks like this (I have changed my author-id. I put same code with different author-ids, one below the other). I even tried putting in two separate text boxes too.

    Code:
    <!-- Place this tag where you want the widget to render -->
    <div id="ezinearticles-widget"></div>
    
    <!-- Place this script before the closing </body> tag -->
    <script type="text/javascript" src="http://ezinearticles.com/js/widget.v2.js"></script>
    <script type="text/javascript">
    EzineArticlesWidget({
        "id": "ezinearticles-widget",
        "author": 111111,
        "bio": 0,
        "category": null,
        "articles": 10,
        "width": 250,
        "height": 300,
        "theme": {
            "shell": {
                "background": "#2F83C4",
                "text": "#ffffff"
            },
            "article": {
                "background": "#ffffff",
                "text": "#333333"
            },
            "links": "#215F8F"
        }
    });
    </script>
    Someone suggested:

    You should create 2 div elements with different ids,

    Code:
    <div id="ezinearticles-widget-1"></div>
    <div id="ezinearticles-widget-2"></div>
    and refer to them in your <script>

    I tried implementing it but could not. I tried all variations but the result is, I end up getting plain english text, nothing formatted as widget.

    Probably, it all ends up referencing the <scripts>, for the mess.

    CAN ANYONE HELP ME OUT?

    I would really appreciate instead of hinting, put the entire code. Thanks
    Last edited by coolgreen; Jul 28, 2013 at 12:21. Reason: Typo


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •