?
Solved

SharePoint 2007 - Show Created Date on top when selected

Posted on 2013-06-04
2
Medium Priority
?
286 Views
Last Modified: 2013-06-10
When I select the filter of 'Created' say 1/1/2013

How do I make 1/1/2013 (selected date) to appear in a content editor above in the dispform.aspx view item

Thanks.
0
Comment
Question by:sharepoint2013
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 44

Accepted Solution

by:
Rainer Jeschor earned 2000 total points
ID: 39223846
Hi,
this code works:
<script type="text/javascript" src="/_layouts/jslib/jquery-1.8.3.min.js"></script>
<script type="text/javascript">
jQuery(document).ready(function () {
var defaultOutput = '';
var requestUri = window.location.search.substring(1);
var rawUrl = decodeURIComponent(requestUri);
var urlParams = new Array();
var urlParam = rawUrl.split("&");
for (var i=0; i<urlParam.length; i++) {
var currParam = urlParam[i].split("=");
var key = currParam[0];
var val = currParam[1];
urlParams[key] = val;
}
//FilterField1=Created&FilterValue1=06%2F05%2F2013
if (urlParams['FilterField1'] &&  urlParams['FilterValue1'])
{
	if (urlParams['FilterField1'] == 'Created')
	{
		defaultOutput = decodeURIComponent(urlParams['FilterValue1']);
	}
}
$("#outputdiv").text(defaultOutput);
});
</script>
<div id="outputdiv">Replace me</div>

Open in new window


HTH
Rainer
0
 

Author Closing Comment

by:sharepoint2013
ID: 39235871
Thanks!!
0

Featured Post

Why Off-Site Backups Are The Only Way To Go

You are probably backing up your data—but how and where? Ransomware is on the rise and there are variants that specifically target backups. Read on to discover why off-site is the way to go.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I thought I'd write this up for anyone who has a request to create an anonymous whistle-blower-type submission form created using SharePoint 2010 (this would probably work the same for 2013). It's not 100% fool-proof but it's as close as you can get…
This article discusses how to create an extensible mechanism for linked drop downs.
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
Suggested Courses

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question