Posts by DiChrist • 4,567 points
91 posts
-
-3
votes3
answers799
viewsA: How to center image to text?
Comrade, take the float off that tag <img>, and put a text-align:center on that tag <div> that holds the text and the image that will solve this problem.
-
1
votes2
answers5990
viewsQ: Is it possible to send email with xampp from a local server?
Well, from time to time, I find myself in the following situation where I cannot take the test of sites/systems that I develop. Practically always, I develop the system on my machine, to then go up…
-
12
votes2
answers9932
viewsQ: What is the difference between . prop() and . attr()?
Do these two jQuery functions do exactly the same thing? Or is there any difference between the same. You are informed that the function .prop() came from jQuery 1.6 She came to replace .attr() ?…
-
1
votes2
answers432
viewsA: PHP output inside a CSS modal
The question is a little old, but come on. First, I recommend the use of bootstrap, which will already make your work much easier. After placing the files in the folder and creating their references…
-
10
votes4
answers3043
viewsQ: What are temporary tables for?
What use can these so-called temporary tables offer? Is there any advantage to using them? There is a difference between the temporary tables and the "normal tables"?
-
2
votes2
answers2254
viewsQ: Is it possible to know where an sql execution originated in SQL SERVER?
There is a situation that I believe will be of great importance to me, which is to know the origin of an sql command in SQL SERVER. Suppose that accidentally a user has executed any command. Then I…
-
3
votes1
answer102
viewsQ: Is it possible to get user location information through your ip?
Is there any possibility using the schedule of getting locations from a supposed visitor to your website? Example: "So-and-so" with ip: 192.168.254.1 visited my website: www.meusite.com.br Through…
-
5
votes3
answers603
viewsQ: Create/Use shortcodes in php
I wonder how I can create shortcodes in pure php (I will not use wordpress and your plugins). I don’t intend to use php functions for this purpose. I’d like to create a structure where I can name a…
-
6
votes1
answer474
viewsQ: Is it correct to name html tag attributes arbitrarily?
I would like to know about creating and manipulating attributes in html that are created. We have the attributes already known as the id, class, etc. that we put in the tags so we can manipulate…
-
12
votes3
answers307
viewsQ: Is there a difference in performance between "echo" content and HTML content?
The use of echo PHP to display on the screen any content differs in performance to use this same content directly in HTML? For example, if I use a PHP file: <?php echo "<p>Seja bem-vindo ao…
-
37
votes1
answer28542
viewsQ: What are the most relevant differences between C# and Java?
I wanted to know the most relevant differences that I should know exist between these two languages. Why am I asking this here? Because normally in my day-to-day when I ask this question, my…
-
11
votes3
answers2360
viewsQ: Voice recognition in php
This question is of curiosity indeed, I am not touching anything of the type, but in the future who knows. I wanted to know if there is any type of system or if it is possible to create a system…
-
7
votes3
answers2385
viewsA: How important is the use of the word "this"?
The reserved word this represents the running object. With it, implicitly you call the object being used. Example: class Classe{ private int numero; Classe(int numero){ this.numero = numero; // Aqui…
-
12
votes2
answers5686
viewsQ: What is the difference between htmlspecialchars() and htmlentities()?
I once had to use htmlentities() to solve a certain encoding situation (words with accents were not with characters) and saw that there was this htmlspecialchars(). In Php.net, I saw the following…
-
42
votes6
answers3282
viewsQ: Is there a Javascript class?
I am studying Javascript and saw some explanations that left me with doubts. Here at Stackoverflow I saw several questions about the possibility of creating an abstract class in Javascript. But my…
-
13
votes3
answers4752
viewsQ: What is the difference between 'Yield' and 'Return' in PHP?
I have been trying to remove this doubt, but without success. At first glance they seemed to me similar commands or they would be the same thing. After seeing some explanations, I was a little…
-
19
votes4
answers10808
viewsQ: Is it possible to create a desktop application using only PHP, HTML, CSS and jQuery?
Although I know that PHP is a language for the web, I would like to know one thing. It is possible in any situation to create an application, system or application with only PHP+HTML+CSS+jQuery that…
-
2
votes2
answers758
viewsQ: Php server check
I have a situation here where I need to identify the server the site is located on. You can check whether a server is windows or Linux using php code?
-
9
votes2
answers1164
viewsQ: What are the differences between the "vw", "em" and "%" font sizes?
I’m having second thoughts about using the size units vw, em, %. Searching the Internet I always saw that some used some units of size, but I never really understood the difference between them. For…
-
1
votes2
answers1012
viewsQ: Function with return using 'case when'
I have a Function that returns the status of a request (in the database is as int) that only has two possible values, 0 (inactive), 1 (active). I was trying to increment it with 'case when' in case…
-
2
votes1
answer1010
viewsQ: Postgresql syntax error using keys
I’m having trouble understanding why pgadmin is pointing syntax error in my query. select first_name, coalesce(to_char(avg(p.amount),'99.99'), 'nnn') valor_medio from { select c.first_name as…
-
7
votes2
answers5915
viewsQ: How to leave a span in the center of a div both vertically and horizontally
I have a text that I wish to manipulate with effect, but I need the structure of it to be correct. The structure I need to do, is that each letter is exactly in the middle of a div (a div for each…
-
0
votes1
answer275
viewsQ: Parameter-based query in SQL Server
I have a situation where I need to bring results depending on the parameter reported. If I gave you any number, which would be the code, it would only bring the result that has the code. If I didn’t…
-
6
votes2
answers7016
viewsQ: remove element css
I wanted to know how I can via jquery remove all css styles from a certain html element. Example: html <h1 class="titulo">Título</h1> css .titulo{ padding: 5px; color: #424255;…
-
1
votes2
answers206
viewsQ: Change attribute "src" with fadein effect
I need to change the src attribute of an image with jquery. Everything works perfectly, I just need to apply an effect that I am not able to put. I don’t know if the way I did it’s the exact way to…
-
1
votes1
answer56
viewsQ: Catch Total value except date
I’m trying to develop a query that will return me a total order value for a particular customer, with an informed date range. For example, between 05/11/2015 to 05/12/2015. The problem is that I…
-
1
votes3
answers124
viewsA: How to use multiselect value in php
Well, after doing some tests I found that it had a value that was receiving wrong quote. Sergio’s comment helped a lot, so $arr = json_decode('["1","2","3"]'); is valid. In my case, I was able to…
-
3
votes3
answers124
viewsQ: How to use multiselect value in php
I’m taking a value from a multiselect and sending it via ajax: Assuming the value of multiselect is: ["1","2","3"] // é esse valor que está sendo enviado (value do multiselect) After rescuing this…
-
1
votes1
answer67
viewsQ: How to return check value marked via ajax
I have a student registration form. It is all ready, the only thing I’m having difficulties is to return the value of a checkbox, which in the register refers to the student being active or not. On…
-
5
votes1
answer432
viewsQ: Insert php with object as parameter
I’d like to understand how I can do an insert function in php that uses an object as a parameter. Example: class Aluno{ private $nome; private $curso; } getters e setters... public function…
-
2
votes1
answer465
viewsQ: toastr does not appear
I am using a form inside a bootstrap modal. It makes a record in the database and returns the message whether or not it has registered. I have inspected the element several times and everything is…
-
0
votes2
answers497
viewsA: How to make stylized mega menu in Wordpress?
Well this can be done in many ways. I would do it on the arm if I were you, applying the styles and effects I desired. But in case you wanted something ready and easy to use this reference:…
-
6
votes3
answers1463
viewsQ: Place images in a div with jquery
How can I place certain images in a div using jquery by clicking the button? Follows the html: <div> <button id="btn2015" class="btn">2015</button> <button id="btn2014"…
-
5
votes3
answers66
viewsQ: Class attribute does not generate error when commented
I had a question that I could not solve. Follow the codes of 3 files Php user. class Usuario{ //protected $nome; public function getNome() { return $this->nome; } public function setNome($nome){…
-
4
votes1
answer2947
viewsQ: How to change primary key referencing foreign key to auto increment
I have two tables, one call aluno and another call HistoricoAluno. After creating them, a change was missing which was to leave the primary key of the table alunos as auto_increment. By trying to…
-
6
votes1
answer195
viewsQ: Application of more than one Pattern design
I’ve been studying about Patterns design and I thought it was really cool, but there was one thing I couldn’t understand. Regarding Patterns design, can I apply more than one of them to the same…
-
9
votes2
answers1768
viewsQ: What is and what is php.ini for?
It may be a simple question but I’d like to know what the php.ini and its use for a website/system. If possible, I would like good references (not always the meeting) that can help in the…
-
4
votes1
answer207
viewsQ: Check closed connection
How can I check if a connection has actually been closed? $con = new Conexao(); $con->abrirConexao(); ... $con->fecharConexao(); I use a variable to instantiate the class Conexao which is in…
-
10
votes4
answers1938
viewsQ: Show age in years in php
I would like to pick up through the date information, the age of the person in years: For example: 06/09/1991 --> 24 years 05/12/1998 --> 16 years Suppose I have these dates in php $data1 =…
-
0
votes2
answers89
viewsA: Error when giving spaces between Ivs
Although you can use jQuery, it is better in this case to use css. To give the spacing just use the margin property. It would look like this: .barraca{ margin: 15px; // junto com as propriedades que…
-
3
votes1
answer63
viewsQ: Avoid button click effect without affecting other links
As I can in jQuery, avoid the click effect of a link that has href="#" without affecting the default behavior of other links. Example: I have 3 links <a href="#">Link 1</a> <a…