Quantcast
Channel: Ionic Forum - Latest topics
Viewing all 70434 articles
Browse latest View live

Where live demo go?

$
0
0

@arlevi wrote:

Not sure if it’s the right category, but I’ve noticed that the docs changed.
I was wondering, the demo on the side ( the phone demo ) isn’t scrolled together with the docs, so I can’t see the options anymore.
And in many pages - there’s no “phone demo” at all …

Now I need to have a codepen, to copy paste examples from the docs in order to see what it does
Is that going to change back to the way it was ?

Posts: 1

Participants: 1

Read full topic


Windows/UWP hangs on splash screen: Runtime Broker and Com Surrogate process does not closes

$
0
0

@puneet63 wrote:

Hi

We have UWP app running on ionic 3. When we close the app it works fine, we can go inside and do anything in the app.

But once we close the app and open second time. it hangs on splash screen. I can see Run-time broker and Com Surrogate process are still running in task manager.

Can someone help to resolve this issue. We need to debug what JS or cordova plugin is casing this issue?

Regards

Posts: 1

Participants: 1

Read full topic

How to solve cordova issue in DevApp?

$
0
0

@josiasbueno wrote:

There are several days I’m trying to create an app following the official tutorial:


I follow all steps, but, by pressing TakePicure button, receive this alert: Camera issue:cordova_not_available.
This problema occur in DevApp only. Using command “ionic cordova run android --device”, I can take the picture from my smartphone, but the app crashes.
I know this is a old problem, but would to know if is there some resolution.

Posts: 1

Participants: 1

Read full topic

Ionic Deploy update stuck at 95/100

$
0
0

@SimonKomlos wrote:

I have Ionic Pro, and so I’m using Ionic Deploy to update the app without having to download any new update from the app store, but the problem is that recently Ionic isn’t updating the app anymore for ALL my users.

The Ionic deploy download gets stuck at 95/100 and it’s trying to download every time someone tries to open the app… So in just 2 days my Ionic Deploy usage has already hit 8500/10000… This is crazy.

I think it must be an Ionic issue as I haven’t touched any code relating to deploy. And it was working perfectly and then just randomly broke.

Any ideas? Are others having this issue?

Posts: 1

Participants: 1

Read full topic

iOS app & windows

$
0
0

@martindd wrote:

Hi,

I just started using Ionic and I am confused about iOS

  1. https://ionicframework.com/docs/installation/ios - This page says that “Unfortunately, iOS apps can only be created on macOS”; my app does run on iOS, but I tried hiding the Status Bar by setting this.statusBar.overlaysWebView(true); and it doesn’t work - is that because I’m building on Windows?

  2. Is there a workaround or will I actually have to get a Mac to be able to develop native functions?

Thanks
Martin

Posts: 1

Participants: 1

Read full topic

Ionic 4 HTTP error

$
0
0

@davidsancho44 wrote:

Hello I am trying to make a request get with HTTP but it does not enter me in data.data tells me undefined, can you help me? Thank you!

It is entering the error.error

The api code is missing, I do not publish it.

import { IonicModule } from '@ionic/angular';
import { RouterModule } from '@angular/router';
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { FormsModule } from '@angular/forms';
import { Tab1Page } from './tab1.page';
import { HTTP } from '@ionic-native/http/ngx';


@NgModule({
imports: [
IonicModule,
CommonModule,
FormsModule,
RouterModule.forChild([{ path: '', component: Tab1Page }])
],
 declarations: [Tab1Page]
})
export class Tab1PageModule {
 constructor(private http: HTTP) {
this.http.get('http://api.openweathermap.org/data/2.5/forecast?zip=94040,us&appid=', {}, {})
.then(data => {

  console.log(data.status);
  console.log(data.data); // data received by server
  console.log(data.headers);

})
.catch(error => {

  console.log(error.status);
  console.log(error.error); // error message as string
  console.log(error.headers);

});
 }
}

This is the error:

error

The json returns this to me:

api

Posts: 1

Participants: 1

Read full topic

Problem with ion-item and click at ios

$
0
0

@ndblackandblue wrote:

Hi everyone, can someone help me with this, i have a aplication with a side menu, and if user click in this menu and his photo, its gonna show a editPage, but for some reason in IOS, only left side from ion-item work with click.

index

In this image from example, only side with name “Pedro” work, the another side dont work … only in ios:

<ion-item (click)="goToEditProfile()" no-lines menuClose text-center class="sidemenu-header-item">
	<ion-avatar>
		<img class="profile-picture" [src]="...">
	</ion-avatar>
		<p style="padding-top: 2vh;">Pedro Vitor (Admin)</p>
</ion-item>

Posts: 1

Participants: 1

Read full topic

Built in Google Map not rendering

$
0
0

@bbredstang wrote:

Good evening all. I am new to Ionic and am blown away already!

I followed the tutorial to enable Google Maps within a new app, however when I go to the Preview pane it is completely blank where the map should be. I setup a new project within the Google Cloud Platform, with a new API key, and ensured that both Android, iOS, and JavaScript is enabled.

To that end, the tutorial is extremely straightforward so I am not sure where things could have gone wrong. Any thoughts from the community?

Here is the Preview Pane
Blank

Here is the Design Pane
Design%20View

Posts: 1

Participants: 1

Read full topic


Ionic 4 DateTime Picker doesn't show the local time

$
0
0

@abhijitmabhi wrote:

<ion-datetime displayFormat=“DD-MM-YYYY” [(ngModel)]=“todo.myDate”></ion-datetime>

Ionic 4 DateTime picker shows the GMT time. But my local time is GMT+6. I’m not getting the exact time.

Posts: 1

Participants: 1

Read full topic

Select text in texarea

$
0
0

@amin9 wrote:

There are many question/posts regarding this issue. Some are resolved in ionic1.
I don’t see any good solution on ionic 2 or 3.

I built a NotePad type app and published it.
Then I noticed,
Cannot select text in the textarea, cannot copy or paste in the textarea. My app became useless.

I was trying to follow https://forum.ionicframework.com/t/how-to-make-text-selectable/4384

Tried - 1 CSS
-webkit-user-select: text;
-moz-user-select: text;
-ms-user-select: text;
user-select: text;

Tried - 2 JS
Cannot fine “ionic.js”

Is it possible to select text in the textarea?

Posts: 1

Participants: 1

Read full topic

Ionic 4 custom styling of components

$
0
0

@dulciepercy wrote:

I’ve nearly converted my app to Ionic 4 but I can’t understand how to customize components (been through every link and tutorial on the forum, but something hasn’t got through to me).

I have many popovers in the app. The first is called “how to read” with the following selectors

@Component({
  selector: 'app-how-to-read',
  templateUrl: './how-to-read.page.html',
  styleUrls: ['./how-to-read.page.scss'],
})

I’ve got some styling in app-how-to-read.page.scss which work fine on my classes…

    td {
            padding: 10px;
            text-align: left;
            font-size: 15px;
       } 
   .myButtons {
   font-size: 20px;
   font-weight: 200;
   width: 100%;
   }

But now I want to change the size and background of the popover. The css CustomProperties of the popover page https://ionicframework.com/docs/api/popover#properties

just says, for the background for example, use --background.

But where do I put it? Do I put something like

app-how-to-read{
    --background:green;
  }

in the scss file, or in variables.scss? I’ve tried both with many versions of the selector to no avail.

Thanks

Posts: 1

Participants: 1

Read full topic

How to resize rating star

PositionError {code: 1, message: "Only secure origins are allowed ionic3?

$
0
0

@RomnEmpire wrote:

hi,
I’m creating an app in ionic3 that needs to access get current location of the user and load the google map in page but i got the position error in the chrome console :

‘PositionError {code: 1, message: "Only secure origins are allowed?’

i have tried below link but working:

below we have upload our index.html as well as ts function with the help of which we have to load the map.please tell me anyone how to fix this error ?0

<!DOCTYPE html>
<html lang=“en” dir=“ltr”>
<head>
<meta charset=“UTF-8”>
<title>Ionic App</title>
<meta name=“viewport” content=“viewport-fit=cover, width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no”>
<meta name=“format-detection” content=“telephone=no”>
<meta name=“msapplication-tap-highlight” content=“no”>

<link rel=“icon” type=“image/x-icon” href=“assets/icon/favicon.ico”>
<link rel=“manifest” href=“manifest.json”>
<meta name=“theme-color” content="#4e8ef7">

<!-- add to homescreen for ios -->
<meta name=“apple-mobile-web-app-capable” content=“yes”>
<meta name=“apple-mobile-web-app-status-bar-style” content=“black”>
<!-- cordova.js required for cordova apps -->
<script src=“http://maps.google.com/maps/api/js?key=YOUR_API_KEY_HERE”></script>
<script src=“cordova.js”></script>

<!-- un-comment this code to enable service worker
<script>
if (‘serviceWorker’ in navigator) {
navigator.serviceWorker.register(‘service-worker.js’)
.then(() => console.log(‘service worker installed’))
.catch(err => console.error(‘Error’, err));
}
</script>–>

<link href=“build/main.css” rel=“stylesheet”>

</head>
<body>

<!-- Ionic’s root component and where the app will load -->
<ion-app></ion-app>

<!-- The polyfills js is generated during the build process -->
<script src=“build/polyfills.js”></script>

<!-- The vendor js is generated during the build process
It contains all of the dependencies in node_modules -->
<script src=“build/vendor.js”></script>

<!-- The main bundle js is generated during the build process -->
<script src=“build/main.js”></script>

</body>
</html>
Run code snippetExpand snippet

    loadMap(){ 
         this.geolocation.getCurrentPosition().then((position) =&gt; { 
       let latLng = new google.maps.LatLng(position.coords.latitude, position.coords.longitude); 
         let mapOptions = { 
            center: latLng, 
            zoom: 15, 
            mapTypeId: google.maps.MapTypeId.ROADMAP 
     } 
    this.map = new google.maps.Map(this.mapElement.nativeElement, mapOptions); 
  }, (err) =&gt; { 
      console.log(err); 
 });   
}

Posts: 1

Participants: 1

Read full topic

Ngx-translate on new lazy page in Ionic 4

$
0
0

@Kypez wrote:

Dear forum members,

i am new to ionic 4 and did not use angualr and ionic since ionic1. I have one beginner question and would be very thankful if soeone could give me a hint on what i am overlooking.

I am using angular 7 and ionic 4 for my application and want to make on multilanguage on buttonclicks. For this purpose i tried the ngx-translate module: http://www.ngx-translate.com/. If i make the tutorial and create a new angular application everything works.

It even works in my ionic application, but only if i translate text chunks in the app.component.html According to the instructions i have to importy and modify app.module.ts and app.component.ts.

However, i want to translate some text in other pages then the app.componen.html. There are a lot of pages and they are all lazy loaded.

What am i doing wrong at this stage? What do i need to import in other pages in order to translate text there? My example page is “tab1” page. I have imported import { TranslateService } from ‘@ngx-translate/core’; in the tab1.module.ts But if i try to translate ion-card-title>

demo.text

on buttonclick nothing happens and the resource from json in the default language is not loaded.

My second question considers the imported “HttpClientModule” and the “HttpModule”. Why does the ngtx-translate docu suggests to import HttpClientModule and the ionic docu suggests to import HttpModule? What is the difference anyway?

Thank you a lot in advane.

Kind Regards

D. Petrik

Posts: 1

Participants: 1

Read full topic

Bug : ionic v4 ranger ionBlur Event not work correctly

$
0
0

@ebeliejinfren wrote:

Hi
i use ionic Ranger for music time bar and use ionBlur on ion-range for update music current time , in ionic 3 its work correctly but in new version it’s not Emitted

ionChange work good but ionBlur not fired

Posts: 1

Participants: 1

Read full topic


Event deviceready: how it works?

$
0
0

@bitkorn wrote:

I have to wrap ScreenOrientation and Device (for AndroidPermissions) into the deviceready event. But deviceready is never fired.

Apart from the deviceready event, my app works as expected. And I use the native function BarcodeScanner and have several views that consume a REST API.

My “not working” code at first.

app.component.ts

import { Device } from '@ionic-native/device/ngx';
import { ScreenOrientation } from '@ionic-native/screen-orientation/ngx';
import { AndroidPermissions } from '@ionic-native/android-permissions';

  constructor(private device: Device, private screenOrientation: ScreenOrientation, private androidPermissions: AndroidPermissions) {
    document.addEventListener('deviceready', this.onDeviceReady, false);
  }

  onDeviceReady() {
    console.log('device is ready');
    this.screenOrientation.lock(this.screenOrientation.ORIENTATIONS.PORTRAIT_PRIMARY);

    if (this.device.platform == 'Android') {
      console.log(this.device.platform);
      this.androidPermissions.checkPermission(this.androidPermissions.PERMISSION.INTERNET).then(
        result => console.log('Has permission?', result.hasPermission),
        error => this.androidPermissions.requestPermission(this.androidPermissions.PERMISSION.INTERNET)
      );
    }
  }

The function onDeviceReady() is never called.

ionic info

Ionic:

   ionic (Ionic CLI)  : 4.10.1 (/usr/lib/node_modules/ionic)
   Ionic Framework    : ionic-angular 3.9.2
   @ionic/app-scripts : 3.2.0

Cordova:

   cordova (Cordova CLI) : 8.1.2 (cordova-lib@8.1.1)
   Cordova Platforms     : android 7.1.1, browser 5.0.4
   Cordova Plugins       : cordova-plugin-ionic-keyboard 2.1.3, cordova-plugin-ionic-webview 2.1.4, (and 9 other plugins)

System:

   Android SDK Tools : 26.1.1 (/opt/google/android/sdk)
   NodeJS            : v8.15.0 (/usr/bin/node)
   npm               : 6.7.0
   OS                : Linux 4.15

How do you implement it correctly?
Why is deviceready not fired with my code?

Posts: 4

Participants: 2

Read full topic

ModalController detail page navigation

$
0
0

@Eraldo wrote:

When clicking on an item in my modal page, I want to open the detail page for the item.
If I try doing this by using NavController, but then the page gets navigated to in the background (behind the modal background) while the modal stays on top.

I guess the current behaviour also makes sense, since the navController uses the current non modal outlet.

How can I manage to “push” the detail page on top (either completely above the modal – or if not possible that way, at least pushing it on top of the modal nav stack.

Context: Ionic 4 with lazy loading

Ideas? Solutions?

Posts: 1

Participants: 1

Read full topic

Rtl in Ionic4

Local notification every 5 minutes

$
0
0

@ahmadklsany wrote:

hello every one
i have problem when i use local notification every 5 min but no notification get so where is the problem here:


             this.localNotifications.schedule({
                  text: ' anything  ',
                   trigger: { every: { minute: 1 }, count: 500 }, => not working 
                   // trigger: {at: new Date(new Date().getTime() + 3600)}, => work fine 
                   led: 'FF0000',
                   sound: null
               });

thanks so much

Posts: 1

Participants: 1

Read full topic

Social share whatsapp

$
0
0

@hanane11 wrote:

hello I use the plugin SocialSharing ionic 3 it works well, but I want to send messages by whatsapp automatically without opening whatsapp, click on the button nothing is displayed but the message is sent.

 this.socialSharing.shareViaWhatsApp(this.text, null).then(() => {
      console.log('success');
    }).catch((e) => {
      console.log('erreur');
    });
  }

Posts: 1

Participants: 1

Read full topic

Viewing all 70434 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>