Questions tagged as 'php'

1
answer

Rest API and Sessions, how does Login work?

I've always worked with PHP / MySQL and Javascript / jQuery. I've always connected PHP with the database directly, and I use sessions to log in. I'm currently working on a project where I use AngularJS for the frontend and PHP / MySQL for the...
asked by 08.12.2015 / 21:32
1
answer

See if SLUG already exists

I would like to know how I can query if a SLUG already exists in the database and, if it exists, how to increment +1 to the end of the string, site.com/artigo/titulo-de-teste1 site.com/artigo/titulo-de-teste2 site.com/artigo/titulo-de-t...
asked by 06.12.2015 / 17:56
0
answers

Returning content from a form via cURL

I have this code that logs in to Instagram, however I want it to open in a modal or any other kind of thing to fomulario from instagram when checkpoint is required , see: <?php $username = 'conta'; $password = 'senha'; functi...
asked by 22.01.2018 / 17:42
0
answers

Monthly shift schedule

I have to create a button in php for when I click generate a monthly shift schedule, but I'm not sure how to do it. Can anyone suggest an idea? What I am thinking is to randomly choose the collaborations I need per day of each shift, but it i...
asked by 08.01.2018 / 18:41
1
answer

How to check if data already exists in the bank before inserting another in angular?

I have already made a modal that receives a name, it sends the controller in the function of inserting new contact. I want to check if this data is already registered in the bank so they do not sign it again. Anyone know how I can do this in Ang...
asked by 07.05.2018 / 19:45
1
answer

play button plays another audio

I have a table named posts , and there is a post_aud column where a text is inserted with the name of the audio / music (which is 'saved' in the audios folder) ... $get_posts = "SELECT * FROM posts ORDER by 1 DESC"; $run_posts = m...
asked by 15.12.2017 / 04:11
1
answer

Creating and communicating with daemon

I have a Python application where I need to keep it online all the time. The application has its own console, which is where I make the communication and step parameters. I understand that I can create the Daemon to leave it online all the...
asked by 18.02.2015 / 15:32
1
answer

How do I correctly pass the data type by PDO

In the php snippet below, what kind of PDO :: PARAM should I use? $cnx = new PostgreSQL(); //Classe de conexão do banco $data = '2015-02-13'; $select = 'SELECT * FROM eventos WHERE "data" = :data'; $query -> prepare($select); $query -> b...
asked by 13.02.2015 / 18:33
1
answer

The cookie time created when I close the browser expires

I'm here asking why unfortunately I've tried all the alternatives in polls since last week. And I'm probably doing something wrong. Come on: setcookie("email", "email", time() + (360 * 24 * 3600)); This is the code that I created the...
asked by 05.03.2015 / 20:21
1
answer

Image Verification (Captcha) does not work

My script has a registration form only that captcha does not show the letters: I'llleavethecodebelow:<?phpdefine('SI_IMAGE_JPEG',1);define('SI_IMAGE_PNG',2);define('SI_IMAGE_GIF',3);classSecurimage{var$image_width=190;/***Thedesiredwid...
asked by 04.03.2015 / 15:23