<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Showing Query String parameters in a page in SharePoint</title>
	<atom:link href="http://www.novolocus.com/2008/03/05/showing-query-string-parameters-in-a-page-in-sharepoint/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.novolocus.com/2008/03/05/showing-query-string-parameters-in-a-page-in-sharepoint/</link>
	<description>Whatever I'm working on, really...</description>
	<lastBuildDate>Fri,  5 Mar 2010 23:09:37 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.1</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Maaike</title>
		<link>http://www.novolocus.com/2008/03/05/showing-query-string-parameters-in-a-page-in-sharepoint/comment-page-1/#comment-5846</link>
		<dc:creator>Maaike</dc:creator>
		<pubDate>Thu, 13 Aug 2009 21:12:03 +0000</pubDate>
		<guid isPermaLink="false">http://www.novolocus.com/2008/03/05/showing-query-string-parameters-in-a-page-in-sharepoint/#comment-5846</guid>
		<description>+ I want to use the same parameter from the QueryString in one page for both the titlebar and the listview webpart.</description>
		<content:encoded><![CDATA[<p>+ I want to use the same parameter from the QueryString in one page for both the titlebar and the listview webpart.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Maaike</title>
		<link>http://www.novolocus.com/2008/03/05/showing-query-string-parameters-in-a-page-in-sharepoint/comment-page-1/#comment-5845</link>
		<dc:creator>Maaike</dc:creator>
		<pubDate>Thu, 13 Aug 2009 21:08:59 +0000</pubDate>
		<guid isPermaLink="false">http://www.novolocus.com/2008/03/05/showing-query-string-parameters-in-a-page-in-sharepoint/#comment-5845</guid>
		<description>Being a newbie; can someone show me with an example where to place this code when you want to show the parameter in the Titlebar Webpart? And is it also possible to use this paramater to filter a Listview webpart (Projecttasks)? Can you give an example of the code including the webpart, please? Thanks a lot!</description>
		<content:encoded><![CDATA[<p>Being a newbie; can someone show me with an example where to place this code when you want to show the parameter in the Titlebar Webpart? And is it also possible to use this paramater to filter a Listview webpart (Projecttasks)? Can you give an example of the code including the webpart, please? Thanks a lot!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Andy</title>
		<link>http://www.novolocus.com/2008/03/05/showing-query-string-parameters-in-a-page-in-sharepoint/comment-page-1/#comment-5716</link>
		<dc:creator>Andy</dc:creator>
		<pubDate>Thu, 25 Jun 2009 15:48:39 +0000</pubDate>
		<guid isPermaLink="false">http://www.novolocus.com/2008/03/05/showing-query-string-parameters-in-a-page-in-sharepoint/#comment-5716</guid>
		<description>Nice! Thanks, good tip!</description>
		<content:encoded><![CDATA[<p>Nice! Thanks, good tip!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: AT</title>
		<link>http://www.novolocus.com/2008/03/05/showing-query-string-parameters-in-a-page-in-sharepoint/comment-page-1/#comment-5715</link>
		<dc:creator>AT</dc:creator>
		<pubDate>Wed, 24 Jun 2009 17:32:14 +0000</pubDate>
		<guid isPermaLink="false">http://www.novolocus.com/2008/03/05/showing-query-string-parameters-in-a-page-in-sharepoint/#comment-5715</guid>
		<description>Hi all,
Here is a simple way of doing it. Just place this javascript code where ever you want to display the querystring variables. (of course change var1 and var2 with your values)


//First we must call the EnsureSetup method
JSRequest.EnsureSetup(); 
//Get a query string parameter
var var1= JSRequest.QueryString[&quot;var1&quot;];
var var2 = JSRequest.QueryString[&quot;var2&quot;];
document.write( var1+ &#039;&#039;);
document.write(var2);



The JSRequest class is a JavaScript object that lives on all SharePoint Pages, and allows us to simply and quickly get query string parameters using JavaScript.

It has 3 fields: QueryString, FileName, and PathName.

QueryString - is an array of key\value pairs representing the current query string parameters.
FileName - is a string containing the current name of the current page.
PathName - is the server relative path of the current page.</description>
		<content:encoded><![CDATA[<p>Hi all,<br />
Here is a simple way of doing it. Just place this javascript code where ever you want to display the querystring variables. (of course change var1 and var2 with your values)</p>
<p>//First we must call the EnsureSetup method<br />
JSRequest.EnsureSetup();<br />
//Get a query string parameter<br />
var var1= JSRequest.QueryString["var1"];<br />
var var2 = JSRequest.QueryString["var2"];<br />
document.write( var1+ &#8221;);<br />
document.write(var2);</p>
<p>The JSRequest class is a JavaScript object that lives on all SharePoint Pages, and allows us to simply and quickly get query string parameters using JavaScript.</p>
<p>It has 3 fields: QueryString, FileName, and PathName.</p>
<p>QueryString &#8211; is an array of key\value pairs representing the current query string parameters.<br />
FileName &#8211; is a string containing the current name of the current page.<br />
PathName &#8211; is the server relative path of the current page.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Andy</title>
		<link>http://www.novolocus.com/2008/03/05/showing-query-string-parameters-in-a-page-in-sharepoint/comment-page-1/#comment-5610</link>
		<dc:creator>Andy</dc:creator>
		<pubDate>Sun, 24 May 2009 08:51:57 +0000</pubDate>
		<guid isPermaLink="false">http://www.novolocus.com/2008/03/05/showing-query-string-parameters-in-a-page-in-sharepoint/#comment-5610</guid>
		<description>No, what you&#039;ve done for what you describe is fine - but it isn&#039;t what I&#039;ve done in this example.

if your query string is &quot;?letter=A&amp;list=123456-1234-1234-1234&quot;

&quot;location.search&quot; would return &quot;?letter=A&amp;list=123456-1234-1234-1234&quot;

&quot;locaton.search.substring(1)&quot; would return &quot;letter=A&amp;list=123456-1234-1234-1234&quot; (i.e. without the leading &quot;?&quot;)

&quot;getQueryParam(&#039;letter&#039;)&quot; would return &quot;A&quot;

As you&#039;re needing to pass the entire query string, location.search.substring(1) is fine - but all I wanted was a single value from the query string.

You migt also find this interesting:
http://www.novolocus.com/2009/05/15/get-query-string-parameters-with-regular-expressions-in-javascript/

(Same function really, but I keep having to tell people to do it this way if you only want one or two query string parameters)</description>
		<content:encoded><![CDATA[<p>No, what you&#8217;ve done for what you describe is fine &#8211; but it isn&#8217;t what I&#8217;ve done in this example.</p>
<p>if your query string is &#8220;?letter=A&#038;list=123456-1234-1234-1234&#8243;</p>
<p>&#8220;location.search&#8221; would return &#8220;?letter=A&#038;list=123456-1234-1234-1234&#8243;</p>
<p>&#8220;locaton.search.substring(1)&#8221; would return &#8220;letter=A&#038;list=123456-1234-1234-1234&#8243; (i.e. without the leading &#8220;?&#8221;)</p>
<p>&#8220;getQueryParam(&#8216;letter&#8217;)&#8221; would return &#8220;A&#8221;</p>
<p>As you&#8217;re needing to pass the entire query string, location.search.substring(1) is fine &#8211; but all I wanted was a single value from the query string.</p>
<p>You migt also find this interesting:<br />
<a href="http://www.novolocus.com/2009/05/15/get-query-string-parameters-with-regular-expressions-in-javascript/" rel="nofollow">http://www.novolocus.com/2009/05/15/get-query-string-parameters-with-regular-expressions-in-javascript/</a></p>
<p>(Same function really, but I keep having to tell people to do it this way if you only want one or two query string parameters)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: CMac</title>
		<link>http://www.novolocus.com/2008/03/05/showing-query-string-parameters-in-a-page-in-sharepoint/comment-page-1/#comment-5603</link>
		<dc:creator>CMac</dc:creator>
		<pubDate>Fri, 22 May 2009 22:03:33 +0000</pubDate>
		<guid isPermaLink="false">http://www.novolocus.com/2008/03/05/showing-query-string-parameters-in-a-page-in-sharepoint/#comment-5603</guid>
		<description>Couldn&#039;t you simply use some Javascript; like &quot;location.search.substring(1);&quot; ?

I had a request to pass parameters to the url of an iFrame embedded in my layout page. I had to accept whatever parameters were sent so I needed to grab the entire query string and append it. 

This worked fine for me; though I&#039;m a newbie and now you have me second guessing myself? :)</description>
		<content:encoded><![CDATA[<p>Couldn&#8217;t you simply use some Javascript; like &#8220;location.search.substring(1);&#8221; ?</p>
<p>I had a request to pass parameters to the url of an iFrame embedded in my layout page. I had to accept whatever parameters were sent so I needed to grab the entire query string and append it. </p>
<p>This worked fine for me; though I&#8217;m a newbie and now you have me second guessing myself? <img src='http://www.novolocus.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
	</item>
	<item>
		<title>By: novolocus.com &#187; When will a page run inline code in SharePoint</title>
		<link>http://www.novolocus.com/2008/03/05/showing-query-string-parameters-in-a-page-in-sharepoint/comment-page-1/#comment-1860</link>
		<dc:creator>novolocus.com &#187; When will a page run inline code in SharePoint</dc:creator>
		<pubDate>Mon, 09 Jun 2008 13:33:14 +0000</pubDate>
		<guid isPermaLink="false">http://www.novolocus.com/2008/03/05/showing-query-string-parameters-in-a-page-in-sharepoint/#comment-1860</guid>
		<description>[...] I&#8217;ve detailed my attempts to show a query string parameter in a page. This should be a simple enough to do as inline code, but as my previous attempts recorded, when I [...]</description>
		<content:encoded><![CDATA[<p>[...] I&#8217;ve detailed my attempts to show a query string parameter in a page. This should be a simple enough to do as inline code, but as my previous attempts recorded, when I [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: novolocus.com &#187; Using a Query String parameter in the Search Results Web Part</title>
		<link>http://www.novolocus.com/2008/03/05/showing-query-string-parameters-in-a-page-in-sharepoint/comment-page-1/#comment-1630</link>
		<dc:creator>novolocus.com &#187; Using a Query String parameter in the Search Results Web Part</dc:creator>
		<pubDate>Wed, 14 May 2008 16:09:10 +0000</pubDate>
		<guid isPermaLink="false">http://www.novolocus.com/2008/03/05/showing-query-string-parameters-in-a-page-in-sharepoint/#comment-1630</guid>
		<description>[...] he seems to have thought that to get the query string parameter he&#8217;d have to use Javascript - something like this. However, I found myself thinking of the Data View web part - it allows parameters based on the [...]</description>
		<content:encoded><![CDATA[<p>[...] he seems to have thought that to get the query string parameter he&#8217;d have to use Javascript &#8211; something like this. However, I found myself thinking of the Data View web part &#8211; it allows parameters based on the [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Greg</title>
		<link>http://www.novolocus.com/2008/03/05/showing-query-string-parameters-in-a-page-in-sharepoint/comment-page-1/#comment-1434</link>
		<dc:creator>Greg</dc:creator>
		<pubDate>Wed, 09 Apr 2008 21:00:57 +0000</pubDate>
		<guid isPermaLink="false">http://www.novolocus.com/2008/03/05/showing-query-string-parameters-in-a-page-in-sharepoint/#comment-1434</guid>
		<description>Nice solution, jst what I needed!</description>
		<content:encoded><![CDATA[<p>Nice solution, jst what I needed!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: novolocus.com &#187; Filtering ListView Web Parts and Spurious Error Messages</title>
		<link>http://www.novolocus.com/2008/03/05/showing-query-string-parameters-in-a-page-in-sharepoint/comment-page-1/#comment-1346</link>
		<dc:creator>novolocus.com &#187; Filtering ListView Web Parts and Spurious Error Messages</dc:creator>
		<pubDate>Fri, 07 Mar 2008 12:51:17 +0000</pubDate>
		<guid isPermaLink="false">http://www.novolocus.com/2008/03/05/showing-query-string-parameters-in-a-page-in-sharepoint/#comment-1346</guid>
		<description>[...] I set up a page with a ListView web part and a filter web part. The filter web part would supply the letter we wanted to filter by to the ListView, which would then filter on the first letter column. As a side note, I started by using the Choice Filter web part, which isn&#8217;t just a drop-down list but is rather uglier - so in the end I just used a QueryString Filter web part and built my own navigation for the filter. This was why I ended up looking at how to show query string parameters within a page. [...]</description>
		<content:encoded><![CDATA[<p>[...] I set up a page with a ListView web part and a filter web part. The filter web part would supply the letter we wanted to filter by to the ListView, which would then filter on the first letter column. As a side note, I started by using the Choice Filter web part, which isn&#8217;t just a drop-down list but is rather uglier &#8211; so in the end I just used a QueryString Filter web part and built my own navigation for the filter. This was why I ended up looking at how to show query string parameters within a page. [...]</p>
]]></content:encoded>
	</item>
</channel>
</rss>
