A Wordpress widget question

Discussion in 'WordPress' started by Pixelrage, Nov 13, 2007.

  1. #1
    This is going to be hard to explain - but I'll try :)

    I'm looking to create a Wordpress site where the bottom part of the main body area of all posts will have a designated spot where a script gets called up (which could be a bunch of links, a banner, a limited time offer, etc). The purpose is to have all pages on the entire Wordpress site have this designated area get updated at the same time:

    [​IMG]

    I was wondering if I could accomplish this by possibly moving the widgets code to that area? Would that work? If not, how could I accomplish something like this?
     
    Pixelrage, Nov 13, 2007 IP
  2. mizaks

    mizaks Well-Known Member

    Messages:
    2,066
    Likes Received:
    126
    Best Answers:
    0
    Trophy Points:
    135
    #2
    You could put the php call in your single.php (or whatever it may be called with your theme).
     
    mizaks, Nov 13, 2007 IP
  3. Pixelrage

    Pixelrage Peon

    Messages:
    5,083
    Likes Received:
    128
    Best Answers:
    0
    Trophy Points:
    0
    #3
    which PHP call is this? A custom one?
     
    Pixelrage, Nov 13, 2007 IP
  4. mizaks

    mizaks Well-Known Member

    Messages:
    2,066
    Likes Received:
    126
    Best Answers:
    0
    Trophy Points:
    135
    #4
    What specifically do you want there?
     
    mizaks, Nov 13, 2007 IP
  5. Pixelrage

    Pixelrage Peon

    Messages:
    5,083
    Likes Received:
    128
    Best Answers:
    0
    Trophy Points:
    0
    #5
    Most likely an affiliate ad, or some other kind of limited-time promotion
     
    Pixelrage, Nov 13, 2007 IP
  6. uglyboy

    uglyboy Peon

    Messages:
    1,963
    Likes Received:
    134
    Best Answers:
    0
    Trophy Points:
    0
    #6
    Put your affiliate ad in a txt file rename it affiliate_ad.php or whatever you want to call it, Place it in your current theme folder

    Then use <?php include(TEMPLATEPATH."/affiliate_ad.php");?> in your single.php or wherever else you want it to call it..

    Any time you change affiliate_ad.php it will change every instance of it

    I think that's what you were asking...
     
    uglyboy, Nov 13, 2007 IP
  7. Pixelrage

    Pixelrage Peon

    Messages:
    5,083
    Likes Received:
    128
    Best Answers:
    0
    Trophy Points:
    0
    #7
    ugly: thanks!! Yes, that sounds like exactly what I was talking about, I'll try this out.
     
    Pixelrage, Nov 14, 2007 IP
  8. xsabrina.chic

    xsabrina.chic Peon

    Messages:
    131
    Likes Received:
    4
    Best Answers:
    0
    Trophy Points:
    0
    #8
    in this case, i used to put the code of advertisement links in single.php
    i always put it wherever i want to see it :)
     
    xsabrina.chic, Nov 14, 2007 IP
  9. Pixelrage

    Pixelrage Peon

    Messages:
    5,083
    Likes Received:
    128
    Best Answers:
    0
    Trophy Points:
    0
    #9
    One more question, do think think this is a security risk in any way?
     
    Pixelrage, Nov 14, 2007 IP
  10. uglyboy

    uglyboy Peon

    Messages:
    1,963
    Likes Received:
    134
    Best Answers:
    0
    Trophy Points:
    0
    #10
    I cant see why it would be a security risk..
     
    uglyboy, Nov 14, 2007 IP
  11. sat123

    sat123 Banned

    Messages:
    1,600
    Likes Received:
    45
    Best Answers:
    0
    Trophy Points:
    0
    #11
    no security risks..mask the affiliate links...
     
    sat123, Nov 15, 2007 IP
    banibhusan likes this.