Posts by Carlos Rocha • 1 point
426 posts
-
0
votes0
answers47
viewsQ: httpresponse resume error
I have the following class: package carcleo.com.radiosingular.classes; import java.io.BufferedReader; import java.io.InputStreamReader; import java.net.URI; import android.os.AsyncTask; import…
-
0
votes2
answers60
viewsA: Error in class object generation
Well, thanks to the efforts of Mr Andrei, who fortunately deleted his reply, I will say here how the solution has turned out and that it can help other colleagues. private ArrayList<Clientes>…
-
-3
votes1
answer128
viewsQ: Failed to add Class objects to the Array List
I have the class below: package carcleo.com.radiosingular.classes; import android.util.Log; import android.widget.Toast; import com.google.gson.JsonArray; import org.json.JSONArray; import…
-
2
votes2
answers60
viewsQ: Error in class object generation
I have the following method: private ArrayList Clientes (JSONObject jObect) { Log.e("Lis: ", jObect.toString()); /* A linha acima impime E/Lis::…
-
0
votes1
answer160
viewsQ: Failed to use Retrofit library in Android Studio
Following the tutorial below, http://www.vogella.com/tutorials/Retrofit/article.html which deals with the use of retrofit library, for testing, I created: One Activity who I called retrofit and a…
-
0
votes2
answers197
viewsA: Get JSON from the URL properly
I found that by adding the código down to the oncreate, the system works properly. if (android.os.Build.VERSION.SDK_INT > 9){ StrictMode.ThreadPolicy policy = new…
-
5
votes2
answers197
viewsQ: Get JSON from the URL properly
I have the following method that gives me one String: public static final String jsonClientes = " {\"clientes\": " + " [" + " { \"idClientesT\": 1," + " \"tipo\":\"s\"," + " \"nome\":\"Carlos\"" + "…
-
2
votes1
answer97
viewsQ: error when receiving JSON from url
Following the answer given to the question: Android: read JSON data Which is exactly the same problem as mine, I arrived in class: package com.example.carlos.radiosingular.classes; import…
-
-1
votes1
answer420
viewsQ: Browse an array of JSON objects in Android Studio
I receive the following JSON link [{"ProdutosidProduto":"1","Produtostipo":"mp","Produtosmodelo":"F540 2 BAN.PNEU. 100 X…
-
-1
votes1
answer157
viewsQ: Error while loading JSON
In the link below, I have a return JSON: http://localhost/hotplateprensas.com.br/Ws/produtos.php is delivering the following return:…
-
0
votes0
answers21
viewsQ: dependency problems!
I’m having problems with libraries and I’m trying to follow this tip below but it’s not working:…
-
2
votes1
answer128
viewsQ: problems with (array) object
I have a array of objects. Ex.: $array = array (1=$obj1, 2=$obj2...ect) Turns out I’m converting these objects in arrays also to have a array of arrays instead of a object array for the purpose of…
-
1
votes1
answer56
viewsQ: (array) $each; and open
I have an array($all) object($each) and the following foreach: foreach ($todos as $cada): $produto[] = (array) $cada; $produtos[] = array( 'idProduto' => $cada->getIdProduto(), 'tipo' =>…
phpasked Carlos Rocha 1 -
0
votes0
answers26
viewsQ: Generating an array properly within a class method
I have a class Products. Within it all attributes are private. Inside it I have the function below: public function getArray($cada) { $produto = array( 'idProduto' => $cada->getIdProduto(),…
phpasked Carlos Rocha 1 -
0
votes1
answer34
viewsQ: JSON Error with Alphabetic Index
I have 2 Arrays: Array ( [0] => Array ( [0] => Amit [1] => [email protected] ) [1] => Array ( [0] => Rahul [1] => [email protected] ) ) and Array ( [0] => Array (…
-
0
votes1
answer47
viewsQ: Convert multi array to json Multi Array
Through a print_r, I am printing the array (object)$all`, and am getting the following array multidimensional: Array ( [0] => Produtos Object ( [idProduto:Produtos:private] => 1…
-
0
votes0
answers32
viewsQ: Stopping system
I got the following form of login: XML <?xml version="1.0" encoding="utf-8"?> <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"…
-
2
votes1
answer148
viewsQ: Different layout for portrait(portraint) and landscape(Landscape)
I got the following: package carcleo.com.cadastro; import android.app.Activity; import android.content.res.Configuration; import android.os.Bundle; public class Principal extends Activity {…
-
0
votes0
answers146
viewsQ: Texts don’t even appear on the button
Good Afternoon! I have the following XML: <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"…
android-studioasked Carlos Rocha 1 -
0
votes2
answers75
viewsQ: Withdraw repeated
I have the following code: var e = Array (10,20,30,40, 50); for (i = 0; i <= 50; i++) { for (j = 0; j < e.length; j++) { if (i == e[j]) document.write ("O numero escolhido é: " + i + "<br…
-
1
votes2
answers557
viewsQ: Know if value is in the unparalleled equality array!
I have the following code in C++: #include <iostream> using namespace std; int main (void){ int e[5] = {10,20,30,40,50}; for (int i = 0; i <= 99; i++){ if ( i in e ) cout << e[i] ; }…
-
0
votes0
answers134
viewsQ: Android emulator does not starta
I’m making a project Android with ionic and cordova but the emulador is not working. I’ve looked through everything and I can’t find the mistake. The emulador just doesn’t open. Note: I am still…
-
0
votes0
answers158
viewsQ: Failed to generate APK
So I’m following this tutorial: http://www.tiagoporto.com/blog/tutorial-de-configuracao-do-ambiente-ionic-android-no-windows/ Which teaches to configure Ionic with Cordova to generate android apk’s…
-
1
votes0
answers20
viewsQ: use . htacces appropriately for links
So, I have in my . htaccess the following condition: RewriteCond %{REQUEST_URI} !.(jpe?g?|png|gif|css|js) [NC] that tells me to release the above extensions in case of the redirect below RewriteRule…
-
1
votes0
answers19
viewsQ: problems with redirecting in . httacess
What do you have to wrong in this code: <ifModule mod_rewrite.c> RewriteEngine on RewriteBase /crud/ RewriteRule ^(.*)$ index.php RewriteCond %{REQUEST_URI} !/manutencao.php$ [NC] RewriteCond…
-
0
votes1
answer25
viewsQ: concatenation error when instantiating PDO
I have the connection PDO with mysql down below: $dsn = 'mysql:host=' . self::$hostname . '; dbname=' . self::$dbname; $opcoes = array(PDO::MYSQL_ATTR_INIT_COMMAND => 'SET NAMES UTF8');…
-
1
votes1
answer45
viewsQ: Class not found on remote server
I have the following file index php. <?php require_once 'global/erros/erros.ini'; require_once 'vendor/autoload.php'; use CLASSES\INIT\Init; new Init(); ?> And the next class Init.php <?php…
-
0
votes2
answers53
viewsA: Finally error with Try Cath
Solution: Class: <?php namespace CONEXAO; ini_set("display_errors",true); ini_set("display_startup_erros",true); error_reporting(E_ALL | E_NOTICE | E_STRICT); use PDO; class Conexao { private…
-
0
votes2
answers53
viewsQ: Finally error with Try Cath
I’m trying to create a classe Statica for conexão at the mysql with PDO but is making a mistake in the line of finally <?php namespace CONEXAO; use PDO; class Conexao { public static $conexao;…
-
0
votes0
answers35
viewsQ: private property Static is getting touched value!
I have the class below: <?php namespace CONSTANTES; class Constantes { private $livre = true; private $util; private $site = array ( "dominio" => "crud.com.br", "www" => "www.crud.com.br",…
-
1
votes1
answer132
viewsQ: how to concatenate array index with your previous one?
I’m trying, inside a classe, create a property that will be populated by an array. The problem is that the second index of this array depends on the value of the first one and would like to…
phpasked Carlos Rocha 1 -
2
votes2
answers218
viewsA: Error in PDO listing
The solution to the doubt was to add use PDO to class Base as below: <?php namespace BASE; use PDO; abstract class Base { ... PDO is a class as well. Therefore, even though it is native, so it…
phpanswered Carlos Rocha 1 -
1
votes2
answers218
viewsQ: Error in PDO listing
I’m trying to learn PDO but I’m having a hard time. I have 3 files: Planos.php <?php namespace PLANOS; use BASE\Base; require_once "Base.php"; class Planos extends Base { public function…
phpasked Carlos Rocha 1 -
2
votes0
answers142
viewsQ: image does not appear by rule in . htaccess
I have my .htaccess in the form below: <IfModule mod_rewrite.c> RewriteEngine on RewriteCond %{REQUEST_FILENAME} -s [OR] RewriteCond %{REQUEST_FILENAME} -t [OR] RewriteCond %{REQUEST_FILENAME}…
-
0
votes1
answer54
viewsA: htdocs change Apache 24 in windows
Okay! I don’t know why. But after the fourth windows reboot Apache updated the DirectoryRoot Thank you all that broke their heads trying to understand the problem!…
-
0
votes1
answer54
viewsQ: htdocs change Apache 24 in windows
I am reading a lot around, including pages in English. But no explanation works. Or it works and something is missing. I’m trying to change the location of the folder htdocs of Apache24 to disk D.…
-
0
votes1
answer102
viewsQ: class does not open
My structure localhost/sistema localhost/sistema/.htaccess localhost/sistema/composer.json localhost/sistema/composer.lock localhost/sistema/composer.phar localhost/sistema/App…
-
0
votes2
answers66
viewsA: Interception and redirection
Although it was a solution that I do not approve of. But what is to be done. There must be a recourse to it. But we’ll know soon. The solution is: <Directory /> AllowOverride All #Require all…
-
0
votes2
answers66
viewsQ: Interception and redirection
My structure localhost/sistema localhost/sistema/.htaccess localhost/sistema/site/index.php Goal: When accessing any url within the domínio occur to interceptação and the redirecionamento to the…
-
1
votes2
answers288
viewsQ: Understanding about MVC
I’m trying to understand the MVC pattern but there are so many videos differently on the web that mess the understanding. I, in turn, am using a pattern of my own. But I would like to know if it is…
-
0
votes1
answer121
viewsQ: namespace php7 does not find url?
I’m trying to learn namespace but I’m having a hard time. Even doing exactly as it is in a video on youtube, but it doesn’t work. I have the project folder Projeto Projeto\Cadastros…
-
1
votes1
answer31
viewsQ: Div does not fit the screen
On the page http://funerariasaopedro.net.br/ I make use of the plugin to the immature https://michalsnik.github.io/aos/ Then the disposition of divs is thus by default <div class="aos-item"…
-
0
votes1
answer28
viewsQ: .Parent() within beforeSend
I have the following code: // JavaScript Document $(document).ready(function(e) { $("a.excluiAdmin").click(function() { if (confirm('Deseja Excluir este Administrador?') ) { var link = $(this);…
-
1
votes1
answer36
viewsQ: take the html of a $('a'). index(this);
A simpler example of what I want would be the following: $(document).ready(function(){ $('a.excluir').click(function(){ var i = $('a').index(this); alert(i); }); }); <script…
jqueryasked Carlos Rocha 1 -
0
votes1
answer114
viewsQ: trade html da li
I have a ajax jquery that will receive the click of a href with a figure within. I wanted to make sure that only during the execution of ajax to image background of li, and not of href was changed…
jqueryasked Carlos Rocha 1 -
1
votes1
answer27
viewsQ: send attr value for $.ajax
I have a link a, that if clicked, leads to a scrpt ajax for the deletion of ID. With the código below I can’t catch the id in page of php // JavaScript Document $(document).ready(function(e) {…
-
3
votes1
answer562
viewsQ: Hidden input fields of html do not come out in $_POST
I have this jQuery // JavaScript Document $(document).ready(function() { $("#contato").on("submit", function () { var formData = new FormData(this); $.ajax({ url: "_requeridos/emailAcompanha.php",…
-
0
votes1
answer110
viewsQ: query the bank with ajax in beforeSend
How to make a bank consultation with ajax in the beforeSend? Example: var formData = new FormData(this); $.ajax({ url: "../_requeridos/cadastraPlano.php", type: 'POST', data: formData, beforeSend:…
-
0
votes1
answer66
viewsQ: plugin creating empty space below HTML when resizes the screen
In the page down below: http://funerariasaopedro.net.br/showroom I’m using the plugin jquery.ez-plus.js. that gives zoom at images. Everything works fine. But when I resize navegador clicking in the…
-
0
votes1
answer88
viewsQ: Address of the namespace
I have the file below that sends authenticated emails normally: <?php ini_set("display_errors",true); ini_set("display_startup_erros",1); error_reporting(E_ALL && E_NOTICE);…