Actualización (01/17/08): Este blog fala sobre a entrada de máis bondade Ligazón XSL: http://www.sharepointsecurity.com/blog/sharepoint/sharepoint-2007-development/rewriting-links-in-search-results-xslt.
Descricións e Obxectivo: I had created a simple bar chart to serve as component on a dashboard. I’ll save the details on building charts for another post, pero eu non inventei esa técnica (nin punto de interrogação, para que o asunto). It turned out there was a bug in the chart and while I fixed that, I took the opportunity to convert some labels into hyperlinks that pointed at the underlying list behind the graph. Por exemplo, there is a label with value "Hold". I wanted to turn the label into a hyperlink so that the user could click on it and drill down to the specific entries in the list whose status value is "Hold".
Pasos:
- Use visual studio para intellisense SharePoint-aware.
- Pega XSLT do DVWP en Visual Studio (crear un proxecto en branco, engadir un ficheiro XSL ao proxecto).
- Copie a ligazón que quere empregar para o portapapeis.
- Pegalo no lugar seguro no XSL.
- Convert URL argument separators on the query string from "&" to "&ères;"
- Url-ENCODE argumentos individuais.
- Enrole que dentro dun <a href…> </un>
Exemplo:
Eu teño un URL:
http://[servidor]/[local]/Lists / Open% 20Positions/AllItems.aspx?Ver ={84EEA2F5-121B-40B7-946F-0FA704A1DAA1}&FilterField1 = Recruiter&= FilterValue1 Manteña
Eu convertelo en:
<un href="Lists / Open% 20Positions/AllItems.aspx?Ver =% 7b84EEA2F5-121B-40B7-946F-
0FA704A1DAA1}&ères;FilterField1 = Recruiter&ères;= FilterValue1 Manteña"> Manter: </un>
Eu transformei man o primeiro argumento de:
{84EEA2F5-121B-40B7-946F-0FA704A1DAA1}
para:
%7b84EEA2F5-121B-40B7-946F-0FA704A1DAA1}
(Neste, a clave aberta transfórmase% 7b ea clave de peche transforma a% 7D)
Os segundo e terceiro argumentos’ parámetros ("FilterField1=Recrutador" and "FilterValue1=Manter" respectivamente) non teñen que ser codificadas URL porque non contén ningún carácter inseguros.
Notas:
Esta técnica normalmente debe traballar en calquera lugar que quere inserir un hiperenlace no XSLT onde a hyperlink inclúe parámetros na URL, como:
http://[servidor]/[local]/Lists / Open% 20Positions/AllItems.aspx?Ver ={84EEA2F5-121B-40B7-946F-0FA704A1DAA1}&FilterField1 = Recruiter&= FilterValue1 Manteña
Eu teño a URL en si, accedendo a lista personalizada e filtrado manual na columna de estado (labeled "Recruiter" arriba).
Cristina, that 84EE.. is a GUID that uniquely identifies the list internally. You can get it by pulling up the view in your browser and inspecting the URL of your browser.
where or how do generate this code ’84EEA2F5-121B-40B7-946F-0FA704A1DAA1′
Could be possible to do this …&FilterField1=Recruiter Center &FilterValue1=Hold CE / ASM?
Ou
Do i need to remove the spaces between them?