date
stringlengths
10
10
nb_tokens
int64
60
629k
text_size
int64
234
1.02M
content
stringlengths
234
1.02M
2018/03/14
998
4,134
<issue_start>username_0: I am making an ajax PUT request and including all the required fields for the request. I am still getting 400 error. This is my formdata ``` var formData = new FormData() var politician_id = this.props.image_reducer.politicianList[this.props.image_reducer.selectedPoliticianRow].pers...
2018/03/14
1,567
5,121
<issue_start>username_0: I often rsync files to the same directory on the remote machine. Is it possible to give it an alias so that I don't have to type it in full every time?<issue_comment>username_1: You can add alias like that `alias myrsync='rsync -av -e "ssh" user@server:/path/to/sync /path/to/local/destination'`...
2018/03/14
1,699
5,611
<issue_start>username_0: I'm using MongoDB for an application. I have a Collection in my db named Role with the following fields: Id, Role and I cannot change these names. In my VS code, I have a class named Role: ``` public class Role { [BsonRepresentation(BsonType.ObjectId)] public string Id { get; set; } ...
2018/03/14
4,297
13,354
<issue_start>username_0: Given a string and a list of substring that should be replaces as placeholders, e.g. ``` import re from copy import copy phrases = ["'s morgen", "'s-Hertogenbosch", "depository financial institution"] original_text = "Something, 's morgen, ik 's-Hertogenbosch im das depository financial inst...
2018/03/14
549
1,807
<issue_start>username_0: In postman, I post the array like [![enter image description here](https://i.stack.imgur.com/2g9wU.png)](https://i.stack.imgur.com/2g9wU.png) ``` key => Image[] / value => 1 key => Image[] / value => 2 key => Image[] / value => 3 ``` I want when I put an array which user's card images, re...
2018/03/14
322
1,114
<issue_start>username_0: I have this batch file which runs the powershell script. I want to run it the background but if I run with "windowstyle hidden" still visible. powershell -ExecutionPolicy ByPass -windowstyle hidden -File "C:\script.ps1"<issue_comment>username_1: ``` $string=$_POST[Image]; $array=array_map('in...
2018/03/14
637
2,164
<issue_start>username_0: I'm looking at the [webpush-java](https://github.com/web-push-libs/webpush-java) code. I run into a problem attempting to build the project using gradle. (I'm a gradle newbie). > > :signArchives FAILED > > > FAILURE: Build failed with an exception. > > > * What went wrong: Execution faile...
2018/03/14
619
2,217
<issue_start>username_0: I'm using Cordova to build Android/IOS app with Javascript Versions: ``` cordova-android: 6.2.3 cordova-ios: 4.4.0 ``` Before continue actions, user must be re-ask to confirm. A comfirmation popup will be displayed. Problem is user can scroll background screen when popup shown in their...
2018/03/14
677
2,770
<issue_start>username_0: This is the part of my code that doesn't work. The `else` statement works fine but when the `password` is wrong the program just closes abruptly. ``` if logged_in == 'admin': tries = -3 while tries < 0: password = input("enter <PASSWORD> password. ") ...
2018/03/14
673
2,613
<issue_start>username_0: I got a bunch of logs, each one with the following format: ``` 10-20-2016 13:57:28 [main] ERROR com.project.Main:11 - Error message here ``` The template of this log is: ``` : - ``` I want to parse that log and create a Java object with fields that match each token on that template. ...
2018/03/14
473
1,479
<issue_start>username_0: I'm trying to replace a word characters with other 'any' special characters, like in this example: ``` "if there is a definitive answer ? $120.223" to "** ***** ** * ********* ****** * ****.***" ``` or by maintain the first and the last character of each word, as: ``` "if there is a definit...
2018/03/14
649
2,087
<issue_start>username_0: I stumbled upon this problem while saving an int in a char array and converting it back. I used bit shifts and logic or, but my result ended up with all the bytes after the least significant as 0xFF. My question is: considering this example ``` #include int main() { char c1 = 0x86; unsign...
2018/03/14
706
2,229
<issue_start>username_0: I've a SQL which creates few metrics in below format and I want to transpose them into rows at every 'n'-th column for example, cut every 4 columns and convert into rows. Also there can be 'n' number of columns i.e 12, 20, 40, etc (multiples of 4 in my case). I need to load these rows into a ...
2018/03/14
1,866
6,553
<issue_start>username_0: This question is about different behaviour of `JEditorPane` in Java 8 and Java 9. I’d like to know if others have experienced the same, whether it could be a bug in Java 9, and if possible have your input to how to handle it in Java 9. Context: In our (age-old) code base we are using a subclas...
2018/03/14
819
3,426
<issue_start>username_0: I am creating an CRUD Application in Asp.Net Core After Add Operation I am redirecting to same view with setting model value as null to get another entry Below is my code ``` public IActionResult Add(OptionMasterVM model) { try { model.QuestionList = context...
2018/03/14
420
1,605
<issue_start>username_0: I've just started to use GCP and I have some doubts regarding the right use of some of its tools. Particularly, I'm trying to ingest data from Google Analytics into BigQuery. Would it be possible to use Dataprep on data stored in BigQuery? Almost every example I've seen uses Dataprep to visuali...
2018/03/14
406
1,476
<issue_start>username_0: To upload a file I use `Storage::disk('spaces')->putFile('uploads', $request->file, 'public');` The file is saved successfully on digital ocean spaces. But I want to rename it to something like this `user_1_some_random_string.jpg`. And then save it. How can I do it?<issue_comment>username_1...
2018/03/14
578
2,022
<issue_start>username_0: I'm using Great Schools Api : ``` fetch("https://api.greatschools.org/search/schools?key=***********&state=CA&q=cupertino&levelCode=elementary-schools&limit=1",{ method: 'GET', Accept:'application/xml', headers : new Headers ({ 'content-type': 'application/x-www-form-urlenco...
2018/03/14
644
2,476
<issue_start>username_0: I have a Jenkinsfile instance using ansible-playbook to deploy webmachine. I need to specified ansible-playbook parameters more than one at once. I got > > WorkflowScript: 25: Multiple occurrences of the parameters section > > > my jenkinsfile like this, ``` pipeline { agent none stag...
2018/03/14
729
2,555
<issue_start>username_0: I would like to use local variables in lambda functions but I get error: Please see the 1. and 2. points in the code. ``` class Foo { int d = 0; // 1. It compiles, but ugly, 2. doesnt compile public void findMax(List> routeLists) { int d = 0; // 2.Error : Local variable dd defined in ...
2018/03/14
8,964
30,877
<issue_start>username_0: I have a list of locations that i want to implement as a dropdown list in Flutter. Im pretty new to the language. Here's what i have done. ``` new DropdownButton( value: _selectedLocation, onChanged: (String newValue) { setState(() { _selectedLocation = newValue; }); }, item...
2018/03/14
238
932
<issue_start>username_0: I have some external website which i am loading using iFrame. And i am trying to implement fake click inside the iframe. Here is my code ``` window.load(function(){ $('#book-iframe').contents().find('.Home').trigger("click"); }); ``` also if try `$('#book-iframe').contents().find('.Home...
2018/03/14
190
763
<issue_start>username_0: I have used CSV file in Jmeter script. But Jmeter is Not reading data from CSV File. Now I want if data is Not read from CSV file then it will pick Default Value. How to do this ? Any Function for doing this ?<issue_comment>username_1: An iframe is independent of the frame that is displaying it...
2018/03/14
685
2,414
<issue_start>username_0: I call http post method from angular4 component to web api. When I print those values return from web api on console it prints empty values. I checked the request using postman also. It also didn't work. Http post call from component file. ``` EditValue(event, name, id) { const headers = ne...
2018/03/14
429
1,904
<issue_start>username_0: I am facing a problem with a specific translation issue on iOS. The app I am currently working on gets all the texts it displays from a web service. I have been able to implement this everywhere with one single exception: I have not yet found a way to programmatically alter texts from info.pli...
2018/03/14
725
2,997
<issue_start>username_0: I am new to the React Native integration in Android. I am creating a chat application and for that need to pass the UserId and another User information in my React Native component. How can I pass that from Android Native? I searched but I haven't found any successful lead. I tried doing it wit...
2018/03/14
349
1,164
<issue_start>username_0: I want to replace if string is started with `/` until next unique character ... I tried like below , but it replace all occurrences into one only ! I want to replace all occurrence characters ... ```js var textTitle = "///test///"; var result = textTitle.replace(/^\/{1,}/g, '../'); console.l...
2018/03/14
413
1,647
<issue_start>username_0: I want to render Local json file by listing it in cards, Im using FlatList View but couldn't get it rendered. Here is my code Snippet : ``` import React, { Component, View, FlatList } from 'react'; import { Image } from 'react-native'; import { Container, H...
2018/03/14
948
3,361
<issue_start>username_0: Let's imagine I have this model and I would like to sort them by logical operation `n1 != n2`: ``` class Thing(Model): n1 = IntegerField() n2 = IntegerField() ... def is_different(self): return self.n1 != self.n2 ``` If I sort them by `sorted` built-in function, I fo...
2018/03/14
692
2,502
<issue_start>username_0: i trying to learn php but found an issue.. im using mamp on a windows PC. and when im trying to connect my php with mysql a get this error:SQLSTATE[HY000] [1045] Access denied for user 'root'@'localhost' (using password: YES)..... in mysql i got the info username and password are 'root', host:...
2018/03/14
686
2,549
<issue_start>username_0: We are not using multi-tenancy. When it is disabled most of the tenant related UI gets hidden but in the LinkedAccount page, the user can view the tenancy name(which is Default). We wanted to hide it in the UI. Tried to find a property like `IsMultiTenancyEnabled` but couldn't find(Actually it ...
2018/03/14
922
2,924
<issue_start>username_0: Php: ``` $json_string = "{ "26":{"blabla":123,"group_id":1,"from":"27.08.2018","to":"02.09.2018"}, "25":{"blabla":124,"group_id":1,"from":"20.08.2018","to":"26.08.2018"}, "24":{"blabla":125,"group_id":1,"from":"20.08.2018","to":"26.08.2018"} }" ``` my.blade.php template: ```...
2018/03/14
464
1,785
<issue_start>username_0: `static_cast()` is the 'C++ way' of writing `void` conversion In the en.cppreference.com website mentioned as discards the value of the expression. In below link four points on **Explanation** section <http://en.cppreference.com/w/cpp/language/static_cast> Where and Why should we use `static...
2018/03/14
299
757
<issue_start>username_0: I want to count the records that start with 123, i need to count several times with different values, Starting with 123, 789, 567, ... I have those values ​​in the column2 ``` - column1 | column2 - 1234567 | 123 - 5489186 | 135 - 1238756 | 548 SELECT column1, LEFT(column1,3) AS prefijo, c...
2018/03/14
1,121
4,133
<issue_start>username_0: I am trying to query a cassandra table for every single kafka message. Below is the code that I have been working on: ``` def main(args: Array[String]) { val spark = SparkSession .builder() .master("local[*]") .appName("Spark SQL basic example") .config("spark.cassandra.connection.h...
2018/03/14
979
3,249
<issue_start>username_0: I've found hints at there being command completion available for bash[1] for the Azure CLI (`az` command), but I have not found any indication on how to install/enable that for zsh. Anyone know how to do that, if it is possible? I use oh-my-zsh, if that is relevant. [1] <https://learn.microsof...
2018/03/14
668
2,420
<issue_start>username_0: Recently I was working with lists in kotlin and had the following snippet: ``` a = listOf(1, 2, 3, 4) println(a[-2]) ``` Of course this causes an `IndexOutOfBoundsException` so I thought it would be nice to extend this functionality. So I thought one could override the `get` operator in the ...
2018/03/14
1,822
4,850
<issue_start>username_0: I have a list containing a set of the history of a file. I need to separate each element in the list into several columns and save it to `CSV` file. The columns I need are `commit_id, filename, committer, date, time, line_number, code`. Suppose, this is my list: ``` my_list = [ 'f52130...
2018/03/14
1,088
3,055
<issue_start>username_0: This is the Code **Person.java** ``` @Entity class Person { @Id private Long Id; @NotNull private String name; //getter setters } ``` **PersonRepository.java** ``` @RepositoryRestResource(collectionResourceRel = "person", path="person" ) interface PersonRepository extends CrudRepo...
2018/03/14
253
771
<issue_start>username_0: I would like to check if `$price_a = 30;` is greater than all the values in ``` $all_prices = [ 1 => 12, 2 => 24, 3 => 32, 4 => 44 ]; ``` I guess I'd have to loop through the array and do the check for each iteration but I'm not sure how that loop should look like. Or is...
2018/03/14
749
2,911
<issue_start>username_0: A standard pattern using DynamoDB is to separate data used by each environment by prefixing the table names with any environment-specific string. I assumed that this would be easy to do using ElasticBeanstalk and the CloudFormation configurations in `.ebextensions`. However - for my platform (...
2018/03/14
224
782
<issue_start>username_0: I have a constructor that looks like ``` constructor(values: Object = {}) { //Constructor initialization Object.assign(this, values); } ``` but it requires named initialization : ``` new Inventory({ Name: "Test", Quantity: 1, Price: 100 }) ``` can it be done directly...
2018/03/14
1,449
4,681
<issue_start>username_0: Hya, I have the below setup: **App.Component.Ts contents** ``` carForm: FormGroup; constructor( private fb: FormBuilder ) { this.carForm= this.fb.group({ name: '', type: '', extras: this.fb.array([]) }); } get carExtras(): FormArray { return this.carF...
2018/03/14
1,489
5,128
<issue_start>username_0: This is my json object: ``` { "id": 2, "service": "mobile", "min": "20", "per": "10", "tax": "1", "categoryservices": [ { "category": { "id": 1, "name": "laptop" } }, { "category": { ...
2018/03/14
897
3,013
<issue_start>username_0: I am getting some syntax error in my PHP code, which I am unable to solve. Please have a look at this and help me to solve this. [Here Is The Screenshot](https://i.stack.imgur.com/lmx6H.png). I have attached the screenshot of the error which I am getting on line 14. ``` php $link = mysqli...
2018/03/14
1,398
5,053
<issue_start>username_0: I am trying to authenticate users through ldap (window active directory) with Symfony 3.4 and i use this [documentation](https://symfony.com/doc/3.4/security/ldap.html) Please, Help Me!!!! But I'm getting error: > > php.DEBUG: Warning: ldap\_bind(): Unable to bind to server: Invalid creden...
2018/03/14
275
851
<issue_start>username_0: I need to create a new model, after setting the virtual host I couldn't acces the url for gii generator. My Virtual Host : ``` DocumentRoot "C:/xampp/htdocs/admin/backend/web" ServerName admin.product ``` How can I access the gii generator now? > > The gii url looks like > <http://h...
2018/03/14
162
565
<issue_start>username_0: Is there feature in WSO2 APIM 2.1 or higher version which could do first flattening of wsdl file and then create APIs ?<issue_comment>username_1: Found the solution. I could access gii via url > > admin.product/gii > > > Note : I use pretty url. Upvotes: 1 [selected_answer]<issue_comment...
2018/03/14
303
1,032
<issue_start>username_0: I have an `Error` table which stores the names of the **table** in which the error occurred. Now I want to query the table using the table name selected from the "Error" table. I tried to store the table name in a variable and use this variable in the FROM clause in my query. But this doesn't ...
2018/03/14
658
2,491
<issue_start>username_0: I want the **random string result(output)** to display inside the **text box** so I can saved the value into my database. ```js (function() { function IDGenerator() { this.length = 4; this.timestamp = +new Date; var _getRandomInt = function( min, max ) { ...
2018/03/14
459
1,520
<issue_start>username_0: I have `NSDictionary` with floating values, I am trying to get values like this ``` [[NSDictionary valueForKey:@"some_value"] floatValue]; ``` but looks like value not rounded correctly. For example: I have value in dictionary: `@"0.35"` but after above conversion returns `0.349999994039535...
2018/03/14
959
3,596
<issue_start>username_0: I have to call a function from one controller an other controller. ``` public function getquickviews(Request $request){ $report = new ReportController(); $report ->Applications($request->except('cl_e_start_date'));//it's not working its giving me error that it expect and instance of ...
2018/03/14
566
1,857
<issue_start>username_0: I'm trying to set a background image in react native.I want a background cover image. I've done like the below ``` { this.state.details.map(a => { a.content = a.content.replace(regex, '') } < /Text> < RadioForm style= {{ width: 350 - 30 }} outerColor = "#080103" innerColor = "#FF5733" i...
2018/03/14
679
2,425
<issue_start>username_0: I have copied an example from their own website but i do not know how to get it working. [Link to their example](http://pycallgraph.slowchop.com/en/master/examples/basic.html#source-code) This is my code: ``` from pycallgraph import PyCallGraph from pycallgraph.output import GraphvizOutput ...
2018/03/14
1,158
4,413
<issue_start>username_0: I am using a SQL query and sql server in my application to display data, it gives a major performance hit. When query gets executed the **CPU and DTU goes till 100%** It is a major performance issue. Query:- ``` SELECT * FROM (SELECT Alls.*, ROW_NUMBER() OVER...
2018/03/14
1,229
3,930
<issue_start>username_0: I have a checkbox when i selected i have on database the value '1' but when i dont select i have this erreur {SQLSTATE[23000]: Integrity constraint violation: 1048 Column 'actif' cannot be null (SQL: insert into `techniciens` (`user_id`, `actif`, `moyenne_avis`, `updated_at`, `created_at`) val...
2018/03/14
691
1,847
<issue_start>username_0: My ruby script filters a log and generates a hash like this ``` scores = {"Rahul" => "273", "John"=> "202", "coventry" => "194"} ``` by skipping multiple values for a key which is obvious log file will be like this > > Rahul has 273 Rahul has 217 John has 202 Coventry has 194 > > > Is...
2018/03/14
456
1,614
<issue_start>username_0: I'm trying to make a recursive function by using os.listdir(), and I am having troble looping to all my directories and list out all the files and directories. I know it's better using os.tree() for solving this kind of problem, but i want to see how to solve this by using os.listdir(). Here...
2018/03/14
313
990
<issue_start>username_0: In the controller I add a (numerical) value to the controller: ``` this.myValue = Number(elem.toFixed(2)); ``` I put it inside an input form: ``` ``` the value is correct, everything is shown as expected on the screen but I got this warning message in console: > > The specified value "{...
2018/03/14
1,910
7,503
<issue_start>username_0: I'm new to swift and trying to figure out the best way to store user defaults. Here are my 3 initial VC classes of my app where i pass data from the on boarding view, to the start your plan view, to the user info (profile view) - which is where i need to store defaults for users. My issue is - ...
2018/03/14
483
1,535
<issue_start>username_0: I've got a class which is inside a modal This is the code: ``` #### Select Theme Close Submit ``` With this piece of code: ``` $("#mymdl").modal({ fadeDuration: 1000, fadeDelay: 1, closeClass: 'icon-remove', closeText: 'X' }); var mymodal1 = $('#mymdl'); mymodal1.fin...
2018/03/14
1,227
4,336
<issue_start>username_0: * I run a RancherOS to run docker containers * I created a container on the GUI to run my databases (image: mysql, name: r-mysql-e4e8df05). Different containers use it. * I can link other containers to it on the GUI [![enter image description here](https://i.stack.imgur.com/9tYVq.png)](https://...
2018/03/14
1,938
5,719
<issue_start>username_0: I'm trying to get companies' info from government website and using Scrapy for it.My spider code is the following one. ### Spider code ``` import scrapy from scrapy.linkextractors import LinkExtractor from scrapy.spiders import CrawlSpider from ..items import CompaniesHouseItem class Spendol...
2018/03/14
371
1,471
<issue_start>username_0: I need to create a new object and push it into an array of objects. When i try the code below it instead results in an integer which is the value of the array length. ``` const newThing = Object.assign( {}, { __typename: 'Group', id: gro...
2018/03/14
824
3,056
<issue_start>username_0: I am new on json in C#. I use newtonsoft.json I have a json file with data (array): ``` [ { "firstName": "Joyce", "lastName": "Huff", "isActive": true, "age": 59, "gender": "female", "eyeColor": "green", "friends": [ ...
2018/03/14
955
2,560
<issue_start>username_0: I have a scenario where user can multiselect items and remove them, so I have two arrays: 1. With checkbox values (checked and index) 2. The actual items which need to filter based on checked values index. here are two arrays and expected result using lodash. ``` const checked = [ { in...
2018/03/14
908
2,705
<issue_start>username_0: I have JSON array like this ``` var array= [{id:1,name:'foo'},{id:2,name:'bar'}] ``` I would like to add a new key (eg:`isApproved`) to each object in the existing array expected output: ``` var array= [{id:1,name:'foo',isApproved:true},{id:2,name:'bar',isApproved:true}] ``` I used the...
2018/03/14
1,696
4,913
<issue_start>username_0: I need to make a POST-request in android. Before I tried it in Postman and it works fine. [![enter image description here](https://i.stack.imgur.com/1ho2z.png)](https://i.stack.imgur.com/1ho2z.png) But in Android (I'm using Retrofit2) it don't want to connect with server. **My ApiService:**...
2018/03/14
599
2,379
<issue_start>username_0: I know how to call instance method and class method. I am a little bit confused that how to call below method from another class or method because it returns the string. ``` + (NSString *)contentTypeForImageData:(NSData *)data; ```<issue_comment>username_1: Here is some steps for call post re...
2018/03/14
573
2,024
<issue_start>username_0: I have Rails API app. And 99% of the routes are JSON routes. however, I want to add one single route that will response with HTML. How can I do that? This is my current setup and when I browse the route I see a string of HTML tags on the screen. ``` class ApplicationController < ActionControl...
2018/03/14
603
2,102
<issue_start>username_0: I searched on the web and didn't find any good answer for my problem. So this is my question: I am using OpenCV and have a function called `replaceInvalidDisparties` and I have to search through the pixels and check if the actual value is `inf` and there is a standard function in `OpenCv` cal...
2018/03/14
624
2,353
<issue_start>username_0: I have seen this issue in many sites such as the [Facebook Registration](https://www.facebook.com/) Birthday dropdown lists or even [WebAim Accessible Forms](https://webaim.org/techniques/forms/controls). The problem is the following: By using the screen reader I focus on a drop down list and ...
2018/03/14
1,265
4,897
<issue_start>username_0: I am trying to check if a username exists or not before the form that will trigger the insertion of a new username is submitted, so that I can notify the user of the availability (or not) of the username she has selected. But my code doesn't works. Where is the problem? Here is my code: ``` p...
2018/03/14
716
2,235
<issue_start>username_0: Getting error `error: expression must have arithmetic or pointer type` in following code snippet. Not sure whats going wrong. ``` struct structX { union { structA varA; /* structA is a structure */ structB varB; /* structB is a structure */ } unionX; #define xa unionX.varA #define...
2018/03/14
399
1,116
<issue_start>username_0: I have a Question. I have a json File this looks like so. ``` [{ "nagelplatten": [ { "kg" : "1000", "rabatt" : "3", "fracht" : "" } ], "metalwebs": [ { "kg" : "1", "rabatt" : "4", "fracht" : "" } ] }] ``` And my function looks...
2018/03/14
1,262
5,240
<issue_start>username_0: I am trying to inject the ModelViewFactory object in the ViewModel and I get the following error. Have been working on this for days cant seem to figure it out. ``` public abstract interface MinutemanComponent { ^ com.xyz.minuteman.view.meeting.detail.MeetingItemDetailsViewModel...
2018/03/14
1,069
3,647
<issue_start>username_0: I am running `SpringBoot Application` just checked server logs and got several errors like this. I can't understand what can cause it as the error appears everyday after 12/24 hours. Tomcat Version running on `8.5.11` ``` 2018-03-04 17:03:26 [http-nio-8080-exec-85] INFO o.a.coyote.http11.Htt...
2018/03/14
868
2,950
<issue_start>username_0: I'm having some issues while trying to copy content of a variable into a file: ``` echo "$template" >> "debug.conf" ``` if I check the content of debug.conf it's empty. $template variable is populated with the following code: ``` template="$(cat /home/scripts/debug-template)" ``` and de...
2018/03/14
1,271
3,889
<issue_start>username_0: I have 8 logos in black&white version and I would like to prepare a classic hover effect with color version of a single logo. I am pretty sure that this effect can be done with a few lines of jQuery code but I am not advanced in it. I just need to change on hover letter in this source from bw ...
2018/03/14
299
1,052
<issue_start>username_0: Is there any default keyboard shortcut to close all tabs except the active one? It can be done by right-clicking the tab and choosing `Close Others` but I'd like to do this using only my keyboard. [![enter image description here](https://i.stack.imgur.com/AVPdH.png)](https://i.stack.imgur.com/...
2018/03/14
293
1,136
<issue_start>username_0: org.apache.commons.cli has interface like this: `public Option.Builder type(Class type)` Sets the type of the Option. Parameters: ``` type - the type of the Option ``` Returns: ``` this builder, to allow method chaining ``` If I want to build an option with type "int", how should I c...
2018/03/14
329
1,383
<issue_start>username_0: So I'm making a chat app. I use ajax to check for new entry(message) in database every 0.5sec. If there is then display the message. Is that too much to ask the server? Im using a cheap shared hosting service. From my experience so far, half the time message is fast and smooth, the other time, ...
2018/03/14
2,145
7,061
<issue_start>username_0: this is my android code when we run application and it is automatically close when login method is call on the clicking of the button > > FATAL EXCEPTION: main Process: soubhagya.hostinger, PID: 25611 > java.lang.IllegalStateException: Could not execute method for > android:onClick at > a...
2018/03/14
503
1,855
<issue_start>username_0: After executing the following code to generate a copy of a text file with Python, the `newfile.txt` doesn't have the exact same file size as `oldfile.txt`. ``` with open('oldfile.txt','r') as a, open('newfile.txt','w') as b: content = a.read() b.write(content) ``` While `oldfile.txt`...
2018/03/14
603
2,266
<issue_start>username_0: I have to sort 3 arrays using jquery but order of the result should be same The fist array is for text answers second is for Image answer and third is for Audio answer after sorting all array should be in same order , but It have to sort when question change ``` var Textanswers = plugin.con...
2018/03/14
427
1,705
<issue_start>username_0: I am trying figure out how to listen to event when the user turns on or off the location in the settings. I tried `navigator.geolocation.watchposition` but didn't have much success, since it does not listen to the respective event.<issue_comment>username_1: I tried on Linux / Ubuntu. It works a...
2018/03/14
591
1,736
<issue_start>username_0: I want to loop through the value of objects of an array that has latitude and longitude together as a value (but separated with a comma). What I want to achieve is to split the latitude and longitude and store them separately like this: [![how it should be](https://i.stack.imgur.com/Ka50V.jpg...
2018/03/14
348
968
<issue_start>username_0: My URL will look something like this : > > "/eshop/products/SMART+TV+SAMSUNG+UE55H6500SLXXH+3D/productDetail/ger\_20295028/" > > > Where product names can keep changing here `SMART+TV+SAMSUNG+UE55H6500SLXXH+3D` and product id here `ger_20295028`. I tried writing a regex which is wrong....
2018/03/14
373
1,466
<issue_start>username_0: I am getting following error when ii try to run the code I know the error is in the append function I don't know how to handle with escape characters ``` function check() { if(usertype==null) { alert('please select user type'); } else { $('#registerusers').h...
2018/03/14
1,006
3,116
<issue_start>username_0: How to convert one var to two var List? Below is my input variable: ``` val input="[level:1,var1:name,var2:id][level:1,var1:name1,var2:id1][level:2,var1:add1,var2:city]" ``` I want my result should be: ``` val first= List(List("name","name1"),List("add1")) val second= List(List("id","i...
2018/03/14
704
2,375
<issue_start>username_0: I have a project hierarchy like this: ``` file.pro src/ files.cpp include/ headers.h build/ files.o bin/ finalExecutable ``` What to specify in the `.pro` file so that the Makefile generated by `qmake` takes the `.cpp` files from my `src/` directory and put the executable...
2018/03/14
1,567
5,928
<issue_start>username_0: I have the application property `APP_ID` that should be randomly generated (UUID) and that should have the same value for the entire Spring Boot application. What I did was the following: I defined in the `application.properties` file the `APP_ID=${random.uuid}`. The UUID gets created success...
2018/03/14
2,089
7,214
<issue_start>username_0: I am looking for a regular expression which matches the pattern src="\*.js", but this should not be enclosed in a comment. consider the following ``` ``` Extended sample input, described by OP as "correct": ``` ``` The result should not match line 1 and 2 (where the content is enclosed ...
2018/03/14
1,065
3,862
<issue_start>username_0: I want to create some test java files with different sizes (100kb-500kb). In that case I am modifying simple hello world. **The program will be never executed** so creating objects inside class wont be called. I'd like to create some constants like in C/C++ language that will be saved in fil...
2018/03/14
500
1,885
<issue_start>username_0: I'm using angular 4 and a quill editor. but I get an error of `quill Invalid Quill container`. I change the name of the container but it still returns the error and cannot identify the container id. I create my quill object in ngOninit but it's not working! these are my codes: ``` import * as...
2018/03/14
625
2,447
<issue_start>username_0: I'm very new in ionic, I'm trying to add records in cards and it added successfully but when i try to add new record it added into same card doesn't create new card with data.I tried with nested component but it won't work. Please help me. Below is my code .html file ``` {{bindlcdetail}} ...
2018/03/14
444
1,349
<issue_start>username_0: I have a following table. ``` id name data 1 DAN xxxxxxxxx 2 ANTONY xxxxxxxxx 3 DAN xxxxxxxxx 4 DAN xxxxxxxxx 5 JOSEPH xxxxxxxxx 6 ANTONY xxxxxxxxx 7 JOSEPH xxxxxxxxx ``` I want to first sort the table using ID and then group by name....
2018/03/14
863
2,946
<issue_start>username_0: Following this tutorial: <https://reacttraining.com/react-router/web/example/auth-workflow>. Trying to reproduce the code: ``` const PrivateRoute = ({ component: Component, ...rest }) => ( fakeAuth.isAuthenticated ? ( ) : ( ) } /> ); ``` In TypeScript: ``` import * as React from 'r...
2018/03/14
834
2,921
<issue_start>username_0: In my app, I have a menu that routes content via ID but I also have a detailed view where the content should be displayed (via the same ID). I'm trying to display objects by their ID via button click and I'm not sure how I could pass the ID value to the item-detail component for it to display ...
2018/03/14
649
2,150
<issue_start>username_0: I am trying to generate a big table using kable on R. I would like to group some rows using names stored in an object but can't find how to do this. This is what I have: ``` kable(Baseline, "html") %>% kable_styling("striped") %>% add_header_above(c(" " = 1, "My score" = 4)) %>% group_r...