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

How can i load media files like instagram and facebook

$
0
0

@VigneshBalakrishnan wrote:

Hi all,
I’m creating a social application where users can upload their images, videos and audio. And i’ll load the media files from s3 through URL. Now i want to make the user experience better so I’m thinking of making it like instagram and facebook. When the media file is big or network is down to show a loader.
Can any one help me, Thanks in advance.

Posts: 1

Participants: 1

Read full topic


iOS code signing not working anymore

$
0
0

@Thilo1992 wrote:

Hello,

I’ve recently tried to install the cordova-plugin-wifiwizard2 plugin but it failed on the Mac I’m using for iOS builds. I’ve then replaced the plugin folder with the one from another PC where I could successfully install the update.

But since this change the code signing doesn#T work anymore, giving me following error message: “App name” requires a provisioning profile with the Hotspot Configuration, Access WiFi Information, and Network Extensions features.

I’ve then tried different settings for automatic signing, but nothing did work. So I’ve created a new provisioning profile for manual signing but this also did not work even though that features wherer listed at the Enabled Capabilities.

Since nothing did work, I’ve removed the iOS platform, updated cordova and re-added the platform. Then I’ve created new certificates and provisioning profiles for the app to use with the new platform. Now I’m getting a different error when trying to select the profile for manual signing: Provisioning profile “profile name” doesn’t include signing certificate “certificate name”
But the new certificates are included and the old ones has been revoked.

Can anybody help me? It already took me many hours.

Cordova: 8.0.0
Xcode: 10.1

Thanks in advance

Thilo

Posts: 1

Participants: 1

Read full topic

Embedding a component on an external web site

$
0
0

@conexcol wrote:

Hi, we have a pwa (ionic4+angular8) and we would like to be able to embed a single component on external sites. The component uses parts of the whole application to produce a card. We would like that card to be shown on any external website and when clicking on it take the user to our app.

What is the best way to embed a component inside an external webpage?

Thanks!

Posts: 1

Participants: 1

Read full topic

Angular Element + cordova

$
0
0

@NurGuz wrote:

Hello guys,

I am testing from an android device.

when I add to my IONIC application a WebComponent generated with Angular Elements and proceed to check if the platform is cordova, it doesn’t work.

This is because if I add a webcomponent it no longer recognizes cordova as a platform. But if I remove the webcomponent, if cordova recognizes me

Posts: 1

Participants: 1

Read full topic

Appflow + capacitor : iOS Package fails

$
0
0

@DFull wrote:

Hi,

Is appflow compatible with capacitor.
I have tried the following steps :

  • ionic start laCap tabs --capacitor
  • Commit on github
  • npm install --save @capacitor/core @capacitor/cli
  • npx cap init labCap com.arasolutions.labcap
  • Commit on github
  • ionic build
  • npx cap add ios
  • add ios certificate in appflow
  • build IOS

The logs ends with :

capacitor init labCap io.ionic.starter --npm-client npm
[12:52:53]: ▸ ? capacitor.config.json already contains cordova preferences. Overwrite with val

‘io.ionic.starter’ is weird because this is not my bundle ID

app ID : fc40254a / build ID : 6807586

Any idea ?

Posts: 1

Participants: 1

Read full topic

Cordova-plugin-firebase issues with ios

$
0
0

@nishamane wrote:

I have created iOS build for my ionic4 app having Cordova version 9.0.0. When I installed cordova-plugin-firebase and build the code with ionic cordova buld ios command, build failed with following error :
The following build commands failed:
CompileC /Users/devbis365/Library/Developer/Xcode/DerivedData/DriversApp-hcwntjbscgtzpvdriulszbasewep/Build/Intermediates.noindex/DriversApp.build/Debug-iphonesimulator/DriversApp.build/Objects-normal/x86_64/FirebasePlugin.o /Users/devbis365/Documents/DriveraAPP/testDrivers/Drivers/platforms/ios/DriversApp/Plugins/cordova-plugin-firebase/FirebasePlugin.m normal x86_64 objective-c com.apple.compilers.llvm.clang.1_0.compiler
(1 failure)

Any ideas.??

Posts: 1

Participants: 1

Read full topic

Loading post from Wordpress category (Api Rest V2)

$
0
0

@interartivity wrote:

Hi,

I’m testing Ionic with Wordpress and I’m loading all posts from my web with this service code:

export class WordpressService {
 
  url = `https://mydomain.com/wp-json/wp/v2/`;
  totalPosts = null;
  pages: any;
 
  constructor(private http: HttpClient) { }
 
  getPosts(page = 1): Observable<any[]> {
    let options = {
      observe: "response" as 'body',
      params: {
        per_page: '5',
        page: ''+page
      }
    };
 
    return this.http.get<any[]>(`${this.url}posts?_embed`, options).pipe(
      map(resp => {
        this.pages = resp['headers'].get('x-wp-totalpages');
        this.totalPosts = resp['headers'].get('x-wp-total');
 
        let data = resp['body'];
 
        for (let post of data) {
          post.media_url = post['_embedded']['wp:featuredmedia'][0]['media_details'].sizes['medium'].source_url;
        }
        return data;
      })
    )
  }
 
  getPostContent(id) {
    return this.http.get(`${this.url}posts/${id}?_embed`).pipe(
      map(post => {
        post['media_url'] = post['_embedded']['wp:featuredmedia'][0]['media_details'].sizes['medium'].source_url;
        return post;
      })
    )
  }
}

It’s working fine (load posts, featured images and parse HTML text) but I need to load posts from one category only.

Any ideas?

Thanks in advance :wink:

Posts: 2

Participants: 2

Read full topic

How to get notification in notification bar on device when it receives the notification as foreground

$
0
0

@Zagrev wrote:

I am using the plugin with cordova-plugin-with-dependecy-updated.
But the notification is shown on notification bar when the app is in background or closed.
I wanna to get the notification in regardless the app is in foreground or background

Posts: 1

Participants: 1

Read full topic


Popover width auto

Error fileopener

How to pass data from page to modal in ionic 4 app?

$
0
0

@Sweg wrote:

In my ionic app, I am trying to navigate from a page to a modal, & display some data which I passed to the Modal.

Below I am creating an ActionSheet & assigning a button to display the modal:

this.actionSheet.buttons = [
{
          text: 'View all comments',
          handler: () => {          
            this.modalCtrl.create({
              component: CommentsPage,
              componentProps: {
                'post': post
              }
            }
            ).then(modal => {
              this.modal = modal;
              modal.present();
            });
          }
        }
];

The modal successfully appears with blank code like so:

export class CommentsPage implements OnInit {
  post: any = {};
  constructor() { }
  ngOnInit() {
  }
}

But I want to get the post data which I added to the componentProps inside the ModalController.

I tried to retrieve this using ActivatedRoute below, but am getting this error:

Property ‘activatedRoute’ does not exist on type ‘CommentsPage’.ts

export class CommentsPage implements OnInit {
  post: any = {};
  constructor(activatedRoute: ActivatedRoute) { }
  ngOnInit() {
    this.post = this.activatedRoute.snapshot.paramMap.get('myid');
  }
}

Am I passing the post value correctly? If so, how can I use that value inside the modal?

Posts: 1

Participants: 1

Read full topic

Ionic 4: Video Upload Error

$
0
0

@MaheshKarumuri wrote:

Hello there,

I’m developing an application using Ionic with Angular Framework. In my application, I need to capture a video and upload it to a server. For that, I’m using media-capture plugin for capturing video and file transfer plugin.

Here is the code that I’m using it for capturing and uploading it to a remote server:

// Capturing Video 
captureVideo() {
    let options: CaptureVideoOptions = { limit: 1 }
    this.mediaCapture.captureVideo(options)
      .then((videoData: MediaFile[]) => {
        var i, path, len;
        for (i = 0, len = videoData.length; i < len; i += 1) {
          path = videoData[i].fullPath;
        }
        this.videoPath = path;
        console.log(this.videoPath);
      })
      .catch((err: CaptureError) => err)
  }

// Uploading Video
uploadVideo() {

    var options: FileUploadOptions = {
      fileKey: "videos",
      fileName: 'sample.mp4',
      chunkedMode: false,
      mimeType: "video/mp4"
    }

    var params: any = {};
    params.typeOfItemGroup = "SPACE";
    params.itemGroupName = "Kitchen";
    options.params = params;

    console.log("options: ", options);

    this.videoFileUpload = this.fileTransfer.create();

    this.videoFileUpload.upload(this.videoPath, 'localhost:8081/api/v1/shield/camera/video/5e706f96b5587e5e6776614f', options)
      .then((data) => {
        console.log("Data: " + data);
      })
      .catch((err) => {
        console.log("Error in upload: ", err);
      });
  }

The Error I’m getting is:

I’m not able to figure it out the code: 2 error.

For Backend It’s working fine as below:

Do you have any suggestions what I can do?

Thanks,
Karumuri

Posts: 1

Participants: 1

Read full topic

Question about capacitor and Android Studio

$
0
0

@srterry wrote:

I’ve created a project using Ionic and Capacitor. Used npx cap init and set an AppName and AppID. My problem is that when I use npx cap open android, the first time it opens but, when I change something and I open it again, it is like the changes don’t apply, it always open like a “cache project”, how can i solve this?

Using ionic serve

enter image description here

Using ionic capacitor open android

enter image description here

It is same project. But project doesnt update on android studio

Posts: 2

Participants: 2

Read full topic

Ionic Cordova running on one android device, but not on another

$
0
0

@Sweg wrote:

I am able to run my ionic 4 app on my own device by running ionic cordova run android.

However, I’m now trying to use it on another older android device, so I can do some testing.

When I connect the older device & run the same command above, I’m getting the following logged to the console:

Preparing Firebase on Android
Checking Java JDK and Android SDK versions
ANDROID_SDK_ROOT=undefined (recommended setting)
ANDROID_HOME=C:\Users\damie\AppData\Local\Android\sdk (DEPRECATED)
Subproject Path: CordovaLib
Subproject Path: app

Configure project :app
WARNING: Configuration ‘compile’ is obsolete and has been replaced with ‘implementation’ and ‘api’.
It will be removed at the end of 2018. For more information see: http://d.android.com/r/tools/update-dependency-configurations.html
WARNING: API ‘variant.getAssemble()’ is obsolete and has been replaced with ‘variant.getAssembleProvider()’.
It will be removed at the end of 2019.
For more information, see https://d.android.com/r/tools/task-configuration-avoidance.
To determine what is calling variant.getAssemble(), use -Pandroid.debug.obsoleteApi=true on the command line to display a stack trace.
WARNING: API ‘variantOutput.getProcessResources()’ is obsolete and has been replaced with ‘variantOutput.getProcessResourcesProvider()’.
It will be removed at the end of 2019.
For more information, see https://d.android.com/r/tools/task-configuration-avoidance.
To determine what is calling variantOutput.getProcessResources(), use -Pandroid.debug.obsoleteApi=true on the command line to display a stack trace.
WARNING: API ‘variantOutput.getProcessManifest()’ is obsolete and has been replaced with ‘variantOutput.getProcessManifestProvider()’.
It will be removed at the end of 2019.
For more information, see https://d.android.com/r/tools/task-configuration-avoidance.
To determine what is calling variantOutput.getProcessManifest(), use -Pandroid.debug.obsoleteApi=true on the command line to display a
stack trace.
WARNING: API ‘variant.getMergeResources()’ is obsolete and has been replaced with ‘variant.getMergeResourcesProvider()’.
It will be removed at the end of 2019.
For more information, see https://d.android.com/r/tools/task-configuration-avoidance.
To determine what is calling variant.getMergeResources(), use -Pandroid.debug.obsoleteApi=true on the command line to display a stack trace.
WARNING: API ‘variant.getMergeAssets()’ is obsolete and has been replaced with ‘variant.getMergeAssetsProvider()’.
It will be removed at the end of 2019.
For more information, see https://d.android.com/r/tools/task-configuration-avoidance.
To determine what is calling variant.getMergeAssets(), use -Pandroid.debug.obsoleteApi=true on the command line to display a stack trace.
WARNING: API ‘variant.getPackageApplication()’ is obsolete and has been replaced with ‘variant.getPackageApplicationProvider()’.
It will be removed at the end of 2019.
For more information, see https://d.android.com/r/tools/task-configuration-avoidance.
To determine what is calling variant.getPackageApplication(), use -Pandroid.debug.obsoleteApi=true on the command line to display a stack trace.
WARNING: API ‘variant.getExternalNativeBuildTasks()’ is obsolete and has been replaced with ‘variant.getExternalNativeBuildProviders()’.
It will be removed at the end of 2019.
For more information, see https://d.android.com/r/tools/task-configuration-avoidance.
To determine what is calling variant.getExternalNativeBuildTasks(), use -Pandroid.debug.obsoleteApi=true on the command line to display a stack trace.

Task :app:preBuild UP-TO-DATE
Task :CordovaLib:preBuild UP-TO-DATE
Task :CordovaLib:preDebugBuild UP-TO-DATE
Task :CordovaLib:checkDebugManifest UP-TO-DATE
Task :CordovaLib:processDebugManifest UP-TO-DATE
Task :app:preDebugBuild
FAILURE: Build failed with an exception. FAILED

I’m afraid to change some things at the moment, because it works on one device, & I’m worried in case any changes I make break existing functionality.

I can provide whatever code is required to help narrow down the problem also.

Posts: 1

Participants: 1

Read full topic

In Ionic 5, should we still use HammerJS for standard gestures?

$
0
0

@Ryan119 wrote:

I noticed that Ionic5 has included gesture support but it looks like that’s really geared towards custom gestures. Is it still recommended to use HammerJS for standard swipe, press, etc?

Posts: 1

Participants: 1

Read full topic


Ionic 3 app initialization guidelines

$
0
0

@lsantaniello wrote:

Hi all,
I need to initialize my app and when initialization has been completed, open the first page.

During inizialization, I need to read from storage and load data from the server.

In my app, the home page costructor is called before that initialization has been completed.

I’d like to block with classic loading page and after I redirect the user to home page

What is the best solution for this scenario?

My code:

export class MyApp {

  constructor(...) {
    this.initializeApp();
  }

  initializeApp() {
    this.platform.ready().then(() => {
      
	  //here I read from storage and load data from the server
	  ...
	  
    });
  }
  
  ..
}

Thanks in advance

Posts: 1

Participants: 1

Read full topic

Question about Notification Push

$
0
0

@srterry wrote:

I know this question is not about Ionic but if anyone could help me. I have a REST conected with my app, builded with node.js, express and mongo. To notify and connect my REST with Firebase, I’m using this plugin(https://www.npmjs.com/package/fcm-node). My problem is that to send a notification, the device token must be registered manually.

image

Is there anyway to do it from REST when User logins automaticall? I’m missing something?

Posts: 1

Participants: 1

Read full topic

How to force user to enable permission oontacts, Location and camera on ionic v3

Ionic Vue Release?

How can we leave an html comment?

$
0
0

@Ryan119 wrote:

I wanted to add a that makes it to the production code, but unfortunately it looks like it get stripped out on build. Is there any way to make a comment that survives to the final product?

Posts: 1

Participants: 1

Read full topic

Viewing all 70432 articles
Browse latest View live


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