rails active admin deployment : couldn’t find file ‘jquery-ui’

The “jquery-rails” gem recently removed jQuery UI. https://github.com/rails/jquery-rails/commit/2fdcdb2633cbc6426d412c050200fc31d14b9a3b They recommend using the jquery-ui-rails gem. There is an active pull request (as of this writing) to add that gem as a dependency. However, the developers of ActiveAdmin have stated that they are “locking it down until we officially drop support for Rails 3.0”. The version they … Read more

android get Bitmap or sound from assets

public static Bitmap getBitmapFromAsset(Context context, String filePath) { AssetManager assetManager = context.getAssets(); InputStream istr; Bitmap bitmap = null; try { istr = assetManager.open(filePath); bitmap = BitmapFactory.decodeStream(istr); } catch (IOException e) { // handle exception } return bitmap; } the path is simply your file name fx bitmap.png. if you use subfolder bitmap/ then its bitmap/bitmap.png

How to load a image from assets?

You can follow my tutorials on displaying data from Assets: https://xjaphx.wordpress.com/2011/10/02/store-and-use-files-in-assets/ The sample with loading image and text to display. I now added the relevant part of the provided link (in case of earthquake or something) 😉 Taifun // load image try { // get input stream InputStream ims = getAssets().open(“avatar.jpg”); // load image as … Read more

Route helpers in asset pipeline

UPDATE: Now there is a gem that does this for you: js-routes The problem is that Sprockets is evaluating the ERB outside of the context of your Rails app, and most of the stuff you’re expecting isn’t there. You can add things to your Sprockets context like so: Rails.application.assets.context_class.class_eval do include Rails.application.routes.url_helpers end That’s all … Read more

Cookie “PHPSESSID” will be soon treated as cross-site cookie against because the scheme does not match

that was exactly same happening with me. the issue was that, firefox keeps me showing even Cookies of different websites hosted on same URL : “localhost:Port number” stored inside browser memory. In my case, i have two projects configured to run at http://localhost:62601, when i run first project, it saves that cookie in browser memory. … Read more

Rails 3.1 and jquery-ui assets

Example of a working setup: $ cat app/assets/javascripts/application.js //= require jquery //= require jquery-ui $ cat app/assets/stylesheets/application.css /* *= require vendor * */ $ cat vendor/assets/stylesheets/vendor.css /* *= require_tree ./jquery_ui * */ vendor/assets/ $ tree stylesheets vendor.css jquery_ui      jquery-ui-1.8.13.custom.css … images    jquery_ui    ui-bg_flat_0_aaaaaa_40x100.png … Finally run this command: vendor/assets/images $ ln … Read more

Symfony2 – Assetic – load images in CSS

use the cssrewrite filter from Assetic bundle In config.yml: assetic: debug: %kernel.debug% use_controller: false filters: cssrewrite: ~ And then call your stylesheets like this: {% stylesheets ‘bundles/cmtcore/css/*’ filter=”cssrewrite” %} <link rel=”stylesheet” type=”text/css” media=”screen” href=”https://stackoverflow.com/questions/7044631/{{ asset_url }}” /> {% endstylesheets %} Oh and don’t forget to use php app/console assetic:dump

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)