Vote count: 0 I am trying to retrieve data from my own password-protected, free Wordpress.com (not .org) site. The syntax for the API seems pretty simple if the site is not password protected, but there is very little information for novices on how to use the Wordpress.com API with authentication. I am looking to figure out these questions: When applying for an individual token without a formal App, what should I put for "Website URL" and "Redirect URL"? Once I have my token, how do I make authenticated API requests using R/RCurl? asked 15 secs agoarebearit This entry passed through the Full-Text RSS service - if this is your content and you're reading it on someone else's site, please read ...
ادامه مطلبVote count: 0 I'm trying to make a stand alone jar from my bare-bones Clojure project using the Leiningen plugin in Intellij's Cursive. To create the project, I just created the project.clj file, opened it, and Cursive offered to import it as a project. project.clj: (defproject WaterTimer "1" :description "A timer that reminds you to drink water" :main tone-producer/main) tone-producer.clj: (ns tone-producer (:require [general-helpers :as g]) (:import [javax.sound.midi MidiSystem Synthesizer MidiChael]) (:gen-class)) (defn main [& args] (println "Test!")) When I run the "uberjar" task, I get the following output: Waing: specified :main without including it in :aot. Implicit AOT of :main will...
ادامه مطلبVote count: 0 I'm ruing into an Unterminated string error when receiving UDP packets on and from a local socket. This is due to my messages being of various lengths, and my buffer size seemingly being insufficient (I've tried as much as 16k buffersize - which wasn't enough). Since I've read that buffers shouldn't be half that size to begin with, I've tried exploring other options, as using TCP sockets is not an option. I came across the socket.makefile method, but have thus far failed to make it work with my UDP packets (all recipes making use of this used TCP sockets). I've tried this: from socket import socket, AF_INET, SOCK_DGRAM def listen(): sock = socket(AF_INET, SOCK_DGRAM) sock.bind(...
ادامه مطلبVote count: 0 I'm trying to query a list of food items from my Firebase database. The app has a UITextfield where the user can type the search word for the food item. I have already implemented basic code for this to work using the below code. NSString *searchString = [sender.text lowercaseString]; [[[[[self.ref queryOrderedByChild:@"fuudTitleCapped"] queryLimitedToLast:5] queryStartingAtValue:searchString] queryEndingAtValue:[NSString stringWithFormat:@"%@uf8ff",searchString]] observeSingleEventOfType:FIRDataEventTypeValue withBlock:^(FIRDataSnapshot *snapshot) { NSLog(@"%@ Key %@ Value", snapshot.key,snapshot.value); }]; My database is structured like in the image below What I want is to o...
ادامه مطلبVote count: 0 I have a mobile app which is trying to authenticate before accessing APIs from a symfony backend. Here is how it is done : the app use a route like oauth/v2/token to which it gives the useame, password and other stuffs like client_id and client_secret. And the oauth retus a auth_token, refresh_token and other stuff. But here is the issue. Whenever I try to access to an API in the mobile (i'm testing via browser by using the command ionic serve) it redirects me to the web authentication page and my API retus in the console html code for that authentication page. Does someone might know where I get it wrong. For info whenever I make an api call I inject the token I get from authe...
ادامه مطلبVote count: 0 I am developing ionic2/angular2 app for Android mobile. I want to provide option to user to choose language option in the login page. Is there any way to do the app level Inteationalization using ionic2/angular2? I have seen so many examples with device level Inteationalization. asked 45 secs agovishnu This entry passed through the Full-Text RSS service - if this is your content and you're reading it on someone else's site, please read the FAQ at fivefilters.org/content-only/faq.php#publishers.Recommended article from FiveFilters.org: Most Labour MPs in the UK Are Revolting....
ادامه مطلبVote count: 0 I have a file composed of three objects, name y which is a numeric vector of length 2805 (composed only of -1 and 1, where -1 means exon is constitutively spliced, and +1 means alteatively spliced. Then, s1, and s2 are DNAStringSet objects, which both contain 2805 sequences of length 201. I want to use the kebabs package from Bioconductor, to train a model that predicts alteative splicing. Though, I don't know how can I combine the two sequences, and what are some available keel types. And afterwards, I have two other data sets with sequences, where I need to use this trained model to predict their label, whether they are +1 or -1. I can do something like this: library(kebabs) ...
ادامه مطلبVote count: 0 I want to get through a pcap file and go to each packet. Then get IP Address and manipulate it. In the end, I'm going to write it into a new pcap file. I use pcap4j version 1.6.4 and below is how I get the Source IP Address: String fname = "FileName"; String dumpFile = "newFileName"; PcapHandle h = Pcaps.openOffline(fname); PcapDumper dumper = h.dumpOpen(newFileName); Packet p = null; while ((p = h.getNextPacket()) != null) { IpV4Packet ip = p.get(IpV4Packet.class); Inet4Address srcAddr = ip.getHeader().getSrcAddr(); } As I mentioned, I got the Source IP Address and now I don't know how to set the new Source IP Address and write it to NewFileName. Any help would be appreciated....
ادامه مطلبVote count: 0 I found this code for a simple chat server here http://www.ibm.com/developerworks/linux/tutorials/l-pysocks/ and it works using telnet. It works so beautifully and i really want to modify it to have a GUI.I don't understand how do i have the clients type in the messages through a GUI window instead of the terminal using telnet.I am attaching the code for ease : import socket import select class ChatServer: def __init__( self, port ): self.port = port; self.srvsock = socket.socket( socket.AF_INET, socket.SOCK_STREAM ) self.srvsock.setsockopt...
ادامه مطلبVote count: 0 enter image description here I want to get descriptive statistics in python using describe function in pandas library. I want the summary statistics for column contb_receipt_amt at level of cand_nm. I tried using aggreggate and groupby function but could nt implement it correctly. Also, how can i use decribe for a selective column in python. asked 38 secs agoAbhisek Gupta This entry passed through the Full-Text RSS service - if this is your content and you're reading it on someone else's site, please read the FAQ at fivefilters.org/content-only/faq.php#publishers.Recommended article from FiveFilters.org: Most Labour MPs in the UK Are Revolting....
ادامه مطلبVote count: 0 Im using PHP and ratchet, im dealing with how i can create an event from the serverside and push it to the clients. I know i can use ZeroMQ, but this will also create an overhead, each time an event has to be notify, a new socket coection is made. So i was wondering, wouldnt it better to have thread which is always selecting from a mysql table named "SocketQueue" using memory as engine? Does this architecture makes the app lose the atribute of "Realtime" ? asked 1 min agogabriel mellace This entry passed through the Full-Text RSS service - if this is your content and you're reading it on someone else's site, please read the FAQ at fivefilters.org/content-only/faq.php#publishers...
ادامه مطلبVote count: 0 I'm getting a the url conf correct for my web app, and I'm at a loose end. I think the idea behind django-subdomains is that the subdomain routing is stored in the SUBDOMAIN_URLCONFS ROOT_URLCONF = 'creativeflow' # A dictionary of urlconf module paths, keyed by their subdomain. SUBDOMAIN_URLCONFS = { None: ROOT_URLCONF + '.urls', # no subdomain, e.g. ``example.com`` 'www': ROOT_URLCONF + '.urls', 'blog': 'blog.urls', } Then my creativeflow.urls and blog.urls are: """Creativeflow URL Configuration.""" from django.conf.urls import url from django.contrib import admin urlpattes = [ url(r'^admin/', admin.site.urls, name="admin"), ] And """Creativeflow URL Configuration the blog app...
ادامه مطلبVote count: 0 I have a problem in my code. I'm creating a Game and I need to have a sprite that can appear multiple times at the same time, to do so I created a class so I can do addChild(obstacle) multiple times and it will spawn one SKSpriteNode exactly similar to another. My problem is that I want to check collision between my player and the obstacle but because it's from the same SKSpriteNode the computer can't know of which obstacle I'm talking about. Here's how I created the player and the obstacle : import SpriteKit class Obstacle: SKSpriteNode { init() { let obstacleTexture = SKTexture(imageNamed: "obstacle") super.init(texture: obstacleTexture, color: UIColor.clearColor(), size: CGS...
ادامه مطلبVote count: 0 I have millions of images and I have to take the text out of them. I have searched about OCR(Optical Character Recognition) APIs and found tesseract to be one of the best. I am supposed to do it using scala and Spark. Can anyone please provide an example on how to use tesseract API using Scala. asked 54 secs agoAnkur Kant This entry passed through the Full-Text RSS service - if this is your content and you're reading it on someone else's site, please read the FAQ at fivefilters.org/content-only/faq.php#publishers.Recommended article from FiveFilters.org: Most Labour MPs in the UK Are Revolting....
ادامه مطلبVote count: 0 I'd like to send a java.util.HashMap converted to JSON from the client to the server. I'm using JSweet to transpile Java to JavaScript for the client side. I had a look at XMLHttpRequest and tried to prepare the map for transfer using JSON.stringify(new HashMap()) but this resulted in a TypeError: cyclic object value on the client side. These are my relevant dependencies (using Gradle): // Java to JavaScript transpilation compile "org.jsweet:jsweet-transpiler:1.2.0-SNAPSHOT" compile "org.jsweet.candies:jsweet-core:1.1.1" // Allows us to use Java features like Optional or Collections in client code compile "org.jsweet.candies:j4ts:0.2.0-SNAPSHOT" asked 39 secs agoMatthias Braun ...
ادامه مطلبVote count: 0 When I write tactics, I often want to saturate the proof context using a particular lemma. A typical example would be adding to the proof context all the inequalities a...
ادامه مطلبVote count: 0 How can I use custombox plugin to render actions in asp.net mvc? With modal boostrap, I use the following code, but the same code gives error with custombox: BUTTON New VIEW JS $(".btnModal").click(function () { $("#myModal").load($(this).attr("data-href")); $("#myModal").modal({ backdrop: 'static', keyboard: false }); }); asked 30 secs agoZack Morgan Let's block ads! بخوانید...
ادامه مطلبVote count: 0 I am trying to replace some text in an XML element with new text which I need to wrap in CDATA. asset = request.responseXML; asset.getElementByTagName("url").textContent = newUrl; newUrl needs to be wrapped in CDATA since it can contains special characters. How is this possible? I have tried the following but it doesn't work asset.getElementByTagName("url").textContent = ""; asked 38 secs agokittels Let's block ads! بخوانید...
ادامه مطلبVote count: 0 Good evening, I have this piece of PHP code : Is there a means in my javascript code to call the function and to pass the two parameters? Many thanks for your help. asked 19 secs agoLaurent Let's block ads! بخوانید...
ادامه مطلبVote count: 0 Is it possible to use hill climbing algorithm to move objects on an interface to achieve an optimum or desired output value? there are 5 objects each with an x and y coordinates. asked 20 secs agoBlaze Let's block ads! بخوانید...
ادامه مطلب