Posts by Paulo Cavalcante • 560 points
31 posts
-
-1
votes3
answers286
viewsA: To create alphabetical list in PHP according to variable number
I hope that settles your question: function alternatives($num){ $letters = array(); $last = ord('z'); $letter = ord('a'); $limit = $letter + $num; for($letter = ord('a'); $letter < $limit;…
-
0
votes1
answer3569
viewsQ: Ajax (POST) Laravel
I am having the famous error 419, that for a certain moment I was able to solve, but after restarting the server, it stopped working. Route: Route::post('ajax/Register', 'Ajax@Register');…
-
0
votes1
answer42
viewsA: How can I pick up items not viewed?
Studying a little more about sql I managed to reach the expected result. I hope to help other people if they have a related question. Here is the final query result: $sql = self::query("SELECT *…
-
0
votes1
answer42
viewsQ: How can I pick up items not viewed?
Use the following select to pick up items already seen: $sql = $conn->query("SELECT * FROM views b, news a WHERE a.status = 'true' AND a.id = b.id_news AND b.ip = '$ip' ORDER BY a.id DESC LIMIT…
-
1
votes1
answer35
viewsQ: Select record that contains result equivalent to a variable
I have a column in my mysql table, in which it is called "positions", where several values in int are placed there, however, with the "|" of division. Example: 8|19|10|20| And each number represents…
-
3
votes1
answer1107
viewsA: Paging datatable with jQuery
I’ll try to help you as I understand: Well, you’ll need to push the limit, which in case you made it clear that they will be 20 records. I suggest you leave a div "father" taking over the table in…
phpanswered Paulo Cavalcante 560 -
0
votes2
answers344
viewsQ: Wave-shaped chart Canvas JS
How can I make a wave-shaped chart using Canvas and JS. The example can help a little more:…
-
2
votes1
answer122
viewsQ: How to send only one form every 5 minutes
Well, I wanted to know, how could I get the person to send form only within 5 minutes. <?php $nome = $_POST["nome"]; $locutor = $_POST["locutor"]; $texto = $_POST["texto"]; $coment = "INSERT INTO…
-
2
votes1
answer775
viewsQ: How to make slide effect with jquery and js
Well, using jquery and js, I wanted to make a slide where my php would pull a lot of Ivs, and the limit will be 8 Ivs, for example, if you click the next button, it will move on to other Ivs that do…
-
2
votes2
answers485
viewsQ: How to send record only once in INSERT
Hello, I have an INSERT, sends, all great, but when it clicks several times on the Ubmit button, sends several, records, how can I avoid this? Code: <?php $id_noticia = $edit["id"]; $autor =…
-
0
votes4
answers115
viewsQ: How do I not allow "<" and ">" in my Insert
Well, I have an INSERT, and I would like to make sure that if someone typed in the text something with "<" or ">" that gave error when sending. Code: $autor_id = $_POST ["autor_id"]; $texto =…
-
4
votes1
answer3424
viewsQ: How to rank with PHP
Well, I have a problem, I know how to pull the ranking and all. My question is I’m gonna pull the 6 with the highest score, and I wanted the first 3 to have a different background, like: Whatever…
-
1
votes1
answer64
viewsQ: Pulling information from a table to a news page
I have a news page that pulls id (is one of those noticias.php?id=1), but I wanted her to tell only the news comments I’m reading, not all. That’s possible? I already got PHP to count, but I wanted…
-
4
votes2
answers2360
viewsQ: How to count number of records in a table?
I have a call table noticias, where every news has a id. I also have a table called comentarios, where there is the id of the news the user commented on. How can I count the comments for that news?…
-
0
votes2
answers124
viewsQ: Login system (error when banned)
I have a login system and I wanted it to appear ERROR if the user is banned. The SQL name in the table is "ban", if "ban" equals "0" the user will not be banned, and if "ban" equals "1" the user…
-
0
votes1
answer42
viewsQ: Decrypting date
I have a dashboard, and it encrypts the date, and I was wondering how I can decrypt it to show on my website. Encrypted date: 1437619904 I wanted to put it to the normal way.
-
0
votes0
answers79
viewsQ: Volume controller
I have a script for the controller, and it sets a value, and this value I wanted to put as volume. Is it possible to do this? Below I will show where I want the value to be: <script…
-
0
votes1
answer373
viewsQ: How to change link from my htaccess page
My normal url is: http://localhost/paginas/noticias.php?id=1 I wish so: http://localhost/paginas/noticias/1 id 1 is generated by php, I don’t know how to get it this way in htaccess.…
-
1
votes1
answer55
viewsQ: When you don’t have news
Hi, I have a news system and wanted a message to appear when there was no news in my database. Code: <?php $news8 = mysql_query("SELECT * FROM 10cms_noticias WHERE status = 'Ativo' ORDER BY ID…
-
2
votes1
answer499
viewsQ: Drag div inside another
I wanted to make a volume controller, I’ve done css, php, html, but it lacks js and jquery to finish. I wanted to . ball dragged inside the . control CSS: .bola { width: 10px; height: 10px; }…
-
0
votes2
answers101
viewsQ: Status in the news system
I have a news system and it is derived from the status, if $status = Active it appears and if $status = Inactive it does not appear, how can I do this? <?php $news8 = mysql_query("SELECT * FROM…
-
2
votes2
answers41
viewsQ: How to stipulate details with a SELECT
Well, I gave a SELECT, to pull my data, only I wanted to do the following: If $category is 1, it would be called World, and if $category equals 2, it would be called Moon, how can I do that? Code:…
-
3
votes2
answers1870
viewsQ: Javascript input transition effect
Hi, I wanted when I opened a page my image would come from the bottom up, and when I got to the top it would disappear, all this in 10 seconds. How could I do that?
-
0
votes1
answer148
viewsQ: User registration system
I already have the system, only I don’t know how to develop the mistakes. For example: Passwords do not match, user already exists, email already exists. <?php include('../includes/config.php');…
-
0
votes1
answer753
viewsQ: How to appear what I typed in the input in an image
Hello, I would like to know how I can do the following, I have several images with names, and created a script in js for me to type in the input and what I typed appear below, and this time I would…
-
0
votes3
answers697
viewsQ: How to box up when logged in
Well, I created a system with $_SESSION, and would like to know how I could do for example. You have the login, the person logs into the index, and returns on the same logged in page, and you want…
-
5
votes3
answers446
viewsQ: How to write and appear somewhere what I wrote
Well, in the sites nowadays are found some things that I can not explain, for example, think of a form asking your name, you fill in, and at the same time appears on your name, as if you were typing…
-
0
votes2
answers1649
viewsQ: How to pull database information into a php code
Hello, I have a code in PHP, and inside it I would like to pull information. @$host = "23.98.102.87"; @$port = "9498"; Where has the number s is where I wanted to pull the data, I’ve already made…
-
5
votes4
answers2045
viewsQ: How to limit PHP words
Hello, I would like to know how I limit the text I pull from the database. For example, I have a text called: Lorem ipsum dolor sit Amet. And I wanted you to limit the text by pulling, I’d be like,:…
-
1
votes2
answers607
viewsQ: Pull data from db
I would like to pull the data from my db. But do not know how to connect, already have the configuration file, but do not know how to pull to use . Connection file: <?php define('BD_USER',…
-
0
votes3
answers137
viewsQ: Message when entering the page
I wish that when someone came onto my page, they’d open a box, but I didn’t want it to be the default browser, but rather one chosen from my CSS. That would be possible? Codes: .box { background:…
javascriptasked Paulo Cavalcante 560