Page 1 of 2 12 LastLast
Results 1 to 20 of 23

Thread: widgets

  1. #1
    Join Date
    Jun 2008
    Posts
    10

    Default widgets

    Has anyone any idea how to place recent or random links in a widget for the cms?

  2. #2

    Default

    Great idea and I too would like to see this as well.

    Dennis

  3. #3
    Join Date
    Dec 2006
    Posts
    13

    Default

    +1

  4. #4

    Default

    That would be great - anyone looking at this??

  5. #5
    Join Date
    Dec 2006
    Posts
    13

    Thumbs up

    Quote Originally Posted by ozidoggy View Post
    Has anyone any idea how to place recent or random links in a widget for the cms?
    Yeah but that is already there on the mainpage. widget could have hottest, featured or something else. anyone with skills who can jump in on this
    Best Regards / Chris

  6. #6
    Join Date
    Aug 2004
    Posts
    348

    Default

    I am also looking for this... It's so great to have VBaLinks working on VB4.x now...
    InterFX
    <br><br>

    my Clients using VBa:
    ChristianMom.com | BrassReview.com | TrumpetForum.com

  7. #7
    Join Date
    Jul 2006
    Location
    England
    Posts
    142

  8. #8
    Join Date
    Jul 2007
    Location
    London UK
    Posts
    30

    Post Random links home page in a widget

    Hi All,

    I put random links on the CMS homepage with this code which is a mod to the classifieds hack. Needs tidying up and it is work in progress and the thumshots do fail to turn up occasionally.

    PHP Code:
    $host 'localhost';
    $dbUser 'forum';
    $dbPass 'pass';
    $db 'your_forum';
    mysql_connect("$host""$dbUser""$dbPass") or die(mysql_error());
    mysql_select_db("$db") or die(mysql_error());

    ob_start();

    $result mysql_query("SELECT linkid,name,linkurl,catid,username FROM bf_adv_links ORDER BY rand() LIMIT 5" ) or die(mysql_error());

    while(
    $link mysql_fetch_array$result )) {

    print
    "<center>";
    print 
    "<a href=" $link['linkurl'] . " " "target=\"_blank\">" ."<img src=\"http://open.thumbshots.org/image.aspx?url=".$link['linkurl']." ""width=\"120\" height=\"90\" border=\"0\" />" "</a>";
    print 
    "<br />";
    print 
    $link['name'] . " listed by " $link['username'];
    print 
    "</center>";
    }

    $output .= ob_get_contents();
    ob_end_clean(); 
    but it works for me

    Cheers

    RoyMogg

  9. #9
    Join Date
    Mar 2010
    Posts
    16

    Default

    rss feed widget works as well

  10. #10
    Join Date
    Jul 2007
    Location
    London UK
    Posts
    30

    Post RSS feed

    can you get the thumnails to show up in the RSS feed?

  11. #11
    Join Date
    Mar 2010
    Posts
    16

    Default

    no thumbnails show, That would be nice though.

  12. #12
    Join Date
    Nov 2007
    Location
    Nashville, Tennessee
    Posts
    249

    Question

    Quote Originally Posted by roymogg View Post
    Hi All,

    I put random links on the CMS homepage with this code which is a mod to the classifieds hack. Needs tidying up and it is work in progress and the thumshots do fail to turn up occasionally.

    PHP Code:
    $host 'localhost';
    $dbUser 'forum';
    $dbPass 'pass';
    $db 'your_forum';
    mysql_connect("$host""$dbUser""$dbPass") or die(mysql_error());
    mysql_select_db("$db") or die(mysql_error());

    ob_start();

    $result mysql_query("SELECT linkid,name,linkurl,catid,username FROM bf_adv_links ORDER BY rand() LIMIT 5" ) or die(mysql_error());

    while(
    $link mysql_fetch_array$result )) {

    print
    "<center>";
    print 
    "<a href=" $link['linkurl'] . " " "target=\"_blank\">" ."<img src=\"http://open.thumbshots.org/image.aspx?url=".$link['linkurl']." ""width=\"120\" height=\"90\" border=\"0\" />" "</a>";
    print 
    "<br />";
    print 
    $link['name'] . " listed by " $link['username'];
    print 
    "</center>";
    }

    $output .= ob_get_contents();
    ob_end_clean(); 
    but it works for me

    Cheers

    RoyMogg
    I was actually kind of hopefull about this, but after visiting your site, not one single thumbnail showed up, even for TLD's.

    Has anyone found a solution yet, which includes the thumbshots?

  13. #13
    Join Date
    Jul 2007
    Location
    London UK
    Posts
    30

    Post Latest Links CMS Home

    Hi Nashchristian

    I did change this to select the latest links as they seem to show up more regularly. So include 'dateline' in the SQL select statement and ORDER BY dateline DESC limit 5

    REM

  14. #14
    Join Date
    Nov 2007
    Location
    Nashville, Tennessee
    Posts
    249

    Default

    Quote Originally Posted by roymogg View Post
    Hi Nashchristian

    I did change this to select the latest links as they seem to show up more regularly. So include 'dateline' in the SQL select statement and ORDER BY dateline DESC limit 5

    REM
    Hello Roymogg,

    I am really looking for a widget that will do the random links... otherwise it keeps the SAME links on the page and that gets boring.

    Thanks anyway. If you ever get this to work right, with thumbs, on random, let me know! I'll be the first to install it.

    THanks. Jeff

  15. #15

    Default

    I tried to install this widget but I get this error, any ideas?

    Table 'db*****_bcfr2009.bf_adv_links' doesn't exist

  16. #16
    Join Date
    Jul 2007
    Location
    London UK
    Posts
    30

    Post error is prefix on my forum

    Quote Originally Posted by Bergler View Post
    I tried to install this widget but I get this error, any ideas?
    If you look at the query ( bf_adv_links) it is from my forum) the prefix is the one I use for the links directory tables. So you should just edit the above code to replace the bf_ with the prefix you use (or if you don't) then just remove it.

    I did not notice when I copied accross the code.

    regards

    RoyMogg

  17. #17

    Default

    That worked, thank you! How do you change it to show new instead of random? Also is there away to have the link in the widget go to the redirection link or details page instead of the direct link, to the link?
    Last edited by Bergler; 06-02-2010 at 04:29 PM.

  18. #18
    Join Date
    Jul 2007
    Location
    London UK
    Posts
    30

    Post Links CMS

    This should work:

    PHP Code:
    $result mysql_query("SELECT dateline,linkid,name,linkurl,catid,username FROM adv_links ORDER BY dateline DESC LIMIT 5" ) or die(mysql_error()); 
    RoyMogg

  19. #19

    Default

    Thats worked good, thanks for that! Any suggestions on the other, "away to have the link in the widget go to the redirection link or details page instead of the direct link, to the link?"

    Thanks

  20. #20

    Default

    Quote Originally Posted by Bergler View Post
    how to have the link in the widget go to the redirection link or details page instead of the direct link?[/I]"

    Thanks
    Any one know if this is possible?

Page 1 of 2 12 LastLast

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Widgets on vbadvance page
    By wmlvb in forum Module & Modification Discussion & Requests
    Replies: 0
    Last Post: 09-13-2008, 12:00 PM
  2. How can I create module to show these widgets?
    By GentleOceanWind in forum "How Do I..." Questions
    Replies: 3
    Last Post: 04-30-2008, 01:06 PM
  3. weather and fox nfl widgets
    By StuntFactoryX in forum Add-On Modules (version 3.x & 2.x)
    Replies: 13
    Last Post: 12-12-2007, 03:16 AM

Posting Permissions

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