All Questions

3
answers

Indications for the use of cookies?

What would be the indication to use cookies ? They would be a IsolateStorage of web development, but until today I could not find an application for them, in a social media project I'm working I used them only once to remember th...
asked on 06.01.2016 / 03:47
2
answers

Big integer does not work

My code looks like this: #include <stdio.h> int main() { unsigned long int L, N; scanf("%lu%lu", &L, &N); printf("%lu\n", (L-(N-1))*(L-(N-1)) + (N-1)); return 0; } When the test case has low numbers, the pro...
asked on 11.02.2016 / 22:50
3
answers

How to create web payment system using PHP [closed]

I would like to create an e-commerce, but I do not have much knowledge about it. And I still have the following doubt.         How to create a payment system via ticket or card, is there any framework or API that offers the service ?, if there i...
asked on 11.08.2014 / 21:53
4
answers

Convert MySQL data (YYYY / mm / dd h: m: s) to dd / mm / yyyy

Look at my database: I'musingthefollowingcode:<?php$data=$noticia->data_cadastro;setlocale(LC_ALL,"pt_BR", "pt_BR.iso-8859-1", "pt_BR.utf-8", "portuguese"); date_default_timezone_set("America/Sao_Paulo"); echo strftime("%A, %d de %B de...
asked on 23.02.2015 / 14:56
5
answers

Capture name of files in directory

The following method takes the name of the files of a certain directory and displays them on the screen, the problem is that .listfiles() returns the number of bytes and not the number of files, although it shows the files name just havin...
asked on 26.02.2016 / 16:33
3
answers

Variable variable in php

I need to generate a variable with an arbitrary name. I have the following code, which does not work: $vv = mysql_query("SELECT * FROM $tabela ORDER BY rand() LIMIT 3"); $i=1; while($v = mysql_fetch_array($vv)){ $vertical.$i=$v['arquivo'];...
asked on 13.12.2016 / 01:02
1
answer

What's the difference between these ways of indexing a pointer to array of structs in c?

Is there any difference in the use of these 3 statements? void addCliente(struct cliente *dadosCliente){ dadosCliente[k].nome="oi"; (*(dadosCliente+k)).nome="oi"; (dadosCliente+k)->nome="oi"; } void main(){ struct cliente cl...
asked on 04.02.2014 / 17:27
2
answers

How to prevent user registration with Login initiated by number or symbol

I would like the help of you to do the following I have in case this function that makes in the case the verification of the login to be registered of the user. If it starts with a number it sends a warning to prevent registration. If you did...
asked on 11.11.2014 / 00:26
4
answers

How to mix an array in JavaScript?

In PHP, when I need to mix an array, I use the shuffle function. So: $a = array('@wallacemaxters', '@rray', '@CiganoMorrisonMendez'); shuffle($a); print_r($a); output: Array ( [0] => @CiganoMorrisonMendez [1] =>...
asked on 26.10.2015 / 16:57
3
answers

Go to the next element with next and add a class to the previous one

I'm trying to make clicking on the "next" link one of my lists revealed and the previous one being hidden, using a class that has display: none; , tried with .next() of jQuery but there were some problems, such as , for example, in...
asked on 19.02.2014 / 22:28