And then visualize it PhoneGap/Cordova download file to the device
I'm doing a magazine app that downloads images to the device for the magazine can be read when offline or with a bad internet connection.
I use PhoneGap/Cordova version 3.1 with 10 of BlackBerry and plugins file and file transfer. I made a few changes to my code base that runs on Android and iOS since before he could download files on the Simulator. Ensure the directory that I wanted to save the file to exist and access to the file with the path indicated in fs.root.toURL ().
But now that I got the files uploaded to the device I can't view. On other platforms, I was able to use theFileEntry.toURL () and set it as the source for an img tag. But for BB10 I see only an empty img tag. =/
The specified local path is: filesystem:local:///persistent/bblogo.png
I was searched and seen references to disabling sandbox and by saving the file on blackberry.io.shared or blackberry.io.home, but blackberry is not available for me with PhoneGap 3.1. Looking at the native documentation , that I saw that the shared path is/accounts/1000/shared but trying to browse the file system I am told that the path does not exist. (fs.root.getDirectory ('accounts') to start with).
I have a GitHub repository with what I'm looking for here: https://github.com/gaqzi/phonegap-bb10-file-transfer-test
The code in question is here: https://github.com/gaqzi/phonegap-bb10-file-transfer-test/blob/master/www/js/index.js#L38
I also noticed that the size of the file when the download is complete is much larger than the actual size of the file on my computer. And the same code running on iOS I see not enough to increase the size of the file. I don't know if that has to do any.
To try to combat the current file size wildly different I coded an image 10 x 10 pixels as Base64, she decoded on the device and saved. Now, he pointed out the same size on my computer and the device, but still can not see. The same exercise done on iOS gives me a visible image.
For the code on the test of Base64, please see my thread Stack Overflow for this: http://stackoverflow.com/questions/19421245/blackberry-10-cordova-phonegap-3-1-filetransfer-image-do...
I am at a loss what can I do to access the files I created, anyone has an idea?
Hello
The patch for the cordova file api is still ongoing. Until that of land, here is an example for download of an image and inject it into the DOM. It uses XHR, but the filetransfer plugin should work as well.
https://gist.github.com/jeffheifetz/c1127b4d3e132ffff972
You will need to 'blackberry.io', which is available as plugin PhoneGap/Cordova here:
https://github.com/BlackBerry/Cordova-BlackBerry-plugins/tree/master/plugin/com.BlackBerry.IO
The patch will automatically update toURL so that it returns the full path which has been hard-coded in the example.
Tags: BlackBerry Developers
Similar Questions
-
Automatic updates of Windows
This security update is constantly appearing: a security update for Microsoft XML Core Services 4.0 Service Pack 2 (KB954430) I successfully download the update and then it reappears to be downloaded again.
See the sections «How to get help...» "and 'known issues' here:
http://support.Microsoft.com/kb/954430Visit the Microsoft Solution Center and antivirus security for resources and tools to keep your PC safe and healthy. If you have problems with the installation of the update itself, visit the Microsoft Update Support for resources and tools to keep your PC updated with the latest updates.
For enterprise customers, support for security updates is available through your usual support contacts.
Read also: http://support.microsoft.com/kb/941729/Hope this helps, Vincenzo Di Russo
Microsoft® MVP Windows Internet Explorer, Windows Desktop Experience & security - since 2003.
My MVP profile: https://mvp.support.microsoft.com/profile/Vincenzo -
Nobody knows... including Adobe why Photoshop crashes when you try to print. I had Adobe take on my computer, they put it is good, and then as soon as I download an update off he goes again. ADOBE when are you going to fix this problem it is we makes everyone crazy.
I'm willing to take to social media, this problem will just on and so forth. Someone has found a permanent solution, if so can you let me know the answer.
Hey Abram,
What version of Photoshop are you using?
What operating system do you use?
~ UL
-
I try to insert two images in a single document, group them, and then export it to a jpg file but cannot do
Hello sara,.
For my part, I prefer to use my German PS in this way (I try to translate the commands):
Use the same height for both images.
Open the first image in PS.
Use Bild > Arbeitsflache (Image > work plan?) See screenshot:
From there:
Give him the new with, by clicking on the left or the right indicating the hand playing around (trial and error).
Now you can insert your second image.
Hans-Günter
-
Original title: blocking or scrolling
Generally when I go in windows or by mail, the computer will pick up, and then when it opens, I can't keep the page at a particular place. It scrolls upwards or downwards, when I try to open a place to file an open letter from mail, or trying to do some work. Please notify.
Hello
1 how long have you been faced with this problem?
2 don't you make changes on the computer before this problem?
3 what e-mail client or browser you use?Step 1: Check if the problem persists in the clean boot state.
From your computer by using a minimal set of drivers and startup programs so that you can determine if a background program is interfering with your game or program. This type of boot is known as a "clean boot".
Reference:
How to configure Windows XP to start in a "clean boot" State
http://support.Microsoft.com/kb/310353When you are finished troubleshooting, follow these steps to reset the computer to start as usual:
1. click on start and then click Run.
2. type msconfig and click OK.The System Configuration Utility dialog box appears.
3. click on the tab general, click Normal Startup - load all services and device drivers and then click OK.
4. When prompted, click on restart to restart the computer.Step 2: Also, viruses or malware scan and check.
http://www.Microsoft.com/security/scanner/en-us/default.aspx
http://www.Microsoft.com/downloads/details.aspx?displaylang=en&FamilyID=ad724ae0-e72d-4f54-9ab3-75b8eb148356Step 3: Also, look for error messages in the event viewer. If you find error messages after return the exact error message so that we can help you better.
Reference:
Using the event viewer
http://www.Microsoft.com/resources/documentation/Windows/XP/all/proddocs/en-us/snap_event_viewer.mspx?mfr=true
Understanding of event viewer
http://www.Microsoft.com/resources/documentation/Windows/XP/all/proddocs/en-us/event_overview_01.mspx?mfr=true
Procedure to view and manage event logs in Event Viewer in Windows XP
http://support.Microsoft.com/kb/308427 -
File extension is missing when you download files from the web
I just got a new PC with preinstalled Windows7. From day one, I have the problem that when I download files from the internet while you have no extension, so when I try to run them, told me that they do not have an associated program. I then rename and add the missing extension and all is well. But it's very annoying to have to do every time :(
I come home from work and now everything works fine - even my webcam which worked yesterday either. Just shows how much it means to close and start fee in time ;)
Seems that my problem has healed itself, but thanks for the help that was offered to me.
-
Impossible to download files from the mp3 player to windows media player
Original title: GPX ML648B MP3 Player 2 GB
Hello
I'm trying to download files from the mention of the above mp3 player for windows media player with Windows 7 on the laptop?
Any suggestions or solutions.
Thank you
Roslyn
Hello
(1) if it works much earlier?
(2) you get an error message?
When you connect the MP3 player to the laptop, it appears in the computer as a removable disk?
If the State, then perform the following steps.
(a) find the files MP3, to modify, select toolbar, select ALL, then copy.
(b) navigate to where you want music go on your hard drive, (usually the My Music folder), the toolbar, select Edit, Paste.
(c) open Windows Media Player from the toolbar, select organize libraries, manage libraries and the music.
You can also see the following article for more information;
Add items to the Windows Media Player library:
http://Windows.Microsoft.com/en-us/Windows7/add-items-to-the-Windows-Media-Player-library
-
* Original title: ease of backup Windows 7
I have Windows 7 and I am unable to back up files. The following message appears: "the task image is corrupt or has been tampered with. I used an ERD without result. The application discovers not a problem. At the same time, I received a message that the Bitlocker system files could not be found. I tried Windows 10 briefly then back to Windows 7. That's when I started getting the message image corrupted
Although many people have problems when back to Windows 7 after trying 10 Windows, before you reinstall Windows 7, you can consider the rest of the steps here--> https://support.microsoft.com/en-us/kb/2305420
-
How can I block a user to download files on the web?
I use Microsoft parental control for a few months, I dig several times to find t somehow I can block the user to download files? Like the way that we have the ability to "Block downloads of files on the web" in Web filtering.
If this isn't the case, using the parental control of Microsoft, y at - it another way I can prevent users from downloading files?
BTW, I'm on Windows 7 x 64.
Hello
Thanks for posting your question in the Microsoft Community forum.
We understand that you want to block the user to download files using the parental control. However, please be informed that this is not possible, since it is by design. Family Safety allows you to block downloads of files from the web, but not to download files:
For more information, you can visit this Wiki link:
Family Safety: frequently asked Questions
Hope this information helps. If you need help with Windows, let us know and will be happy to help you.
-
Recently, when I download files from the SD card, LR6 not rename the files. How can I fix it?
If I open the folder, not through Lr, I can rename the file. Now, the problem disappeared. Maybe it was related to the DD. I removed and put back in place the protections in SD via the menu of my camera and the problem disappeared. Now, he works as usual. Amount and rename the files by LR. Thank you for your interest
-
my Iphone 5 was automatically turned off, and then I couldn't go? What is the problem please help me?
Have you tried to connect your iPhone to iTunes or the wall charger and let your iPhone for 5-10 minutes to charge its battery?
-
When we turn on my wife's ipad, a box of red line begins to jump around the screen, and then a pale red stripe moves back on the screen. Any ideas on how to stop it? Thank you
The standard specifies:
-Reset the device iOS. Nothing will be lost
Device iOS Reset: Hold down the On / Off button and the Home button at the same time for to
ten seconds, until the Apple logo appears.
-Reset all settings
Go to settings > general > Reset and tap reset all settings.
All your preferences and settings are reset. Information (such as your contacts and calendars) and media (such as songs and videos) are not affected.
-Restore from backup. See:
Restore your device from an iCloud or iTunes backup - Apple Support
-Restore factory settings/new iOS device.
If still problem, make an appointment at an Apple store Genius Bar because it appears that you have a hardware problem.
-
How can I set the time display on the toolbar of the low wing? When I click with the right button on the taskbar, and click show properties, it does not give me the options to display the time? Where should I go in windows 7 to do this? I clicked on the date and time also, and it does give me an option to add there either. Please help.
Thank youHow can I set the time display on the toolbar of the low wing? When I click with the right button on the taskbar, and click show properties, it does not give me the options to display the time? Where should I go in windows 7 to do this? I clicked on the date and time also, and it does give me an option to add there either. Please help.
Thank youRight-click the taskbar, and then select Properties. On taskbar you of the tab, click Customize. Scroll to the clock and change the "behaviours" on it.
-
If I activate a campaign and then turn it off, will be updated in the segment?
Hello
If I activate a campaign and then turn it off, will be updated in the segment?
Thank you
Rahul
Hi Rahul
If the segments are updated every hour until the campaign is disabled.
Thank you
-
How can I disable retention to the files on your system within the Areader? Already have downloaded files in the download folder. Enjoy your reading utility, but do not want to delete the list. I thank you, Director, actuarial Systems IBM WE
Edit > Preferences > Documents > open settings. 'Documents in the list recently used' zero value.
Maybe you are looking for
-
Re: Erratic behavior on Satellite M40X
Hello Very often but not always, when I start the laptop (Satellite M40X - 186 Windows XP SP3), after a while, the Windows Media Player popup window. I got close but it reappears etc... also very often, there's erratic behavior: the keyboard is unusa
-
the mouse disappears at the level of the office. F8 doesn't let me do it in safe mode
Ideas: You have problems with programs Error messages Recent changes to your computer What you have already tried to solve the problem restarted several times without success Remember - this is a public forum so never post private information such as
-
product key no longer works for windows vista service Pack 2
can I get the product key without buying?
-
Hello, I have laptop Dell studio 1558 and am recently facing problem with its sound system. its woofers really starts cracking sounds when I play anything either the song or vedio... but its left and right speakers works fine. I doubt if his material
-
Cannot perform the operation while the host belongs to a Windows domain.
HelloI'm trying to change recording alter DNS for a host of esx5.1 via vCenter but the following error;Cannot perform the operation while the host belongs to a Windows domain.The host is joined to the domain, but has a static IP configuration. I pref