I used example3 here
I set rigidly width/1000px and height/600px.
$(".group3").colorbox ( {
rel: 'group3', transition: "none" , width: "1000", height: "600"}
) ; I used example3 here
I set rigidly width/1000px and height/600px.
$(".group3").colorbox ( {
rel: 'group3', transition: "none" , width: "1000", height: "600"}
) ; // set placeholder values
$('[placeholder]').each(function() {
if ($(this).val() == '') // if field is empty
{
$(this).val($(this).attr('placeholder'));
}
});
// focus and blur of placeholders
$('[placeholder]').focus(function() {
if ($(this).val() == $(this).attr('placeholder')) {
$(this).val('');
$(this).removeClass('placeholder');
}
}).blur(function() {
if ($(this).val() == '' || $(this).val() == $(this).attr('placeholder')) {
$(this).val($(this).attr('placeholder'));
$(this).addClass('placeholder');
}
});
// remove placeholders on submit
$('[placeholder]').closest('form').submit(function() {
$(this).find('[placeholder]').each(function() {
if ($(this).val() == $(this).attr('placeholder')) {
$(this).val('');
}
})
});Należy oczywiście sprawdzić czy placeholder jest wspierane przez przeglądarkę.
if (!("placeholder" in document.createElement("input"))) {
odpalPlaceHolder(); // tutaj odpalamy funkcje która obsługuje placeholder
}Można również użyć modernize jeżeli oczywiście używamy już w projekcie.
if(!Modernizr.input.placeholder) {
// custom placeholder code
} select
n_id,
substring(nazwa, '[^\-]*') as nazwa_pre
from nazwy n
where
n_status = 1
order by
nazwa
limit
150Dane:
Adamowice-jezowka
Wynik:
Adamowice
Zablokowanie wyświetlania numeru wersji wordpressa
Dodanie linii kodu np. w wp-config.php
remove_action ('wp_head', 'wp_generator'); Ten post pokazuje, jak wstawić wiele rekordów w MySQL za pomocą jednego zapytania:
insert into osoba_jezyki (imie, jezyk_id) values ('Janek',13),('Marek',11)Wstawianie wielu rekordów w MySQL za pomocą pojedynczego zapytania, jest możliwe, przez oddzielonie przecinkami listę wartości.