Txoj kev sai thiab yooj yim: Embed ib hyperlink rau hauv tej ntaub ntawv saib web Tshooj XSLT

HLOOV TSHIAB (01/17/08): No nkag teb chaws hauv blog hais txog ntau hyperlink XSL siab zoo: http://www.sharepointsecurity.com/blog/sharepoint/sharepoint-2007-development/rewriting-links-in-search-results-xslt.

Txheej txheem cej luam thiab lub hom phiaj: Kuv tau tsim ib yooj yim bar daim ntawv kom tswj tivthaiv rau ib dashboard. Kuv yuav txuag kom paub meej txog tsev kab kos rau ib qho, tab sis, kuv tsis tau txua tus txheej txheem (los yog cov lus nug kos, rau qhov teeb meem ntawd). Nws muab tau ib kab nyob rau ntawm daim ntawv thiab thaum kuv tas uas muaj, Kuv muab lub hwj tsam los mus hloov tej daim ntawv lo rau hauv hyperlinks uas taw tes qhia rau lwm daim ntawv qab cov teeb. Piv txwv, muaj ib daim ntawv lo nrog tus nqi "Tuav". Kuv xav mus dhau los ntawm daim ntawv lo ua ib hyperlink kom tus neeg siv yuav tau nyem rau ntawm nws thiab tho coj mus rau kev nkag rau hauv daim ntawv uas tus nqi raws li txoj cai yog "Puag".

Ruam:

  1. Siv kev studio rau sharepoint-paub intellisense.
  2. Luam rau DVWP XSLT rau studio nrig txog kev pom (tsim ib qhov dawb paug project, ntxiv ib cov ntaub ntawv XSL rau peb tes num).
  3. Copy qhov link koj yuav siv tau rau hauv cov ntawv los teev cia.
  4. Paste rau hauv qhov chaw zoo nyob rau lub XSL.
  5. Hloov ua lwm yam URL cav separators rau cov lus nug txoj hlua ntawm"&" mus"&"
  6. Url-encode ib tug neeg lus.
  7. Muab qhwv rau ntawd hauv ib <ib tug href…> </ib tug>

Piv txwv:

Kuv muaj ib tug URL:

http://[neeg rau zaub mov]/[kawm ntawv]/Lists/Open Positions/AllItems.aspx?Pom ={84EEA2F5-121B-40B7-946F-0FA704A1DAA1}&FilterField1 = Recruiter&FilterValue1 = tuav

Kuv yuav hloov rau nws:

     <ib tug href="Lists/Open Positions/AllItems.aspx?Pom = % 7b84EEA2F5-121B-40B7-946F-
0FA704A1DAA1 %7 d&amp;FilterField1 = Recruiter&amp;FilterValue1 = tuav"> Tuav: </ib tug>

Kuv manually transformed thawj sib cav los:

{84EEA2F5-121B-40B7-946F-0FA704A1DAA1}

mus:

%7b84EEA2F5-121B-40B7-946F-0FA704A1DAA1 %7 d

(Nyob rau hauv no, transforms brace qhib rau % 7b thiab kaw brace transforms mus %7 d)

Nqe lus thib ob thiab peb’ tsis ("FilterField1 =Recruiter" thiab "FilterValue1 =Tuav" feem) tsis xav url encoded vim lawv tsis muaj kev tsis zoo kev cim.

Sau ntawv:

Cov txheej txheem no yuav tsum tau feem ntau haujlwm nyob txhua qhov chaw uas koj xav kom ib tug hyperlink embed nyob qhov twg cov hyperlink muab tsis tau rau hauv qhov URL xws li XSLT:

http://[neeg rau zaub mov]/[kawm ntawv]/Lists/Open Positions/AllItems.aspx?Pom ={84EEA2F5-121B-40B7-946F-0FA704A1DAA1}&FilterField1 = Recruiter&FilterValue1 = tuav

Kuv tau txais qhov URL nws tus kheej ntawm tus txheejtxheem ntawm kev cai sau thiab manually filtering rau sab pej xeem Mes Kas (labeled "Recruiter" saum toj).

6 xav txog"Txoj kev sai thiab yooj yim: Embed ib hyperlink rau hauv tej ntaub ntawv saib web Tshooj XSLT

  1. Paul Galvin

    Pang, 84EE ntawd.. yog ib tug GUID uniquely kuas daim ntawv ntxiv hauv lawv. Koj yuav tau txais nws rub rov qab ua li qhov pom nyob rau hauv koj tus browser thiab xyuas(audits) qhov URL ntawm koj tus browser.

    Teb
  2. Cristina Perez Otaiza

    qhov twg los li cas Meskas cov txoj ' 84EEA2F5-121B-40B7-946F-0FA704A1DAA1′

    Yuav tsum tau ua li no …&FilterField1 = Recruiter Center &FilterValue1 = tuav WIC / ASM?

    Los sis
    Kuv puas yuav tshem tau rau tej qhov chaw ntawm lawv?

    Teb
  3. Eric Anderson
    Koj puas muaj tej lub tswv yim rau cov teeb meem uas koj xav kom dhau cov ntaub ntawv los ntawm ib daim ntawv teev SharePoint li cov FilterValue1 nqi, thiab qhov twg cov nqi no rau sab yuav muaj ampersands? (Kuv twb sim txoj kev encode/khiav tawm ntawm tus nqi heev heev, tab sis, kuv tsis muaj hmoov nyob rau kis zoo heev.)
    Teb
  4. Costas Tsaklas
    Kuv pom cov piv txwv hauv daim ntawv thov pab rooj hauv lub xib fab 40'. Qhov teeb meem kuv tsis paub li cas nws twb generated thiab yog vim li cas kuv tab tom nrhiav rau pem hauv ntej rau cov kauj ruam yuav ua li cas ua
    Teb
  5. Paul Galvin
    Kuv muaj tsis txua, tab sis nws tsis yog coj txawv txawv tsis yooj yim npaum li cas nws tseem mus nrhiav tau.
    Kuv tuaj hla ib tug piv txwv tej qhov chaw no kuv xav tias ib tug los ntawm qhov "fab 40" templates.
    Nws cov ntaub ntawv saib web qhov nrog XSLT generates ib lub teeb. Kuv mas nws yeej npaj ua ib qho rau nws.
    Teb
  6. Costas Tsaklas
    Kuv tab tom nrhiav rau pem hauv ntej kom tus ncej txog kev npaj muaj ib daim ntawv. Kuv muaj tau nrhiav cov ntaub ntawv sau cov kab kos npe raws li yuav ua li cas (e.g qhib, yog muaj teeb meem raug kaw, feem pua thiab lwm yam.) thiab kuv nrhiav tsis tau ib yam. Tsaug
    Teb

sau ntawv cia

Koj email chaw nyob yuav tsis muab luam tawm. Search cim *