Results 1 to 3 of 3

Thread: create widget to view video stream from custom field

  1. #1
    Thread Starter
    lausha's Avatar
    Join Date
    Dec 2010
    Location
    United Kingdom
    Posts
    422
    Thanks
    62
    Thanked 11 Times in 11 Posts

    create widget to view video stream from custom field

    Using embedly plug-in, I want advertisers to be able to show a video - embed code entered in one of their custom fields - and for that field to be displayed in a widget in sidebar. It is just one field that I want to put in there.

    Presumably I go to theme-widgets.php and create a new widget. You gave me the code to insert a field outside the loop so I know WHAT to install, I just need to know what the code is to write the widget WHERE I can install it.

    Does anyone have the code to write a simple box with one line of text as a title for it and then to include the code as advised below?

    <?php
    global $wp_query;
    $postid = $wp_query->post->ID;
    echo get_post_meta($postid, 'customField', true);
    ?>

    I tried using a text widget to create it but all it showed was the code not the video.

    Please help.

  2. #2
    jomarkosabel's Avatar
    Join Date
    Mar 2009
    Location
    Philippines
    Posts
    40,982
    Thanks
    170
    Thanked 3,408 Times in 3,279 Posts
    You must be an AppThemes customer and logged in to view this response. Join today!
    Please help our moderating team work more efficiently by not sending us support questions via PM. You can read more about how AppThemes support works here. However, you can send a PM to follow up and remind me if I missed your support request/thread.

    Thank you and have a nice day.

  3. #3
    Veteran bluecafe's Avatar
    Join Date
    Apr 2010
    Location
    Berlin
    Posts
    1,563
    Thanks
    58
    Thanked 359 Times in 273 Posts
    You must be an AppThemes customer and logged in to view this response. Join today!

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Ad Sponsors Widget - Create Ads How?
    By jschodde in forum Help Using ClassiPress
    Replies: 1
    Last Post: July 1st, 2010, 11:24 AM
  2. Create custom field to be only seen by admin?
    By Wamba in forum ClassiPress General Discussion
    Replies: 1
    Last Post: April 30th, 2010, 05:13 PM
  3. ideas of how to create a featured category widget
    By groan in forum ClassiPress General Discussion
    Replies: 7
    Last Post: April 17th, 2010, 08:06 AM
  4. Create custom field to be only seen by admin?
    By Wamba in forum Help Using ClassiPress
    Replies: 0
    Last Post: December 31st, 1969, 07:00 PM