A mockumentary on How Black People See White Culture … in this case the Eastern Alps … with an awesome explanation for “Wanderlust.” 😀
Author: riyad
Der Islam als sozialer Pflegefall?!
Auszug:
In Deutschland hat sich die Forschung hingegen mehrere Jahrzehnte später in den 1990er Jahren zunehmend der Frage nach Religion in Zusammenhang mit Migration gewidmet. Dabei stand der Islam meistens als empirisches Fallbeispiel im Vordergrund. Doch die Auseinandersetzung mit dem Islam erfolgte überwiegend religionsimmanent und war bis auf Ausnahmen kaum verankert in religionssoziologische oder migrationssoziologische Kontexte. Der Islam erscheint in Deutschland als Sonderfall und nicht als ein Beispiel unter anderen. Muslime sind damit etwas anderes, entwickeln aus sich selbst und ihrer religiösen Tradition, was sich nicht mit gesellschaftlichen Verhältnissen vertragen will. Sie sind lange Zeit weder von der Öffentlichkeit noch von wissenschaftlicher Seite als eine gesellschaftliche Teilgruppe betrachtet worden, die sich in Wechselwirkung mit sozialen Kontexten und Bedingungen im Lande unter anderem mit Religion auseinandersetzt. Sie sind je nach Betonung ihrer ethnischen Eigenschaft etwa als „Türken“ oder ihrer religiösen als Muslime als „homines religiosi“ betrachtet worden, die einer Religion zugehören, die grundsätzliche Inkompatibilitäten mit der „christlich-jüdischen“ Kultur aufweist.
Look on a map if you want to know why you can’t see the Pacific Ocean from Korea
Look on a map if you want to know why you can’t see the Pacific Ocean from Korea.
Sometimes there are real gems in subber commentaries. xD
Sortable Columns Across Tables
If you follow Railscast 228 you get sortable table columns for your model. But what if you don’t want to expose the name of the actual database columns or more interesting if you want to sort across tables? Here is how I do it.
In your controller add order or reorder if you already have an order clause in one of the used scopes (default_scope counts too).
class AttendeesController < ApplicationController
def index
@attendances = @conference.attendances.reorder(sort_query).page(params[:page])
end
# ...
end
As I’m using this mechanism in different controllers I added the common functionality to the application_controller.rb file.
class ApplicationController < ActionController::Base
helper_method :navigation_params, :sort_column, :sort_direction
protected
# supports only attendances for now
ALLOWED_SORT_COLUMNS = {
"fee_payed" => "fee_payed",
"fee_payed_on" => "fee_payed_on",
"name" => "users.last_name, users.first_name",
"payment_confirmation_sent_at" => "payment_confirmation_sent_at",
"registered_at" => "registered_at",
"registration_confirmation_sent_at" => "registration_confirmation_sent_at",
"town" => "users.town"
}
# use this in views
def sort_column
ALLOWED_SORT_COLUMNS.keys.include?(params[:sort]) ? params[:sort] : "name"
end
def sort_direction
%w[asc desc].include?(params[:direction]) ? params[:direction] : "asc"
end
def navigation_params
{ direction: params[:direction], page: params[:page], sort: params[:sort] }
end
def sort_query
sort_query_column.split(',').map{ |column| column + ' ' + sort_direction }.join(', ')
end
# use this in controllers
def sort_query_column
ALLOWED_SORT_COLUMNS[sort_column]
end
end
This will use the ALLOWED_SORT_COLUMNS hash to map between user visible and actual database sort columns. Adding sort_query also allows us to sort by multiple columns at once. navigation_params is a shortcut I use when generating URLs (e.g. in link_to) and I want to preserve pagination, sorting, filters/searches, etc. across pages.
def link_to_sortable(column, title = nil)
title ||= column.titleize
sort_icon = column == sort_column ? content_tag(:i, nil, class: (sort_direction == "asc" ? "icon-chevron-down" : "icon-chevron-up")) : ""
direction = column == sort_column && sort_direction == "asc" ? "desc" : "asc"
link_to (title+" "+sort_icon).html_safe, params.merge(sort: column, direction: direction, page: nil)
end
Note that sort_icon assumes you are using Bootstrap.
Now we can have sortable columns in our views:
<%= link_to_sortable "name" %> ...
Debugging SASL
If you are using Cyrus SASL with your Postfix you might feel the need to debug what SASL does in the background. But SASL does not log into /var/log/mail.*. 🙁
So after some research I fount a way …
/etc/init.d/saslauthd stop
Stop the SASL daemon and start it by hand:
saslauthd -d -a pam -r -c -m /var/spool/postfix/var/run/saslauthd
Consult the MECHANISMS and OPTIONS settings in /etc/defaults/saslauthd for which options to use in your case.
But the most important option is -d. It will run the daemon in the foreground and make it more verbose.
Now it will show you everything it does. 😀
Don’t forget to start the actual daemon once you are done debugging:
/etc/init.d/saslauthd start
Hate Mail for an Unhappy Birthday
Firefox Add-on for visualizing who’s tracking you in real time
If you want an idea on how you are being tracked on the internet and who rats you out to whom you might be interested in Mozilla’s Collusion Demo.
Windows 8 Consumer Preview (a.k.a. Beta) is out
The Windows 8 Consumer Preview (a.k.a. Beta) is out. The link to directly download ISOs is a little hidden though.
GoingNative 2012
If you are interested in C++11 and what might come afterwards I advise you to have a look at the conference recordings from this years GoingNative conference. 🙂
I especially liked the day 2 keynote, the STL11 guts and the static if talk. 🙂
Thou Shalt Not Kill
I talked about how Chrome Beta for Android makes itself feel so snappy.
Well Tony Gentilcore from Google has more details.