All Questions

1
answer

Image does not load with JavaScript

Why does not my image on my desktop load my HTML page?  I'm doing it through JavaScript, but just upload the images from the internet by putting the url. This is my code: function mostrar() { var src = "C:\Users\User\Desktop\fondo.jpg";...
asked on 25.12.2017 / 15:22
2
answers

Error inserting data with PDO and POO

Greetings community. I am developing an application using PDO, I am starting and I have had a problem when inserting records in the database. Next I put the functions that I am using and the error that is giving me. First my controller receiv...
asked on 31.12.2017 / 01:03
1
answer

How can I change the text content by clicking on it in HTML / CSS?

Well, it turns out that I put a text that says "off" in red, and that when you pass the pointer over it says "turn on" in yellow. However, my question is: what do I do so that when I press the text of "off" it changes to "on" in green color and...
asked on 14.08.2017 / 15:56
3
answers

Do operations on columns in a Dataframe loop

I want to do calculations on three columns of an array values_array . def calculateAllEMA(self,values_array): df = pd.DataFrame(values_array, columns=['BTC', 'ETH', 'DASH']) for i,column in enumerate(df[column]): ema=[]...
asked on 11.08.2017 / 16:01
1
answer

Using $ this when not in object context - PHP

I have explored several similar questions before sending this post, so I am sure of what I am doing. I am creating a web application written in PHP, where I have some classes that I usually call, such as using Url::exists($alias) . W...
asked on 04.08.2017 / 00:43
1
answer

Using objects as properties of another class Swift 3

I am new to Swift, I have a class that has properties that belong to other classes. class Pizza { var tamaño=Tamaño.self var masa=Masa.self var queso=Queso.self var ingredientes = [Ingrediente]() var aa:String = "" } The...
asked on 19.08.2017 / 23:01
1
answer

How to get the output code that throws an exe executed from java with runtime?

I run a file .exe (for sending images) from java which can pull different output codes depending on the error, this is my class: public static int SendImg(String ip, int puerto, String rutaIMG, String tipo) { Process p =...
asked on 15.08.2017 / 22:19
1
answer

Make the diagonal of a matrix 0. Python

Good morning everyone, I would like to be able to make the diagonal of a matrix equal to 0 with some type of command, does anyone know how? Is there any numpy that can do it? for example SO: [,0] [,1] [,2] [,3] [,4] [0,] 0 0 1...
asked on 03.08.2017 / 08:12
2
answers

How to truncate a date with time in postgresql?

Execute: SELECT NOW() and it appears to me: '2017-08-07 10:53:44.207-06' And I want to appear '2017-08-07'     
asked on 07.08.2017 / 16:55
3
answers

Problems with a list using CSS

This Image: It's from a list I'm doing but I want it to be like this And this is my CSS and HTML code: ul{ list-style:none; counter-reset:li; padding:10px; left:-8px; width:100%; } li{ /* Styles of each element */ wid...
asked on 03.08.2017 / 21:44