w3hello.com logo
Home PHP C# C++ Android Java Javascript Python IOS SQL HTML videos Categories
Android: how create xml file that contains the list of albums and photos from gallery
I would suggest you to get some basic java experience as these problems are really common in the programming world and has almost nothing to do with Android. Anyway you should make a List that holds Album objects (model) and an Album object should contain a List that holds Photo objects (model). Then you can loop though the list by getting the number of photos/albums with the List.size() method. Good luck.

Categories : Android

Image took from gallery is displayed in different orientation while using phonegap in android
It simply solved my issue by adding the parameter encodingType. Now the code looks like navigator.camera.getPicture(onPhotoURISuccess, onFail, { quality: 50, destinationType: destinationType.FILE_URI, encodingType : encodingType.PNG, targetWidth:120, targeHeight: 120, correctOrientation: true, sourceType: source }); }

Categories : Android

PhoneGap's getPicture() call does not save to the Gallery on Android Phone
I have been remained stuck for the same issue but using jquery mobile. I also copied the working example of apache cordova camera plug in. Simply i just commented the whole code in their provided .js file and paste the following code copied from stack overflow. It worked perfectly fine but with one issue that image will be saved at the bottom with some date of 1970 but it is saved. Code is below. $('#capturePhotoButton').on('click', function () { alert('capturePhotoButton click() called'); cameraGetPicture(); }); function cameraGetPicture() { navigator.camera.getPicture(imageReceived, cameraFail, { quality: 50, destinationType: Camera.DestinationType.FILE_URI, allowEdit: false, saveToPhotoAlbum: true, correctOrientation: tr

Categories : Android

Why can't I see my taken pictures in gallery?
Use MediaStore.Images.Media MediaStore.Images.Media.insertImage(getContentResolver(), imageBitmap, imageTitle, imageDescription); you can use the internal storage for saving.

Categories : Android

Open pictures from a folder in gallery
Intent intent = new Intent(Intent.ACTION_GET_CONTENT); intent.setData(uri); startActivity(intent); The code you use above is to open picture in gallery, but not passing a uri to gallery to open it. If you want to view pictures in a folder by gallery, I introduce you to see How to open gallery to show images in a specific directory ,hope it will help.

Categories : Android

jQuery Image Gallery with Pictures Flying in and out
Check this one, but this one is only fly in and out from left to right. Check their scripts whether you can change direction/angle or not. DEMO http://wowslider.com/jquery-slider-pinboard-fly-demo.html

Categories : Jquery

Apply center position to the gallery but not to the pictures
I would change the way you are positioning #sidebar and #wrap to start with. I would change the styles on #sidebar to be: #sidebar { background-color: #FFFFFF; float: left; height: 100%; left: 0; min-height: 720px; padding: 15px 30px 0; position: fixed; text-align: center; width: 16%; } All I have done on this is removed the hard-coded width: 260px to make the design a little bit easier to work with and removed the redundant left: 0. If I was to continue refining the design I would change other declarations slightly but that is beyond the scope of the question. Next, I would change the style of #wrap to be: #wrap { float: right; margin-right: 1%; width: 78%; } And finally change the style of .box to be: .box { display: inline-blo

Categories : HTML

Starting one gallery from multiple preview pictures, with Fancybox2
You could use a single script only and a single class for all your links. Then you could add a (HTML5) data-index attribute to any of your links to set what picture it should start the gallery from. For instance, if you want the second link to start the gallery from the 3rd image you could do : <a class="open_fancybox" href=""><img src="http://fancyapps.com/fancybox/demo/1_s.jpg" alt=""/></a> <a class="open_fancybox" data-index="3" href=""><img src="http://fancyapps.com/fancybox/demo/3_s.jpg" alt=""/></a> Then in your script, detect if the link has the data-index attribute and set the fancybox index accordingly, otherwise start the gallery from the first element, so : $(".open_fancybox").click(function () { // detect if data-index exists othe

Categories : Javascript

Issue with stock Browser picking photos from Gallery
Since the issue is probably browser-related, and you can't really fix the browser(you could report a bug to Google though), I'd suggest taking a different path. Have a look Here: In Node.js, given a URL, how do I check whether its a jpg/png/gif? See the comments of the accepted answer, which suggests a method to check the file type using the file stream. I'm pretty sure this would work on browser-implemented Javascript and not only in Node.js.

Categories : Javascript

Create a button in order to add a group of photos to a gallery
This is a very basic question. You should read the jQuery docs about DOM manipulation http://api.jquery.com/category/manipulation/ To answer your question: You can use before to insert a DOM element before your button: $(".more").before('<a href="images/big/05.jpg" class="photo"><img alt="" src="images/gallery/05.jpg"></a>')

Categories : Javascript

create a gallery images in my website where there is albums that hold many pictures
To get you started in the right direction: Create two tables in your database: userImages & userAlbums userImages fields could consist of say: id, location (where the file is saved on the server), userId (the owner's id from a user table), albumId, caption userAlbums fields could consist of say: id, userId(the owner of the album), title, description

Categories : PHP

Android: How to display selected image gallery in ImageView?
If the image size is large you can scale down the bitmap as below BitmapFactory.Options options = new BitmapFactory.Options(); options.inSampleSize = 2; bitmap = BitmapFactory.decodeFile(path, options); image.setImageBitmap(BitmapFactory.decodeFile(picturePath)); Also as an alternative you can determine the sampleSize based on the image size and the display size

Categories : Android

How to retrieve mutiple images from url and display them in a gallery in android?
I suggest you to refer this UniversalImageLoader to fulfill your purpose. This Example provide a reusable instrument for asynchronous image loading, caching and displaying. It has the same example which you are looking for(i.e. download the image from the different URL's and Set in Gallery/GridView/ListView). Hope this helps ... :)

Categories : Android

jQuery - Flickr plugin with colorbox - gallery displays previous photos
I figured it out. I was using the rel property incorrectly to group the photos together. This is what worked: $("a.gallery[rel=" + PhotoSetID +"]").colorbox(); here is a working fiddle: http://jsfiddle.net/eBGVV/6/

Categories : Jquery

choose image from android image gallery - PhoneGap not working
try this link i hope it might be help you http://tympanus.net/codrops/2010/05/27/awesome-mobile-image-gallery-web-app/ See the api http://docs.phonegap.com/en/2.8.0/index.html and you also try like if Camera.sourceType = Camera.PictureSourceType.PHOTOLIBRARY or Camera.PictureSourceType.SAVEDPHOTOALBUM, then a photo chooser dialog is shown, from which a photo from the album can be selected.

Categories : Android

phonegap cound not get camera pictures in folder tmp
try this code. may this work on IOS & Android not tested. document.addEventListener("deviceready", onDeviceReady, false); // device APIs are available // function onDeviceReady() { window.resolveLocalFileSystemURI("your imageURI",sucess,fail); } function sucess(fileEntry){ // you can do with your fileEntry object }

Categories : IOS

How can I apply animation on Gallery : Animated Gallery Android
You can achieved this by using the StackView feature. Check out below links,Hope this link help for you. 1) android-stackview 2) example 3) stacked card view

Categories : Android

Is this possible to make video gallery in android like image gallery
my main gallay class public class HorizontalScrollExampleActivity extends Activity implements OnClickListener { LinearLayout myGallery; Cursor cursor; private ArrayList<VideoViewInfo> _videoRows; private VideoView mVideoView; @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.gallaryview); myGallery = (LinearLayout) findViewById(R.id.mygallery); mVideoView = (VideoView) findViewById(R.id.videoView1); String targetPath = Environment.getExternalStorageDirectory() .getAbsolutePath(); Toast.makeText(getApplicationContext(), targetPath, Toast.LENGTH_LONG) .show(); loaddata(); /*

Categories : Java

Crash when selecting picture from gallery in phonegap
I guess you are trying with Android version 4.1 or 4.2. If it's the case so refer to this answer : Phonegap : Upload picture crashes on Samsung mobile 4.1.2 but works fine on Google Nexus 4.3.0

Categories : Android

display random pictures using java
but dont know how to map these no's with images Don't map the numbers, map the letters: Map<String, Image> images = new HashMap<String, Image>(); images.put("a", imageA); images.put("b", imageB);

Categories : Java

Display Album's Photos with EmberJs
Your approach is correct, but there are some issues with your fixture data. your fixture javascript is not formatted property (you need to remove the -) you need to not embed the Photos records, instead put them in the Photos fixture and reference them by id need to add some ids to your fixture records and make sure some are not duplicated Working JSBin

Categories : Ember Js

Is there a way to display the already added pictures when editing a post using Paperclip?
Sorry. I just found out that there is a solution on Ryanb's Nested Form page. It is possible to track the event that generates new fields by listening to the nested:fieldAdded event, and the generated elements can be found by via event.field.

Categories : Ruby On Rails

Flickr API - phpFlickr - Display private pictures with photosets_getPhotos()
Hey almost 2 years ago myself... Anyway. I found a solution a bit later after the question and never posted a reply. I think it could be interesting, even if late, for other people : So, pretty sure there is something smarter to do but I didn't find it. I found "a way" to do what I needed. I needed to make a private web page with galeries of private photos. <?php require_once("phpFlickr.php"); $f = new phpFlickr('myapikey','myapisecret'); $f->enableCache("fs", "cache"); //This is what I really missed: the token number. $f->setToken('myratherlongtoken-number'); //Dan Coulter explains it in the documentation of phpFlickr //He also provides a tool to ask a token. $username="My Username"; $result = $f->people_findByUsername($username); $nsid = $result["id"]; ?> //After,

Categories : PHP

Missing photos when retrieving Users tagged photos facebook-graph API
The only thing that comes to mind is the settings of each user since according to the answer posted here - facebook graph api - missing fields, API access to these things can be turned off at the user's discretion.

Categories : Facebook

How can I show last saved photo in Photos app iOS via "photos-redirect:" URL scheme?
photos-redirect:// is the URL Scheme for Photo App. However, it is undocumented, thus you shouldn't use it. To view / select a photo, use UIImagePickerController .

Categories : IOS

PhoneGap 3.0: `phonegap platform build android` returns success but buildfile doesn't exist
It appears that the problem was a badly-formed config file stemming from the fact that I created the project incorrectly, leaving out the quotes in: $ cordova create hello com.example.hello "HelloWorld"

Categories : Cordova

PhoneGap "Hello World" launches in android emulator but no default PhoneGap "Device is ready" Screen
Ok, after a couple of weeks scratching my head around this I finally figured out what the problem was. I was using the PhoneGap CLI to build an android project against the bin directory. For some reason, when I opened Eclipse and started a new project with existing code (according to the PhoneGap documentation) somehow it produced an incomlplete java file. I discovered this by comparing a working application's java file with my one and realized the code was different. So, instead of using the CLI, I simply opened Eclipse, and started a new project from the "example" folder in the PhoneGap android directory and ran the project - it worked!

Categories : Android

PhoneGap: iOS/Android | save eMail attachment into PhoneGap-App
It is URL scheme. Here there are some information: https://developer.apple.com/library/ios/documentation/iPhone/Conceptual/iPhoneOSProgrammingGuide/AdvancedAppTricks/AdvancedAppTricks.html#//apple_ref/doc/uid/TP40007072-CH7-SW21

Categories : Android

Porting Phonegap Android asset into Phonegap Windows
Best thing to do is to try it and see what happens! But yes, you just need to copy the contents of the www folder of the Android app to the www folder of a new Windows Phone PhoneGap project. You might find you might have to make minor modifications to things like CSS because of the differences in how the mobile browsers render the web pages (since the Android app will run on a webkit browser frame whilst the Windows app will run on an Internet Explorer browser frame). You might need to set the 'Build Action' property for any image resources you copy across to the Windows Phone using Visual Studio to get the images to render.

Categories : Android

Preventing Display of Post Gallery when on Homepage
You can add the following to your theme's functions.php file or to a custom plugin (better, as you can disable it without touching the theme). The filter post_gallery is used to create your own gallery, and the $content parameter comes empty by default. If it returns empty, the original [gallery] shortcode is processed. Here, we are using a dummy empty value, so the filter is tricked into thinking that we are passing some actual gallery content, but it's just a white space. add_filter( 'post_gallery', 'disable_home_galleries_so_17635042', 10, 2 ); function disable_home_galleries_so_17635042( $content, $atts ) { // http://codex.wordpress.org/Conditional_Tags if( is_home() ) return '&nbsp;'; return $content; }

Categories : Wordpress

Simple highslide gallery doesn't display correctly
First problem about one row the simplest way: <ul class="highslide-gallery"> <li> <a href="your_url1"><img src="your_source1"></a> </li> <li> <a href="your_url2"><img src="your_source1"></a> </li> <li> <a href="your_url3"><img src="your_source3"></a> </li> </ul> And css something like this: ul.highslider li { float: left; margin: 0 10px; } Or just add to your css file: .highlslide-gallery a {float:left;}

Categories : Misc

get a random picture from phone gallery and display in view
The following snippet retrieve the gallery`s content and put every image path inside an array list. Then it choose randomly one of the path inside the ArrayList and put as resources for an ImageView Handler handler = new Handler(); protected int counter = 0; private ImageView mImageView; private Bitmap currentBitmap = null; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.image); mImageView = (ImageView) findViewById(R.id.imageView); String[] projection = new String[]{ MediaStore.Images.Media.DATA, }; Uri images = MediaStore.Images.Media.EXTERNAL_CONTENT_URI; Cursor cur = managedQuery(images, projection, "", null, "" );

Categories : Android

Android API for Google+ Photos
I finally found all the pieces for that I need. The end result is to use AccountManager to get the auth token and PicasawebService to do the rest. Though there are some annoying bug with adapting the class. I wrote up my little adventure here along with example code. http://roostertech.wordpress.com/2013/08/09/accessing-gphoto-android/

Categories : Java

Crop many pictures as circle in Android
I think you could combine the answers given in the following two posts: Create a bitmap: How to crop an image in android? Crop the bitmap to a circle using canvas. Android - Cut a circle from a square Bitmap Kind regards

Categories : Android

Android camera does not save pictures
Taken strictly off of http://developer.android.com/training/camera/photobasics.html. Request permission to use camera <uses-feature android:name="android.hardware.camera" /> Take photo private void dispatchTakePictureIntent(int actionCode) { Intent takePictureIntent = new Intent(MediaStore.ACTION_IMAGE_CAPTURE); startActivityForResult(takePictureIntent, actionCode); } Save photo storageDir = new File( Environment.getExternalStoragePublicDirectory( Environment.DIRECTORY_PICTURES ), getAlbumName() ); Set the file's name private File createImageFile() throws IOException { // Create an image file name String timeStamp = new SimpleDateFormat("yyyyMMdd_HHmmss").format(new Date()); String imageFileName = JPEG_FILE_PREFIX + timeSta

Categories : Android

Android: Get Pictures from Camera - be careful
I used one of the many tutorials that are out there and everything worked fine. But then i tested it on a different device and nothing worked at all. At first i was very suprised but then i decided to go deeper into this topic. And i realized that a lot of these tutorials can cause a big problem. So i decided to share my experience with you. Let me start with a common approch most of the tutorials are using. At first you choose a requestID something like that: private static final int CAMERA_PIC_REQUEST = 1337; Then you create an Intent and start the camera Activity Intent cameraIntent = new Intent(android.provider.MediaStore.ACTION_IMAGE_CAPTURE); startActivityForResult(cameraIntent, CAMERA_PIC_REQUEST); To get the Picture back you use the onActivityResult function and read the pi

Categories : Android

Get private photos using flickrj-android
I'm not very familiar with Java and that framework but will try to help. I found next method name in that framework: public class PeopleInterface { public static final String METHOD_GET_PHOTOS = "flickr.people.getPhotos"; /** * Returns photos from the given user's photostream. Only photos visible the * calling user will be returned. this method must be authenticated. * * @param userId * @param extras * @param perpage * @param page * @return * @throws IOException * @throws FlickrException * @throws JSONException */ public PhotoList getPhotos(String userId, Set<String> extras, int perPage, int page) From Flick API docs I found next: flickr.people.getPhotos Return photos from the given user's photostr

Categories : Android

Android: My GridView's photos is mixed
Try this... Use View holder for holding details... public View getView(int position, View convertView, ViewGroup parent) { View view = convertView; final ViewHolder holder; if(convertView == null) { view = inflater.inflate(R.layout.phototab_list, parent, false); holder = new ViewHolder(); holder.photo = (ImageView)convertView.findViewById(R.id.PHOTOS); holder.CHECK = (CheckBox)convertView.findViewById(R.id.PHOTOSCHECK); holder.options = new BitmapFactory.Options(); holder.options.inSampleSize = 16; }else { holder = (ViewHolder) view.getTag(); } Log.i("LOAD", position + ""); if(ReceivePhotos.get(position) == null) { ReceivePhotos.set(position, BitmapFac

Categories : Android

Gridview onclick images display imageview as gallery view using viewpager
If you are starting a new activity for view pager, get the position of selected image from gridview and pass it to that activity. Then you can set selected image in view pager like, pager.setCurrentItem(currentid); // here current id is the position of selected image.

Categories : Java

PNG vs JPG for displaying pictures [not icons] in Android Application
This question should shed some light on that. Very helpful. A big reason most go with PNG is the alpha transparency issue. If this doesn't apply to you, you may not be as tied to it as most. Also, this article goes a bit more in depth. PNG is a newer format, and is really a good replacement for GIFs. Sadly, however, it has a few drawbacks: Firstly it cannot support animation like GIF can. Secondly it has some support issues with older browsers like IE6. Thirdly, important software like Photoshop have very poor implementation of the format. Here's what's good about it: Unlike GIFs, PNGs can either be Indexed or Direct color (like JPGs), if need be. That means that it can have nice smooth gradients, if you don't mind a larger file. PNG also supports a nifty thing called Alpha Tra

Categories : Android



© Copyright 2017 w3hello.com Publishing Limited. All rights reserved.