Txhawm rau qhia cov ntaub ntawv los ntawm ntau qhov chaw ntawm ib nplooj ntawv, cov nplooj ntawv HTML-splitting mechanism feem ntau siv. Hauv qab no yog cov lus piav qhia ntawm hom lus tsim rau kev nkag ua ke.
Tsim nyog
Kev paub yooj yim ntawm HTML
Cov Lus Qhia
Kauj ruam 1
HyperText Markup Language (HTML) muab ob hom thav ntawv. Ntab yog yoog dua thiab yooj yim dua los ntxig rau hauv nplooj ntawv uas twb muaj lawm. Feem ntau, kev tsim kho piav qhia txog lub qhov rais thav duab siv ntab ntab zoo li qhov no: Ntawm no, nplooj ntawv tseem ceeb ntawm tus xaib tam sim no tau hais tseg raws li cov ntaub ntawv siv rau tus ncej no (src attribute). Nws yuav qhib rau hauv 400 x 300 pixel thav duab, raws li teev hauv qhov dav thiab qhov siab tus cwj pwm. Koj tseem tuaj yeem hais qhia nplooj ntawv ntawm koj lub xaib hauv src attribute. Hauv qhov no, nws txaus los sau qhia qhov chaw nyob sib txheeb (uas yog, qhov chaw nyob txheeb ze rau nplooj ntawv uas tus ncej nkag): Hauv qhov qauv no, qhov dav thiab qhov siab ntawm tus ncej tsis tau teev tseg, tab sis muaj tus id cwj pwm-neeg qhia kom paub. Siv nws, koj tuaj yeem siv CSS () los teeb tsa qhov xav tau qhov ntev rau tus ncej no:
#frameOne {qhov dav: 700px; qhov siab: 200px;}
Kauj ruam 2
Lwm hom ntawm thav ntawv - "classic" - yuav tsum muaj ib nplooj ntawv cais, uas yuav muaj cov lus piav qhia ntawm hom ncej. Cov ntas lawv tus kheej yuav nyob ntawm nyias nplooj ntawv, tej zaum txawm nyob rau lwm qhov chaw. Cov HTML code rau xws li cov ncej ntim nplooj ntawv yuav zoo li no:
Tsis tas yuav muaj ib qho… thiab… yuav tsum thaiv cov nplooj ntawv rau ib txwm. Hauv qhov ua piv txwv no, lub thawv qhib lub thawv muaj cov kab ntaus cim, uas txhais tau tias qhov chaw ntawm nplooj ntawv yuav tsum muab cais tawm ntawm sab thiab yuav muab rau thawj kab xwm. Yog tias koj hloov cov kab nrog cols, ces qhov faib yuav yog kab rov tav. Tus nqi ntawm cov cwj pwm no "*, *" qhia tau hais tias qhov sib faib ua feem sib npaug - 50% txhua tus. Yog tias koj qhia kom meej, piv txwv li, "20%, *", tom qab ntawd tsuas yog 20% yuav muab rau thawj thav duab, thiab qhov chaw seem mus rau lub koob thib ob. Tus neeg siv tuaj yeem hloov cov kev tiv no los ntawm kev rub lub laj kab ntawm cov thav ntawv nrog tus nas, tab sis nws yog qhov ua tau kom lov qhov kev ua no. Ua li no, ntxiv cov noresize cwj pwm rau cov cim npe ntawm tus ncej tshwj xeeb. Koj tseem tuaj yeem hais qhia qhov loj me ntawm kab rov tav thiab kab rov tav los ntawm tus ncej uas nyob ib sab (cov kab npoo thiab npoo ntawm cov cwj pwm): Nws yog qhov tsim nyog los teeb tsa cov cai ntawm kev coj ua rau cov scrollbars ntawm txhua tus ncej cais. Rau qhov no, kev ntaus nqi scrolling yog siv, uas tuaj yeem muaj ib ntawm peb qhov kev txiav txim siab ua ntej. Yog tias tau teev tseg, cov ntawv pov tseg yuav tshwm thaum cov ntsiab lus ntawm lub thav duab tsis haum hauv nws cov ciam teb. Yog tias "yog" - cov kab txaij yuav nyob rau txhua lub sijhawm, tsis hais qhov xav tau ntawm lawv. Yog tias "tsis muaj" - nws yuav txhais hais tias tsis pom cov kab ntawv rau cov ncej no.
Kauj ruam 3
Raws li cov ntaub ntawv tau muab rau hauv ob kauj ruam dhau los, koj yuav tsum tsim cov cai html uas tsim nyog dua los daws koj qhov teeb meem. Tom qab ntawd, txhua qhov uas tseem yuav yog nws ntxig rau nws qhov chaw ntawm nplooj ntawv. Txhawm rau ua qhov no, koj tuaj yeem siv cov nplooj ntawv khoos phis ntawm koj lub xaib tswj kev tswj hwm - qhib cov nplooj ntawv xav tau hauv nws, hloov mus rau html code hloov hom thiab muab koj cov lej cim rau hauv qhov chaw xav tau ntawm nplooj ntawv Hloov lwm txoj kev, koj tuaj yeem rub tawm nplooj ntawv cov ntaub ntawv code los ntawm lub hosting tswj cov ntaub ntawv lossis cov txheej txheem tswj hwm cov ntsiab lus, qhib nws rau hauv kab lus phau ntawv thiab muab cov code rau nws. Thiab tom qab ntawd tib txoj kev upload cov hloov code rov qab rau lub server.