All Questions

2
answers

Problem when interacting with dict Python

I have my following code: for noms in json_obj['nom']: Type = noms.split("-") x = Type[1] y = Type[2] Where json_obj['nom'] has the following values: [{u'nom': u'7558-802'}, {u'nom': u'7558-998'}] What I'm looking fo...
asked on 01.03.2017 / 00:11
2
answers

Python script not executed from Cron

I'm trying to run a Python script from cron. Manually functional without problems. I have already tried all the solutions that can be found on the web. The crontab file is as follows: PATH=/usr/sbin:/usr/bin:/sbin/bin:/sbin:/bin:/home/p...
asked on 27.02.2017 / 15:03
3
answers

How do I prevent a "patient" from registering twice? PHP MySQL

I am creating a small "site" for a medical friend, who needs to keep track of patients, he needs to enter the data for each client as Full Name and Address, but I want to register a new patient, check if he is already is registered, taking into...
asked on 27.02.2017 / 05:04
3
answers

How to insert a select in a table (Datatables)?

Use datatables to list data brought from a DB but I need to insert a select (drop-down list) in one column of the rows try this way but it did not work. var users = $('#users').DataTable( {}); $.ajax({ url: 'users'...
asked on 28.02.2017 / 15:30
1
answer

I can not show and delete a record using a pop-up window

The delete function works perfectly by doing the following with the delete button. <a href="borrar.php?id=<?php echo $persona->id; ?>"><button type="button" class="btn btn-danger" onClick="<?php $identificador = $persona-&...
asked on 27.02.2017 / 07:49
2
answers

Click on a button to open a pdf file in python and QT

I'm a newbie programming in Python and my idea is that by clicking on the button that calls "Botonawg" a file pdf is opened. I would like this to work both in windows and systems UNIX . I use GNU-Linux ARCh ....
asked on 04.09.2016 / 22:12
3
answers

Error making a post request in angular using application / json

Previously I made a request using the following in the Headers 'Content-Type': 'application/x-www-form-urlencoded' But now the API asks me to send it in the following way: 'Content-Type': 'application/json' The functi...
asked on 28.02.2017 / 21:25
1
answer

Generate PDF in memory not in hard disk

How the pdf could be stored in memory; What I do not want to do is the following: File newPdf = new File("/var/reports/genera01.pdf") Basically I do not want to occupy space on the disk since after I get the PDF I want to print it with P...
asked on 05.09.2016 / 21:36
1
answer

count results from the controller

With the following code I have to search in a BD = payments and if 'payment_date' is equal to today I will show it in the view. And according to what I found, I added an accountant. If you found 2 results the value of the variable $ varnum = 2....
asked on 07.09.2016 / 21:43
1
answer

SplashScreen: AsyncTask + ProgressBar + rotate device, Android

I have a splashcreen where I run a background process with AsyncTask , when the device is broken the previous task continues, but it starts again. I am reading about how to face the problem, in the best way possible, that is, avoid bad...
asked on 06.09.2016 / 18:15