Posts

Showing posts from June, 2014

dart - How to read file from an imported library -

i have 2 packages: webserver , utils provides assets webserver. the webserver needs access static files inside utils. have setup: utils/ lib/ static.html how can access static.html file in 1 of dart scripts in webserver ? edit : tried far, use mirrors path of library, , read there. problem approach is, if utils included package: , url returned currentmirrorsystem().findlibrary(#utils).uri package uri, can't transformed actual file entity. use resource class, new class in dart sdk 1.12. usage example: var resource = new resource('package:myapp/myfile.txt'); var contents = await resource.loadasstring(); print(contents); this works on vm, of 1.12. however, doesn't directly address need actual file entity, package: uri. given resource class today, you'd have route bytes loadasstring() http server's response object.

linq - How return multi table(of T) by vb.net function -

i use linq model sql database, , need make function insert data every table. dim mydata object = myarray (1) dim indx integer=1 call insertdata (indx) ... sub insertdata (indx integer) myfunction(indx) '_context.table1s .insertonsubmit(myarray(indx)) end _context.submitchanges() end sub function myfunction(i integer) select case case 1 :return _context.table1s case 2:return _context.table2s case 3: return _context.table3s ... end select end function function myarray (i integer) select case case 1 : dim y table (of table1) ' ... y set return y case 2 dim y2 table (of table2) .... return y2 ... end select end function how can this?

inline - Reg:chrome extensions-calling chrome.webstore.install in javascript dragend function -

chrome.webstore.install working onclick function add app chrome extensions,but when tried other events throwing exception uncaught chrome web store installations can initated user gesture.please confirm , update asap work onclick.if work other events please update because need in dragend function add app chrome extensions.when gone through search in many places used in onclick function. yes, works onclick. dragend not considered user gesture.

c - Dereferencing iterators performance -

i have 3 functions come down code below, runs 800x800 times: each while loop below runs 800 times before iter1 == lim , duration measured ran 800x800x800 (512 millions) times. iter1 , iter2 , lim double pointers. point large enough vector of double 's. sum double local variable. s1 , s2 local unsigned int 's, both equal 800. first runs in 2.257 seconds: while ( iter1 < lim ) { sum += *iter1 * *iter2; ++iter1; iter2 += s2; } second runs in 7.364 seconds: while ( iter1 < lim ) { sum += *iter1 * *iter2; iter1 += s1; iter2 += s2; } third runs in 1.355 seconds: while ( iter1 < lim ) { sum += *iter1 * *iter2; ++iter1; ++iter2; } if remove sum += *iter1 * *iter2; instruction each of them, run in around 1.07 seconds. if remove second multiplication , change instruction sum += *iter1; , first , third run in 1.33 seconds, while second runs in 1.46 seconds. if remove other iterator, this: sum += *iter2; , ...

web services - Get calendar appointment from EWS exchange with jquery only -

i want calendar appointment ews exchange jquery, think should use soap envelope in ajax jquery request. tried lot of syntax , nothing works because can't find correct xml request. tried soap ui, soap ui doesn't accept kind of web service https://office.company.com/ews/exchange.asmx or https://office.company.com/ews/service.wsdl the soap request format shown here: https://msdn.microsoft.com/en-us/library/office/dn495614(v=exchg.150).aspx

Initializing an array within a c++ constructor -

this question has answer here: how can use member initialization list initialize array? 2 answers i want have array class member, way know how initialize array in constructor adding each element individually (array[x] = char) class myclass { public: myclass(); ~myclass(); void printletters(); // prints each character in array private: int alpha[3]; // allocate memory array }; myclass::myclass() { // initialize array alpha[0] = 1; alpha[1] = 2; alpha[2] = 3; printletters(); } myclass::~myclass() { } void myclass::printletters() { (int x = 0; x < 3; x += 1) { cout << alpha[x] << endl; } } int main() { myclass abc; return 0; } is there way it? if try this: myclass::myclass() { // initialize array alpha[3] = {1, 2, 3}; printletters(); } i following error: expr...

javascript - Flexslider infinite loop and create("clones") > 1 -

here example of infinite loop flexslider: http://jsfiddle.net/u2ysh/161/ problem clones first image @ end. if click through slides you'll have reach end before show starts beginning. is there solution fire image clones couple of slides before avoid ugly white gap? or else achieve this? thx alot. $('.flexslider.banners').flexslider({ animation: "slide", animationloop: true, controlnav: false, slideshow: false, smoothheight: true, variableimagewidth: true,

php - Woocommerce Payment Gateway Based Checkout Fields -

i looking remove checkout fields based on payment gateway selected. i have added following code in function.php, not working. problem facing is, going in if condition, unset not working inside if condition. when tried echo inside if condition, showing in browser. add_filter( 'woocommerce_checkout_fields' , 'custom_override_checkout_fields' ); function custom_override_checkout_fields( $fields ) { if($_post['payment_method'] === "wcwcpdpg"){ echo "this"; unset($fields['billing']['billing_first_name']); unset($fields['billing']['billing_last_name']); unset($fields['billing']['billing_company']); unset($fields['billing']['billing_address_1']); unset($fields['billing']['billing_address_2']); unset($fields['billing']['billing_city']); unset($fields['billing']['billing_postc...

Histrogram in MDX with icCube -

how possible dynamic histrogram using mdx ? for example, our schema based on web visits, we've number sessions , number of click-outs. have number of session 1 click-out taking account might depend on other dimensions (country, hour, entry-page...). to solve going work 2 different concepts. first create new hierarchy , afterwards use mdx+. first we've create new dimension, [histrogram]. new dimension contain defintion of buckets 2 member properties : start-bucket , end-bucket. pseudo table looks like name start-bucket end-bucket 0-1 0 1 1-2 1 2 2-3 2 3 ... 10++ 10 2147483647 this hierarchy not linked facts , defines each member 2 properties defining bucket. let's put use in mdx. let's assume we've dimension, [sessions], , measure, [click-outs]. first we're going use oo features of iccube , create vector each session calculates number of [click-outs] -> vector ( [sessions], [cli...

How much database column length should i allocate for Google Maps place_id? -

i'm using google maps api , need store relations of own geo objects administrative areas using reverse geocoding in sql database. want use place_id uniquely identify area, docs don't give me clue how long may be. should use varchar(255) usual?

android illegal exception when dialog is showing -

i have crash log: java.lang.illegalargumentexception: view=com.android.internal.policy.impl.phonewindow$decorview{21f9ba68 v.e..... r.....id 0,0-1136,402} not attached window manager @ android.view.windowmanagerglobal.findviewlocked(windowmanagerglobal.java:402) @ android.view.windowmanagerglobal.removeview(windowmanagerglobal.java:328) @ android.view.windowmanagerimpl.removeviewimmediate(windowmanagerimpl.java:84) @ android.app.dialog.dismissdialog(dialog.java:433) @ android.app.dialog.dismiss(dialog.java:416) @ ys.a(confirmationdialog.java:82) @ ys.a(confirmationdialog.java:76) @ **com.smarttech.kapp.snapshotactivity.onoptionsitemselected(snapshotactivity.java:147)** @ android.app.activity.onmenuitemselected(activity.java:3036) @ android.support.v4.app.fragmentactivity.onmenuitemselected(fragmentactivity.java:373) @ com.android.internal.policy.impl.phonewindow.onmenuitemselected(phonewindow.java:1222) @ com.android.internal.view.menu.menubuilder.dispatchmenuitemselected(menubui...

php - Web Master Tools API Search Analytics Ver 3 -

i using google web master tools api v3 search analytics. using service account retrieve analytics. received following message. (403) user not have sufficient permission site ' http://www.1800medexpress.com/ '. see also: https://support.google.com/webmasters/answer/2451999 .' i added service account email address web master tools owner. still received same error. i used php api library. i haven't tried should work. in webmaster tools website in question. upper right hand corner there cogwheel click on go users , property owners click add new user button add service account email address. then try , run code. service accounts need granted access data other user default don't have access data. update: by checking documentation can see in fact possible use service account webmaster tools api needs set properly. may issue code or how have set up. clod should simlar this. service account google calendar a service account used in ...

php - Curl is not working on my live server -

i have using sms gateway api on server $live_url = "http://sms6.routesms.com:8000/bulksms/bulksms?username=xxx&password=xxx&type=1&dlr=0&destination=xxx&source=routesms&message=curlsecond"; $ch = curl_init(); curl_setopt($ch, curlopt_url, $live_url); curl_setopt($ch, curlopt_header, 0); curl_exec($ch); curl_close($ch); for this, if var_dump(curl_exec($ch)); , showing false if var_dump(curl_getinfo($ch)); , showing like array(26) { ["url"]=> string(153) "http://sms6.routesms.com:8000/bulksms/bulksms?username=xxx&password=xxx&type=1&dlr=0&destination=xxx&source=routesms&message=curlsecond" ["content_type"]=> null ["http_code"]=> int(0) ["header_size"]=> int(0) ["request_size"]=> int(0) ["filetime"]=> int(-1) ["ssl_verify_result"]=> int(0) ["redirect_count"]=> int(0) ["total_time"]=> float(...

c++ - locale Facet Constructor Ignored -

the locale facet constructor : constructs copy of other except facet of type facet (typically deduced type of argument) installed argument facet. if facet null, constructed locale full copy of other. locale constructed in manner has no name. i try construct using facet here , when put break-point in do_decimal_point , do_thousands_sep never called :( i can see facet being passed in, it's passed standard library implementation files can't see if ever done it. i've tried on visual studio 2013, clang 3.6.0, , gcc 4.9.2. all of them behave though had never passed in facet using other locale 's behavior. i can't find bugs against constructor in of compilers. think i'm doing right way. why can't locale construct using facet ? edit: at the request of 0x499602d2 have added example. it's interesting note facet does seem picked not used get_money . i'm linking live example of this (which uses locale("c") instead o...

Scala - Sum of positive Ints being negative - Overflow Exception? -

i had hard time finding bug being caused due large sum of positive ints being greater integer.max_value. my question is: why: val a:int = integer.max_value + 2 -> = -2147483648 returns negative number, opposed giving overflow exception doing: val b:int =999999999999999999 -> error: integer number large why not throwing exception standard? adding checks costs performance , code rely on how overflows work. if don't want overflow java 8 has solution: math.addexact(left, right); https://docs.oracle.com/javase/8/docs/api/java/lang/math.html#addexact-int-int-

How to skip a job in Jenkins if another job is in the failed state -

i have 2 jenkins jobs same project: a job continuous build run whenever there new commits a job nightly build , triggered time, same thing additional steps take long time (e.g. slow tests, sandcastle documentation generation, etcetera) when continuous build failed @ end of day, don't want nightly build run; know fail. how configure in jenkins? i have considered using conditional build steps : way skip build steps , build still run. don't want new passed or failed build appear in history; want skip nightly build altogether. have tried build result trigger plugin - https://wiki.jenkins-ci.org/display/jenkins/buildresulttrigger+plugin use similar purpose

docker - Load balancing is not working properly -

we want test kubernetes load balancing. create 2 node cluster thats runs 6 replicas of our container. container has running apache2 server , php , print pod name if browse hostname.php cluster details: 172.16.2.92 -- master , minion 172.16.2.91 -- minion rc , service details: frontend-controller.json: { "kind":"replicationcontroller", "apiversion":"v1beta3", "metadata":{ "name":"frontend", "labels":{ "name":"frontend" } }, "spec":{ "replicas":6, "selector":{ "name":"frontend" }, "template":{ "metadata":{ "labels":{ "name":"frontend" } }, "spec":{ "containers":[ { "name...

javascript - why the for loop is not playing audio files again and again? -

for full code please visit this question for problem coming in code is: var times_played =1, l=pattern_config[actions().whichpattern].wp_slotscounter; var p = setinterval(function(){ var x = pattern[actions().whichpattern][times_played]; for(var i=0; i<x.length;i++){ var tobeplayed = x[i]; if(tobeplayed !== undefined){ var url= "all drums sounds/"+tobeplayed+".wav"; audio.src = url; audio.play(); //console.log(audio); }else{}; } times_played++; console.log(l); if(times_played === l+1){clearinterval(p);}; }, pattern_config[actions().whichpattern].delay); note: part of function named _play() and problem that: suppose have array like: [['drum_snare_01'],['drum_snare_01'],['drum_snare_01']] . should expect function play audio file named 'drum_snare_01' 3 times. not happening playing once. debugging know file p...

How do I fix my "java.util.InputMismatchException" error? -

all need loop again user can continuously use program if to. let me know if there reference can read to, me understand more problem. in advance. import java.util.scanner; public class module3assignment1 { // public variables public static string letterchosen; public static int loop = 0; public static double radius, area; public static scanner scanner = new scanner(system.in); public static void main(string[] args) { // tells user program system.out.println("welcome round object calculator"); system.out.println("this program calculate area of circle of colume of sphere."); system.out.println("the calculations based on user input radius."); system.out.println(""); // loops while user wants calculate information while (loop == 0){ input(); system.out.print(answer()); system.out.println("do want cal...

c# - Shortest way to turn a regular IEnumerable collection into a DataView -

i'm not used working datatables , built in functionalities, rather use debug visual display feature. i'm new wpf, , although experienced linq/ienumerable extension methods, learned datagrid, in order support editing, object assigned itemssource property must implement given interface (which not sure is, time being let's either ieditablecollectionview or ibindinglist). since used collection manipulations via ienumerable extension methods, here how manipulate datatable, filter , project columns want: grdsettings.itemssource = _settings .asenumerable() .where(row => row["table"].tostring().equals(e.addeditems[0].tostring())) .select(s => new { setting = s["field"], description = s["description"], charvalue = s["charvalue"], numminvalue...

android - make minimum height based on imageview -

<?xml version="1.0" encoding="utf-8"?> <linearlayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" android:minheight="400dp" android:background="@android:color/black" android:layout_height="wrap_content" android:orientation="vertical"> <imageview android:id="@+id/invitation_imageview" android:layout_width="match_parent" android:layout_height="wrap_content" android:adjustviewbounds="true" android:layout_margin="1dp" android:scaletype="centercrop" /> <imageview android:id="@+id/invitation_avatar_view_1" android:layout_width="28dp" android:layout_height="28dp" android:scaletype="centercrop" android:layout_margin=...

cookies - Tracking non logged-in users in Yii/PHP -

i trying track actions of non-logged in users on site. aim store activity can add profile when create account. i using behaviour below assign new users cookie , use cookie basis of "temp user" row in users table. way user can straight away start interacting api. this seems work fine. however, seeing loads more "temp user" rows being created in db have visitors site - 2500 compared around 500 visits yesterday (according google analytics). is there wrong behaviour below, or doing else wrong? there better way? <?php class applicationbehavior extends cbehavior { private $_owner; public function events() { return array( 'onbeginrequest' => 'setcookies' ); } public function setcookies() { $owner = $this->getowner(); if ($owner->user->getisguest() && !isset(yii::app()->request->cookies['dc_tempusername'])): $tempuserna...

c# - Adding Exchange web services api to MonoDevelop -

i using monodevelop in ubuntu. how add reference microsoft exchange web services api in monodevelop.i tried following ( https://msdn.microsoft.com/en-us/library/office/dn567668(v=exchg.150).aspx#setup ) i have downloaded api source github ( https://github.com/officedev/ews-managed-api/blob/master/readme.md ) not find dll file in it.so possible work library in ubuntu ? if , how can add in mono ?

html - Drop Down Menu is not working in lesser version than IE9 -

Image
the css , html code working fine in internet explorer9 .the drop down working fine in ie9 , higher.but changing alignment in lower version of ie , drop down disappears.can guide me how make work in lower version of ie or correction should done in codes. my html code <div class="navigation"> <ul id="nav" class="drop"> <li><a href="index.jsp">home</a></li> <li>upload <ul> <li><a href="uploadbacklog.jsp">backlog</a></li> <li><a href='messageupload.jsp'>message</a></li> <li><a href="upload.jsp">customer</a></li> </ul> </li> <li>download format <ul> <li><a href="backlog">backlog format</a></li> <li><a href='msg...

model view controller - MVC DisplayFormatAttribute - DataFormatString for strings -

i have string stored in db 12 characters (digits) long. want displayed on screen : "###/####/####" i use displayformatattribute [displayformat(dataformatstring = "{0:##/####/#####}", applyformatineditmode = true)] but provided dataformatstring not seems working. edit tought solving creating customer displayformatattribute, seems not obvious. any suggestions ? i had quite similar problem, , solved using uihint attribute in viewmodel class. in addition created formatter in editortemplates folder. (mvc looks folder default think). happens rendring engine replace editor in view formatter. example bankaccount number 11 digits, have modify case. backend db accept 11 digits no separators, therefore remove these before save. in view @html.editorfor(m => m.bankaccount) in folder views/editortemplates @model string @{ script.require("common"); } @{string temp = string.empty;} @if (!string.isnullorempty(model)) { if (mod...

java - Reading deadlettered messages from service bus queue -

i know if it's possible read deadlettered messages azure service bus queue in java. i found following example https://code.msdn.microsoft.com/windowsazure/brokered-messaging-dead-22536dd8/sourcecode?fileid=123792&pathid=497121593 however, haven't been able translate code java. i found https://github.com/azure/azure-storage-java/tree/master/microsoft-azure-storage/src/com/microsoft/azure/storage there not seem deadlettering in there @ all. i found several blogs (i'm not allowed put more links don't know if should anyway without proper tags). not describe how read deadlettered messages in java. much in advance i know it's old thread next lost soul looking solution... i've been digging in .net sdk source , found it's simple http call "/$deadletterqueue", i.e.: https://mynamespace.servicebus.windows.net/myqueuename/$deadletterqueue/messages/head // peek-lock message dlq curl -x post -h "authorization: insertsasher...

javascript - Safari/SVG/Unicode: Unicode character not rendering in Safari -

i using d3.js append text element svg group element follows: d3.select('#legend').append('text') .attr('x', 10) .attr('class', 'remove-country') .attr('y', 10) .attr('font-size', '15px') .attr('font-weight', 'bold') .attr('fill', '#555') .style('cursor', 'pointer') .html('&#9747;') here, '#legend' group element. &#9747 unicode used print cross symbol in html. reference: http://www.w3schools.com/charsets/ref_utf_misc_symbols.asp the problem cross symbol rendering fine on chrome doesn't seem work on safari. different way in ...

PHP script does not work in a specific order -

i have simple html code displays image using link php script shown below. upon loading html page, want display image in browser , send email specific email addess. the php script listed below working fine intended. however, when move "show image in browser client" code top bottom of script, program sends email , not return image html page. can somone tell me why happening , how can fix it. html page code: <body> <img src="http://www.inoxel.com/test/image&email.php > </body> image&email.php php script file works: <?php // show image in browser client. $logo = "http://www.inoxel.com/test/happy_face2.gif"; // set image full path readfile($logo); // send test email. ini_set( 'display_errors', 1 ); error_reporting( e_all ); $from = "mblasberg@inoxel.com"; $to = "menb@pacbell.net"; $subject = "php mail test script"; $message = "this tes...

Explicit wait in selenium web driver for multiple mindow -

i automating web base tool have handle multiple windows,but there problem in explicit wait not working properly,though script getting fail time. using below code explicit wait. wait.until(expectedconditions.elementtobeclickable(by.partiallinktext("logout"))).click(); please guide me same.

How to Update ObservableCollection on click in c# with or without using LINQ in Windows 10 universal app development -

hello new windows app development , trying update observablecollection in c# reflect changes dynamically in xaml ui .but changes not reflect in ui.am doing wrong or doesn't work windows 10 or what. someone please correct me or suggest me best approach doing. thanks in advance. my class: public class students { public string name; public int age; public int section_no; } my c# code: public observablecollection<students> student = new observablecollection<students>(); private void filteritem_click(object sender, routedeventargs e) { menuflyoutitem selecteditem = sender menuflyoutitem; if (selecteditem != null) { if (selecteditem.tag.tostring() == "section") { student =new observablecollection<students>(student.orderby(i => i.section_no)); } else if (selecteditem.tag.tostring() == "age") { ...

python 2.7 - Partial Text Matching GAE -

Image
i developing web application managing customers. have customer entity made usual fields such first_name, last_name, age etc. i have page these customers shown table. in same page have search field, , i'd filter customers , update table while user typing in search field, using ajax. here how should work: figure 1: main page showing of customers: figure 2: long user types letter "b", table updated results: given partial text matching not supported in gae, have tricked , implemented arising shown here : tl;dr: have created customers index , contains search document every customer(doc_id=customer_key). each search document contains atom fields every customer's field want able search on(eg: first_name, last_name): every field made this: suppose last_name berlusconi, field going made these atom fields "b" "be" "ber" "berl" "berlu" "berlus" "berlusc" "berlusco" "berluscon...

Set CORS header in Tomcat -

i had static website hosted tomcat. how set header site like: access-control-allow-origin: * they static file, not servlet application. if it's static site, starting tomcat 7.0.41, can control cors behavior via built-in filter . pretty thing have edit global web.xml in catalina_home/conf , add filter definition: <!-- ================== built in filter definitions ===================== --> ... <filter> <filter-name>corsfilter</filter-name> <filter-class>org.apache.catalina.filters.corsfilter</filter-class> </filter> <filter-mapping> <filter-name>corsfilter</filter-name> <url-pattern>/*</url-pattern> </filter-mapping> <!-- ==================== built in filter mappings ====================== --> be aware, though, firefox not access-control-allow-origin: * , requests credentials (cookies): when responding crede...

windows installer - Why Installshield msp size is big -

i have 2 msis size of around 17mb, difference between 2 msis small. when i'm generating patch via the patch design, output msp around 15mb , cannot correct, because there no such difference exists. reason this? how can verify i'm patching difference between 2 msis? please note files added msi via dynamic linking option. i've opened both msis in msi diff tool , i've noticed each file has status of deleted , added, think somehow comparing component name , not actual file. because msi file grabbed via "dynamic linking" option. are using patch optimization when building patches? should in case. take @ following documenation: http://helpnet.installshield.com/installshield18helplib/upgradeconsiderations.htm also, when build patch there option include whole files or differntial files. make sure make use of option. hope helps. regards, kiran hegde

c# - Access to the path is denied. google api local iis publish -

i'm having trouble getting access folders, when have validate authentication google user. im getting error: access path '..' denied when i've published locally on iis. i tried change folder location, in app_data of project - no luck. i have tried these guys doing, didnt well. my code looks like: string path = appdomain.currentdomain.basedirectory + @"\json\client_secrets.json"; using (var stream = new filestream(path, filemode.open, fileaccess.read)) { try { string googlecalendarpath = folderpath + @"\app_data\googlecalendar"; credential = googlewebauthorizationbroker.authorizeasync( googleclientsecrets.load(stream).secrets, scopes, _currentaccountno, //vær sikker på, @ dette er det samme altid, og er unikt, da ens permissions til google calendar bliver b...

Android store json data from php in String[] -

i have json [{"id":"67","title":"1852","customlabel":"66479"}, {"id":"68","title":"1859","customlabel":"5478"}...] now store "title"s in string[] in order pass autocompletetextview i'm newbie , don't know how. could me? appreciated. in advance. you can like: //you have jsonarray store in jsonarray object. int len = jsonarray.length(); string[] titles = new string[len]; (int = 0; < len; i++) { final jsonobject e = jsonarray.getjsonobject(i); titles[i] =e.getstring("title"); } and set adapter autocompletetextview like: arrayadapter<string> adapter = new arrayadapter<string>(this, android.r.layout.simple_dropdown_item_1line, titles); autocompletetextview textview = (autocompletetextview) findviewbyid(r.id.autocompletetextview1); textview.setadapter(adapter); ...

objective c - How to get Highlight the human body parts by tapping on body image iOS? -

i have human body head, arms, legs, , all. when tap on head need show table related head diseases,when touch leg same previous 1 , how can highlight tapped part on image. its symptom tracker in human body displayed user , user selects part of body , can highlight part user elected , navigates him other view detailed data displayed. how achieve in ios? can pls me.. add buttons on each body part , set image button's highlighted state , selected state , needfull.

makefile - Ensure that called scripts exist and are executable with make -

i have makefile call bunch of makers such compilers , small scripts. sometime (often clearcase issue), executable flag missing or worse script missing. what best way check executable flag , existence of list of programs in makefile. my first implementation foreach on each executable , call them, catch exit flag. because check takes time, had ifdef in order bypass check makes rules not need use these scripts. example case of make clean call rm has installed on platforms. don't need check other programs. the second implementation check execution flag $(shell) , [ -x foo ] combined in ifdef directive. feed solution bit ugly. the third solution call shell script job. however, shell script must remain executable in case. can foo != chmod u+x checker quite ugly. what best solution? will approach following help? target: source ./script_1 test -x ./script_1 || chmod +x ./script_1 ./script_1 < source > target

angularjs - Joining the two audio files in node js -

i developing web page , user select 2 audio files , app join 2 audio files , make single output audio file. using nodejs in end , angularjs in client side. how can achieve requirement? went through many libraries nothing suits it. http://blog.ragingflame.co.za/2013/5/31/using-nodejs-to-join-audio-files i believe should useful you, have used before.

python - Looking for a way to stop memory leak in this basic program -

i'm new python. program creates label inside tk() window. word "hi" written label indefinitely. how can delete old hi's while still writing new ones indefinitely? how stop memory leak? here code: from tkinter import * def box(a): z=label(root,text='%s'%(a)) z.place(width=50,height=20) def start(root): a="hi" box(a) root.after(100, start, root) root = tk() start(root) root.mainloop() how replace text instead of creating label object every time. from tkinter import * def box(a): z['text'] = def start(root): box('hi') root.after(100, start, root) root = tk() z = label(root, text='') z.place(width=50, height=20) start(root) root.mainloop() from tkinter import * def start(root, z): = 'hi' z['text'] = root.after(100, start, root, z) root = tk() z = label(root, text='') z.place(width=50, height=20) start(root, z) root.mainloop() ...

javascript - Latex Plugin with CK Editor to create mathematical formulas -

i using latex plugin ckeditor . plugin returns math equation in image form. i looking hold of latex text instead of image. how achieve it? there configuration enable it? example great. please refer following code. ckeditor.extraplugins = 'mathjax,eqneditor'; ckeditor.plugins.addexternal('eqneditor', '../../vendors/ckeditor-ext-plugins/eqneditor/plugin.js'); ckeditor.config.toolbar = [ {name:'document',items:[ 'cut', 'copy', 'paste', 'pastetext', 'eqneditor'], } ]; edited p.s. : need panel edit math equation, http://www.codecogs.com/latex/eqneditor.php you using third-party plugin, nothing wrong of course, however, need ask authors support core ckeditor team unable support external addons. there is, however, official ckeditor mathematical formulas plugin available - referencing in code (ckeditor.extraplugins = 'mathjax';) seems not using it. see sample here: ...

How can I Add Search Vew in Toolbar android? -

1. want add serch view in toolbar in android.how can do? <android.support.v7.widget.toolbar android:id="@+id/toolbar" android:minheight="?attr/actionbarsize" android:background="#2196f3" android:layout_width="match_parent" android:layout_height="wrap_content"> </android.support.v7.widget.toolbar> thanks in advance. just this: <android.support.v7.widget.toolbar android:id="@+id/toolbar" android:minheight="?attr/actionbarsize" android:background="#2196f3" android:layout_width="match_parent" android:layout_height="wrap_content"> <edittext <--todo code--> /> </android.support.v7.widget.toolbar>

Restricting character input in custom Python Qt text editor? -

i interested in writing custom gui text editor of sorts dna using python , qt. editor restrict user input in text window letters (such atgc). best way of doing this? you can use ignore function. example: def keypressevent(self, e): if e.key() == qtcore.qt.key_a: e.ignore()

How laravel redirects to the before auth page after login -

i using laravel 5. i have tried access following url http:://localhost/myproject/public/index.php/tasks i have added app/controllers/controller.php following code public function __construct() { $this->middleware('auth'); } this code redirects login page whenever try access pages in project. redirects same page have tried access after login. don't know how laravel doing this. can tell how working? create following function in authcontroller . function override same function in authenticatesandregistersusers trait. can modify code redirect desired location. /** * post register / login redirect path. * * @return string */ public function redirectpath() { if (property_exists($this, 'redirectpath')) { return $this->redirectpath; } return property_exists($this, 'redirectto') ? $this->redirectto : '/'; }

how to save html table into excel file format using javascript in laravel -

iam trying save html(blade.php file)table excel file in laravel. javascript code function exporttoexcel() { var htmls = ""; var uri = 'data:application/vnd.ms-excel;base64,'; var template = '<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:x="urn:schemas-microsoft-com:office:excel" xmlns="http://www.w3.org/tr/rec-html40"><head><!--[if gte mso 9]><xml><x:excelworkbook><x:excelworksheets><x:excelworksheet><x:name>{worksheet}</x:name><x:worksheetoptions><x:displaygridlines/></x:worksheetoptions></x:excelworksheet></x:excelworksheets></x:excelworkbook></xml><![endif]--></head><body><table>{table}</table></body></html>'; var base64 = function(s) { return window.btoa(unescape(encodeuricomponent(s))) }; var format = function(s, c) { return s.r...

html - Manage click events in JavaScript -

i have li element , inside have span. have given click event li,and want give click event span move functionality. click event li works on span. this structure: <li> <span>::</span> item 3 </li> on span event can use event.stoppropagation() stop bubbled event. not call parent events

php - How can create multiple pdf files using mpdf API -

how can create multiple pdf files using mpdf api. when try create using mpdf got error message fatal error: cannot redeclare class mpdf $sql1=mysql_query("select * $tbl_name"); while($row=mysql_fetch_array($sql1)) { $alert_date=$row['alert_mail_date']; $cart_body='<!doctype html public "-//w3c//dtd xhtml 1.0 transitional//en" "http://www.w3.org/tr/xhtml1/dtd/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="content-type" content="text/html; charset=utf-8" /> <title>new order placed</title> </head> <body> <table width="550" border="0" cellspacing="0" cellpadding="0"> <tr> <td width="400" align="left" valign="top"> <a style="font-size:16px"><strong>.$aler...

android - How to create View with xml layout programmatically inside fragment? -

i have layout , need create many views add tham gridlayout inside fragment. i have now: arraylist<tables> tables; arraylist<view> tablelist = new arraylist<>(); tables = parsedarray.get(0).gettables(); gridlayout gridlayout = (gridlayout) getview().findviewbyid(r.id.grid_layout); (int = 0; < tables.size(); i++) { tablelist.add(getview().findviewbyid(r.id.table_layout)); //textview textview = (textview) tablelist.get(i).findviewbyid(r.id.table_number); //textview.settext(tables.get(i).gettablenumber()); gridlayout.spec row = gridlayout.spec(i / 5); gridlayout.spec col = gridlayout.spec(i); gridlayout.layoutparams params = new gridlayout.layoutparams(row, col); gridlayout.addview(tablelist.get(i), i, params); } } but wrong way, need find out how create new views , add them list, ...