session killer script

this one line of script is a killer of asp.net session on ie 7, 8, and 9 browsers (maybe ie6, i didn't test it):

$(document).ready(function() {
// for remembering the selected tabs
$("div[id*='tabs']").tabs({ cookie: { expires: 999, name: this.id }, cache: false, collapsible: true });
}

script'i 2 parça halinde yazmak buna neden oluyor.


//        // for remembering the selected tabs
        //        $("div[id*='tabs']").tabs({ cookie: { expires: 999, name: this.id }, cache: false, collapsible: true });

        // fade effect
        $("div[id*='tabs']").tabs({
            fx: {
                opacity: 'toggle',
                duration: 'fast'
            },
            cookie: { expires: 999, name: this.id }, cache: false, collapsible: true
        });

t-sql find object references

select object_name(object_id), OBJECT_DEFINITION(object_id)
from sys.objects
where OBJECT_DEFINITION(object_id) like '%CDS%' and type='P'

örn: ProductId alanının kullanıldığı sp'ler.

streamreader encoding

sorun: doğru encoding verilmezse türkçe karakterler okunamıyor.

çözüm:
StreamReader sr = new StreamReader("ornek.txt", Encoding.GetEncoding("windows-1254"));
textBox1.Text = sr.ReadToEnd();

Value cannot be null. Parameter name: name

add web reference ile web service eklenirken, veya web service çalıştırılırken, dbml'in güncel olmaması nedeniyle bulunamayan nesneler (stored procedure vb.) bu hataya neden olabiliyor.

indexed view with schemabinding

ALTER VIEW [dbo].[Vw_View1] WITH SCHEMABINDING AS
SELECT ...
FROM ...

CREATE UNIQUE CLUSTERED INDEX [IX_Index1] ON [dbo].[Vw_View1]
(
[Column1] ASC
)
GO

related errors:
Cannot create index on view  because the view is not schema bound.

http://www.mssqltips.com/tip.asp?tip=1610

checkboxlist prerender

protected void cblDilekceTipi_PreRender(object sender, EventArgs e)
{
foreach (ListItem item in cblDilekceTipi.Items)
{
item.Text = item.Text.Replace(" Dilekçesi", "");
}
}

ie6 background image

{ background: transparent url('../img/external.gif') no-repeat; padding-left: 10px; height: 20px; float: left; position: relative; filter: alpha(opacity=40); opacity: .40; }

the critical points are bold.

fixed bottom bar (facebook style) with jquery

http://ryan.rawswift.com/2009/02/15/fixed-that-bar-at-the-bottom-like-facebook/

jquery ui tabs sayfa yüklenirken dağılma sorunu

sayfanın tamamı yüklenmeden önce, yani document.ready sırasında çalışacak ve tab'ları düzenleyecek tabs metodu çalışmadan önce, tab'lar açık görünüyor. bunun önüne geçmek için kullanılabilecek bir yol; tab içeriğini gizlemek, sayfa yüklendikten sonra göstermek:

$("div[id*='tabs']").tabs({
fx: {
opacity: 'toggle',
duration: 'fast'
}
});

$(document).ready(function() {
document.getElementById('toptab').style.display = 'block';
}

http://stackoverflow.com/questions/1069758/should-jquery-tabs-be-inside-document-ready

jquery tipsy ie tooltip bug fix

http://github.com/jaz303/tipsy/commit/88923af6ee0e18ac252dfc3034661674b7670a97

search this blog (most likely not here)