Questions tagged as 'php'

1
answer

How to use {} instead of opening PHP tags?

I see in several sites of MuOnline, as in others, I see people use instead of <? SERVER_NAME; ?> they use {#SERVER_NAME} , without opening PHP tags. Instead of using <? include("menuLeft.php"); ?> they use {...
asked by 24.07.2015 / 16:36
1
answer

Problem with bindParam - PHP

I'm having problems with bindParam, could anyone help me? I have a code for user registration in the bank ... <?php require_once 'init.php'; // Pega os dados do formulario $nome = isset($_POST['nome']) ? $_POST['nome'] : null; $nascime...
asked by 28.12.2016 / 01:18
1
answer

How does [modus operandi] autoload work in PHP?

Suppose I have the following file structure in the root of my site: index.php autoload.php ----| /Models --------| /MainModel ------------| MainModel.php ----| /Controllers --------| /MainController ------------| MainController.php Suppos...
asked by 04.01.2017 / 20:42
1
answer

Make a DIV appear only at a certain time

For example, I have a certain div, but I want it to appear only from 6 p.m. to 00 p.m. every day, but I have no idea how to do it. <div class="conteudo"> <h1>aqui vai o conteudo da div</h1> </div> I want...
asked by 30.03.2018 / 00:21
1
answer

"Syntax error, unexpected 'if' (T_IF)", even without apparent error

You're giving this error:    Parse error: syntax error, unexpected 'if' (T_IF) in C: \ Program Files \ EasyPHP-Devserver-17 \ eds-www \ Hugg \ sys \ historico.php on line 3 I've been looking for the solution for some time but I can not fi...
asked by 16.04.2018 / 05:57
2
answers

How to get the CPU load from the server

I'm looking for ways to get the server CPU load, previously used scripts where there was the exec() function that on this other server has the function disabled by security. Would there be another way to do this?     
asked by 24.01.2015 / 03:06
2
answers

How to get value from a checkbox

When I submit the form the input does not return the value of checkbox and says $_POST['newsconf'] does not exist. HTML <input type="checkbox" id="newsconf" name="newsconf" value="1"/> <label for="newsconf">...
asked by 31.12.2014 / 23:15
1
answer

Calculate distance between 2 points in Google maps

I do not have much experience with javascript and I have no idea how to get the result of this script and move to a <input text> field. This script calculates the distance and time between two points. So I wanted to take the time an...
asked by 05.02.2015 / 05:07
1
answer

Updating data in SQL

I have a table with the following fields: Nome(VARCHAR) , Email(VARCHAR) , Credito(INT) I wanted to know how, or with what command, to decrease or increase the Credito field. I know you have to use UPDATE b...
asked by 13.12.2014 / 21:10
1
answer

online users and past time on site

How can I get the amount of online users on my site (instantly) using only PHP MYSQL and JQUERY? and respectively get the time the user spent on my site     
asked by 26.12.2014 / 03:41