Posts by Giancarlo Abel Giulian • 3,999 points
173 posts
-
0
votes1
answer178
viewsA: Make ajax request with user IP
Following example: $('#enviar').click(function () { $.ajax({ method: "GET", url: "http://ip-api.com/json" }).success(function (msg) { $.ajax({ method: "POST", url:…
-
-2
votes2
answers586
viewsA: Error trying to use isset in Javascript
if ((n1 != undefined) && (n2 != undefined)){ // Resto do código após verificar se ambas as variáveis estão ou não vazias } Or I’d rather trade the undefined for null in some situations,…
-
2
votes1
answer55
viewsA: Receive array values
foreach( $_POST['Item']['IDCatalogo']['IDItem'] as $key => $n ) { print "<p>".$n." | ".$key."</p>"; } I hope it helps you.
-
8
votes2
answers678
viewsQ: Mixing Javascript libraries in a project
I wonder if it is not good practice to load several different Javascript libraries in one application. For example, the project has an X deadline for delivery, but should be done in Angularjs but…
-
0
votes0
answers39
viewsQ: Randomization of IVD classes in Google?
Today I entered Developer Mode on a Google website from Chrome by pressing F12 and I noticed that the classes of divs are totally different compared to what you’ve seen before. Usually a name is…
-
1
votes2
answers87
viewsA: Slide in jquery with div, containing image and content
I use this library in the projects: https://github.com/blueimp/jQuery-Image-Gallery I hope it will be useful for you…
-
4
votes3
answers579
viewsA: Programming for the interface means programming for a super-type, why?
Interface is an object orientation resource used in Java that defines actions that must be executed, but each class can perform differently. As an example: We have the abstract class Veículo and the…
-
4
votes3
answers302
viewsA: Access web images application
You can create a AsyncTask to load images asynchronously. See the codes below for how to do: private class FetchImageTask extends AsyncTask<String, Integer, Bitmap> { @Override protected…
-
3
votes1
answer495
viewsA: Change script to show video in Html5
Search for tutorials that teach how to run videos in HTML 5. <video controls> <source src="foo.ogg" type="video/ogg"> <source src="foo.mp4" type="video/mp4"> Seu navegador não…
-
1
votes1
answer1103
viewsA: How to remove a Tlistbox selection
Enough at the event OnExit() from your Listbox you make the following code: ListBox1.ClearSelection;
delphianswered Giancarlo Abel Giulian 3,999 -
0
votes2
answers1501
viewsA: How to get JSON from an external url
From what I observed in your code there is a comma (,) right after the closure of the success in your call AJAX, in the code below removed the comma, note: $.ajax({ type: 'GET', url:…
-
1
votes1
answer46
viewsA: Application returns null when instantiating custom component
Solved, it goes to those who have the same problem regarding null instantiation: The second problem was in the method onCreate of the component, where it was necessary to pass two parameters in the…
-
1
votes1
answer46
viewsQ: Application returns null when instantiating custom component
Good night. I need to make a component AutoCompleteTextView search the information directly from the server and for this I am following the following article:…
-
1
votes2
answers3513
viewsA: How to run an application with Database on Android?
Example of creating a database on Android using Sqlite: public class FeedReaderDbHelper extends SQLiteOpenHelper { // If you change the database schema, you must increment the database version.…
-
0
votes1
answer534
viewsQ: How to get markers close to the user’s location?
Good night Anyone who knows the Tinder app knows that a map is not shown, but knows that it takes the user’s location and uses it to look for people who are close in a certain radius. I would like…
-
5
votes1
answer190
viewsA: Components of the Spring MVC Framework
Spring MVC is not a framework that works with front-end like the ones you mentioned, follows definition found in Wikipedia: Spring is an open source framework for the Java platform created by Rod…
-
4
votes2
answers8705
viewsA: Compare items from different tables
Since the ID of both tables are equal, you can do the following: SELECT a.Nome FROM Pessoa1 a JOIN Pessoa2 b ON a.Id = b.Id; Or exchange the Id for the Name, but the result would be the same and the…
-
1
votes4
answers2514
viewsA: Is there a difference between the is_file and file_exists function?
Documentation of the methods: file_exists() - Checks if a file or directory exists is_file() - Informs if the file is a common file (not directory) References:…
phpanswered Giancarlo Abel Giulian 3,999 -
0
votes1
answer59
viewsQ: Skip User registration activities already logged in the application
Good afternoon. I wish I knew the best way to jump Activities of registration when initializing the application on Android when the user is already registered in the application, as occurs on…
-
1
votes1
answer384
viewsA: Websocket with PHP using IIS 8.0 server
Solved. In the archive php.ini I’ve cracked the following line: ;extension=php_sockets.dll And I restarted the IIS server and when running the PHP script it started running. If you do not have the…
-
1
votes1
answer384
viewsQ: Websocket with PHP using IIS 8.0 server
Good morning. Next, I downloaded the following project as an example to create a Websocket: http://www.nhatanh.net/blog/websocket-php-html5-tutorial-echo-server.html Testing on a machine with Linux…
-
4
votes1
answer9504
viewsQ: Creating tabs the right way on Android currently
I’m trying to implement in the app I’m creating Tabs, like this: But always when I try to implement I face classes and methods deprecated, as an example, TabListener, ActionBarActivity and now I’m…
-
2
votes2
answers427
viewsQ: What is the sequence of executions for Asynctask?
I need to synchronize data between the server and client application on Android and for this I created several classes ASyncTask, one synchronizes the Third Party, the other the Financial,…
-
1
votes2
answers1538
viewsA: sum of values with ng-repeat
Remove double quotes from the commission value attribute, did it work? Angularjs, as well as other frameworks and Javascript, recognize double quotes as a String and not a numerical value for…
-
0
votes0
answers497
viewsQ: Fix position of Relativelayout in Activity
Good afternoon. I want to fix the position of two RelativeLayout on the screen, but when the user changes the text of the TextSwitcher the RelativeLayout the one it belongs to increases in size, and…
-
2
votes1
answer76
viewsQ: Pretend the device doesn’t have GPS
I wonder if there is any way to "cheat" the device during debug by saying that it has no GPS. I don’t want to just disable, otherwise during development the GPS will be found. I have the purpose of…
-
2
votes2
answers4140
viewsA: Catch user city with IP
Link: http://ip-api.com/json Documentation: http://ip-api.com/docs/api:json Example: { "status": "success", "country": "United States", "countryCode": "US", "region": "CA", "regionName":…
phpanswered Giancarlo Abel Giulian 3,999 -
1
votes1
answer44
viewsA: Correctly exchange text using Textswitcher
I managed to solve the problem, the following was done: I implemented the interface OnGestureListener package android.view.GestureDetector and used two main methods to make the logic: @Override…
-
2
votes1
answer44
viewsQ: Correctly exchange text using Textswitcher
I need to use a component TextSwitcher with the intention that when the user moves this TextSwitcher to the right as well as to the left the text of the same. For this I created a variable of type…
-
9
votes4
answers13678
viewsQ: Rounding a decimal to a lower decimal
Using Javascript how can I round a decimal number with several decimal places to a number with two decimal places being the lowest decimal number? Example: 44,97714285714286 To 44,97 I’ve used the…
-
1
votes1
answer79
viewsQ: Google Cloud Messaging and Synchronization Standardization
I am building a project that will use Google’s GCM, something new in my projects, and I would like to know the following. At the time the user makes his registration who will request the first data…
-
2
votes0
answers141
viewsQ: Send data from the app with locked cell screen to the server using voice command
Good afternoon. I wonder if there is a way to create a service in my application where when the user said something you take the content of what he said and send it to the server, but with the cell…
-
9
votes1
answer6033
viewsQ: Using @Supresswarnings in Java
Good morning. Until when it is recommended to use the annotation @SuppressWarnings to hide a Warning of a certain problem that the compiler finds in your code and show that you know what you’re…
-
3
votes3
answers1332
viewsA: Run functions without the Jquery click event
Would solve the problem you mentioned using the onkeypress event in input or from jQuery with the keypress method if it is empty or not empty, example: HTML: <input type="text" id="inputText">…
-
5
votes2
answers176
viewsA: Retrieve data/text from other websites with PHP
Yes, usually these sites create Apis for other sites to pick up information by using Web Services. I found this API that returns the rating of a series or movie: http://www.omdbapi.com/ Usually…
phpanswered Giancarlo Abel Giulian 3,999 -
0
votes2
answers570
viewsA: List of all installed applications
Following the code to get the list of activities/apps installed on Android: final Intent mainIntent = new Intent(Intent.ACTION_MAIN, null); mainIntent.addCategory(Intent.CATEGORY_LAUNCHER); final…
androidanswered Giancarlo Abel Giulian 3,999 -
0
votes3
answers104
viewsA: How to place an image on the website via link
You can pass a path from the server directories to the image or directly to the image URL, for example: Way in the HD: <img src="C:/imagem.jpeg" alt="imagem" /> URL of the internet: <img…
-
0
votes0
answers234
viewsQ: Rendering HTML with AJAX call using PHP and MVC concept
Good night. I usually use the MVC (Model-View-Controller) standard in projects, independent of the programming language. In PHP the directory structure looks like this: - assets - css - js - img -…
-
3
votes2
answers975
viewsA: Database connection error
Utilize Msqli Documentation: http://php.net/manual/en/book.mysqli.php
-
1
votes2
answers1472
viewsA: how to know if the date is of the date type yyyy-mm-dd, dd/mm/yyyy etc?
Another way using regular expressions: $variations = array ( '^([0-9]{4})/[0-9]{2}/[0-9]{2} [0-9]{2}:[0-9]{2}:[0-9]{4}2$' => 'Y/m/d H:i:s', // Mais outras expressões regulares aqui ); foreach…
phpanswered Giancarlo Abel Giulian 3,999 -
8
votes2
answers2404
viewsA: Calculate mathematical expression in string
Using the Eval method. calc = eval("7*2+1/2"); Another example: var x = 10; var y = 20; var a = eval("x * y") + "<br>"; var b = eval("2 + 2") + "<br>"; var c = eval("x + 17") +…
-
1
votes3
answers290
viewsA: How to fix this function, if I type something appears the same thing when I type nothing
As it turned out: <!DOCTYPE html> <html> <head> <title>Atividade 02</title> <meta charset="utf-8"> </head> <body> <form name="form1" id="form1"…
javascriptanswered Giancarlo Abel Giulian 3,999 -
1
votes4
answers9996
viewsA: Modal Bootstrap on Modal by JS
Yes, you can open a modal over another one using Javascript. See this example: http://www.bootply.com/86958 HTML: <a data-toggle="modal" href="#myModal" class="btn btn-primary">Launch…
-
2
votes1
answer672
viewsA: Remove Registration in jQuery
Example deleting a record: Javascript: $(document).on('click', '.delete-btn', function(){ if(confirm('Are you sure?')){ // Pega o id var product_id =…
-
2
votes2
answers81
viewsA: App with Maps
Check out the Google Maps API documentation for Android: https://developers.google.com/maps/documentation/android/…
-
0
votes1
answer34
viewsA: In Eclipse how do I add Packages to be imported later and use them?
Right-click on your project > New > Other > Search by package > Select Package and click Next > Put the package name, example: br.com.example.package. Click on Finish. Is that it? I…
eclipseanswered Giancarlo Abel Giulian 3,999 -
3
votes4
answers18668
viewsQ: Javascript money format with Angularjs and jQuery
Good morning, everyone. Next, I need to make when the user leaves with the focus of the field or when typing it format this field according to the format of money, first in the Brazilian format.…
-
1
votes2
answers2330
viewsA: Registration lock
This process is known as Deadlock. Check out the Mysql documentation, I hope this link helps you as well as other people: https://dev.mysql.com/doc/refman/5.5/en/innodb-lock-modes.html A shared lock…
mysqlanswered Giancarlo Abel Giulian 3,999 -
0
votes2
answers1998
viewsA: Installation of Android studio on Ubuntu
Download the . DEB file on this site: https://paolorotolo.github.io/android-studio/ Enter the directory by Terminal and execute the following command(s) (s), then inform the password to execute as…
-
4
votes3
answers19925
viewsA: Firebird, native date format function
Firebird does not have a date-ready function. I believe you can create a precedent that returns a formatted date.Follow a SELECT to return the date in the dd/MM/yyyy format. SELECT CAST(EXTRACT(DAY…
firebirdanswered Giancarlo Abel Giulian 3,999