Posts by Silvio Lucena Junior • 979 points
18 posts
-
4
votes1
answer114
viewsA: How to pass a function as an argument in Python?
I ran your code and I’ll tell you what’s going on with him. First let the error message Traceback (most recent call last): File "C:\Users\Lucas\Downloads\teste.py", line 28, in <module>…
-
0
votes1
answer91
viewsA: Split Mongo data into more than one folder. Possible?
There are some ways you can do this, if you want to use sharding but don’t have a new machine, you can have two or more instances of mongod running on the same machine, each with a different dbpath.…
mongodbanswered Silvio Lucena Junior 979 -
0
votes2
answers515
viewsA: How to get duplicated records with mongoDB and Morphia?
If you want to know only the distinct values for a given field in a set of documents in a Colection, you can use distinct. db.collection.distinct(field, query). However if you want to return a set…
-
1
votes1
answer464
viewsA: Find in two Customers using Aggregation
Mongodb does not support, as far as I know, to use the Aggregate framework in more than one Center, nor does it support find, findOne and any operation other than a single Center. Update 3.2 Mongodb…
-
1
votes3
answers167
viewsA: How to know if at the beginning of a <p> they have "x" character?
There are many ways to do this,. First you need to know that the Javascript strings can be accessed as if they were an array, then you could check if the string starts with a > by simply…
-
0
votes3
answers2757
viewsA: Detect if a particular page opens within an IFRAME
I believe you can use the property parent (A Reference to the Parent of the Current window or subframe. ), and even be more specific as picking the address of the window that contains the iframe.…
-
0
votes3
answers4599
viewsA: Javascript - save/update content
As Brunorb said, you probably won’t be able to do what you want using only HTML/Javascript. But if your page . html is on your server and you have access, you could change it using javascript only,…
-
1
votes2
answers141
viewsA: Increase table without selecting manual id.
Let me see if I understand your question, you want to increase and decrease without having to select the table id because you will have more than one table and more than one set of buttons to…
javascriptanswered Silvio Lucena Junior 979 -
27
votes6
answers3282
viewsA: Is there a Javascript class?
I think this settles the question. 4.2.1 Objects Even though Ecmascript includes syntax for class Definitions, Ecmascript Objects are not fundamentally class-based such as those in C++, Smalltalk,…
-
4
votes1
answer1449
viewsA: Manipulating elements with Javascript page scroll
@Ghabriel you can start by sculpting the scroll event from the window. window.addEventListener('scroll', function(ev){ }); And inside the event you can check by the value of the variable Scrolly and…
-
9
votes3
answers61753
viewsA: Remove a specific element from the javascript array
As Pedro Camara answered you can use the Slice method, however this method does not remove elements from the original array but returns a new array with the elements specified by the start and end…
javascriptanswered Silvio Lucena Junior 979 -
3
votes3
answers147
viewsA: How to put Html snippet on all child elements except the last one?
The Children function can receive a selector as parameter, and in this selector you can directly use :not as well as :last. $("#id").children(":not(:last)").html("<input type='text' value='" +…
-
4
votes3
answers1081
viewsA: As I put a button inside iframe
Friend, it is easier if you leave some clear points about the iframe and what you intend to do. Iframe Domain is the same as the page on which it is inserted ? You are not allowed to change the…
-
2
votes3
answers7520
viewsA: What is void in javascript?
The operator void evaluates an expression such as undefined. in the case void 0, it evaluates the value 0 as Undefined. In this case void 1, void 2, void (1 + 2) and void Math.round(12.5), both are…
javascriptanswered Silvio Lucena Junior 979 -
4
votes6
answers2483
viewsA: Why is Drag-and-Drop programming rarely used?
I think this is somewhat relative, depends on the application, the technology and the company’s policies. See the Xcode for example and the development for IOS, I believe that a good job is using…
-
1
votes1
answer853
viewsA: Dynamic maps in Google Maps
Yes, and are basically two steps, the first is to get the geographical coordinates of the address, for this you can use a geolocation service of the google itself, you can know more at this address:…
-
7
votes3
answers4829
viewsA: click a play button on the Youtube iframe
You cannot manipulate the DOM documents of an iframe that points to a domain other than the page that contains it. What you can do in this case to have a greater control over the player is to use…
-
6
votes2
answers581
viewsA: Use Cookie or Localstorage?
I think this depends a lot on the support you intend to give to browsers. If you seek to support as many browsers as possible you could use, or suggest, a pollyfill for Webstorage. In the link…