Posts by Shura16 • 2,113 points
114 posts
-
0
votes1
answer629
viewsA: Curl or Webservice Running Javascript
A cool way to emulate browsers is via Selenium using Java, C#, Ruby, Python or Javascript with Nodejs. This allows you to perform operations in an emulated web browser. It’s usually used for…
-
0
votes1
answer231
views -
4
votes4
answers318
viewsA: Div inside another broken div
You can use the float:left in the div CSS to prevent this. #register { float:left; } <div id="menubarwidget"> <div id="register"><a…
-
8
votes2
answers883
viewsA: What is the difference, in practice, between Session and Application?
Session is each user connected to a web application. Session data is useful when it is individual to the user. For example, every user logged in here in the forum has their Session. A shopping cart…
-
1
votes2
answers65
viewsA: What to do when a model has N responsibilities
That will depend on your business rule. When will you add Collections your list of services you can perform this treatment. For example, you can only have 10 collections in the list, so you treat…
-
2
votes1
answer1665
views -
0
votes2
answers1471
viewsA: Allow special characters as Java keyboard input
I tested it here and it worked like this (based on the answer from the colleague): import java.util.Scanner; public class Teste { public static void main(String[] args) { // read line…
-
-1
votes1
answer693
viewsA: Mysql Code Translation for Postgresql
Beyond the PDO cited by the colleague, I will also recommend as an option an ORM framework as TORM or Doctrine. All of these abstract the part of the database making the same code compatible with…
-
1
votes4
answers2951
viewsA: What ways to measure the performance of an algorithm?
I will then recommend the use of profiling tools. Each language has its tools, and may have generic tools. Some IDE’s usually have a built-in tool, but they all display a report about a program’s…
-
3
votes2
answers327
viewsA: Set file name in input file dialog
After a query of the HTML documentation, I confirmed that you do not have an option to define where the dialog will open. What you can define is the type of files that will be accepted with Accept:…
-
2
votes2
answers229
views -
0
votes1
answer285
viewsA: How to detect which js file is being used by the class of an element?
You can search inside the files by $(".classe1") or document.getElementByClass("classe1"). You can also comment on all other files by leaving only one uncommented, or comment one by one on whether…
-
4
votes3
answers3711
views -
1
votes1
answer39
views -
1
votes1
answer420
viewsA: Minimize jfx window
There may be different ways to get the Stage, but the method setIconified(true) should be called.
-
1
votes1
answer527
viewsA: How to break at the end of the checkbox line
You can use Grid Layout by setting the number of columns or use the Responsive layout (also with the number of columns). <h3>Grid Layout</h3> <p:selectManyCheckbox id="grid"…
-
1
votes2
answers658
viewsA: Can I generate a certificate for an IOS app without an Apple device?
Yes, there is a way, using the Phonegap Builder they have a documentation that shows how to do, see here. I will not post here because it is quite extensive. But you’ll still need Apple’s…
-
2
votes2
answers125
viewsA: Syntax error warning in the console running Angularjs
I changed the part return { getData2: _getData2, } for return { getData2: _getData2 }; I removed the last comma and added a semicolon. Jslint passed (adding the angular variable and checking the…
-
2
votes2
answers333
viewsA: Difficulty defining the path where a particular txt will be created
The most I could was to generate a file in a fixed location like the User folder (it can be a subfolder inside it if you want) or an Absolute Path as C disk:, Program Files folder etc. Stay like…
-
1
votes1
answer2126
viewsA: Angularjs User Authentication with Java/Jersey Rest API
For the security part to work the same must be configured on the server. This can be done with JAAS using Spring Security, Apache Shiro or other solutions. There are several tutorials on the…
-
1
votes2
answers1298
viewsA: How to integrate Spark Theme - primefaces with Maven
Because it is a Premium theme it will not be open to the public unless you pay. Probably when you buy they pass you the instructions to use it or you can contact their support.
-
1
votes3
answers698
viewsA: In OOP, what are the differences between Afferent Coupling and Efferent Coupling?
O acoplamento aferente (Ca) representa a contagem de quantas classes diferentes referem-se à classe atual, por meio de campos ou parâmetros. For example, I have a class Animal and the classes Pessoa…
-
3
votes2
answers695
viewsA: Web scraping with pure Javascript
It is possible yes. For example: var parser = new DOMParser(); var tmplXML = document.getElementById("tmplXML"); var blobXML = new Blob([tmplXML.innerHTML], { type: 'text/xml' }); var urlXML =…
-
2
votes1
answer921
viewsA: Desktop development with Electron
Positives: Developers already familiar with web languages will not need to learn a new language. Applications do not depend on internet to work. Very good when the internet is slow or does not…
-
1
votes1
answer867
viewsA: How to integrate Java code with Javascript?
Initially you should have a method that returns a json with the desired data, can be in the same class. But it would involve a REST configuration that I won’t quote here, but you can find in this…
-
1
votes3
answers404
viewsA: Grab Preview image of a video / listFiles() does not work
In the case of Windows (most used system), it creates thumbnails in a file Thumbs.db. If you can access it you can get these thumbnails. The bad thing about this approach is depending on operating…
-
1
votes3
answers504
viewsA: BD for distribution together with java application
Inside your jar only goes the database driver. In your program you’re going to have him set up a bank externally. It can be in the same jar folder, or in a common path like disk C: (in case of…
-
3
votes3
answers13259
viewsA: How to develop user manuals?
You can use Text Editor templates to format your document. If you master, you can use HTML with a CSS Framework and develop a Web manual. You can develop a Latex manual (also interested in…
-
1
votes2
answers256
viewsA: Windows Forms and Panels
The best then is to use the property IsMdiContainer from the main form. Set it to true. In other (internal) Forms, you use the property MdiParent (defined in code before the show()). So you only…
-
0
votes3
answers594
viewsA: How to set a column with adjustable size inside the container
Using the columns you set the width using the bootstrap grid. If this width is good for you use it. Otherwise adjust to the desired size. You can also set a fixed width with width, but it is better…
twitter-bootstrapanswered Shura16 2,113 -
0
votes1
answer26
viewsA: Warn in Parameter when climbing the application
Usually @Viewscoped is used in the Managed Bean and not in the parameters of the same. The warning is just about this.
demoiselleanswered Shura16 2,113 -
11
votes6
answers10103
viewsA: What is a Web Service?
A common web application, the browser launches a request (request) to the server, then the server (which is expecting requests) returns information (after processing or not) to the browser. This…
-
1
votes1
answer620
viewsA: Primefaces - p:fileDownload PDF
As already said in the comment, use the option immediate=true in the commmandButton. Answer also already validated in another question.…
-
3
votes2
answers66
viewsA: Show or hide a pregnancy option, whenever the user selects in the registration that is female
You can use the ng-show or ng-Hide option <div ng-show="myValue"></div>. On the following page there is an example if you need: Angularjs Ngshow…
-
1
votes1
answer1568
viewsA: Upload and Recover an Image with Angular
If you are using Angularjs I will indicate a javascript plugin for the same. Is the Flowjs (ng-flow). An example: <div flow-init="{target: '/upload'}" flow-files-submitted="$flow.upload()"…
-
1
votes3
answers11918
viewsA: Enlarge an image by clicking it (HTML5 and CSS3)?
There are tools ready for such as Lightbox or Fancybox. Or even you can download the source code of one of these solutions, study and develop your own solution. You can also use a thumbnail with…
-
0
votes3
answers2889
viewsA: Running my Angularjs application on some server
You can put your application on the Rails index page even as if it were a normal page. On the Rails port, you can run the command rails server -p 8080. More information about deploy is available…
-
0
votes2
answers805
viewsA: Is it correct to use JSON to store data that does not need to be in a database?
Power can, I believe there are no right or wrong practices, it depends a lot on what you need. But the question is whether you will need to consult this all the time from the file. Reading the file…
-
3
votes1
answer202
viewsA: p:selectOneMenu no list
Follow an example: No Enum: public enum ClienteTipos{ SUSPECT("Suspect"), PROSPECT("Prospect"), CLIENTE("Cliente"); ClienteTipos(String nome){ this.nome = nome; } //Attributes private String nome;…
-
0
votes1
answer32
viewsA: Create textboxs in a user-determined amount?
You created Textbox, but you didn’t add it to the form. See an example with a button: private void InitializeComponent() { this.button1 = new System.Windows.Forms.Button(); this.SuspendLayout(); //…
-
1
votes2
answers4619
viewsA: Tic-tac-toe - Implement logic
On the button: In Click Event you check the text. If the text is "" set it "X", if it is "X" set it to "O", if it is "O" set it to "". Several if or a switch solve this. About the win: With each…
-
1
votes1
answer334
viewsA: Perform function in ng-Bank Angularjs
You are calling the function in the routeProvider solver, soon it will be called when the page loads. Create a function in the controller (not mentioned above) and call it in ng-Blur of the desired…
-
0
votes1
answer141
viewsA: Links and content on the same page without frames
Using Javascript is possible, and using javascript frameworks becomes much easier. I will recommend the Angularjs or the W3.CSS both frameworks offer options for browsing the way you want. As there…
-
0
votes1
answer136
viewsA: Does an http request on a JSP page open a session?
If it’s a "Restservice" who wants to do something like this: import java.io.IOException; import java.io.PrintWriter; import java.util.ArrayList; import java.util.List; import…
-
2
votes4
answers4026
viewsA: Percentage Com javascript
25 % more than the present value would be: valorAtual + valorAtual * 25 / 100 Then we have: var valorInput = 25; var valorAtual = 50; var valorAMais = valorAtual + valorAtual * 25 / 100; if…
javascriptanswered Shura16 2,113 -
0
votes1
answer338
viewsA: Problems with selectOneMenu in Jsf 1.2
When calling the second method (which I didn’t see where the method or call is) you should use the setPropertyActionListener or an alternative to set the CNPJ value in the bean again.…
-
1
votes3
answers1312
viewsA: How to install Angular JS modules?
On the Angularjs page, click the button Download and then in Browse addicional modules. A list of module files will appear, click on the module file you want to add, copy the link and add from the…
-
1
votes1
answer1023
viewsA: JPA annotation @Autowired
No, everything is one thing. This annotation is automatically injecting an instance of ParticipanteRepository. So you don’t need to use new ParticipanteRepository() or other method of rearing.…
-
0
votes2
answers1437
viewsA: Problems with Google Cache
If the Cache disabled did not work I will guide to clean the cache manually or even use an extension to clear the cache always as the Cache Killer.…
-
1
votes2
answers712
viewsA: Select separated by semicolon to xls
You should then perform the query by following the SQL standards, and then based on the result of your query format for csv or other form desired. Searching I found even examples: Export SQL Server…