Vote count: 0 This is my component(react) which include rematch(Re play or play again) button. render() { const rematchTitle = formattedMessage('App.rematch'); retu ( {rematchTitle} ); } I want to give click event to that button.And when user click that (rematch-play again)button I want to trigger ready state(I want to change state to ready when user click that button).Because previous developer developed ready state and it works very well(ready state has reducers,actions...).I could not access previous developer and I am new at the redux. I try to give onclick event to that button but this.props is not work.Where can I bind or set this.props?Should I add a new action as name reMatch and red...
ادامه مطلبVote count: 0 I'm using the following code to modify the form answer: $('QR~QID24~1').insert({after: ' out of'}); $('QR~QID24~2').style.position = "relative"; $('QR~QID24~2').style.left = "100px"; $('QR~QID24~2').style.bottom = "34.5px"; This doesn't work anymore because when the block is looped the question is repeated five times, with the following names: QR~1_QID24~1 QR~2_QID24~1 QR~3_QID24~1 QR~4_QID24~1 QR~5_QID24~1 I tried to repeat the code with every name: $('QR~1_QID24~1').insert({after: ' out of'}); $('QR~1_QID24~2').style.position = "relative"; $('QR~1_QID24~2').style.left = "100px"; $('QR~1_QID24~2').style.bottom = "34.5px"; $('QR~2_QID24~1').insert({after: ' out of'}); $('QR~2_Q...
ادامه مطلبVote count: 0 This is my first post on Stackoverflow as after hours researching on how to deal with this problem (searching on Stackoverflow itself) I've decided to ask you guys for help. I'd like to know how to remove the "limit" on markers that this piece of code has. I'm quite new using Google Maps API, so I do apologize in advance if the code looks confusing. I'm using the Geocode feature + Autocomplete feature from Google Maps API. Places Searchbox html, body { height: 100%; margin: 0; padding: 0; } #map { height: 100%; } .controls { margin-top: 10px; border: 1px solid transparent; border-radius: 2px 0 0 2px; box-sizing: border-box; -moz-box-sizing: border-box; height: 32px; outline: no...
ادامه مطلبVote count: 0 var socket = io.coect(); socket.on('coect', function () { socket.on('mqtt', function (msg) { var message = msg.topic.split('/'); var area = message[1]; var state = message[2]; console.log(msg.topic, msg.payload); var timestamp = Math.round((new Date()).getTime() / 1000); $('#topic').html(msg.topic); $('#message').html(msg.topic + ', ' + msg.payload); switch (area) { case 'living': $('#value1').html('(Sensor value: ' + msg.payload + ')'); $('#label1').text(msg.payload + '°C'); $('#label1').removeClass('').addClass('label-default'); var entry = new Array(); entry.push(timestamp); entry.push(parseInt(msg.payload)); Temperature.push(entry); // Show only 20 values if (Temperature.le...
ادامه مطلبVote count: 0 So I have this text: ' Location Address Number Website ' Except the top and bottom lines are empty as well, there aren't single quotes on those two lines. I basically want to make sure each line is one after another without any line breaks. This is what I would like it to look like. Location Address Number Website I want to strip all of the line breaks and just have each result one line after another. This is the code to scrape the information from a webpage. results = soup.findAll('div', class_='name') for each in results: worksheet.write(row,1,each.text) row += 1 Each time I run through this, I want the results to print one line after another. Thanks. asked 4 mins agoWes Let'...
ادامه مطلبVote count: 0 I have been recently working on WordPress and trying to create sessions however I'm facing the following issue: I have created my own PHP file, where I will get the POST data and assign it to session variable. I have created the following function in Theme Footer file: if(document.getElementById("size")) { var sizeSelect = document.getElementById("size"); sizeSelect.addEventListener("change", function(){ var size=document.getElementById("size").value; if(size=="Custom Size") { document.getElementById("measurementChart").style.display = "block"; } else { clearCookies(); } }); } function closeMeasurementWindow() { document.getElementById("measurementChart").style.display = "none"...
ادامه مطلبVote count: 0 I'm getting the below error while ruing my tests using Karma with Jasmine in my Angular2 with NativeScript project. The tests are being executed correctly, but, this error keeps repeating in the console. I observed the error is coming only after importing zone.js (imported it because it says zone is not defined while using inject, etc from Angular2/testing). Error: JS: NSUTR-socket.io: transport error JS: NSUTR-socket.io: 1 JS: NSUTR: socket.io error on coect: Error: xhr poll error JS: NSUTR-socket.io: 2 JS: NSUTR: socket.io error on coect: Error: xhr poll error 04 05 2016 12:33:42.046:WARN [NativeScript / 23 (6.0; Google Nexus 6P - 6.0.0 - API 23 - 1440x2560)]: D iscoected (1 ...
ادامه مطلبVote count: 0 How could i set .NET CRL Version to Application Pool using InstallShield 2012?? In InstallShield 2009 , it easy to do it in Application Pool setting. But it seem hide in InstallShield 2012. Thanks ! p/s : please see attach files. asked 1 min agotuancoi Let's block ads! بخوانید...
ادامه مطلبVote count: 0 function val() { var name=document.getElementById("name").value; if(name == '') { alert(name+" is empty"); } else { var dataString = "name = "+name; $.ajax({ type:"POST", url:"hi.php", data:dataString, cache:false, success:function(html){ $('#msg').html(html); } }); } retu false; } Here is my hi.php file When clicking on submit button it show an error Notice: Undefined index: name in C:wampwwwSendEmailAjaxJqueryhi.php on line 2 I don't know where is the error plz help me to find out the error... Thanks in advance asked 40 secs agoDevraj Let's block ads! بخوانید...
ادامه مطلبVote count: 0 I'm using Slim's Twig-View - https://github.com/slimphp/Twig-View - component to render Twig templates to a Slim framework. There's a complete set of instructions on the page that makes it easy to get it working. The thing is that on Slim's templates page - http://www.slimframework.com/docs/features/templates.html - there's another set of instructions, practically the same except for the instatiation part. Whereas Twig-View has the following: $basePath = rtrim(str_ireplace('index.php', '', $c['request']->getUri()->getBasePath()), '/'); $view->addExtension(new SlimViewsTwigExtension($c['router'], $basePath)); the Templates page has this a bit more trimmed code: $view->addExtensi...
ادامه مطلبVote count: 0 I think there is a bug with respect to how PyDev (version 4.6) recognizes intra-package imports when selecting Grammar 3.x for the project preferences. I have a project like this: foobar mypack __init__.py mod1.py mod2.py mod2.py simply says from mod1 import fun1 mod1.py simply says def fun1(): print("Hey we are in fun1 in mod1") If the project Python project preferences are set to use Grammar 3.0-3.5, with a Python 3.4 interpreter, and I open up mod2.py the line from mod1 import fun1 is highlighted with an error Unresolved import: fun1. If I change the Python project preferences to use Grammar 2.7, close the file mod2.py and reopen it, the error disappears. Just by changing th...
ادامه مطلبVote count: 0 I would like to find a begiing and an end date in a range and then highlight all those cells included in the date range. I would like to use Set g1 = .Range("A1") Set g2 = .Range("C3")as advised in the link but my cell range changes, so a hard-coded "A1" or "C3" won't work. What would the above code look like utilizing variables instead? asked 46 secs agolindqmx1 Let's block ads! بخوانید...
ادامه مطلبVote count: 1 I have the following array of data: NSArray *denoms = [NSArray arrayWithObjects:@"$1", @"$1.5", @"$2", @"c2.5", @"c10", @"$100", @"$51", nil]; If I try to search following string in array then it should retu me the exact values out of the array if exist. For e.g. @"$1,$100" then result should be $1 $100 How to filter in this way? asked 7 mins agoHemang 1 Answer Vote count: 1 NSPredicate *bPredicate = [NSPredicate predicateWithFormat:@"SELF IN %@", @"$1,$100"]; I used to get the solution while posting the question. So keep it for future references. answered 7 mins agoHemang Let's block ads! بخوانید...
ادامه مطلبVote count: 0 I'm using rasbian jessie this is the very simple code import kivy from kivy.app import App from kivy.uix.label import Label class mamdouh(App): def build(self): retu Label(text='mamdouh') if __name__=='__main__': mamdouh().run() asked 1 min agomamdouh abdelfatah Let's block ads! بخوانید...
ادامه مطلبVote count: 0 I'm having serious brain farts with Gulp. I need to concatenate two SASS files into one. That is easy enough, but I'm using Compass as well and that's what seems to be messing me up. Here's the critical/important stuff I have related to this issue: // Include Gulp var gulp = require('gulp'), // Include plugins cache = require('gulp-cache'), gutil = require('gulp-util'), plumber = require('gulp-plumber'), notify = require('gulp-notify'), rename = require('gulp-rename'), compass = require('gulp-compass'), minifycss = require('gulp-minify-css'), jshint = require('gulp-jshint'), uglify = require('gulp-uglify'), concat = require('gulp-concat'), // imagemin = require('gulp-imagemin')...
ادامه مطلبVote count: 0 I have python code as below. It searches a google news page and prints hyperlinks and titles for each news. My problem is that googlenews groups news that are similar in one bucket and below script prints only 1st news in each bucket. How can I print all new from all buckets? from bs4 import BeautifulSoup import requests headers = {'user-agent': 'Mozilla/5.0 (Windows NT 6.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/41.0.2228.0 Safari/537.36'} #r = requests.get('http://www.aflcio.org/Legislation-and-Politics/Legislative-Alerts', headers=headers) r = requests.get('https://www.google.com/search?q=%22eric+bledsoe%22&tbm=nws&tbs=qdr:d', headers=headers) r = requests.get('https:...
ادامه مطلبVote count: 0 I am using below maven compiler plugin to compile my java code org.apache.maven.plugins maven-compiler-plugin true 2.5.1 1.6 1.6 My java_home points to java 7 My first question will my classes be compiled with java 6 or java 7? If with java 6 (because of 1.6 ), how maven will know the path java 1.6 as java home points to 1.7? If i need to compile the source code with java 1.8, i believe i need to set source and target as 1.8? But maven again will know jdk 1.8 path ? Do i need to change java_home to pint to java 8 ? asked 1 min agoemilly Let's block ads! بخوانید...
ادامه مطلبVote count: 0 I am trying to get medicine name from TrueMD using api. I am using this from my localhost. For that reason web service security I also include 'Access-Control-Allow-Origin' as a null still same error of security. Is there somthing that I am missing? $scope.medicines = []; var search = "crocin"; var api_key = "API_KEY"; $http.get("http://www.truemd.in/api/medicine_suggestions?id=" + search + "?key=" + api_key) .then(function(response){ response.header('Access-Control-Allow-Origin', "null"); $scope.medicines = response.data; console.log($scope.medicine); }); asked 1 min agoAnudeep Let's block ads! بخوانید...
ادامه مطلبVote count: 0 I am try to build a android application in which I have two activities FirstActivity and SecondActivity In FirstActivity I have two cases case 1, case 2; And in SecondActivity I have recyclerView.addOnItemTouchListener So what I am trying to do is that when recyclerView.addOnItemTouchListener is initialized or when i touch any item than case 1 will run else case 2 will run. so can anyone can tell how to do this. Thnk you in advance asked 1 min agoShivam Let's block ads! بخوانید...
ادامه مطلبVote count: 0 I know this is not a new question, but I have researched a bit and so far none of the answers I've seen gave me the answer. I have this situation: I´m working on a campus where the network is highly insecure (certain people are doing packet sniffing) and proxy servers are used for inteet access. I have access to a server (communication between this and the proxy does not have this problem) having mounted an sshd. Although I can not log in directly, I can use it for ssh tuel (in fact the tuel is already being used with Windows machines with personal configurations). I need to make downloads with wget using one of the proxies that are configured to access. I created the following...
ادامه مطلب