Posts

javascript - Vaadin application gets hanged -

i using vaadin development of web applications. using vaadin charts in application. when go chart window entire application getting hanged. following error given in browser console: highcharts error #16 highcharts defined in page this error happens second time highcharts or highstock loaded in same page, highcharts namespace defined. keep in mind highcharts.chart constructor , features of highcharts included in highstock, if running chart , stockchart in combination, need load highstock.js file. also when check tomcat log following notification: license warning vaadin charts commercial product. after 30 days of evaluation use, must either acquire license or stop using it. more information commercial vaadin add-on license available @ https://vaadin.com/license/cval-2.0 . you may obtain valid license subscribing vaadin pro account @ https://vaadin.com/pro or purchasing perpetual license @ https://vaadin.com/directory . a...

Windows phone 8.1 javascript+html local toast notification -

i display local toast notification on wp8.1 app build javascript , html. found how c# , xaml can't find anywhere how js , html. can display hello world, later on figure out myself. ok figured out. here message displays toast. , in manifest have enable toast notifications. function toast(message) { document.getelementbyid("klik").innerhtml = "bla"; var toasttextelements = toastxml.getelementsbytagname("text"); toasttextelements[0].appendchild(toastxml.createtextnode(message)); var toastnode = toastxml.selectsinglenode("/toast"); toastnode.setattribute("duration", "long"); var audio = toastxml.createelement("audio"); toastnode.appendchild(audio); var toast = new notifications.toastnotification(toastxml); var toastnotifier = notifications.toastnotificationmanager.createtoastnotifier(); toastnotifier.show(toast); }

.htaccess rewrite URL - and playground -

i have following url: http://example.com/reviews/view-course?courseid=933 which i'd show as: http://example.com/933/somethingdynamichere this i'm trying blank page: rewriterule ^([^/]*)$ /reviews/view-course?courseid=$1 [l] is there better way this? also, importantly, there playground can try changes , see results on fly can learn more? update i have html5 angular rewrite rules in file total follows: #angular html5 rewritecond %{request_filename} -s [or] rewritecond %{request_filename} -l [or] rewritecond %{request_filename} -d rewriterule ^.*$ - [nc,l] rewriterule ^(.*) /reviews/index.html [nc,l] your pattern not matching desired pretty uri. use rule: rewriterule ^(\d+)/[^/]+/?$ reviews/view-course?courseid=$1 [l,qsa]

POST not working after rewrite .htaccess -

my forms not working after adding rewrite .htaccess. found many topics similar problem neither have solution issue. grateful if take look. there is: rewriteengine on rewritebase / rewritecond %{the_request} ^[a-z]{3,}\s([^.]+)\.php [nc] rewriterule ^ %1 [r=301,l] rewritecond %{request_filename} !-d rewritecond %{request_filename}.php -f rewriterule ^(.*?)/?$ $1.php [nc,l] and here post code:) <?php function send_email ($to_email, $from_email, $from_name, $subject, $msg, $showinfo) { //split email array, if given if (is_array($to_email)) { $to_email_string = implode(', ', $to_email); } else { $to_email_string = $to_email; } // build content $message = '<html><body>'; $message .= '<table rules="all" style="border-color: #666;" cellpadding="10">'; $message .= "<tr style='background: #eee;'><td><strong>imie nazwisko: </strong> </td><td>" ....

Connecting to MySQL via a batch file -

i've configured batch file check web hosted db every 30 seconds or see if value in 1 field has been set 1. i'm happy how works , results come through fine. however 1 issue have once in while script unable connect sql server. when happens script errors out , batch file stops. the connection line using is: mysql --host=xxx.xxx.xxx --port=3306 --force --user=wmc --password=xxxxxxxxx --database=xxx < xxx.sql the sql file @ end contains commands want run. read documentation said --force should make script continue after error still errors out when can't connect sql server. there way can trap error? your main problem seems error handling. change script able detect failure , retry until successful. quick test a rough test did on own system check error level pseudo environmental variable: test.bat d:\xampp\mysql\bin\mysql --host=127.0.0.1 --port=3306 --force --user=root2 --password= --database=saasplex < test.sql echo exit code %errorlevel% ...

Clojure parse JSON objects and extract specific key -

given have json file contents: [ { "email": "benb@mit.edu" }, { "email": "aphacker@mit.edu" }, { "email": "eval@mit.edu" }, { "email": "prolog@mit.edu" }, { "email": "bugs@mit.edu" }, { "email": "morebugs@mit.edu" }, { "email": "test@mit.edu" }, { "email": "google@google.com" } ] how can parse file , value each email tag need perform operations using values. example: retrieve list of emails (benb@mit.edu, aphacker@mit.edu...) for each element in list pass value function. understand how pass function, , have come across get-in function im not sure how use in context. optionally, if possible wish file stored benb@mit.edu aphacker@mit.edu ... which more practical. know how write file , such im not sure how extract email data. slurp rea...

css3 - Mixins Gradient for IE8 -

i trying make less mixin graditent wotk in ie8, know can use gradient in ie8 this filter: progid:dximagetransform.microsoft.gradient( startcolorstr='#1e5799', endcolorstr='#7db9e8',gradienttype=0 ); /* ie6-9 */ this juwt example, need make custom mixin create ie8, css have background-image: linear-gradient(bottom, rgba(0,0,0, 0) 50%, rgba(255,255,255, 0.08) 0%); background-image: -o-linear-gradient(bottom, rgba(0,0,0, 0) 50%, rgba(255,255,255, 0.08) 0%); background-image: -moz-linear-gradient(bottom, rgba(0,0,0, 0) 50%, rgba(255,255,255, 0.08) 0%); background-image: -webkit-linear-gradient(bottom, rgba(0,0,0, 0) 50%, rgba(255,255,255, 0.08) 0%); background-image: -ms-linear-gradient(bottom, rgba(0,0,0, 0) 50%, rgba(255,255,255, 0.08) 0%); what need modified less mixins created .gradient (@startcolor: #eee, @endcolor: white) { background-color: @startcolor; background: -webkit-gradient(linear, left top, left bottom, from(@startcolor...