Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Page 37 of 81 FirstFirst ... 27353637383947 ... LastLast
Results 541 to 555 of 1210
Like Tree7Likes

Thread: YouTube-to-MP3 conversion - PHP class and script

  1. #541
    Senior Coder chump2877's Avatar
    Join Date
    Dec 2004
    Location
    the U.S. of freakin' A.
    Posts
    2,795
    Thanks
    19
    Thanked 156 Times in 147 Posts
    Looks good, Luckyplaya...that is the general idea...although I would employ PHP constants instead of regular variables in my language files.

    but when I choose English and then convert a video , it automatically jumps to the default language (German) .
    without looking closely, I would guess that you are not passing the GET variable 'lang' in the action of your conversion form...
    Regards, R.J.

    ---------------------------------------------------------

    Help spread the word! Like my YouTube-to-Mp3 Conversion Script on Facebook !! :)
    [Related videos and tutorials are also available at my YouTube channel and on Dailymotion]
    Get free updates about new software version releases, features, and bug fixes!

  2. #542
    New Coder
    Join Date
    Sep 2012
    Location
    Germany
    Posts
    40
    Thanks
    11
    Thanked 2 Times in 2 Posts
    Thank you. it was

    I have the solution

    Change
    PHP Code:
    <form action="<?php echo $_SERVER['PHP_SELF']; ?>" method="post" id="conversionForm" style="display:none; width:auto;">
    to

    PHP Code:
    <form action="<?php echo $_SERVER['PHP_SELF']; ?>?lang=<?php echo $lang ?> " method="post" id="conversionForm" style="display:none; width:auto;">
    and add in Language Files $lang = "de"; and $lang = "en";

    Works Perfekt
    Last edited by Luckyplaya; 11-04-2012 at 09:02 PM.

  3. #543
    New Coder
    Join Date
    Nov 2012
    Posts
    13
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Quote Originally Posted by chump2877 View Post
    Have you modified my core code and/or the ffmpeg commands in any way? Can you post the full ffmpeg log file for a failed conversion? Are your failed conversions even generating log files? Your phpinfo looks ok....this is probably a ffmpeg or file permissions problem...If you can convert ok locally, then it's more likely a permissions or file ownership (chown) problem...
    i tried some converting seems to work remote

    http://snuthuset.se/fixed/ffmpeg/

    still not yourscript doh

  4. #544
    New to the CF scene
    Join Date
    Jul 2012
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Hi R.J.
    I have some fund now! I'm thinking of buying your script soon. Can you check your PM box please. How on earth to contact you directly? Do you mind giving me your email address please.

  5. #545
    Senior Coder chump2877's Avatar
    Join Date
    Dec 2004
    Location
    the U.S. of freakin' A.
    Posts
    2,795
    Thanks
    19
    Thanked 156 Times in 147 Posts
    Quote Originally Posted by slaine View Post
    i tried some converting seems to work remote

    http://snuthuset.se/fixed/ffmpeg/

    still not yourscript doh
    I can't explain your server's (frequent?) inability to process remote access to my converter script. I honestly have never heard of an issue like yours up until now. It sounds like you have an unconventional server setup, in that you are trying to make your computer/server at home a node on the public internet. I can only suggest trying to install my software on a professionally configured and/or commercially hosted server, and see if you have the same results.
    Regards, R.J.

    ---------------------------------------------------------

    Help spread the word! Like my YouTube-to-Mp3 Conversion Script on Facebook !! :)
    [Related videos and tutorials are also available at my YouTube channel and on Dailymotion]
    Get free updates about new software version releases, features, and bug fixes!

  6. #546
    New Coder
    Join Date
    Sep 2012
    Location
    Germany
    Posts
    40
    Thanks
    11
    Thanked 2 Times in 2 Posts

  7. #547
    Senior Coder chump2877's Avatar
    Join Date
    Dec 2004
    Location
    the U.S. of freakin' A.
    Posts
    2,795
    Thanks
    19
    Thanked 156 Times in 147 Posts
    Quote Originally Posted by Luckyplaya View Post
    Solid.
    Regards, R.J.

    ---------------------------------------------------------

    Help spread the word! Like my YouTube-to-Mp3 Conversion Script on Facebook !! :)
    [Related videos and tutorials are also available at my YouTube channel and on Dailymotion]
    Get free updates about new software version releases, features, and bug fixes!

  8. #548
    New Coder
    Join Date
    Sep 2012
    Location
    Germany
    Posts
    40
    Thanks
    11
    Thanked 2 Times in 2 Posts
    Hi chump,
    can grab the javascript code to an external file?
    so that it is no longer visible in the source code!

    e.g. <script type="text/javascript" src="js/js.php"></script> ?

  9. #549
    Senior Coder chump2877's Avatar
    Join Date
    Dec 2004
    Location
    the U.S. of freakin' A.
    Posts
    2,795
    Thanks
    19
    Thanked 156 Times in 147 Posts
    Quote Originally Posted by Luckyplaya View Post
    Hi chump,
    can grab the javascript code to an external file?
    so that it is no longer visible in the source code!

    e.g. <script type="text/javascript" src="js/js.php"></script> ?
    Did you answer your own question here:

    Code:
    <script type="text/javascript" src="js/js.php"></script>
    What exactly are you trying to do?
    Regards, R.J.

    ---------------------------------------------------------

    Help spread the word! Like my YouTube-to-Mp3 Conversion Script on Facebook !! :)
    [Related videos and tutorials are also available at my YouTube channel and on Dailymotion]
    Get free updates about new software version releases, features, and bug fixes!

  10. #550
    New Coder
    Join Date
    Sep 2012
    Location
    Germany
    Posts
    40
    Thanks
    11
    Thanked 2 Times in 2 Posts
    Quote Originally Posted by chump2877 View Post
    Did you answer your own question here:

    Code:
    <script type="text/javascript" src="js/js.php"></script>
    What exactly are you trying to do?
    Code:
    <script type="text/javascript">
    		var conversionLogLength = 0;
    
    		function updateVideoDownloadProgress
    ...
    This code I would like to put it in a external file for hidden in index.php.
    But in this javascript php is also available, so I can not create a js file. If I create a php file and with <script type="text/javascript" src="js/js.php"> views, the converter will not be displayed.

  11. #551
    Senior Coder chump2877's Avatar
    Join Date
    Dec 2004
    Location
    the U.S. of freakin' A.
    Posts
    2,795
    Thanks
    19
    Thanked 156 Times in 147 Posts
    Quote Originally Posted by Luckyplaya View Post
    Code:
    <script type="text/javascript">
    		var conversionLogLength = 0;
    
    		function updateVideoDownloadProgress
    ...
    This code I would like to put it in a external file for hidden in index.php.
    But in this javascript php is also available, so I can not create a js file. If I create a php file and with <script type="text/javascript" src="js/js.php"> views, the converter will not be displayed.
    If your javascript has PHP in it (in other words, the PHP is dynamically generating the Javascript), then you have to put it in a PHP or INC file. (I wouldn't use the INC file type unless your application is already using it by convention.)

    In your situation it sounds like you will want to include the new PHP file (that contains your javascript) inside of index.php, i.e.:
    PHP Code:
    // somewhere in index.php
    include 'someFolder/myNewFile.php'
    Regards, R.J.

    ---------------------------------------------------------

    Help spread the word! Like my YouTube-to-Mp3 Conversion Script on Facebook !! :)
    [Related videos and tutorials are also available at my YouTube channel and on Dailymotion]
    Get free updates about new software version releases, features, and bug fixes!

  12. #552
    New to the CF scene
    Join Date
    Jul 2012
    Posts
    6
    Thanks
    2
    Thanked 0 Times in 0 Posts
    Randall, my site www.videotomp3online.org was working fine but since last few days I'm getting this video error.. can you tell me what is wrong here

    http://videotomp3online.org/error.jpg

  13. #553
    Senior Coder chump2877's Avatar
    Join Date
    Dec 2004
    Location
    the U.S. of freakin' A.
    Posts
    2,795
    Thanks
    19
    Thanked 156 Times in 147 Posts
    Quote Originally Posted by soofi View Post
    Randall, my site www.videotomp3online.org was working fine but since last few days I'm getting this video error.. can you tell me what is wrong here

    http://videotomp3online.org/error.jpg
    Hi,

    I tried to convert both a YouTube and Dailymotion video on your site, and I had no problems.

    Also, just to be sure, I tested my software on my own installation of Ubuntu Linux, and, again, I had no problems converting both YouTube and Dailymotion videos.

    What is the URL of the video that you are having problems converting?

    Edit: Is this the video url: http://www.youtube.com/watch?v=PAytXoFZN58 ? When I try to access that video in YouTube, it says the video is blocked in my country. That would explain your error. There are some videos on YouTube that are blocked in certain countries, and some videos that are blocked in all countries except for one. There is very little a person can do to circumvent this.

    To my knowledge, the best way around this issue is to use a proxy network like Tor -- and implement its command interface (in the PHP converter class file) to create a new, anonymous identity (IP address), which you can then use to access the blocked video (via cURL). I have done something like this before. The problems with this kind of solution are as follows:

    1. Proxy networks are notoriously slow. So the downloads of your blocked videos will often be significantly slower, because you are stuck with the download speed of whatever proxy server you are using -- as well as any other relevant proxy server hardware/software specs. Speeds are also slower because proxy servers often cause the data to travel a longer and more complex path to its destination (than would otherwise be the case without a proxy server).

    2. Tor, in particular, is an "anonymizing" service. It assigns you a random, anonymous id (ip address) from one of the nodes in its network. So the IP address you are given is not in any way guaranteed to come from a country that is not blocked by a given YouTube video. Subsequently, you have to keep generating new id's until you can find one that is from a country that is not blocked by the video. This process can further slow down the conversion of the video. (Note: Tor used to give you a way to exclude countries when generating new id's, but that feature is now deprecated, and no longer appears to function as expected.)

    3. In any proxy network, you are confined to only the locations of the nodes in the network. So if a video is blocked in Canada, the U.S., and Mexico, for example, and all of the nodes in your proxy network are located in those 3 countries, then none of your proxy servers will be able to access and download the video either.

    So, while a proxy network is the best solution to this problem (in my experience), it is not without its problems. But it can work most of the time for blocked videos if you don't mind the sometimes ridiculous amount of time it takes to download a video via proxy. And, chances are, a good percentage of your site users won't have patience for this.

    As an aside, I have also explored VPN solutions like hidemyass.com's VPN service. The problem there is that the service only allows you to create a finite number of simultaneous VPN connections. So, let's say you have 100 people that are simultaneously converting blocked videos on your site. If you can only initiate 10 (for example) simultaneous VPN connections at any one time (via a service like hidemyass), then the other 90 people must wait to convert their videos. This issue could be addressed with a queuing system, but again you potentially have a lot of people waiting in line to convert videos (when you scale up the popularity of and traffic to your site). With proxy networks, you don't have this problem -- because there is really no significant limit to the number of simultaneous proxy connections you can make.

    So, as you can see, it's a slippery slope to address the issue of blocked videos. While there are ways to address the issue, none of them are even close to providing an ideal or perfect solution. That said, if you need help addressing this issue, I can implement a proxy solution for you (as I have done it before). I would have to charge you my hourly rate to do this. Let me know if this interests you.


    Edit: Forgot to mention that another way to deal with this issue is to carefully choose the location of your server. If you are able to use a server that is located in a country where relatively few videos are blocked, then that could potentially go a long way to addressing the problem. But, personally, I have no data or reference for you regarding which are the best countries to choose for this purpose. You would have to conduct your own research on this topic (if possible), and make your decision based on that research.
    Last edited by chump2877; 11-24-2012 at 12:28 AM.
    Regards, R.J.

    ---------------------------------------------------------

    Help spread the word! Like my YouTube-to-Mp3 Conversion Script on Facebook !! :)
    [Related videos and tutorials are also available at my YouTube channel and on Dailymotion]
    Get free updates about new software version releases, features, and bug fixes!

  14. #554
    New Coder
    Join Date
    Nov 2012
    Posts
    13
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Quote Originally Posted by chump2877 View Post
    I honestly have never heard of an issue like yours up until now. It sounds like you have an unconventional server setup, .
    what is an unconventional server setup Now i have tried everything.

    I did a clean install totally formated the disk and installed only the things in your setup file. As your guide is for Ubuntu

    ---my system-----
    Ubuntu 12.04.1 LT

    PHP 5.3.10-1ubuntu3.4 with Suhosin-Patch (cli) (built: Sep 12 2012 19:00:43)
    Copyright (c) 1997-2012 The PHP Group
    Zend Engine v2.3.0, Copyright (c) 1998-2012 Zend Technologies

    Server version: Apache/2.2.22 (Ubuntu)

    ffmpeg version 0.8.4-4:0.8.4-0ubuntu0.12.04.1, Copyright (c) 2000-2012 the Libav developers.

    Everything works perfect on 192.x remote it get stucked on converting part.

    only error i can see in any log is
    ob_flush(): failed to flush buffer. No buffer to flush
    ob_end_flush(): failed to delete and flush buffer. No buffer to delete or flush

    i put a @ before ob_end_flush(): ob_flush(): that filled up the access and error.log in /var/log/apache2 to 10 mb in zero time. but thats not the problem.

    Give me a clue here mister chump. im not gonna use this for anything just want it to work.

  15. #555
    Senior Coder chump2877's Avatar
    Join Date
    Dec 2004
    Location
    the U.S. of freakin' A.
    Posts
    2,795
    Thanks
    19
    Thanked 156 Times in 147 Posts
    Quote Originally Posted by slaine View Post
    what is an unconventional server setup Now i have tried everything.

    I did a clean install totally formated the disk and installed only the things in your setup file. As your guide is for Ubuntu

    ---my system-----
    Ubuntu 12.04.1 LT

    PHP 5.3.10-1ubuntu3.4 with Suhosin-Patch (cli) (built: Sep 12 2012 19:00:43)
    Copyright (c) 1997-2012 The PHP Group
    Zend Engine v2.3.0, Copyright (c) 1998-2012 Zend Technologies

    Server version: Apache/2.2.22 (Ubuntu)

    ffmpeg version 0.8.4-4:0.8.4-0ubuntu0.12.04.1, Copyright (c) 2000-2012 the Libav developers.

    Everything works perfect on 192.x remote it get stucked on converting part.

    only error i can see in any log is
    ob_flush(): failed to flush buffer. No buffer to flush
    ob_end_flush(): failed to delete and flush buffer. No buffer to delete or flush

    i put a @ before ob_end_flush(): ob_flush(): that filled up the access and error.log in /var/log/apache2 to 10 mb in zero time. but thats not the problem.

    Give me a clue here mister chump. im not gonna use this for anything just want it to work.
    Again, to use my software in a production environment, my recommendation to you is the following:

    I can only suggest trying to install my software on a professionally configured and/or commercially hosted server, and see if you have the same results.
    There is sufficient documentation in the software files distribution and within this thread to successfully install the software. The only thing that isn't documented is the installation of the OS, which I assume people already know how to do, or it is already done for them.

    Note: When installing my software, I recommend that you 'apt-get install' to get the stable versions of each package. I advise against building each (or any) of the packages from the git source.

    Alternatively, you can download an Ubuntu VMware virtual machine here, and try to install inside a preconfigured VM. (for testing purposes?)

    I can also install the software for you at my hourly rate.

    Edit: You could also try installing in Ubuntu 11.10 instead of 12.04 to see if that has any effect. I suppose it is possible that 12.04 may require steps that are not required by 11.10. Just as different flavors of Linux require slightly different steps for the same installation. In the files distribution, I have included only one possible way to install my software. Installation steps may vary slightly in subsequent versions of Ubuntu, and will definitely vary across different Linux distributions. There are simply too many different Linux distributions (and versions within each distribution) for me to write installation guides for each and every one.
    Last edited by chump2877; 11-24-2012 at 01:51 AM.
    Regards, R.J.

    ---------------------------------------------------------

    Help spread the word! Like my YouTube-to-Mp3 Conversion Script on Facebook !! :)
    [Related videos and tutorials are also available at my YouTube channel and on Dailymotion]
    Get free updates about new software version releases, features, and bug fixes!


 
Page 37 of 81 FirstFirst ... 27353637383947 ... LastLast

LinkBacks (?)

  1. 08-24-2014, 04:09 AM
  2. 07-21-2014, 05:32 PM
  3. 07-12-2014, 05:59 PM
  4. 06-26-2014, 03:39 PM
  5. 05-31-2014, 09:13 PM
  6. 04-24-2014, 07:53 PM
  7. 04-19-2014, 10:22 AM
  8. 04-04-2014, 08:33 PM
  9. 04-04-2014, 01:58 AM
  10. 03-28-2014, 06:03 AM
  11. 03-20-2014, 06:11 PM
  12. 03-16-2014, 01:22 AM
  13. 03-08-2014, 04:56 PM
  14. 03-07-2014, 06:21 PM
  15. 03-01-2014, 12:48 PM
  16. 02-22-2014, 08:40 PM
  17. 02-22-2014, 12:02 AM
  18. 02-21-2014, 08:15 PM
  19. 02-21-2014, 12:00 AM
  20. 02-20-2014, 08:37 PM
  21. 02-20-2014, 06:53 PM
  22. 02-20-2014, 03:21 PM

Tags for this Thread

Posting Permissions

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