All Questions

1
answer

How does Laravel 5 do so that an instance is passed automatically if we only define the Type Hinting in the parameter in a function?

I think this is a totally valid curiosity, as it greatly facilitates and speeds development. I often analyze the framework code I usually use, such as Cakephp 2 , Laravel 4 and Symfony 2 . I started working shortly with...
asked on 02.03.2016 / 12:52
1
answer

Difference between methods to close JFrame and JDialog after keyboard event

I need to deploy to a desktop application built using swing , a way for the JFrame master to close the application when the user clicks ESC , and the JDialogs daughters of this%
asked on 17.02.2016 / 17:09
2
answers

Add days to date of input date

I have a input of type date, I would like to add to it 7 days and put that value in another input also of type date, I tried to do so: <script> $('#txtSolicitacao').on('blur', function(){ data = $('#txtSolicitacao').val...
asked on 04.03.2016 / 18:12
1
answer

Automatic class generator

How do I get an entity in the DB (Oracle) and generate a class on my system that represents that entity? Ex: I have this entity    Customer       ID int primary key       Name varchar (100) And now with the tool it already generates...
asked on 17.02.2016 / 11:56
1
answer

Select last JOIN record

I have a table tb_processos and another tb_detalhes (it keeps details of a certain process), I would like to get all the process data and only the last detail of the process. The way I'm doing I search for all records of tb_d...
asked on 16.03.2016 / 13:21
1
answer

Working with Canvas - Borderless

I have a canvas on my page and would like to remove the border .... so I can not ... which property works with the border? function desenhaBase(canvas, context, x1, y1, x2, y2){ context.fillStyle = "white"; c...
asked on 17.12.2014 / 13:00
1
answer

How to know the last weekend of a month in LUA

How to get the last weekend of March to change your time for daylight saving time. Code to identify whether it is the month of March and whether it is a Sunday. month_now=os.date("%m") week_day=os.date("%w") if week_day=="7" then print("d...
asked on 17.01.2015 / 12:52
1
answer

How to avoid misuse of a REST API?

I'm developing an application that is made up of three parts: Backend (BD + API), developed with Symfony 2 + Doctrine 2 iOS Client Android client Most client requests to the API must be authenticated through a token that is obtained t...
asked on 06.01.2015 / 12:05
4
answers

How to get the "src" value of an "img" tag through Javascript and copy it to clipboard?

I want to make when when clicking on an image, your url is copied to the clipboard, I tried to use Clipboard but I was only able to copy the text. var a = document.getElementById('id' + img).src.toString(); alert(a); I want to do this but w...
asked on 02.03.2016 / 17:49
1
answer

Generate a random value in a track, excluding a track

Using Javascript how to do a range with random values with a deleted internal range? Exemplifying:    min | | | | | | x | x | x | x | x | x | | | | | | max       | | = accepted value | x | = value denied Code used: function gen(mi...
asked on 16.01.2015 / 13:41