Jump to content


These Forums Are Now Read-Only


For TubePress support, please post a question here or open a support ticket and we will be glad to assist.


Photo

How do I include a HTML description with each video?


  • Please log in to reply
4 replies to this topic

#1 Andrey Deshkin

Andrey Deshkin

    Advanced Member

  • Members
  • PipPipPip
  • 32 posts

Posted 26 January 2012 - 01:44 AM

Eric,

I read the instructions, re-read them and followed the step by step very careful and I'm spinning my wheels.

1) How do you use "shortcodes" in a standalone PHP?
2) Where do i place it? My current setup is:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"

        "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<?php 

$tubepress_base_url = 'C:\xampp\htdocs';

include 'C:\xampp\htdocs\sys\classes\TubePressPro.class.php';

?>



<html>

	<head>

	<title>Slavic Christian Center</title>

	<meta http-equiv="Content-Type" content="text/html; charset=utf-8">



	<?php print TubePressPro::getHtmlForHead(true); ?>



	</head>

<body>

	<div id="showresults">

<?php print TubePressPro::getHtmlForShortcode(" output='ajaxSearchInput' searchResultsDomId='#showresults' searchProvider='youtube'"); ?>

<?php print TubePressPro::getHtmlForShortcode(" randomize_thumbnails='false' embeddedWidth='650' embeddedHeight='395' description='true' views='false' orderBy='published' resultsPerPage='20' mode='playlist' playlistValue='49F0EA68F19E7AF8' loop='true' playerLocation='normal' ajaxPagination='true' showRelated='false'"); ?>

<?php print TubePressPro::getHtmlForShortcode(" tubepress <span class="search_hit">theme</span>="slaviccenter_theme"); ?>

	</div>

</body>

</html>


and then i get a error
Parse error: syntax error, unexpected T_STRING in C:\xampp\htdocs\2012\01.php on line 38
As soon as i remove line 38 which is (theme="slaviccenter_theme"); ?>) tubepress works as expected.

Any suggestions?

#2 eric

eric

    Lead Developer

  • TubePress Staff
  • 2787 posts

Posted 28 January 2012 - 11:53 PM

Hi,

I'm sorry that it took me so long to respond! I think what you're experiencing is a simple PHP syntax error. Change line 38 from

<?php print TubePressPro::getHtmlForShortcode(" tubepress <span class="search_hit">theme="</span>slaviccenter_theme"); ?>
to

<?php print TubePressPro::getHtmlForShortcode("theme='slaviccenter_theme'"); ?>
That will at least get rid of the syntax error, but you'll probably want to add to the shortcode to configure it to your needs.

Give that a try and we can work from there. Sound good? Thanks!

#3 Andrey Deshkin

Andrey Deshkin

    Advanced Member

  • Members
  • PipPipPip
  • 32 posts

Posted 31 January 2012 - 09:54 PM

thanks Eric,

that works great. but now I'm having an issue displaying the description on the bottom of the main player.

When i add the

<div>
        <?php echo ${org_tubepress_api_const_template_Variable::VIDEO}->getDescription(); ?>
    </div>


to normal.tpl.php located in tubepress-content/themes/slaviccenter_theme/sys/ui/themes/default/normal.tpl.php

I dont see any change. and where i want to place tubepress code looks like this

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"

            "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

    <?php

    $tubepress_base_url = 'C:\xampp\htdocs';

    include 'C:\xampp\htdocs\sys\classes\TubePressPro.class.php';

    ?>



    <html>

       <head>

       <title>Slavic Christian Center</title>

       <meta http-equiv="Content-Type" content="text/html; charset=utf-8">



       <?php print TubePressPro::getHtmlForHead(true); ?>



       </head>
    <body>   <div>                  <?php print TubePressPro::getHtmlForShortcode(" theme='slaviccenter_theme' randomize_thumbnails='false' embeddedWidth='650'

    embeddedHeight='395' description='true' views='false' orderBy='published' resultsPerPage='20' mode='playlist' playlistValue='49F0EA68F19E7AF8' loop='true'

    playerLocation='normal' ajaxPagination='true' showRelated='false'"); ?>   





    </div></body></html>



I dont get any description below the main player. with the description='true" I just get the description under the thumbnails but nothing under the main player.

By the way, i added a link to one of my youtube video's and under the thumbnails the link appeared as straight text and cannot be clicked, but when you watch same video on youtube and look under the description the link is clickable and im guessing that is the same case for when we get the video description under the main player working, is it going to do the same thing? the links arent clickable in tubepress?

Any suggestions?

#4 eric

eric

    Lead Developer

  • TubePress Staff
  • 2787 posts

Posted 01 February 2012 - 11:50 PM

Could you post a link to your site so I could take a first-hand look? Or if that's not possible, then please post your debug output. TubePress's debug output is super chatty when it comes to handling custom themes. My guess is that if the description isn't showing up then it's a permissions problem or misplaced custom template. Either way, should be easy to fix!

As for the thumbnails not playing when you click on them, that's usually a JavaScript error that will need to be corrected.. Again if you could share a link to your site it should be easy for me to diagnose, otherwise here are some troubleshooting docs that might be useful to you.

We'll get you squared away!

#5 Andrey Deshkin

Andrey Deshkin

    Advanced Member

  • Members
  • PipPipPip
  • 32 posts

Posted 08 February 2012 - 05:49 PM

Thanks Eric,

I will post a link to my website as soon as my isp comes out and connects the internet to my new home.