Posts

javascript - iframe tag not loading some URL's -

i passing url's dynamically http://ip:port/myproject/dashboard.do?method=loaddashboard . methods of same action class not loading loading in browser. here method name loaddp. http://ip:port/myproject/dashboard.do?method=loaddp . $("#containerid").html(' <ifrme id="iframeid" src= '+ url +' style="width: 100%; height: 100%;"></iframe>'); you have typo issues, should have iframe not ifrme missing quotes in src attribute: $("#containerid").html('<iframe id="iframeid" src="'+ url +'" style="width: 100%; height: 100%;"></iframe>'); //----------------------^^^^^^^^------------------^--here---^

php - PayPal IPN OPENSSL error:14077410:SSL routines:SSL23_GET_SERVER_HELLO:sslv3 alert handshake failure -

Image
my current php version 5.3. have updated 5.2 5.3 i have searched in google can't find solution regarding paypal ipn validation. i saw phpinfo() there enabled openssl still getting error message - warning: fsockopen() [function.fsockopen]: ssl operation failed code 1. openssl error messages: error:14077410:ssl routines:ssl23_get_server_hello:sslv3 alert handshake failure in /home/xxx/public_html/paypal_test/socketopen.php on line 5 warning: fsockopen() [function.fsockopen]: failed enable crypto in /home/xxx/public_html/paypal_test/socketopen.php on line 5 warning: fsockopen() [function.fsockopen]: unable connect ssl://www.sandbox.paypal.com:443 (unknown error) in /home/xxx/public_html/paypal_test/socketopen.php on line 5 () my code - <?php $fp = fsockopen ( 'ssl://www.sandbox.paypal.com', "443", $err_num, $err_str, 60); if (!$fp) { echo "$errstr ($errno)<br />\n"; } else { $out = "get / http/1.1\r\n"; $out ....

php - While downloading pdf file from another server forward slash is get replaced with underscore -

i trying download pdf file server. while downloading file replaces forward slash(/) underscore , file path become this( 127.0.0.1_file_upload_demoform1.pdf ), because of not able download file. here code. header('content-type: application/pdf'); $download_path = "127.0.0.1/file_upload/demoform1.pdf"; header('content-disposition: attachment; filename='.$download_path); readfile('downloads/'.$download_path); can suggest issue in it. i got answer. trying download pdf file server. not allow me directly download location. here solution. $content = file_get_contents('http://127.0.0.1/file_upload/demoform1.pdf'); header('content-type: application/pdf'); header('content-disposition: attachment; filename=demoform1.pdf'); echo $content;

iphone - Animating Values in UILable IOS Swift -

i want display values 1-10 repeatedly in uilable animation user should able see fluctuation of values how can achieve functionality ? you can use : var timer : nstimer = nstimer.scheduledtimerwithtimeinterval(1, target: self, selector: "change_label", userinfo: nil, repeats: true) func change_label() { count = count+1 label.text = string(format: "%d",count) }

Php and MySQL Querys using values in other tables -

so i'm trying fetch of user_id's users-events table event_id equal passed in variable (let's it's 2 now.) in database there 2 id's registered event_id 1 , 2. this code returns first of these values. feel need incorporate first query while loop dont know how go it. any appriciated! function showregisteredplayers($id){ $eventq = mysql_fetch_assoc(mysql_query("select user_id `users-events` event_id = '".$id."'")); $rosterq = mysql_query("select username `users` `user_id` = '".$eventq['user_id']."'"); while($player = mysql_fetch_assoc($rosterq)){ echo(" <tr> <td>".$player['username']."</td> </tr> "); } } use sub query kill first one. select username `users` `user_id` in ( select user_id `users-events` event_id = 5 ) rest fine, looping on second result set should do. unless have large nu...

sql - I want to fetch this data year wise -

select cidetail.itemname, sum(cidetail.taxamount+ cidetail.lineamount) [totalamount] cidetail (nolock) inner join ciheader on cidetail.invoiceno= ciheader.invoiceno ciheader.invoicedate between '2010-04-01' , '2014-04-01' group cidetail.itemname have derived table use ansi sql's extract year part out of date, , add amounts together. @ main level group by both itemname , year: select itemname, "year", sum(amount) totalamount ( cidetail.itemname, extract(year ciheader.invoicedate) "year", cidetail.taxamount + cidetail.lineamount amount cidetail (nolock) inner join ciheader on cidetail.invoiceno= ciheader.invoiceno ) dt group itemname, "year" no dbms tagged in question, if dbms doesn't support extract , try year(ciheader.invoicedate) example, or else.

netbeans - Read/Write bits for Huffman coding in java -

i have huffman coding project in first step obtain code of each character depends on huffman tree.i obtain code of each character example : = 01 , b= 101 , c = 111.these codes string , want save them in file .cmp extension in binary example have text such : abc , encoding is:01101111 how can write them file binary value in file .cmp extension , after read them , decode them? hopefully know bytes , integers consist of bits, need build little queue of bits single integer containing bits , integer tracks number of bits in first integer, accumulating bits using shift , or operators. once have accumulated byte, write out , shift out of queue. e.g. put n bits in buf |= val << bits; bits += n; , , pull bits out if have enough: while (bits >= 8) { write_out(buf & 0xff); buf >>= 8; bits -= 8; . make sure integer large enough handle largest value of n have. i.e., buf needs able hold maxn+7 bits, since while loop never leave more 7 bits in buffer.